Switch to Materia theme for better GTK & Qt consistency

Set Plasma accent colour in config, using base16 defined accent
colour.
This commit is contained in:
Evie Litherland-Smith 2024-07-10 15:19:45 +01:00
parent 21f27fdc88
commit 44ee0f1e5b
5 changed files with 41 additions and 24 deletions

View file

@ -8,7 +8,10 @@
./desktop/plasma/default.nix ./desktop/plasma/default.nix
]; ];
programs.plasma = lib.mkIf config.programs.plasma.enable { programs.plasma = lib.mkIf config.programs.plasma.enable {
configFile.kcminputrc."Libinput/1160/4132/DELL0A21:00 0488:1024 Touchpad".NaturalScroll = true; configFile = {
kcminputrc."Libinput/1160/4132/DELL0A21:00 0488:1024 Touchpad".NaturalScroll = true;
kwinrc."Tiling/8c3e40a5-6d02-561d-be90-abdf39b7afe6"."tiles" = "{\"layoutDirection\":\"horizontal\",\"tiles\":[{\"width\":0.5},{\"width\":0.5}]}";
};
}; };
wayland.windowManager.sway = lib.mkIf config.wayland.windowManager.sway.enable { wayland.windowManager.sway = lib.mkIf config.wayland.windowManager.sway.enable {
config = { config = {

View file

@ -51,26 +51,17 @@
enable = true; enable = true;
gtk3 = {inherit extraCss;}; gtk3 = {inherit extraCss;};
gtk4 = {inherit extraCss;}; gtk4 = {inherit extraCss;};
theme = let theme = {
color = "purple"; package = pkgs.materia-theme;
in { name = "Materia-${config.scheme.variant}";
package = pkgs.colloid-gtk-theme.override {
themeVariants = [color];
colorVariants = [config.scheme.variant];
};
name = "Colloid-${toCapital color}-${toCapital config.scheme.variant}";
}; };
iconTheme = let iconTheme = let
color = "breeze"; color = "violet";
in { in {
package = pkgs.papirus-icon-theme.override {inherit color;}; package = pkgs.papirus-icon-theme.override {inherit color;};
name = "Papirus-${toCapital config.scheme.variant}"; name = "Papirus-${toCapital config.scheme.variant}";
}; };
}; };
# qt = {
# enable = true;
# style.name = "breeze";
# };
xdg = { xdg = {
mime.enable = true; mime.enable = true;
mimeApps = let mimeApps = let

View file

@ -3,6 +3,7 @@
pkgs, pkgs,
fonts, fonts,
rc2nix, rc2nix,
accentColourName,
... ...
}: { }: {
imports = [ imports = [
@ -13,6 +14,7 @@
rc2nix rc2nix
wl-clipboard wl-clipboard
colloid-kde colloid-kde
materia-kde-theme
]; ];
services.gpg-agent.pinentryPackage = pkgs.pinentry-qt; services.gpg-agent.pinentryPackage = pkgs.pinentry-qt;
programs.plasma = { programs.plasma = {
@ -22,7 +24,7 @@
workspace = { workspace = {
clickItemTo = "open"; clickItemTo = "open";
lookAndFeel = "org.kde.breeze.desktop"; lookAndFeel = "org.kde.breeze.desktop";
theme = "breeze-light"; theme = "default";
colorScheme = "BreezeLight"; colorScheme = "BreezeLight";
cursor = { cursor = {
inherit (config.home.pointerCursor) size; inherit (config.home.pointerCursor) size;
@ -184,22 +186,38 @@
}; };
}; };
kdeglobals = { kdeglobals = {
General = { General = let
AccentColor = let
r = config.scheme."${accentColourName}-rgb-r";
g = config.scheme."${accentColourName}-rgb-g";
b = config.scheme."${accentColourName}-rgb-b";
in "${r}, ${g}, ${b}";
in {
inherit AccentColor;
LastUsedCustomAccentColor = AccentColor;
TerminalApplication = "konsole"; TerminalApplication = "konsole";
TerminalService = "org.kde.konsole.desktop"; TerminalService = "org.kde.konsole.desktop";
}; };
WM = {
# TODO convert to base16 colours at some point
activeBackground = "227,229,231";
activeBlend = "227,229,231";
activeForeground = "35,38,41";
inactiveBackground = "239,240,241";
inactiveBlend = "239,240,241";
inactiveForeground = "112,125,138";
};
}; };
kwinrc = { kwinrc = {
Plugins = { Plugins = {
frozenappEnabled = false; frozenappEnabled = false;
mouseclickEnabled = true; mouseclickEnabled = true;
shakecursorEnabled = true; shakecursorEnabled = false;
}; };
Windows = { Windows = {
FocusPolicy = "FocusFollowsMouse"; FocusPolicy = "FocusFollowsMouse";
RollOverDesktops = true; RollOverDesktops = true;
}; };
Tiling.padding = 10;
NightColor = { NightColor = {
Active = true; Active = true;
Mode = "Location"; Mode = "Location";
@ -207,11 +225,17 @@
LongitudeFixed = "-1.2"; LongitudeFixed = "-1.2";
}; };
"Effect-translucency" = { "Effect-translucency" = {
# Re-enable translucency when I can work out how to apply
# blur to all windows
Inactive = 100; Inactive = 100;
MoveResize = 80; MoveResize = 100;
Dialogs = 80; Dialogs = 100;
ComboboxPopups = 80; ComboboxPopups = 100;
Menus = 80; Menus = 100;
};
"org.kde.kdecoration2" = {
BorderSize = "None";
BorderSizeAuto = "false";
}; };
}; };
}; };

View file

@ -3,7 +3,6 @@
fonts, fonts,
... ...
}: { }: {
home.packages = [pkgs.kdePackages.yakuake];
programs.konsole = { programs.konsole = {
enable = true; enable = true;
defaultProfile = "One-Light"; defaultProfile = "One-Light";

View file

@ -94,7 +94,7 @@ Blur=true
ColorRandomization=false ColorRandomization=false
Description=One Light Description=One Light
FillStyle=Tile FillStyle=Tile
Opacity=0.9 Opacity=1.0
Wallpaper= Wallpaper=
WallpaperFlipType=NoFlip WallpaperFlipType=NoFlip
WallpaperOpacity=1 WallpaperOpacity=1