Remap symbols (characters) #388
-
First, thanks for the project, I find it great 😃 I was able to achieve a lot of complex and super useful stuff (home row mods, layers, shortcuts to drive workspaces/windows, launch apps,...) in a really simple manner, that's really fantastic. My question though is about doing a more simple thing, but I'm not sure if this is out of the scope of KMonad. Can I just remap symbols? Either in the same physical key or among keys? For example I'm interested in swapping the
I guess that at least in Linux probably The GoalThe goal is trying to get a universal key-map setup that can be ported among OSes (Linux/MacOS/Windows), so if I change job and I got a non-Linux computer I can keep using my custom keyboard with the less possible ceremony. Cheers! |
Beta Was this translation helpful? Give feedback.
Replies: 4 comments 11 replies
-
you can combine a button like |
Beta Was this translation helpful? Give feedback.
-
UPDATE 2023-12-07: After a lot of time I switched from KXB to keyd because of the linked issue in XKB related with hotpluggin devices (and very happy now!). See here: rvaiya/keyd#289 (comment) Hi folks! Here are my findings up 'till now:
🐧 For Linux: XKBGoing through the example of swapping the File:
File:
//
// Originally produced by `setxkbmap -print`, then modified to add symbol: myMods
// This keyboard map can be loaded by: `xkbcomp -I$HOME/.config/xkb kbmap $DISPLAY`
//
xkb_keymap {
xkb_keycodes { include "evdev+aliases(qwerty)" };
xkb_types { include "complete" };
xkb_compat { include "complete" };
xkb_symbols { include "pc+us(altgr-intl)+es:2+gb:3+inet(evdev)+compose(menu)+terminate(ctrl_alt_bksp)+myMods" };
xkb_geometry { include "pc(pc105)" };
}; File: //
// Adding `+myMods` to `xkb_symbols` in `~/.config/xkb/kbmap` file will load this mods.
// The whole keyboard map can be inspected with `xkbcomp $DISPLAY /tmp/kbmap-dump.xkb`
//
xkb_symbols "myMods" {
// Colon-semicolon
key <AC10> {
type[group1]= "FOUR_LEVEL",
symbols[Group1]= [ colon, semicolon, paragraph, degree ]
};
// ... other symbol swaps
}; 🐛 X.Org sleep/suspend issueLoading the modified key map on desktop startup works fine, but when you suspend your computer, the changes are lost 😢 This seems to be an old X.Org bug. I could come up with a workaround to solve that, by storing and restoring the keymap on sleep/resume. ❓ Open questionsThinking in porting the above to other platforms (preferably using configuration files based tools)
Thanks =) |
Beta Was this translation helpful? Give feedback.
-
having the ability to invert keys like OP is asking for would be amazing! I have been trying to do this in vim so that I can switch |
Beta Was this translation helpful? Give feedback.
-
Tools that I'm aware of:
Edit:
|
Beta Was this translation helpful? Give feedback.
UPDATE 2023-12-07:
After a lot of time I switched from KXB to keyd because of the linked issue in XKB related with hotpluggin devices (and very happy now!). See here: rvaiya/keyd#289 (comment)
Hi folks! Here are my findings up 'till now:
shift
-,
emmit$
; to say something).xkbcomp
) will do the job on Linux, and yes! it seems it shoul…