Keyboard Shortcuts settings feedback
Compositor
- [x] niri
- [ ] Hyprland
- [ ] dwl (MangoWC)
- [ ] sway
- [ ] Other (specify)
I wrote niri because I only use niri and have only tested on this compositor.
Distribution
Arch Linux
dms version
dms-git version v0.6.2-250-gae066f42
Description
I've been using the new Keyboard Shortcuts settings in DMS, it's great, but there's various bugs and things that can be improved.
Issues
1. Dashboard toggle doesn't work because it's missing the default "" argument.
This (default) doesn't work
Super+D hotkey-overlay-title="Dashboard: Toggle" { spawn "dms" "ipc" "call" "dash" "toggle"; }
This works (tho will get reverted when DMS cleans up the keybinds config file
Super+D hotkey-overlay-title="Dashboard: Toggle" { spawn "dms" "ipc" "call" "dash" "toggle" ""; }
2. Cannot bind certain keys (doesn't register or triggers something else while listening for keybind)
- Cannot bind shortcuts with
ESCbecause it will cancel the keybind listen box - Cannot bind
Alt+Print(it doesn't register), butCtrl+Printworks - Alt-Tab: Adding
Alt+Shift+Tabkeybind doesn't work, it changes the settings page - Cannot add mousewheel keybinds
3. Missing some niri actions (here's some I've noticed):
- set-column-width
- set-window-height
- center-visible-columns
- expand-column-to-available-width
- reset-window-height
- focus-workspace (by reference)
- move-column-to-workspace (by reference)
- set-column-width
- set-column-height
- switch-focus-between-floating-and-tiling
4. Some kdl parsing error
DMS settings will give kdl parsing error if I add any of these binds manually into DMS's binds.kdl file, but these work fine when put into niri's config.kdl
Mod+1 hotkey-overlay-title="Focus Workspace 1" { focus-workspace 1; }
Mod+2 hotkey-overlay-title="Focus Workspace 2" { focus-workspace 2; }
Mod+3 hotkey-overlay-title="Focus Workspace 3" { focus-workspace 3; }
Mod+4 hotkey-overlay-title="Focus Workspace 4" { focus-workspace 4; }
Mod+5 hotkey-overlay-title="Focus Workspace 5" { focus-workspace 5; }
Mod+6 hotkey-overlay-title="Focus Workspace 6" { focus-workspace 6; }
Mod+7 hotkey-overlay-title="Focus Workspace 7" { focus-workspace 7; }
Mod+8 hotkey-overlay-title="Focus Workspace 8" { focus-workspace 8; }
Mod+9 hotkey-overlay-title="Focus Workspace 9" { focus-workspace 9; }
Mod+0 hotkey-overlay-title="Focus Workspace 10" { focus-workspace 10; }
Mod+Shift+1 hotkey-overlay-title="Move to Workspace 1" { move-column-to-workspace 1 focus=false; }
Mod+Shift+2 hotkey-overlay-title="Move to Workspace 2" { move-column-to-workspace 2 focus=false; }
Mod+Shift+3 hotkey-overlay-title="Move to Workspace 3" { move-column-to-workspace 3 focus=false; }
Mod+Shift+4 hotkey-overlay-title="Move to Workspace 4" { move-column-to-workspace 4 focus=false; }
Mod+Shift+5 hotkey-overlay-title="Move to Workspace 5" { move-column-to-workspace 5 focus=false; }
Mod+Shift+6 hotkey-overlay-title="Move to Workspace 6" { move-column-to-workspace 6 focus=false; }
Mod+Shift+7 hotkey-overlay-title="Move to Workspace 7" { move-column-to-workspace 7 focus=false; }
Mod+Shift+8 hotkey-overlay-title="Move to Workspace 8" { move-column-to-workspace 8 focus=false; }
Mod+Shift+9 hotkey-overlay-title="Move to Workspace 9" { move-column-to-workspace 9 focus=false; }
Mod+Shift+0 hotkey-overlay-title="Move to Workspace 10" { move-column-to-workspace 10 focus=false; }
Super+Minus hotkey-overlay-title="Adjust Column Width -10%" { set-column-width "-10%"; }
Super+Equal hotkey-overlay-title="Adjust Column Width +10%" { set-column-width "+10%"; }
Super+Shift+Minus hotkey-overlay-title="Adjust Window Height -10%" { set-window-height "-10%"; }
Super+Shift+Equal hotkey-overlay-title="Adjust Window Height +10%" { set-window-height "+10%"; }
Suggestions
1. Add adjustable options for some ipc actions
To list a few (that I can think of):
- Volume/brightness
- (niri) set-column-width/set-window-height & focus-workspace/move-column-to-workspace (these are missing btw, see issue 3)
- (niri) screenshot commands (write-to-disk, show-pointer, etc), currently I have 2 different binds:
Print(screenshot screen to clipboard) andSuper+Print(screenshot screen and save to disk). DMS groups them into the same action "Screenshot Screen". I have to override them in niri's main config file so DMS doesn't mess with them and remove the arguments. - (niri) move window to workspace (focus=true/false)
- Maybe this can be applied to some DMS actions as well
Fixed, a bunch of it - but didnt test it extensively yet 6b1bbca620a0f6d6262dab8b9ec442c762862e41
Fixed, a bunch of it - but didnt test it extensively yet 6b1bbca
Thank you! Alt+Print works for me now.
edit: Alt+Shift+Tab also works 👍
edit 2: ESC works now, and kdl parsing error is gone too. I will do more testing
Arguments need a small fix tho:
screenshotonly hasshow-pointerparameterscreenshot-screenhas bothwrite-to-diskandshow-pointerparametersscreenshot-windowonly haswrite-to-diskparameter
niri will give an error if we mix these up.
Actions like move-column-to-workspace and focus-workspace show as Custom command when I expand them in the settings page
Also iirc focus for move-columnto-workspace is true by default in niri, so DMS should explicitly add focus=false when the option isn't ticked (currently it still follows focus for me even if I disabled it in DMS keybind settings).
ATM I can keep almost all my keybinds in dms/binds.kdl because DMS doesn't break them anymore (except Dashboard: Toggle because it still doesn't work, and screenshot binds because of mismatched ipc parameter options) ^^
I did some extra fixes for the states issues
I did some extra fixes for the states issues
Thank you! Sorry for the late reply, I was just able to test the latest commits, everything seems to be working now, except that screenshot-window shouldn't have the show-pointer option, you might've forgot that single one. Other than that, all my addressed issues are resolved <3
Also I just noticed that for the Brightness Up/Brightness Down/Volume Up/Volume Down DMS actions, their titles don't change when I adjust the percentage option in keybind settings.
Okay Dashboard: Toggle is still broken, I just found out.
Here's how I was able to reproduce it:
- Set
Dashboard: Togglebind in DMS settings (it writesspawn "dms" "ipc" "call" "dash" "toggle" ""which is expected) - Adjust something in DMS keybinds settings
Dashboard: Togglecommand becomesspawn "dms" "ipc" "call" "dash" "toggle";indms/binds.kdland stops working, also shows this in UI
I was gonna bring up removing the optional empty argument for dms ipc call dash toggle, but remembered you said something about a limitation that doesn't allow actual optional args?
Apparently some options in niri ipc screenshot actions also default to true if not explicitly stated, like show-pointer. This is similar to move-column-to-workspace's focus option.
So right now if I turn off the show pointer option in DMS settings, it'd still show up in screenshots.
In niri, when changing a dms brightness keybind through the dms settings menu, there is an issue where the empty string at the end of the command specifying "default device" will sometimes get stripped, even if it was there before
I think we're ready to close to out finally after iterating many improvements. The final update in this one lands via 510269dda901ca427909e09abfba1c5a50369a91