This commit is contained in:
Vince 2021-05-13 19:36:29 +08:00
parent 41f1b9dba5
commit 902e02ec62

View file

@ -413,7 +413,7 @@ install_gdm_theme() {
if check_theme_file "${COMMON_CSS_FILE}"; then # CSS-based theme
install_beggy_blur
install_shelly "${colors[0]}" "${opacities[0]}" "${alts[0]}" "${themes[0]}" "${icon}" "${WHITESUR_GS_DIR}"
sed ${SED_OPT} "s|assets|${WHITESUR_GS_DIR}/assets|" "${WHITESUR_GS_DIR}/gnome-shell.css"
sed $SED_OPT "s|assets|${WHITESUR_GS_DIR}/assets|" "${WHITESUR_GS_DIR}/gnome-shell.css"
if check_theme_file "${UBUNTU_CSS_FILE}"; then
TARGET="${UBUNTU_CSS_FILE}"
@ -430,7 +430,7 @@ install_gdm_theme() {
else # GR-based theme
install_beggy_blur
install_shelly "${colors[0]}" "${opacities[0]}" "${alts[0]}" "${themes[0]}" "${icon}" "${WHITESUR_TMP_DIR}/shelly"
sed ${SED_OPT} "s|assets|resource:///org/gnome/shell/theme/assets|" "${WHITESUR_TMP_DIR}/shelly/gnome-shell.css"
sed $SED_OPT "s|assets|resource:///org/gnome/shell/theme/assets|" "${WHITESUR_TMP_DIR}/shelly/gnome-shell.css"
if check_theme_file "$POP_OS_GR_FILE"; then
TARGET="${POP_OS_GR_FILE}"
@ -554,18 +554,18 @@ gtk_base() {
cp -rf "${THEME_SRC_DIR}/sass/_gtk-base.scss" "${THEME_SRC_DIR}/sass/_gtk-base-temp.scss"
# Theme base options
sed ${SED_OPT} "/\$laptop/s/false/${compact}/" "${THEME_SRC_DIR}/sass/_gtk-base-temp.scss"
sed $SED_OPT "/\$laptop/s/false/${compact}/" "${THEME_SRC_DIR}/sass/_gtk-base-temp.scss"
if [[ "${opacity}" == 'solid' ]]; then
sed ${SED_OPT} "/\$trans/s/true/false/" "${THEME_SRC_DIR}/sass/_gtk-base-temp.scss"
sed $SED_OPT "/\$trans/s/true/false/" "${THEME_SRC_DIR}/sass/_gtk-base-temp.scss"
fi
if [[ "${color}" == 'light' && ${opacity} == 'solid' ]]; then
sed ${SED_OPT} "/\$black/s/false/true/" "${THEME_SRC_DIR}/sass/_gtk-base-temp.scss"
sed $SED_OPT "/\$black/s/false/true/" "${THEME_SRC_DIR}/sass/_gtk-base-temp.scss"
fi
if [[ "${theme}" != '' ]]; then
sed ${SED_OPT} "/\$theme/s/default/${theme}/" "${THEME_SRC_DIR}/sass/_gtk-base-temp.scss"
sed $SED_OPT "/\$theme/s/default/${theme}/" "${THEME_SRC_DIR}/sass/_gtk-base-temp.scss"
fi
}
@ -580,37 +580,37 @@ customize_theme() {
# Change gnome-shell panel transparency
if [[ "${panel_opacity}" != 'default' ]]; then
prompt -w "Changing panel transparency ..."
sed ${SED_OPT} "/\$panel_opacity/s/0.15/0.${panel_opacity}/" "${THEME_SRC_DIR}/sass/_theme-options-temp.scss"
sed $SED_OPT "/\$panel_opacity/s/0.15/0.${panel_opacity}/" "${THEME_SRC_DIR}/sass/_theme-options-temp.scss"
fi
# Change gnome-shell show apps button style
if [[ "${showapps_normal}" == 'true' ]]; then
prompt -w "Changing gnome-shell show apps button style ..."
sed ${SED_OPT} "/\$showapps_button/s/bigsur/normal/" "${THEME_SRC_DIR}/sass/_theme-options-temp.scss"
sed $SED_OPT "/\$showapps_button/s/bigsur/normal/" "${THEME_SRC_DIR}/sass/_theme-options-temp.scss"
fi
# Change Nautilus sidarbar size
if [[ "${sidebar_size}" != 'default' ]]; then
prompt -w "Changing Nautilus sidebar size ..."
sed ${SED_OPT} "/\$sidebar_size/s/200px/${sidebar_size}px/" "${THEME_SRC_DIR}/sass/_theme-options-temp.scss"
sed $SED_OPT "/\$sidebar_size/s/200px/${sidebar_size}px/" "${THEME_SRC_DIR}/sass/_theme-options-temp.scss"
fi
# Change Nautilus style
if [[ "${nautilus_style}" != 'stable' ]]; then
prompt -w "Changing Nautilus style ..."
sed ${SED_OPT} "/\$nautilus_style/s/stable/${nautilus_style}/" "${THEME_SRC_DIR}/sass/_theme-options-temp.scss"
sed $SED_OPT "/\$nautilus_style/s/stable/${nautilus_style}/" "${THEME_SRC_DIR}/sass/_theme-options-temp.scss"
fi
# Change Nautilus titlebutton placement style
if [[ "${right_placement}" == 'true' ]]; then
prompt -w "Changing Nautilus titlebutton placement style ..."
sed ${SED_OPT} "/\$placement/s/left/right/" "${THEME_SRC_DIR}/sass/_theme-options-temp.scss"
sed $SED_OPT "/\$placement/s/left/right/" "${THEME_SRC_DIR}/sass/_theme-options-temp.scss"
fi
# Change maximized window radius
if [[ "${max_round}" == 'true' ]]; then
prompt -w "Changing maximized window style ..."
sed ${SED_OPT} "/\$max_window_style/s/square/round/" "${THEME_SRC_DIR}/sass/_theme-options-temp.scss"
sed $SED_OPT "/\$max_window_style/s/square/round/" "${THEME_SRC_DIR}/sass/_theme-options-temp.scss"
fi
}