From ba6dec9ea56c8deb2c6e84c647f3161d86b6a3d5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Jonas=20R=C3=B6ger?= Date: Sat, 3 May 2025 18:44:57 +0200 Subject: [PATCH] Home Gen512 @ 2025-05-03-18:44 by jonas@comfy-station --- modules/home/plasma.nix | 182 ++++++++++++++++++++++++++++++++++++---- 1 file changed, 167 insertions(+), 15 deletions(-) diff --git a/modules/home/plasma.nix b/modules/home/plasma.nix index fe433cf..201c477 100644 --- a/modules/home/plasma.nix +++ b/modules/home/plasma.nix @@ -77,7 +77,10 @@ in { lookAndFeel = "Utterly-Nord"; theme = "breeze"; colorScheme = "UtterlyNord"; - cursorTheme = "Breeze"; + cursor = { + theme = "Breeze"; + size = 32; + }; wallpaper = "/home/jonas/.local/share/wallpaper/nord.png"; }; @@ -92,28 +95,171 @@ in { { location = "bottom"; widgets = [ - "org.kde.plasma.kickoff" - "org.kde.plasma.pager" - # We can also configure the widgets. For example if you want to pin - # konsole and dolphin to the task-launcher the following widget will - # have that. + # We can configure the widgets by adding the name and config + # attributes. For example to add the the kickoff widget and set the + # icon to "nix-snowflake-white" use the below configuration. This will + # add the "icon" key to the "General" group for the widget in + # ~/.config/plasma-org.kde.plasma.desktop-appletsrc. { - name = "org.kde.plasma.icontasks"; + name = "org.kde.plasma.kickoff"; config = { - General.launchers = [ + General = { + icon = "nix-snowflake-white"; + alphaSort = true; + }; + }; + } + # Or you can configure the widgets by adding the widget-specific options for it. + # See modules/widgets for supported widgets and options for these widgets. + # For example: + { + kickoff = { + sortAlphabetically = true; + icon = "nix-snowflake-white"; + }; + } + # Adding configuration to the widgets can also for example be used to + # pin apps to the task-manager, which this example illustrates by + # pinning dolphin and konsole to the task-manager by default with widget-specific options. + { + iconTasks = { + launchers = [ "applications:org.kde.dolphin.desktop" "applications:org.kde.konsole.desktop" ]; }; } - "org.kde.plasma.marginsseperator" - "org.kde.plasma.systemtray" - "org.kde.plasma.digitalclock" + # Or you can do it manually, for example: + { + name = "org.kde.plasma.icontasks"; + config = { + General = { + launchers = [ + "applications:org.kde.dolphin.desktop" + "applications:org.kde.konsole.desktop" + ]; + }; + }; + } + # If no configuration is needed, specifying only the name of the + # widget will add them with the default configuration. + "org.kde.plasma.marginsseparator" + # If you need configuration for your widget, instead of specifying the + # the keys and values directly using the config attribute as shown + # above, plasma-manager also provides some higher-level interfaces for + # configuring the widgets. See modules/widgets for supported widgets + # and options for these widgets. The widgets below shows two examples + # of usage, one where we add a digital clock, setting 12h time and + # first day of the week to Sunday and another adding a systray with + # some modifications in which entries to show. + { + digitalClock = { + calendar.firstDayOfWeek = "sunday"; + time.format = "12h"; + }; + } + { + systemTray.items = { + # We explicitly show bluetooth and battery + shown = [ + "org.kde.plasma.battery" + "org.kde.plasma.bluetooth" + ]; + # And explicitly hide networkmanagement and volume + hidden = [ + "org.kde.plasma.networkmanagement" + "org.kde.plasma.volume" + ]; + }; + } + ]; + hiding = "autohide"; + } + # Application name, Global menu and Song information and playback controls at the top + { + location = "top"; + height = 26; + widgets = [ + { + applicationTitleBar = { + behavior = { + activeTaskSource = "activeTask"; + }; + layout = { + elements = ["windowTitle"]; + horizontalAlignment = "left"; + showDisabledElements = "deactivated"; + verticalAlignment = "center"; + }; + overrideForMaximized.enable = false; + titleReplacements = [ + { + type = "regexp"; + originalTitle = "^Brave Web Browser$"; + newTitle = "Brave"; + } + { + type = "regexp"; + originalTitle = ''\\bDolphin\\b''; + newTitle = "File manager"; + } + ]; + windowTitle = { + font = { + bold = false; + fit = "fixedSize"; + size = 12; + }; + hideEmptyTitle = true; + margins = { + bottom = 0; + left = 10; + right = 5; + top = 0; + }; + source = "appName"; + }; + }; + } + "org.kde.plasma.appmenu" + "org.kde.plasma.panelspacer" + { + plasmusicToolbar = { + panelIcon = { + albumCover = { + useAsIcon = false; + radius = 8; + }; + icon = "view-media-track"; + }; + playbackSource = "auto"; + musicControls.showPlaybackControls = true; + songText = { + displayInSeparateLines = true; + maximumWidth = 640; + scrolling = { + behavior = "alwaysScroll"; + speed = 3; + }; + }; + }; + } ]; - hiding = null; } ]; + kwin = { + edgeBarrier = 0; # Disables the edge-barriers introduced in plasma 6.1 + cornerBarrier = false; + + scripts.polonium.enable = true; + }; + + kscreenlocker = { + lockOnResume = true; + timeout = 10; + }; + # # Some mid-level settings: # @@ -160,13 +306,19 @@ in { # Some low-level settings: # configFile = { - "baloofilerc"."Basic Settings"."Indexing-Enabled".value = false; - "kwinrc"."org.kde.kdecoration2"."ButtonsOnLeft".value = "SF"; - "kwinrc"."Desktops"."Number" = { + baloofilerc."Basic Settings"."Indexing-Enabled" = false; + kwinrc."org.kde.kdecoration2".ButtonsOnLeft = "SF"; + kwinrc.Desktops.Number = { value = 8; # Forces kde to not change this value (even through the settings app). immutable = true; }; + kscreenlockerrc = { + Greeter.WallpaperPlugin = "org.kde.potd"; + # To use nested groups use / as a separator. In the below example, + # Provider will be added to [Greeter][Wallpaper][org.kde.potd][General]. + "Greeter/Wallpaper/org.kde.potd/General".Provider = "bing"; + }; }; }; };