From efbbe37a304cc67bea1e01156e5ff06f2a9d0af0 Mon Sep 17 00:00:00 2001 From: aleidk Date: Thu, 8 Jan 2026 14:49:09 -0300 Subject: [PATCH] modularize niri config --- configs/niri/base/config.kdl | 503 +-------------------------- configs/niri/base/keys.kdl | 291 ++++++++++++++++ configs/niri/base/noctalia-shell.kdl | 16 + configs/niri/base/options.kdl | 67 ++++ configs/niri/base/rules.kdl | 53 +++ configs/niri/work-laptop/local.kdl | 8 +- 6 files changed, 436 insertions(+), 502 deletions(-) create mode 100644 configs/niri/base/keys.kdl create mode 100644 configs/niri/base/noctalia-shell.kdl create mode 100644 configs/niri/base/options.kdl create mode 100644 configs/niri/base/rules.kdl diff --git a/configs/niri/base/config.kdl b/configs/niri/base/config.kdl index 4f340da..399a3fe 100644 --- a/configs/niri/base/config.kdl +++ b/configs/niri/base/config.kdl @@ -1,503 +1,8 @@ -include "include/local.kdl" -// ╭─────────────────────────────────────────────────────────╮ -// │ Windows Rules │ -// ╰─────────────────────────────────────────────────────────╯ -window-rule { - // This regular expression is intentionally made as specific as possible, - // since this is the default config, and we want no false positives. - // You can get away with just app-id="wezterm" f you want. - match app-id="^org\\.wezfurlong\\.wezterm$" - default-column-width { +include "noctalia-shell.kdl" +include "keys.kdl" +include "options.kdl" - } -} -// Floatin Windows -window-rule { - match app-id="firefox$" title="^Picture-in-Picture$" - match app-id="^brave-.*-Default$" - // Extensions popup open-floating true -} -// Full width window -window-rule { - match app-id="beekeeper-studio" - open-maximized true -} -window-rule { - match app-id="^org\\.keepassxc\\.KeePassXC$" - match app-id="^org\\.gnome\\.World\\.Secrets$" - // block-out-from "screen-capture" - // Use this instead if you want them visible on third-party screenshot tools. - block-out-from "screencast" -} -window-rule { - match app-id="brave-browser" - match at-startup=true - default-column-width { - proportion 0.5 - } -} -window-rule { - match title="^Meet: .*" app-id="brave-browser" - open-floating true -} -window-rule { - geometry-corner-radius 4 - clip-to-geometry true -} -layer-rule { - match namespace="kitty-quick-access" - geometry-corner-radius 12 - shadow { - on - spread 10 - softness 20 - offset x=-10 y=10 - } -} -// ╭─────────────────────────────────────────────────────────╮ -// │ Auto Start Apps │ -// ╰─────────────────────────────────────────────────────────╯ spawn-at-startup "./fix_float.py" -spawn-at-startup "/usr/lib/pam_kwallet_init" spawn-at-startup "udieskie" -spawn-at-startup "brave" -// To run a shell command (with variables, pipes, etc.), use spawn-sh-at-startup: -// spawn-sh-at-startup "qs -c ~/source/qs/MyAwesomeShell" -// ╭─────────────────────────────────────────────────────────╮ -// │ System Config │ -// ╰─────────────────────────────────────────────────────────╯ -// ── Layout Config ─────────────────────────────────────────────────── -layout { - gaps 10 - always-center-single-column - center-focused-column "never" - preset-column-widths { - // The default preset widths are 1/3, 1/2 and 2/3 of the output. - proportion 0.33333 - proportion 0.5 - proportion 0.66667 - } - preset-window-heights { - - } - default-column-width { - proportion 0.5 - } - focus-ring { - // Uncomment this line to disable the focus ring. - // off - // How many logical pixels the ring extends out from the windows. - width 2 - active-color "#7fc8ff" - inactive-color "#505050" - } -} -// ── Keybindings ───────────────────────────────────────────────────── -binds { - Mod+Shift+Slash { - show-hotkey-overlay - } - Mod+Return hotkey-overlay-title="Open a Terminal: kitty" { - spawn "kitty" - } - Mod+Shift+Return hotkey-overlay-title="Open Quick Terminal" { - spawn "kitten" "quick_access_terminal" - } - Mod+Shift+E hotkey-overlay-title="Open Code Editor" { - spawn-sh "kitten quick_access_terminal --instance-group editor-choice fish -c \"zeditor (zoxide query -i)\"" - } - Mod+D hotkey-overlay-title="Run an Application: Rofi" { - spawn "rofi" "-show" "drun" "-run-command" "uwsm app -- {cmd}" - } - XF86AudioRaiseVolume allow-when-locked=true { - spawn-sh "wpctl set-volume @DEFAULT_AUDIO_SINK@ 0.025+" - } - XF86AudioLowerVolume allow-when-locked=true { - spawn-sh "wpctl set-volume @DEFAULT_AUDIO_SINK@ 0.025-" - } - XF86AudioMute allow-when-locked=true { - spawn-sh "wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle" - } - XF86AudioMicMute allow-when-locked=true { - spawn-sh "wpctl set-mute @DEFAULT_AUDIO_SOURCE@ toggle" - } - XF86MonBrightnessUp allow-when-locked=true { - spawn "brightnessctl" "--class=backlight" "set" "+10%" - } - XF86MonBrightnessDown allow-when-locked=true { - spawn "brightnessctl" "--class=backlight" "set" "10%-" - } - // Open/close the Overview: a zoomed-out view of workspaces and windows. - // You can also move the mouse into the top-left hot corner, - // or do a four-finger swipe up on a touchpad. - Mod+A repeat=false { - toggle-overview - } - Mod+Shift+Q repeat=false { - close-window - } - Mod+Tab { - focus-column-right-or-first - } - Mod+shift+Tab { - focus-column-left-or-last - } - Mod+Left { - focus-column-left - } - Mod+Down { - focus-window-or-workspace-down - } - Mod+Up { - focus-window-or-workspace-up - } - Mod+Right { - focus-column-or-monitor-right - } - Mod+H { - focus-column-or-monitor-left - } - Mod+J { - focus-window-or-workspace-down - } - Mod+K { - focus-window-or-workspace-up - } - Mod+L { - focus-column-or-monitor-right - } - Mod+Shift+Left { - move-column-left - } - Mod+Shift+Down { - move-window-down-or-to-workspace-down - } - Mod+Shift+Up { - move-window-up-or-to-workspace-up - } - Mod+Shift+Right { - move-column-right - } - Mod+Shift+H { - move-column-left - } - Mod+Shift+J { - move-window-down-or-to-workspace-down - } - Mod+Shift+K { - move-window-up-or-to-workspace-up - } - Mod+Shift+L { - move-column-right - } - Mod+Home { - focus-column-first - } - Mod+End { - focus-column-last - } - Mod+Ctrl+Home { - move-column-to-first - } - Mod+Ctrl+End { - move-column-to-last - } - Mod+WheelScrollDown cooldown-ms=150 { - focus-column-right - } - Mod+WheelScrollUp cooldown-ms=150 { - focus-column-left - } - Mod+Ctrl+WheelScrollDown cooldown-ms=150 { - move-column-to-workspace-down - } - Mod+Ctrl+WheelScrollUp cooldown-ms=150 { - move-column-to-workspace-up - } - Mod+WheelScrollRight { - focus-column-right - } - Mod+WheelScrollLeft { - focus-column-left - } - Mod+Ctrl+WheelScrollRight { - move-column-right - } - Mod+Ctrl+WheelScrollLeft { - move-column-left - } - Mod+Shift+WheelScrollDown cooldown-ms=150 { - focus-workspace-down - } - Mod+Shift+WheelScrollUp cooldown-ms=150 { - focus-workspace-up - } - Mod+Ctrl+Shift+WheelScrollDown { - move-column-right - } - Mod+Ctrl+Shift+WheelScrollUp { - move-column-left - } - // Similarly, you can bind touchpad scroll "ticks". - // Touchpad scrolling is continuous, so for these binds it is split into - // discrete intervals. - // These binds are also affected by touchpad's natural-scroll, so these - // example binds are "inverted", since we have natural-scroll enabled for - // touchpads by default. - // Mod+TouchpadScrollDown { spawn-sh "wpctl set-volume @DEFAULT_AUDIO_SINK@ 0.02+"; } - // Mod+TouchpadScrollUp { spawn-sh "wpctl set-volume @DEFAULT_AUDIO_SINK@ 0.02-"; } - Mod+1 { - focus-workspace 1 - } - Mod+2 { - focus-workspace 2 - } - Mod+3 { - focus-workspace 3 - } - Mod+4 { - focus-workspace 4 - } - Mod+5 { - focus-workspace 5 - } - Mod+6 { - focus-workspace 6 - } - Mod+7 { - focus-workspace 7 - } - Mod+8 { - focus-workspace 8 - } - Mod+9 { - focus-workspace 9 - } - Mod+Shift+1 { - move-window-to-workspace 1 - } - Mod+Shift+2 { - move-window-to-workspace 2 - } - Mod+Shift+3 { - move-window-to-workspace 3 - } - Mod+Shift+4 { - move-window-to-workspace 4 - } - Mod+Shift+5 { - move-window-to-workspace 5 - } - Mod+Shift+6 { - move-window-to-workspace 6 - } - Mod+Shift+7 { - move-window-to-workspace 7 - } - Mod+Shift+8 { - move-window-to-workspace 8 - } - Mod+Shift+9 { - move-window-to-workspace 9 - } - // Switches focus between the current and the previous workspace. - Mod+Bar { - focus-workspace-previous - } - // The following binds move the focused window in and out of a column. - // If the window is alone, they will consume it into the nearby column to the side. - // If the window is already in a column, they will expel it out. - Mod+BraceLeft { - consume-or-expel-window-left - } - Mod+BraceRight { - consume-or-expel-window-right - } - // Consume one window from the right to the bottom of the focused column. - Mod+Comma { - consume-window-into-column - } - // Expel the bottom window from the focused column to the right. - Mod+Period { - expel-window-from-column - } - Mod+R { - switch-preset-column-width - } - // Cycling through the presets in reverse order is also possible. - // Mod+R { switch-preset-column-width-back; } - Mod+Shift+R { - switch-preset-window-height - } - Mod+Ctrl+R { - reset-window-height - } - Mod+F { - maximize-column - } - Mod+Shift+F { - fullscreen-window - } - // Expand the focused column to space not taken up by other fully visible columns. - // Makes the column "fill the rest of the space". - Mod+Ctrl+F { - expand-column-to-available-width - } - Mod+C { - center-column - } - // Center all fully visible columns on screen. - Mod+Ctrl+C { - center-visible-columns - } - // Finer width adjustments. - // This command can also: - // * set width in pixels: "1000" - // * adjust width in pixels: "-5" or "+5" - // * set width as a percentage of screen width: "25%" - // * adjust width as a percentage of screen width: "-10%" or "+10%" - // Pixel sizes use logical, or scaled, pixels. I.e. on an output with scale 2.0, - // set-column-width "100" will make the column occupy 200 physical screen pixels. - Mod+Minus { - set-column-width "-10%" - } - Mod+Plus { - set-column-width "+10%" - } - // Finer height adjustments when in column with other windows. - Mod+Shift+Minus { - set-window-height "-10%" - } - Mod+Shift+Equal { - set-window-height "+10%" - } - // Move the focused window between the floating and the tiling layout. - Mod+Shift+Space { - toggle-window-floating - } - Mod+Space { - switch-focus-between-floating-and-tiling - } - // Toggle tabbed column display mode. - // Windows in this column will appear as vertical tabs, - // rather than stacked on top of each other. - Mod+W { - toggle-column-tabbed-display - } - Print { - screenshot - } - Shift+Print { - screenshot-window - } - Shift+Ctrl+Print hotkey-overlay-title="Edit image in Clipboard" { - spawn-sh "wl-paste | swappy -f -" - } - // Applications such as remote-desktop clients and software KVM switches may - // request that niri stops processing the keyboard shortcuts defined here - // so they may, for example, forward the key presses as-is to a remote machine. - // It's a good idea to bind an escape hatch to toggle the inhibitor, - // so a buggy application can't hold your session hostage. - // - // The allow-inhibiting=false property can be applied to other binds as well, - // which ensures niri always processes them, even when an inhibitor is active. - Mod+Escape allow-inhibiting=false { - toggle-keyboard-shortcuts-inhibit - } - Ctrl+Alt+Delete { - quit - } -} -// ── Environment Variables ─────────────────────────────────────────── -environment { - QT_STYLE_OVERRIDE "kvantum" - QT_AUTO_SCREEN_SCALE_FACTOR "1" - QT_QPA_PLATFORM "wayland;xcb" - QT_WAYLAND_DISABLE_WINDOWDECORATION "1" - QT_QPA_PLATFORMTHEME "qt5ct" - MOZ_ENABLE_WAYLAND "1" - XCURSOR_SIZE "24" - GTK_THEME "catppuccin-macchiato-teal-standard-default" - SSH_AUTH_SOCK "$XDG_RUNTIME_DIR/rbw/ssh-agent-socket" - EDITOR "nvim" - VISUAL "nvim" - TERMINAL "/usr/bin/kitty" -} -// ── Display Options ───────────────────────────────────────────────── -output "HDMI-A-1" { - scale 1 - mode "3440x1440" -} -// ── Input Options ─────────────────────────────────────────────────── -input { - keyboard { - xkb { - layout "latam" - options "caps:escape" - } - // Enable numlock on startup, omitting this setting disables it. - numlock - } - // Next sections include libinput settings. - // Omitting settings disables them, or leaves them at their default values. - // All commented-out settings here are examples, not defaults. - touchpad { - // off - tap - // dwt - // dwtp - // drag false - // drag-lock - natural-scroll - // accel-speed 0.2 - // accel-profile "flat" - // scroll-method "two-finger" - // disabled-on-external-mouse - } - mouse { - // off - // natural-scroll - // accel-speed 0.2 - // accel-profile "flat" - // scroll-method "no-scroll" - - } - trackpoint { - // off - // natural-scroll - // accel-speed 0.2 - // accel-profile "flat" - // scroll-method "on-button-down" - // scroll-button 273 - // scroll-button-lock - // middle-emulation - - } - // warp-mouse-to-focus - focus-follows-mouse -} -// ── Animations ────────────────────────────────────────────────────── -animations { - // Uncomment to turn off all animations. - // off - - // Slow down all animations by this factor. Values below 1 speed them up instead. - // slowdown 3.0 - -} -// ── Misc ──────────────────────────────────────────────────────────── -cursor { - xcursor-theme "catppuccin-macchiato-lavender-cursors" - xcursor-size 24 -} -hotkey-overlay { - skip-at-startup -} -// Uncomment this line to ask the clients to omit their client-side decorations if possible. -// If the client will specifically ask for CSD, the request will be honored. -// Additionally, clients will be informed that they are tiled, removing some client-side rounded corners. -// This option will also fix border/focus ring drawing behind some semitransparent windows. -// After enabling or disabling this, you need to restart the apps for this to take effect. -// prefer-no-csd -screenshot-path null +include "include/local.kdl" diff --git a/configs/niri/base/keys.kdl b/configs/niri/base/keys.kdl new file mode 100644 index 0000000..3e71629 --- /dev/null +++ b/configs/niri/base/keys.kdl @@ -0,0 +1,291 @@ +binds { + Mod+Shift+Slash { + show-hotkey-overlay + } + // + // ╭─────────────────────────────────────────────────────────╮ + // │ Launchers │ + // ╰─────────────────────────────────────────────────────────╯ + // + Mod+Return hotkey-overlay-title="Open Terminal" { + spawn "kitty" + } + Mod+Shift+Return hotkey-overlay-title="Open Quick Terminal" { + spawn "kitten" "quick_access_terminal" + } + Mod+D hotkey-overlay-title="Launcher" { + spawn "qs" "ipc" "-c" "noctalia-shell" "call" "launcher" "toggle" + } + // + // ╭─────────────────────────────────────────────────────────╮ + // │ Layout │ + // ╰─────────────────────────────────────────────────────────╯ + // + Mod+R { + switch-preset-column-width + } + Mod+Shift+R { + expand-column-to-available-width + } + Mod+F { + maximize-column + } + Mod+Shift+F { + fullscreen-window + } + Mod+C { + center-column + } + // + // ╭─────────────────────────────────────────────────────────╮ + // │ Window Management │ + // ╰─────────────────────────────────────────────────────────╯ + // + Mod+W repeat=false { + toggle-overview + } + Mod+Shift+Q repeat=false { + close-window + } + // + // ── Change focus ──────────────────────────────────────────────────── + // + Mod+Tab { + focus-column-right-or-first + } + Mod+shift+Tab { + focus-column-left-or-last + } + Mod+Left { + focus-column-left + } + Mod+Down { + focus-window-or-workspace-down + } + Mod+Up { + focus-window-or-workspace-up + } + Mod+Right { + focus-column-or-monitor-right + } + Mod+Ctrl+Left { + consume-or-expel-window-left + } + Mod+Ctrl+Right { + consume-or-expel-window-right + } + Mod+Alt+Left { + consume-window-into-column + } + Mod+Alt+Right { + expel-window-from-column + } + Mod+H { + focus-column-or-monitor-left + } + Mod+J { + focus-window-or-workspace-down + } + Mod+K { + focus-window-or-workspace-up + } + Mod+L { + focus-column-or-monitor-right + } + Mod+Ctrl+H { + consume-or-expel-window-left + } + Mod+Ctrl+L { + consume-or-expel-window-right + } + Mod+Alt+H { + consume-window-into-column + } + Mod+Alt+L { + expel-window-from-column + } + Mod+WheelScrollDown cooldown-ms=150 { + focus-column-right + } + Mod+WheelScrollUp cooldown-ms=150 { + focus-column-left + } + Mod+Space { + switch-focus-between-floating-and-tiling + } + // + // ── Move windows ──────────────────────────────────────────────────── + // + Mod+Shift+Left { + move-column-left + } + Mod+Shift+Down { + move-window-down-or-to-workspace-down + } + Mod+Shift+Up { + move-window-up-or-to-workspace-up + } + Mod+Shift+Right { + move-column-right + } + Mod+Shift+H { + move-column-left + } + Mod+Shift+J { + move-window-down-or-to-workspace-down + } + Mod+Shift+K { + move-window-up-or-to-workspace-up + } + Mod+Shift+L { + move-column-right + } + Mod+Ctrl+WheelScrollDown cooldown-ms=150 { + move-column-to-workspace-down + } + Mod+Ctrl+WheelScrollUp cooldown-ms=150 { + move-column-to-workspace-up + } + Mod+WheelScrollRight { + focus-column-right + } + Mod+WheelScrollLeft { + focus-column-left + } + Mod+Ctrl+WheelScrollRight { + move-column-right + } + Mod+Ctrl+WheelScrollLeft { + move-column-left + } + Mod+Ctrl+Shift+WheelScrollDown { + move-column-right + } + Mod+Ctrl+Shift+WheelScrollUp { + move-column-left + } + Mod+Shift+Space { + toggle-window-floating + } + // + // ╭─────────────────────────────────────────────────────────╮ + // │ Workspaces │ + // ╰─────────────────────────────────────────────────────────╯ + // + Mod+Bar { + // Switches focus between the current and the previous workspace. + focus-workspace-previous + } + Mod+1 { + focus-workspace 1 + } + Mod+2 { + focus-workspace 2 + } + Mod+3 { + focus-workspace 3 + } + Mod+4 { + focus-workspace 4 + } + Mod+5 { + focus-workspace 5 + } + Mod+6 { + focus-workspace 6 + } + Mod+7 { + focus-workspace 7 + } + Mod+8 { + focus-workspace 8 + } + Mod+9 { + focus-workspace 9 + } + Mod+Shift+1 { + move-window-to-workspace 1 + } + Mod+Shift+2 { + move-window-to-workspace 2 + } + Mod+Shift+3 { + move-window-to-workspace 3 + } + Mod+Shift+4 { + move-window-to-workspace 4 + } + Mod+Shift+5 { + move-window-to-workspace 5 + } + Mod+Shift+6 { + move-window-to-workspace 6 + } + Mod+Shift+7 { + move-window-to-workspace 7 + } + Mod+Shift+8 { + move-window-to-workspace 8 + } + Mod+Shift+9 { + move-window-to-workspace 9 + } + Mod+Shift+WheelScrollDown cooldown-ms=150 { + focus-workspace-down + } + Mod+Shift+WheelScrollUp cooldown-ms=150 { + focus-workspace-up + } + // + // ╭─────────────────────────────────────────────────────────╮ + // │ Volume │ + // ╰─────────────────────────────────────────────────────────╯ + // + XF86AudioRaiseVolume allow-when-locked=true { + spawn-sh "wpctl set-volume @DEFAULT_AUDIO_SINK@ 0.025+" + } + XF86AudioLowerVolume allow-when-locked=true { + spawn-sh "wpctl set-volume @DEFAULT_AUDIO_SINK@ 0.025-" + } + XF86AudioMute allow-when-locked=true { + spawn-sh "wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle" + } + XF86AudioMicMute allow-when-locked=true { + spawn-sh "wpctl set-mute @DEFAULT_AUDIO_SOURCE@ toggle" + } + // + // ╭─────────────────────────────────────────────────────────╮ + // │ Brightness │ + // ╰─────────────────────────────────────────────────────────╯ + // + XF86MonBrightnessUp allow-when-locked=true { + spawn "brightnessctl" "--class=backlight" "set" "+10%" + } + XF86MonBrightnessDown allow-when-locked=true { + spawn "brightnessctl" "--class=backlight" "set" "10%-" + } + Print { + screenshot + } + Shift+Print { + screenshot-window + } + Shift+Ctrl+Print hotkey-overlay-title="Edit image in Clipboard" { + spawn-sh "wl-paste | swappy -f -" + } + // Applications such as remote-desktop clients and software KVM switches may + // request that niri stops processing the keyboard shortcuts defined here + // so they may, for example, forward the key presses as-is to a remote machine. + // It's a good idea to bind an escape hatch to toggle the inhibitor, + // so a buggy application can't hold your session hostage. + // + // The allow-inhibiting=false property can be applied to other binds as well, + // which ensures niri always processes them, even when an inhibitor is active. + Mod+Escape allow-inhibiting=false { + toggle-keyboard-shortcuts-inhibit + } + Ctrl+Alt+Delete { + quit + } +} + diff --git a/configs/niri/base/noctalia-shell.kdl b/configs/niri/base/noctalia-shell.kdl new file mode 100644 index 0000000..8e4f66c --- /dev/null +++ b/configs/niri/base/noctalia-shell.kdl @@ -0,0 +1,16 @@ +window-rule { + // Rounded corners for a modern look. + geometry-corner-radius 20 + // Clips window contents to the rounded corner boundaries. + clip-to-geometry true +} +debug { + // Allows notification actions and window activation from Noctalia. + honor-xdg-activation-with-invalid-serial +} +// Set the overview wallpaper on the backdrop. +layer-rule { + match namespace="^noctalia-overview*" + place-within-backdrop true +} + diff --git a/configs/niri/base/options.kdl b/configs/niri/base/options.kdl new file mode 100644 index 0000000..13d0ac9 --- /dev/null +++ b/configs/niri/base/options.kdl @@ -0,0 +1,67 @@ +// ── Layout Config ─────────────────────────────────────────────────── +layout { + gaps 10 + always-center-single-column + center-focused-column "never" + preset-column-widths { + // The default preset widths are 1/3, 1/2 and 2/3 of the output. + proportion 0.33333 + proportion 0.5 + proportion 0.66667 + } + preset-window-heights { + + } + default-column-width { + proportion 0.5 + } + focus-ring { + // Uncomment this line to disable the focus ring. + // off + // How many logical pixels the ring extends out from the windows. + width 2 + active-color "#7fc8ff" + inactive-color "#505050" + } +} +// ── Environment Variables ─────────────────────────────────────────── +environment { + ELECTRON_OZONE_PLATFORM_HINT "auto" + QT_STYLE_OVERRIDE "kvantum" + QT_AUTO_SCREEN_SCALE_FACTOR "1" + QT_QPA_PLATFORM "wayland;xcb" + QT_WAYLAND_DISABLE_WINDOWDECORATION "1" + QT_QPA_PLATFORMTHEME "qt5ct" + MOZ_ENABLE_WAYLAND "1" + XCURSOR_SIZE "24" + GTK_THEME "catppuccin-macchiato-teal-standard-default" + SSH_AUTH_SOCK "$XDG_RUNTIME_DIR/rbw/ssh-agent-socket" + EDITOR "nvim" + VISUAL "nvim" + TERMINAL "/usr/bin/kitty" +} +// ── Input Options ─────────────────────────────────────────────────── +input { + keyboard { + xkb { + layout "latam" + options "caps:escape" + } + numlock + } + touchpad { + tap + natural-scroll + } + focus-follows-mouse +} +// ── Misc ──────────────────────────────────────────────────────────── +cursor { + xcursor-theme "catppuccin-macchiato-lavender-cursors" + xcursor-size 24 +} +hotkey-overlay { + skip-at-startup +} +screenshot-path null + diff --git a/configs/niri/base/rules.kdl b/configs/niri/base/rules.kdl new file mode 100644 index 0000000..6c6bf46 --- /dev/null +++ b/configs/niri/base/rules.kdl @@ -0,0 +1,53 @@ +window-rule { + // This regular expression is intentionally made as specific as possible, + // since this is the default config, and we want no false positives. + // You can get away with just app-id="wezterm" f you want. + match app-id="^org\\.wezfurlong\\.wezterm$" + default-column-width { + + } +} +// Floatin Windows +window-rule { + match app-id="firefox$" title="^Picture-in-Picture$" + match app-id="^brave-.*-Default$" + // Extensions popup open-floating true +} +// Full width window +window-rule { + match app-id="beekeeper-studio" + open-maximized true +} +window-rule { + match app-id="^org\\.keepassxc\\.KeePassXC$" + match app-id="^org\\.gnome\\.World\\.Secrets$" + // block-out-from "screen-capture" + // Use this instead if you want them visible on third-party screenshot tools. + block-out-from "screencast" +} +window-rule { + match app-id="brave-browser" + match at-startup=true + default-column-width { + proportion 0.5 + } +} +window-rule { + match title="^Meet: .*" app-id="brave-browser" + open-floating true +} +window-rule { + geometry-corner-radius 4 + clip-to-geometry true +} +layer-rule { + match namespace="kitty-quick-access" + geometry-corner-radius 12 + shadow { + on + spread 10 + softness 20 + offset x=-10 y=10 + } +} + diff --git a/configs/niri/work-laptop/local.kdl b/configs/niri/work-laptop/local.kdl index 0e93f89..fdb8b9d 100644 --- a/configs/niri/work-laptop/local.kdl +++ b/configs/niri/work-laptop/local.kdl @@ -1,5 +1,7 @@ +spawn-at-startup "brave" +spawn-at-startup "firefox" window-rule { - match app-id="brave-work" + match app-id="firefox" open-on-workspace "1" open-focused true default-column-width { @@ -7,7 +9,7 @@ window-rule { } } window-rule { - match app-id="brave-personal" + match app-id="brave-browser" open-on-workspace "2" open-focused false default-column-width { @@ -22,7 +24,7 @@ output "HDMI-A-1" { } output "eDP-1" { mode "1920x1080@60.000" - position x=0 y=720 + position x=0 y=0 layout { default-column-width { proportion 1.0