Closed D3vil0p3r closed 8 months ago
You should use gtk.theme.package
. Also this is related to how home-manager works, which is less relevant here.
You should use
gtk.theme.package
. Also this is related to how home-manager works, which is less relevant here.
Is there a way to set GTK themes with no home-manager?
Is there a way to set GTK themes with no home-manager?
A forced but not recommended method is to use GTK_THEME
. You can also try adding in /etc/gtk-3.0/settings.ini:
[Settings]
gtk-theme-name = <Your theme>
But I'm not sure if that works.
Thank you @Aleksanaa . What I'm noting is is that, since I'm using Thunar (XFCE default one) as File Manager, when I configure GTK Graphite theme as:
{ pkgs, nixpkgs, home-manager, username, ... }:
{
home-manager.users.${username} = { pkgs, ...}: {
home.packages = with pkgs; [
bibata-cursors
];
gtk = {
enable = true;
gtk3.extraConfig.gtk-decoration-layout = "menu:";
cursorTheme.name = "Bibata-Modern-Ice";
iconTheme.package = pkgs.tela-circle-icon-theme.override {
colorVariants = [ "black" ];
};
iconTheme.name = "Tela-circle-dark";
theme.package = pkgs.graphite-gtk-theme.override {
tweaks = [ "rimless" ];
};
theme.name = "Graphite-Dark";
};
};
}
Thunar window appears like:
While, if I use Nautilus (GNOME default File Manager) in my NixOS, it correctly is shown as:
Thunar Graphite theme should appear like the following one I have in my Arch Linux VM:
Why Thunar seems to not apply the Graphite theme in NixOS?
I'm not sure. Have you restarted your desktop environment (like logout and login again)? Thunar theming does work for me, but I'm not using xfce4.
Yes I restarted. I noted it applies correctly on Thunar if I am on GNOME (as shown in the images above), but not if I am in XFCE... Maybe should I use xfconf settings? Is it possible to deploy by .nix file with home-manager the following xfconf settings? Maybe they could solve the issue in XFCE:
xfconf-query -c xsettings -p /Net/ThemeName -s "$theme_name"
xfconf-query -c xsettings -p /Net/IconThemeName -s "$icon_theme"
xfconf-query -c xsettings -p /Gtk/CursorThemeName -s "$cursor_theme"
xfconf-query -c xfwm4 -p /general/theme -s "Everblush-xfwm"
# Iterate through the monitors and set the wallpaper
for x in $(xfconf-query -c xfce4-desktop -lv | grep last-image | awk '{print $1}'); do xfconf-query -c xfce4-desktop -p $x -s $background_theme; done
Yes, xfconf.settings
in home-manager.
I have noticed in XFCE that the selected theme in Appearance is not correctly applied if xsettingsd
is running. In this case the theme specified in the xsettingsd
configuration is applied.
In my setup I use xsettingsd
to configure simple desktops or window managers that does not have a specific tool for this purpose.
After disabling xsettingsd
, theme selecting in XFCE works as expected, and the Graphite theme can be applied successfully.
Yes, you are correct. I applied xfconf.settings
expression to apply Graphite.
Describe the bug
I'm using flakes to deploy a configuration in NixOS consisting of XFCE as desktop environment and Graphite as theme.
The configuration can be found in https://github.com/Athena-OS/athena-nix
and the configuration can be deployed by:
The
xfce
configuration should install also Graphite Theme as specified here but after the deployment, Graphite Theme is not applied.Steps To Reproduce
Steps to reproduce the behavior:
sudo nixos-rebuild switch --flake 'github:Athena-OS/athena-nix#xfce'
Expected behavior
Theme applied correctly.
Screenshots
If applicable, add screenshots to help explain your problem.
Additional context
Add any other context about the problem here.
Notify maintainers
@romildo
Metadata
Please run
nix-shell -p nix-info --run "nix-info -m"
and paste the result.Add a :+1: reaction to issues you find important.