diff --git a/home-manager/modules/colors.nix b/home-manager/modules/colors.nix index 4d2f78a..3d88c48 100644 --- a/home-manager/modules/colors.nix +++ b/home-manager/modules/colors.nix @@ -95,6 +95,11 @@ in type = types.attrsOf types.str; }; + plasma = mkOption { + default = false; + type = types.bool; + }; + baseColors = mkOption { type = types.either (types.attrsOf types.str) types.path; description = "base16 color scheme or path to an image to use to generate the scheme"; @@ -241,11 +246,11 @@ in base16FromImage = lib.filterAttrs (k: v: k != "scheme" && k != "author") (builtins.fromJSON (builtins.readFile base16FromImageSrc)); in - mkIf cfg.enable { + mkMerge [(mkIf cfg.enable { # Read only utility attributes ezcolors.base16 = if builtins.typeOf cfg.baseColors == "set" then cfg.baseColors else base16FromImage; - ezcolors.base16Rgb = builtins.mapAttrs hexToRgb cfg.base16; - ezcolors.base16Split = builtins.mapAttrs splitHex cfg.base16; + ezcolors.base16Rgb = builtins.mapAttrs (n: c: hexToRgb c) cfg.base16; + ezcolors.base16Split = builtins.mapAttrs (n: c: splitHex c) cfg.base16; # Element xdg.configFile."Riot/config.json".text = builtins.toJSON elementConfig; @@ -370,5 +375,113 @@ in } ) ]; - }; + }) (mkIf (cfg.enable && cfg.plasma) { + programs.plasma.files.kdeglobals = with (lib.mapAttrs (n: c: "#${c}") cfg.base16); { + # programs.plasma.files.kdeglobals = with (lib.mapAttrs (n: c: "${toString c.r},${toString c.g},${toString c.b}") cfg.base16Rgb); { + General = { + ColorScheme = "Generated"; + Name = "Generated"; + shadeSortColumn = true; + }; + KDE.contrast = 4; + WM = { + activeBackground = base00; + activeBlend = base00; + activeForeground = base06; + inactiveBackground = base00; + inactiveBlend = base00; + inactiveForeground = base05; + }; + "ColorEffects:Disabled" = { + Color = "56,56,56"; + ColorAmount = 0; + ColorEffect = 0; + ContrastAmount = "0.65000000000000002"; + ContrastEffect = 1; + IntensityAmount = "0.10000000000000001"; + IntensityEffect = 2; + }; + "ColorEffects:Inactive" = { + ChangeSelectionColor = true; + Color = "112,111,110"; + ColorAmount = "0.025000000000000001"; + ColorEffect = 2; + ContrastAmount = "0.10000000000000001"; + ContrastEffect = 2; + Enable = false; + IntensityAmount = 0; + IntensityEffect = 0; + }; + "Colors:Button" = { + BackgroundAlternate = base00; + BackgroundNormal = base00; + DecorationFocus = base08; + DecorationHover = base08; + ForegroundActive = base0B; + ForegroundInactive = base05; + ForegroundLink = base0D; + ForegroundNegative = base0F; + ForegroundNeutral = base05; + ForegroundNormal = base06; + ForegroundPositive = base0C; + ForegroundVisited = base0E; + }; + "Colors:Selection" = { + BackgroundAlternate = base08; + BackgroundNormal = base08; + DecorationFocus = base08; + DecorationHover = base08; + ForegroundActive = base0B; + ForegroundInactive = base01; + ForegroundLink = base0D; + ForegroundNegative = base0F; + ForegroundNeutral = base05; + ForegroundNormal = base01; + ForegroundPositive = base0C; + ForegroundVisited = base0E; + }; + "Colors:Tooltip" = { + BackgroundAlternate = base00; + BackgroundNormal = base00; + DecorationFocus = base08; + DecorationHover = base08; + ForegroundActive = base0B; + ForegroundInactive = base05; + ForegroundLink = base0D; + ForegroundNegative = base0F; + ForegroundNeutral = base05; + ForegroundNormal = base06; + ForegroundPositive = base0C; + ForegroundVisited = base0E; + }; + "Colors:View" = { + BackgroundAlternate = base00; + BackgroundNormal = base00; + DecorationFocus = base08; + DecorationHover = base08; + ForegroundActive = base0B; + ForegroundInactive = base05; + ForegroundLink = base0D; + ForegroundNegative = base0F; + ForegroundNeutral = base05; + ForegroundNormal = base06; + ForegroundPositive = base0C; + ForegroundVisited = base0E; + }; + "Colors:Window" = { + BackgroundAlternate = base00; + BackgroundNormal = base00; + DecorationFocus = base08; + DecorationHover = base08; + ForegroundActive = base0B; + ForegroundInactive = base05; + ForegroundLink = base0D; + ForegroundNegative = base0F; + ForegroundNeutral = base05; + ForegroundNormal = base06; + ForegroundPositive = base0C; + ForegroundVisited = base0E; + }; + }; + })]; } diff --git a/home-manager/modules/de3u.nix b/home-manager/modules/de3u.nix index 82a5601..ea5af26 100644 --- a/home-manager/modules/de3u.nix +++ b/home-manager/modules/de3u.nix @@ -28,6 +28,7 @@ in config = mkIf cfg.enable { ezcolors.enable = lib.mkDefault true; + ezcolors.plasma = lib.mkDefault true; ezfonts.enable = lib.mkDefault true; ezfonts.plasma = lib.mkDefault true; @@ -86,9 +87,19 @@ in "Script-bismuth" = { untileByDragging = false; + ignoreClass = "yakuake,spectacle,Conky,zoom,pinentry-qt"; + maximizeSoleTile = true; }; }; + kcminputrc = { + Mouse.cursorSize = 24; + }; + + plasmashellrc = { + "PlasmaViews.Panel 28.Defaults".thickness = 34; + }; + kdeglobals = { KDE = { LookAndFeelPackage = "org.kde.breezedark.desktop"; @@ -194,23 +205,25 @@ in toggle_window_floating = "Meta+S"; - increase_window_height = "Meta+Shift+Up"; - decrease_window_height = "Meta+Shift+Down"; - increase_window_width = "Meta+Shift+Right"; - decrease_window_width = "Meta+Shift+Left"; + increase_window_height = "Meta+Ctrl+Up"; + decrease_window_height = "Meta+Ctrl+Down"; + increase_window_width = "Meta+Ctrl+Right"; + decrease_window_width = "Meta+Ctrl+Left"; increase_master_size = "Meta+="; decrease_master_size = "Meta+-"; - decrease_master_win_count = [ ]; - increase_master_win_count = [ ]; - move_window_to_bottom_pos = [ ]; - move_window_to_left_pos = [ ]; + move_window_to_bottom_pos = "Meta+Shift+Down"; + move_window_to_left_pos = "Meta+Shift+Left"; + move_window_to_right_pos = "Meta+Shift+Right"; + move_window_to_upper_pos = "Meta+Shift+Up"; + + push_window_to_master = "Meta+M"; + move_window_to_next_pos = [ ]; move_window_to_prev_pos = [ ]; - move_window_to_right_pos = [ ]; - move_window_to_upper_pos = [ ]; - push_window_to_master = [ ]; + decrease_master_win_count = [ ]; + increase_master_win_count = [ ]; rotate = [ ]; rotate_part = [ ]; rotate_reverse = [ ]; @@ -306,6 +319,8 @@ in plasma5Packages.bismuth plasma5Packages.kate + thunderbird + xdg-desktop-portal-kde ]; diff --git a/home-manager/modules/gaming.nix b/home-manager/modules/gaming.nix index b0b8209..76bcde6 100644 --- a/home-manager/modules/gaming.nix +++ b/home-manager/modules/gaming.nix @@ -61,10 +61,7 @@ in sc-controller - dolphinEmuMaster - tuxpaint - extremetuxracer ] ++ lib.optionals cfg.newWine [ (