joshgoebel / keyszer

a smart, flexible keymapper for X11 (a fork/reboot of xkeysnail )
Other
69 stars 15 forks source link

Make shorter aliases available for all modifiers #118

Closed RedBearAK closed 1 year ago

RedBearAK commented 1 year ago

Since there was already "A", and "C", and the code doesn't seem to be bothered by having modifiers represented by single characters as long as they aren't in the final position in the shortcut combo, this adds short and "very short" aliases for as many modifiers as possible.

New aliases: Sup, S, W, O, Sh, Cd, and their L/R variants.

Shift and Command would be ambiguous with single character aliases, so are shortened to a minimum of 2 characters so they can still be distinguished from Super/Sup/S and Control/Ctrl/C.

The logic of these shorter aliases should be intuitive for users that have already seen or used the "RC/LC/C" and "RA/LA/A" aliases. Leaving Meta alone for now, to avoid confusion with the past "M" = "Alt" that was removed.

Changes

Checklist

joshgoebel commented 1 year ago

I entirely dislike this, it makes the macros super hard to read. Long-term now I'm considering deprecating the 1 and 2 letter variants, they aren't very good and we only have them because we inherited them.

This is also easy enough to add with pure Python if someone really thought this was a good idea - it doesn't need to be in core.

Sorry.

RedBearAK commented 1 year ago

@joshgoebel

I can kind of understand the reaction to the shorter ones. Are the 3-letter non-ambiguous variants acceptable? Sup, Opt?

joshgoebel commented 1 year ago

Opt is a common abbrev., I don't think that's true of "Sup" for super.

RedBearAK commented 1 year ago

Opt is a common abbrev., I don't think that's true of "Sup" for super.

Well, in most cases when it's shown as a shortcut it would probably be shown as wither Win or Cmd, or Meta in the case of KDE. It's mainly GNOME desktops that seem to want to call it Super. They don't abbreviate it like they do with Ctrl, so maybe you're right.