I encountered difficulties applying the LAVA-cyan GTK theme to my Garuda Hyprland system. Despite attempts to modify GTK configuration files , the desired theme changes were not reflected in GTK applications.
Steps Taken:
Installed the LAVA-cyan theme into the ~/.themes directory.
Utilized lxappearance to select the LAVA-cyan theme, resulting in theme changes within lxappearance itself but not in other GTK applications.
Manually edited .gtkrc and configs in ~/.config
Desperately edited GTK configuration files in /usr/share/, and /root/.config/.
Modified the apply-settings script to prevent theme reloads on reboot.
So i need help in applying a gtk theme to my overall system
Random advice on the web?
Undo these changes and don’t touch those, unless you know what you are doing.
Gnome does not like users to change their theming. If a user wants to disobey them, they need to work and make some effort reading and testing.
A usual workaround is per application changing the gtk theme, adding the theme variable to the Exec command of the application’s .desktop file.
Example:
I’m honestly not sure why the script has hard-coded values in it like that; I think it is supposed to be just variables, and it pulls from whatever you have set in ~/.config/gtk-3.0/settings.ini like this:
#!/bin/sh
# usage: import-gsettings
config="${XDG_CONFIG_HOME:-$HOME/.config}/gtk-3.0/settings.ini"
if [ ! -f "$config" ]; then exit 1; fi
gnome_schema="org.gnome.desktop.interface"
gtk_theme="$(grep 'gtk-theme-name' "$config" | sed 's/.*\s*=\s*//')"
icon_theme="$(grep 'gtk-icon-theme-name' "$config" | sed 's/.*\s*=\s*//')"
cursor_theme="$(grep 'gtk-cursor-theme-name' "$config" | sed 's/.*\s*=\s*//')"
font_name="$(grep 'gtk-font-name' "$config" | sed 's/.*\s*=\s*//')"
gsettings set "$gnome_schema" gtk-theme "$gtk_theme"
gsettings set "$gnome_schema" icon-theme "$icon_theme"
gsettings set "$gnome_schema" cursor-theme "$cursor_theme"
gsettings set "$gnome_schema" font-name "$font_name"
See also this wiki note here (from Sway, but still relevant because GTK wackiness affects Hyprland in a similar way):
If you want to set the theme globally, an easy way to do that is to set GTK_THEME directly in your Hyprland config as described here: Environment variables – Hyprland Wiki. If the theme is called " LAVA-Cyan" you would set it in your config like this:
env = GTK_THEME,LAVA-Cyan
You may need to log out/log back in after that one, I’m not sure.
I hope that helps, welcome to the community @Lazydev0.