From 9e7af86826c7f6e5ce8eab8ec4670bf57b6fc090 Mon Sep 17 00:00:00 2001 From: lelgenio Date: Wed, 26 Oct 2022 17:44:38 -0300 Subject: [PATCH] update theming --- user/theme.nix | 45 +++++++++++++++++++++++++++++++++++++++------ 1 file changed, 39 insertions(+), 6 deletions(-) diff --git a/user/theme.nix b/user/theme.nix index 4a637d7..23483a2 100644 --- a/user/theme.nix +++ b/user/theme.nix @@ -1,6 +1,11 @@ -{ config, pkgs, lib, inputs, ... }: { +{ config, pkgs, lib, inputs, ... }: let + font = pkgs.uservars.font; + gtk_theme = "Orchis-Red-Dark-Compact"; + icon_theme = "Papirus-Dark"; + cursor_theme = "capitaine-cursors"; +in { home.pointerCursor = { - name = "capitaine-cursors"; + name = cursor_theme; size = 32; package = pkgs.capitaine-cursors; gtk.enable = true; @@ -8,15 +13,15 @@ gtk = { enable = true; font = { - name = pkgs.uservars.font.interface; - size = pkgs.uservars.font.size.medium; + name = font.interface; + size = font.size.medium; }; theme = { - name = "Orchis-Red-Dark-Compact"; + name = gtk_theme; package = pkgs.orchis_theme_compact; }; iconTheme = { - name = "Papirus-Dark"; + name = icon_theme; package = pkgs.papirus_red; }; }; @@ -26,6 +31,34 @@ # # style.package = pkgs.libsForQt5.qtstyleplugins; # # style.name = "gtk2"; # }; + + # fonts.fontconfig.enable = true; + xdg.configFile = { + "qt5ct/qt5ct.conf".text = '' + [Appearance] + # color_scheme_path=/nix/store/f07mk0vrm47jxw3y5v99hxncy0w4vcyq-qt5ct-1.5/share/qt5ct/colors/darker.conf + custom_palette=false + icon_theme=${ icon_theme } + standard_dialogs=default + style=kvantum-dark + + # [Fonts] + # fixed=@Variant(\0\0\0@\0\0\0\x1c\0H\0\x61\0\x63\0k\0 \0N\0\x65\0r\0\x64\0 \0\x46\0o\0n\0t@(\0\0\0\0\0\0\xff\xff\xff\xff\x5\x1\0\x32\x10) + # general=@Variant(\0\0\0@\0\0\0\x1e\0L\0i\0\x62\0\x65\0r\0\x61\0t\0i\0o\0n\0 \0S\0\x61\0n\0s@(\0\0\0\0\0\0\xff\xff\xff\xff\x5\x1\0\x32\x10) + ''; + }; + services.xsettingsd = { + enable = true; + settings = { + "Gtk/FontName" = "${ font.interface } ${toString font.size.small }"; + "Net/ThemeName" = "${ gtk_theme }"; + "Net/IconThemeName" = "${ icon_theme }"; + "Gtk/CursorThemeName" = "${ cursor_theme }"; + "Gtk/CursorThemeSize" = 24; + "Net/SoundThemeName" = "freedesktop" ; + }; + }; + home.sessionVariables = { QT_QPA_PLATFORMTHEME = "qt5ct"; };