Files
nix-config/modules/home/stylix/default.nix
mjallen18 47d7d5b11e fix plasma: disable stylix qt target and set widgetStyle=Breeze
Stylix's qt target sets QT_STYLE_OVERRIDE=kvantum and writes qt6ct/qt5ct
configs with style=kvantum. plasmashell/KWin crash with a fatal
'module kvantum is not installed' QML error because the kvantum Qt style
plugin is not available in the Plasma session.

- stylix: targets.qt.enable = false (stops QT_STYLE_OVERRIDE=kvantum)
- plasma: remove kvantum package, add widgetStyle=Breeze as belt-and-suspenders
2026-03-26 09:38:38 -05:00

122 lines
3.4 KiB
Nix

{
config,
pkgs,
system,
...
}:
let
# # Pull from global theme options
# themeSize = "standard"; # "standard" | "compact"
# themeAccent = "default"; # "default" | ... | "all"
# themeTweak = "normal"; # "normal" | "rimless" | "float" | "black"
# themeColor = "dark"; # "light" | "dark"
# iconThemeVariant = "default"; # "default" | ... | "all"
# iconScheme = "nord"; # "default" | "nord" | "dracula" | ...
# # GTK
# gtkTheme = "Colloid-dark-standard";
# gtkThemePkg = pkgs.colloid-gtk-theme.override {
# sizeVariants = [ themeSize ];
# colorVariants = [ themeColor ];
# themeVariants = [ themeAccent ];
# tweaks = [ themeTweak ];
# };
# # Icons
# iconTheme = "Colloid-nord-dark";
# iconThemePkg = pkgs.colloid-icon-theme.override {
# schemeVariants = [ iconScheme ];
# colorVariants = [ iconThemeVariant ];
# };
isDarwin = system == "aarch64-darwin";
in
{
# The default value of `gtk.gtk4.theme` has changed from `config.gtk.theme` to `null`.
# You are currently using the legacy default (`config.gtk.theme`) because `home.stateVersion` is less than "26.05".
# To silence this warning and keep legacy behavior, set:
# gtk.gtk4.theme = config.gtk.theme;
# To adopt the new default behavior, set:
# gtk.gtk4.theme = null;
gtk.gtk4.theme = config.gtk.theme;
stylix = {
enable = true;
overlays.enable = false;
enableReleaseChecks = false;
base16Scheme = "${pkgs.base16-schemes}/share/themes/nord.yaml";
polarity = "dark";
cursor = {
name = "macOS";
size = 24;
package = pkgs.apple-cursor;
};
fonts = {
serif = {
package = pkgs.dejavu_fonts;
name = "DejaVu Serif";
};
sansSerif = {
package = pkgs.dejavu_fonts;
name = "DejaVu Sans";
};
monospace = {
package = pkgs.nerd-fonts.jetbrains-mono;
name = "JetBrainsMono NFM";
};
emoji = {
package = pkgs.noto-fonts-color-emoji;
name = "Noto Color Emoji";
};
sizes = {
applications = if isDarwin then 10 else 12;
desktop = if isDarwin then 12 else 14;
popups = config.stylix.fonts.sizes.desktop;
terminal = config.stylix.fonts.sizes.applications;
};
};
icons = {
enable = true;
package = pkgs.colloid-icon-theme.override {
schemeVariants = [ "nord" ];
colorVariants = [ "default" ];
};
dark = "Colloid-Nord-Dark";
light = "Colloid-Nord-Light";
};
opacity = {
terminal = 0.85;
};
targets = {
hyprlock = {
enable = false;
useWallpaper = false;
};
kde.enable = false;
# Disable Stylix Qt theming (qt6ct/qt5ct + kvantum). When enabled, Stylix
# sets QT_STYLE_OVERRIDE=kvantum and writes qt6ct/qt5ct configs with
# style=kvantum. Plasma's plasmashell/KWin crash with a fatal
# "module kvantum is not installed" QML error because the kvantum Qt style
# plugin is not available. The Plasma home module sets widgetStyle=Breeze
# to counteract this, but disabling the source of the problem here is
# simpler and avoids the issue for all desktops.
qt.enable = false;
firefox = {
enable = false;
profileNames = [
"default"
"954lxlok.default"
];
};
};
};
}