aboutsummaryrefslogtreecommitdiffstats
path: root/keybinds/README.md
blob: 11244d547a109f9c3abb4f8403cde9f50865fcdc (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
# keybinds

Every Hyprland keybind with what it does, grouped, over a dimmed screen.
SUPER+k opens it, Escape or a click closes it.

The list is `hyprctl binds -j`, asked on every opening, so it is what Hyprland
has loaded: binds generated in Lua loops included, and an edit to
`keybindings.lua` shows once `hyprctl reload` makes it real, not before.
There is no cache to go stale.

`hyprctl` reports every Lua action as `__lua` with an opaque number, so the
text comes from each bind's `description` option, written `Group: Label`:

    hl.bind("SUPER + w", hl.dsp.exec_cmd(P.browser), { description = "Apps: Browser" })

The part before `: ` is the heading. A bind with no description is listed
last under "Undescribed", so a missing one shows instead of vanishing.

Key names are Hyprland's unless `NAMES` in `Binds.js` gives a friendlier one
(`mouse:272` shows as `LMB`, `XF86Calculator` as `Fn+F9`), and SUPER shows as
Win. Add a line there to rename another.

The left fifth of the screen is the macropad, drawn as it sits on the desk:
twelve keys wearing their real keycaps' icons and colours, and the two
encoders. Hovering
a key or an encoder lists everything it does underneath, with what is held
and how an encoder is turned. `PAD` in `Binds.js` maps each combo the pad's
firmware sends to its place, keyed by the combo as displayed, so renaming a
key in `NAMES` means renaming it there too.

## Running

    qs -p ./keybinds
    qs -p ./keybinds ipc call keybinds toggle

## Blur

Optional, in the Hyprland config:

    hl.layer_rule({
        name         = "blur-keybinds",
        match        = { namespace = "^(quickshell-keybinds)$" },
        blur         = true,
        xray         = false,
        ignore_alpha = 0.1,
    })

## Check

    node keybinds/test_binds.js