144 lines
3.4 KiB
Nix
144 lines
3.4 KiB
Nix
{ extra, config, ... }:
|
|
{
|
|
programs.plasma = {
|
|
enable = true;
|
|
overrideConfig = true;
|
|
|
|
workspace = {
|
|
lookAndFeel = "org.kde.breezedark.desktop";
|
|
} // (if config.i3-plasma then {} else {
|
|
wallpaper = "${extra.wall}";
|
|
});
|
|
|
|
kscreenlocker = {
|
|
appearance.wallpaper = "${extra.wall}";
|
|
};
|
|
|
|
hotkeys.commands = if config.i3-plasma then {} else ({
|
|
"launch-terminal" = {
|
|
name = "Launch terminal";
|
|
key = "Meta+Return";
|
|
command = "wezterm";
|
|
};
|
|
|
|
|
|
"cpypsk" = {
|
|
name = "Launch cpypsk";
|
|
key = "Meta+p";
|
|
command = "${extra.cpypsk}";
|
|
};
|
|
} // (if config.mcsr then {
|
|
"eye" = {
|
|
name = "eye zoom";
|
|
key = "Alt+PgUp";
|
|
command = "${extra.eyezoom} eye";
|
|
};
|
|
|
|
"default" = {
|
|
name = "default zoom";
|
|
key = "Alt+PgDown";
|
|
command = "${extra.eyezoom} default";
|
|
};
|
|
|
|
"thin" = {
|
|
name = "thin zoom";
|
|
key = "Alt+End";
|
|
command = "${extra.eyezoom} tiktok";
|
|
};
|
|
|
|
"wide" = {
|
|
name = "wide zoom";
|
|
key = "Alt+Home";
|
|
command = "${extra.eyezoom} wide";
|
|
};
|
|
} else {}));
|
|
|
|
fonts = {
|
|
general = {
|
|
family = "SAX2 Nerd Font";
|
|
pointSize = 10;
|
|
};
|
|
};
|
|
|
|
powerdevil = {
|
|
AC.whenLaptopLidClosed = "hibernate";
|
|
battery.whenLaptopLidClosed = "hibernate";
|
|
lowBattery.whenLaptopLidClosed = "hibernate";
|
|
};
|
|
|
|
panels = [
|
|
{
|
|
location = if config.i3-plasma then "top" else "bottom";
|
|
floating = true;
|
|
height = if config.i3-plasma then 36 else 44;
|
|
widgets = let
|
|
clock = {
|
|
digitalClock = {
|
|
calendar.firstDayOfWeek = "monday";
|
|
time.format = "24h";
|
|
};
|
|
};
|
|
spacer = {
|
|
name = "org.kde.plasma.panelspacer";
|
|
config = { General.expanding = true; };
|
|
};
|
|
nolaunchtasks = {
|
|
name = "org.kde.plasma.icontasks";
|
|
config = { General.launchers = [ ]; };
|
|
};
|
|
launchtasks = {
|
|
name = "org.kde.plasma.icontasks";
|
|
config = {
|
|
General.launchers = [
|
|
"applications:thunderbird.desktop"
|
|
"applications:org.wezfurlong.wezterm.desktop"
|
|
"applications:firefox.desktop"
|
|
"applications:discord.desktop"
|
|
];
|
|
};
|
|
};
|
|
kickoff = {
|
|
name = "org.kde.plasma.kickoff";
|
|
config = {
|
|
General.icon = "nix-snowflake-white";
|
|
};
|
|
};
|
|
systray = {
|
|
systemTray.items = {
|
|
shown = [
|
|
"org.kde.plasma.battery"
|
|
"org.kde.plasma.bluetooth"
|
|
"org.kde.plasma.networkmanagement"
|
|
"org.kde.plasma.volume"
|
|
];
|
|
};
|
|
};
|
|
in if config.i3-plasma then [
|
|
clock
|
|
spacer
|
|
nolaunchtasks
|
|
systray
|
|
] else [
|
|
kickoff
|
|
launchtasks
|
|
systray
|
|
clock
|
|
];
|
|
}
|
|
];
|
|
|
|
configFile."kcminputrc" = {
|
|
"Mouse"."X11LibInputXAccelProfileFlat" = true;
|
|
"Mouse"."XLbInptPointerAcceleration" = 0;
|
|
};
|
|
|
|
configFile."startkderc" = if config.i3-plasma then {
|
|
"General"."systemdBoot" = false; # needed to use i3 in place of KWin
|
|
} else {};
|
|
};
|
|
|
|
home.packages = [
|
|
extra.rc2nix
|
|
];
|
|
}
|