diff --git a/modules/xfce/hm.nix b/modules/xfce/hm.nix index 0790a80d..0eeae1b7 100644 --- a/modules/xfce/hm.nix +++ b/modules/xfce/hm.nix @@ -1,19 +1,21 @@ -{ config, lib, ... }: - -{ +{ mkTarget, ... }: +mkTarget { + name = "xfce"; + humanName = "Xfce"; # Disabled by default due to https://github.com/nix-community/stylix/issues/180 - options.stylix.targets.xfce.enable = - config.lib.stylix.mkEnableTarget "Xfce" false; + autoEnable = false; - config = lib.mkIf (config.stylix.enable && config.stylix.targets.xfce.enable) { - xfconf.settings = with config.stylix.fonts; { - xfwm4 = { - "general/title_font" = "${sansSerif.name} ${toString sizes.desktop}"; - }; - xsettings = { - "Gtk/FontName" = "${sansSerif.name} ${toString sizes.applications}"; - "Gtk/MonospaceFontName" = "${monospace.name} ${toString sizes.applications}"; + configElements = + { fonts }: + { + xfconf.settings = with fonts; { + xfwm4 = { + "general/title_font" = "${sansSerif.name} ${toString sizes.desktop}"; + }; + xsettings = { + "Gtk/FontName" = "${sansSerif.name} ${toString sizes.applications}"; + "Gtk/MonospaceFontName" = "${monospace.name} ${toString sizes.applications}"; + }; }; }; - }; }