On 2022-11-23 02:21, Mike Fischer wrote:


> Am 23.11.2022 um 11:43 schrieb Vlad Meșco <vlad.me...@gmail.com>:
>
> On Wed, Nov 23, 2022 at 06:57:17AM +0000, Jason McIntyre wrote:
> > On Wed, Nov 23, 2022 at 12:21:26AM +0100, Mike Fischer wrote:

>
>
> keyboard.encoding=us
> keyboard.map+="keysym Caps_Lock = Control_L"
> mouse.tp.tapping=3
> mouse.reverse_scrolling=1
> keyboard.map+="keysym Caps_Lock = Control_L"

Duplicate?

...probably.


> keyboard.map+="keycode 184 = Cmd2 Mode_switch Multi_key"

I don't think I understand what this actually does?


In my case, maps right alt to AltGr. I don't remember exactly how it works, but I \ think CmdN tells the driver it's a modifier and the next N tokens tell it what.

First of all none of my ‚keyboard.map's have a keycode 184. I tried \
keyboard.encoding=us, keyboard.encoding=de, keyboard.encoding=fr, \
keyboard.encoding=fr.apple.

I don't know, there might be differences between PC, USB and Apple. I mentioned HU \
earlier because that definitely has altgr defined.

Second, if the columns normally represent levels (or layers), how does that work \ here? Plain 184 is Cmd2; 184 + some modifier is Mode_switch; and 184 + some other \
modifier is Multi_key (whatever that is supposed to mean)?

> # use ? for unicode that causes mojibake
> keyboard.map+="keycode 26 = question question bracketleft braceleft"
> keyboard.map+="keycode 27 = question question bracketright braceright"
> keyboard.map+="keycode 39 = question question semicolon colon"
> keyboard.map+="keycode 40 = question question apostrophe quotedbl"
> keyboard.map+="keycode 41 = question question grave asciitilde" # 3byte 
UTF-8, \
> don't bother keyboard.map+="keycode 43 = question question backslash bar"
> keyboard.map+="keycode 51 = comma semicolon less question"
> keyboard.map+="keycode 52 = period colon greater question"
>
> A more proper example for e.g. keycode 26:
>
> keyboard.map+="keycode 26 = abreve Abreve bracketleft braceleft"
>
> Or for keys that don't have a symbolic name:
>
> keyboard.map+="keycode 43 = unknown_50082 unknown_50050 backslash bar"
>
> I started from US which is 90% there, and the first thing is to add
> right Alt as `Mode_switch', otherwise it's just (left) Alt (which I
> think just sets the MSB, IDK; you want AltGr/Mode_switch if you want to
> map specific characters).
>
> Which keycode is what? I don't know. I dumped the hu layout as a
> reference with `doas wsconsctl keyboard.map > hu.map' and looked at what
> was done for that crazy layout, and started from there.
>
> Cheers,
> Vlad

Thanks, that helps somewhat. It still is strange to have to resort to experiments \
to figure things out instead of having them documented on OpenBSD.
By xkb do you mean xkeyboard-config(7)? I have looked at the man page but I \ honestly can't see much similarity to the keyboard.map syntax. I also looked at \ setxkbmap(1) and xkbcomp(1) but they where no help either. I don't normally use X \ for anything so I am not very familiar with all of the associated settings. https://www.x.org/wiki/XKB/ did seem to explain some relevant concepts though. For \ example the concept of levels which probably translates to the columns used in the \ keycode statements? But where are the definitions of which modifier (or combination \
thereof) selects which column?


Hello!

I would like to find some supporting documentation too, if anything is available, but for certain other reasons (https://github.com/letoram/arcan/issues/263). Basically, this "desktop engine" has problems with figuring out my keyboard layouts, and I want to figure out why. This might've been more appropriate to post in ports@ but this thread catched my eye, so I'm here. It would be nice to be able to determine what keycodes correspond to what symbols in console, to figure out what goes wrong in the process of how Arcan determines my keyboard layout. Any help appreciated!

Reply via email to