feat(theme): set qt config declaratively

This commit is contained in:
matt1432 2023-10-03 22:42:20 -04:00
parent 640be8c112
commit 4ab6a4d527
3 changed files with 17 additions and 21 deletions

View file

@ -28,12 +28,6 @@
nix.settings.experimental-features = [ "nix-command" "flakes" ]; nix.settings.experimental-features = [ "nix-command" "flakes" ];
nixpkgs.config.allowUnfree = true; nixpkgs.config.allowUnfree = true;
environment.sessionVariables = {
NIXPKGS_ALLOW_UNFREE = "1";
QT_QPA_PLATFORMTHEME = "qt5ct";
QT_FONT_DPI = "125";
};
# This value determines the NixOS release from which the default # This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions # settings for stateful data, like file locations and database versions
# on your system were taken. It's perfectly fine and recommended to leave # on your system were taken. It's perfectly fine and recommended to leave

View file

@ -69,17 +69,17 @@
firefox # TODO: use programs.firefox firefox # TODO: use programs.firefox
spotifywm spotifywm
zeal zeal
libreoffice-fresh # TODO: add spelling stuff libreoffice-fresh # TODO: add spelling stuff and declarative conf?
photoqt photoqt
gimp-with-plugins gimp-with-plugins # TODO: set plugins using nix
vlc vlc
discord discord
nextcloud-client nextcloud-client
jellyfin-media-player
xournalpp
# Misc CLI # Misc CLI
neofetch neofetch
qt5.qtwayland
qt6.qtwayland
acpi acpi
progress progress
alsa-utils alsa-utils

View file

@ -7,11 +7,6 @@
}; };
in in
{ {
home.packages = with pkgs; [
plasma5Packages.qtstyleplugin-kvantum
qt5ct
];
home.pointerCursor = { home.pointerCursor = {
name = "Dracula-cursors"; name = "Dracula-cursors";
package = pkgs.dracula-theme; package = pkgs.dracula-theme;
@ -38,14 +33,21 @@ in
}; };
}; };
qt = {
enable = true;
platformTheme = "qtct";
style.name = "Kvantum";
};
xresources.extraConfig = builtins.readFile("${dracula-xresources}/Xresources"); xresources.extraConfig = builtins.readFile("${dracula-xresources}/Xresources");
xdg.configFile = { home.sessionVariables = {
"../.themes/Dracula".source = "${pkgs.dracula-theme}/share/themes/Dracula"; QT_FONT_DPI = "125";
};
"Kvantum/Dracula".source = "${pkgs.dracula-theme}/share/Kvantum/Dracula"; xdg.configFile = {
"Kvantum/Dracula-Solid".source = "${pkgs.dracula-theme}/share/Kvantum/Dracula-Solid"; "Kvantum/Dracula/Dracula.kvconfig".source = "${pkgs.dracula-theme}/share/Kvantum/Dracula-purple-solid/Dracula-purple-solid.kvconfig";
"Kvantum/Dracula-purple".source = "${pkgs.dracula-theme}/share/Kvantum/Dracula-purple"; "Kvantum/Dracula/Dracula.svg".source = "${pkgs.dracula-theme}/share/Kvantum/Dracula-purple-solid/Dracula-purple-solid.svg";
"Kvantum/Dracula-purple-solid".source = "${pkgs.dracula-theme}/share/Kvantum/Dracula-purple-solid"; "Kvantum/kvantum.kvconfig".text = "[General]\ntheme=Dracula";
}; };
} }