Hello everyone, I am currently trying to set up a kmonad config file to replace the autohotkey script I used on windows. My goal is simply to use the right alt key in combination with a,o,u and so on to type german umlaut characters like ä,ö,ü, etc.
So far I am having trouble even getting kmonad to run the config. I guess I probably misunderstand how this is supposed to work significantly. My initial config file was generated by ChatGPT since I had no idea where to even start.
This is my current config file
(defcfg
input (device-file "/dev/input/by-path/platform-i8042-serio-0-event-kbd")
output (uinput-sink "kmonad_keyboard")
fallthrough true
allow-cmd true
)
(defsrc
ralt a o u s lsft
)
(deflayer german
ralt-a "ä"
ralt-o "ö"
ralt-u "ü"
ralt-s "ß"
ralt-shift-a "Ä"
ralt-shift-o "Ö"
ralt-shift-u "Ü"
)
Any help would be appreciated.
I did have a look at their tutorial and found it very technical, difficult to read and was unable to find any information on whether it is possible to send characters/text that are not part of the current keyboard layout. From what you describe I can guess now that kmonad is not really suited to what I am trying to achieve though.
The only way to send characters that are not part of the current layout is to use a compose key sequence. Which you would have to ask about in one of their communication circles. (reddit, etc.) Alternatively you could use command buttons which allow you to execute a command on key press. That way you could use ydotool (https://github.com/ReimuNotMoe/ydotool) to send a sequence to type the umlaut as described on ubuntu wiki (https://wiki.ubuntu.com/ComposeKey#Typing_Macrons.2C_Umlauts.2C_Accents.2C_…) That probably would not need Kmonad when I think about it though. You could just use keybindings of your window manager / desktop environment.