theme: Fix issues.
This commit is contained in:
parent
d5dd1ec6d6
commit
35851d92eb
6
neofetch
6
neofetch
|
@ -1614,8 +1614,8 @@ get_style() {
|
||||||
kde_config_file="${kde_config_dir}/kdeglobals"
|
kde_config_file="${kde_config_dir}/kdeglobals"
|
||||||
|
|
||||||
kde_theme="$(grep "^${kde}" "$kde_config_file")"
|
kde_theme="$(grep "^${kde}" "$kde_config_file")"
|
||||||
kde_theme="${theme/${kde}*=}"
|
kde_theme="${kde_theme/${kde}*=}"
|
||||||
kde_theme="$(uppercase "$theme")"
|
kde_theme="$(uppercase "$kde_theme") [KDE], "
|
||||||
else
|
else
|
||||||
err "Theme: KDE config files not found, skipping."
|
err "Theme: KDE config files not found, skipping."
|
||||||
fi
|
fi
|
||||||
|
@ -1697,7 +1697,6 @@ get_style() {
|
||||||
# Toggle visibility of GTK themes.
|
# Toggle visibility of GTK themes.
|
||||||
[[ "$gtk2" == "off" ]] && unset gtk2_theme
|
[[ "$gtk2" == "off" ]] && unset gtk2_theme
|
||||||
[[ "$gtk3" == "off" ]] && unset gtk3_theme
|
[[ "$gtk3" == "off" ]] && unset gtk3_theme
|
||||||
[[ "$kde" == "off" ]] && unset kde_theme
|
|
||||||
|
|
||||||
# Format the string based on which themes exist.
|
# Format the string based on which themes exist.
|
||||||
if [[ "$gtk2_theme" && "$gtk2_theme" == "$gtk3_theme" ]]; then
|
if [[ "$gtk2_theme" && "$gtk2_theme" == "$gtk3_theme" ]]; then
|
||||||
|
@ -1715,6 +1714,7 @@ get_style() {
|
||||||
|
|
||||||
# Final string.
|
# Final string.
|
||||||
theme="${kde_theme}${gtk2_theme}${gtk3_theme}"
|
theme="${kde_theme}${gtk2_theme}${gtk3_theme}"
|
||||||
|
theme="${theme%, }"
|
||||||
|
|
||||||
# Make the output shorter by removing "[GTKX]" from the string.
|
# Make the output shorter by removing "[GTKX]" from the string.
|
||||||
if [[ "$gtk_shorthand" == "on" ]]; then
|
if [[ "$gtk_shorthand" == "on" ]]; then
|
||||||
|
|
Reference in New Issue