aboutsummaryrefslogtreecommitdiff
path: root/home/profiles/gui/config
diff options
context:
space:
mode:
Diffstat (limited to 'home/profiles/gui/config')
-rw-r--r--home/profiles/gui/config/dunst.nix50
-rw-r--r--home/profiles/gui/config/mako.nix45
-rw-r--r--home/profiles/gui/config/sway.nix16
-rw-r--r--home/profiles/gui/config/waybar/settings.nix14
-rw-r--r--home/profiles/gui/config/waybar/style.nix19
5 files changed, 89 insertions, 55 deletions
diff --git a/home/profiles/gui/config/dunst.nix b/home/profiles/gui/config/dunst.nix
deleted file mode 100644
index f6e80b3..0000000
--- a/home/profiles/gui/config/dunst.nix
+++ /dev/null
@@ -1,50 +0,0 @@
-{ config, neotheme }:
-
-with neotheme.colors;
-
-let
- guiCfg = config.profiles.gui;
-in
-{
- global = {
- padding = 8;
- width = "330";
- origin = "top-right";
- offset = "8x25";
- notification_limit = 5;
- frame_width = 2;
- vertical_alignment = "center";
- horizontal_padding = 8;
- icon_position = "left";
- corner_radius = 10;
-
- markup = "full";
- word_wrap = true;
- show_indicators = false;
- format = "<b>%s</b>\\n\\n%b";
- font = "${guiCfg.font.name} ${toString guiCfg.font.size}";
- frame_color = "#${color3}";
- separator_color = "auto";
- max_icon_size = 80;
- };
-
- urgency_low = {
- foreground = "#${foreground}";
- background = "#${background}";
- frame_color = "#${color4}";
- timeout = 4;
- };
-
- urgency_normal = {
- foreground = "#${foreground}";
- background = "#${background}";
- frame_color = "#${color3}";
- timeout = 8;
- };
-
- urgency_critical = {
- foreground = "#${foreground}";
- background = "#${background}";
- frame_color = "#${color1}";
- };
-}
diff --git a/home/profiles/gui/config/mako.nix b/home/profiles/gui/config/mako.nix
new file mode 100644
index 0000000..a471a6a
--- /dev/null
+++ b/home/profiles/gui/config/mako.nix
@@ -0,0 +1,45 @@
+{ config, neotheme }:
+
+with neotheme.colors;
+
+let
+ guiCfg = config.profiles.gui;
+in
+{
+ anchor = "top-right";
+ width = 330;
+ padding = "8";
+ margin = "16,8";
+ borderRadius = 10;
+ borderSize = 2;
+
+ borderColor = "#${color3}";
+ backgroundColor = "#${background}";
+ textColor = "#${foreground}";
+ progressColor = "over #${color5}";
+
+ markup = true;
+ font = "${guiCfg.font.name} ${toString guiCfg.font.size}";
+
+ maxVisible = 5;
+
+ extraConfig = ''
+ [urgency=low]
+ border-color=#${color4}
+ default-timeout=4000
+
+ [urgency=normal]
+ border-color=#${color3}
+ default-timeout=8000
+
+ [urgency=critical]
+ border-color=#${color1}
+ default-timeout=0
+
+ [app-name=yubikey-touch-detector]
+ anchor=bottom-center
+ text-alignment=center
+ padding=32
+
+ '';
+}
diff --git a/home/profiles/gui/config/sway.nix b/home/profiles/gui/config/sway.nix
index 36b1b95..162be7d 100644
--- a/home/profiles/gui/config/sway.nix
+++ b/home/profiles/gui/config/sway.nix
@@ -70,6 +70,11 @@ in
# floating
bindsym $mod+f floating toggle
+ bindsym $mod+Shift+f move position center
+
+ # scratchpad
+ bindsym $mod+grave scratchpad show; focus
+ bindsym $mod+shift+grave move scratchpad
# kill focused
bindsym $mod+w kill
@@ -84,6 +89,7 @@ in
for_window [window_type="dialog"] floating enable
for_window [window_type="menu"] floating enable
for_window [class="mpv"] floating enable
+ for_window [app_id="kicad"] floating enable
for_window [class=".*"] inhibit_idle fullscreen
for_window [app_id=".*"] title_format ""
for_window [class=".*"] title_format ""
@@ -200,6 +206,8 @@ in
default_border pixel 3
hide_edge_borders --i3 smart
gaps inner 8
+ # TODO: https://github.com/swaywm/sway/issues/8102
+ gaps right 2
smart_borders on
set $color0 #${color0}
@@ -250,9 +258,11 @@ in
tap_button_map lmr #1Finger > Left Click , 2Finger > Right Click, 3Fingers > MiddleClick
}
- input "1149:8264:Primax_Kensington_Eagle_Trackball" {
- accel_profile flat
- pointer_accel 0
+ # Kensington Slimblade Pro
+ # TODO: directly handle device?
+ input "4012:6878:keyd_virtual_pointer" {
+ accel_profile adaptive
+ pointer_accel -0.7
}
input type:keyboard {
diff --git a/home/profiles/gui/config/waybar/settings.nix b/home/profiles/gui/config/waybar/settings.nix
index 9470824..341a1b3 100644
--- a/home/profiles/gui/config/waybar/settings.nix
+++ b/home/profiles/gui/config/waybar/settings.nix
@@ -1,4 +1,4 @@
-{ config, lib, neotheme }:
+{ config, lib, pkgs, neotheme }:
with neotheme.colors;
@@ -10,7 +10,7 @@ in
position = "top";
height = 22;
modules-left = [ "wireplumber" "custom/separator" "cpu" "custom/separator" "memory" "custom/separator" "idle_inhibitor" ];
- modules-center = [ "sway/workspaces" ];
+ modules-center = [ "sway/workspaces" "custom/scratchpad-indicator" ];
modules-right = [ "group/tray" "custom/separator" "network" "custom/separator" ]
++ lib.optionals (guiCfg.laptop.enable) [ "battery" "custom/separator" ]
++ [ "clock" ];
@@ -96,6 +96,16 @@ in
tooltip = false;
};
+ "custom/scratchpad-indicator" = {
+ format = "(+{})";
+ interval = 3;
+ return-type = "json";
+ hide-empty-text = true;
+ exec = "${pkgs.writeShellScript "scratchpad-indicator" (import ../../scripts/scratchpad-indicator.nix)}";
+ on-click = "exec swaymsg scratchpad show";
+ on-click-right = "exec swaymsg move scratchpad";
+ };
+
"custom/separator" = {
format = "|";
interval = "once";
diff --git a/home/profiles/gui/config/waybar/style.nix b/home/profiles/gui/config/waybar/style.nix
index 92eb772..1f5327e 100644
--- a/home/profiles/gui/config/waybar/style.nix
+++ b/home/profiles/gui/config/waybar/style.nix
@@ -73,6 +73,21 @@ in
border-bottom: 1px solid #${bright0};
}
+ @keyframes blinkBattery {
+ to {
+ border-color: #${color3};
+ }
+ }
+
+ #battery.charging {
+ border-bottom: 1px solid transparent;
+ animation-name: blinkBattery;
+ animation-duration: 1s;
+ animation-timing-function: steps(12);
+ animation-iteration-count: infinite;
+ animation-direction: alternate;
+ }
+
#tray {
/* TODO: https://github.com/Alexays/Waybar/issues/2906 */
margin: 0;
@@ -92,6 +107,10 @@ in
padding-right: 0.2rem;
}
+ #custom-scratchpad-indicator {
+ color: #f0a0c0;
+ }
+
#custom-separator {
color: #${alt1};
background-color: #${background};