2

I found in

Two keyboards two language layouts

that it is possible to assign a specific layout to a specific keyboard device.

I want to use a keyboard as a pure hot-keys/macro one (for commanding the functions of GIMP, Photoshop or MangaStudio), by creating a keyboard layout comprised of Unicode characters outside the ones present in my other keyboards, and then using Autokey to creating the actual macro calls.

Not as seamless as HidMacros in Windows, but still manageable (also, Autokey has a filters on window names that would allow to keep uniform the shortcuts layout, no matter the application in use).

The first step, was checking the behaviour of setxkbmap in my system.

I proceeded to check my xinput list, obtaining

$ xinput --list
⎡ Virtual core pointer                      id=2    [master pointer  (3)]
⎜   ↳ Virtual core XTEST pointer                id=4    [slave  pointer  (2)]
⎜   ↳ Logitech Unifying Device. Wireless PID:400e   id=10   [slave  pointer  (2)]
⎜   ↳ Wacom Intuos2 12x18 stylus                id=11   [slave  pointer  (2)]
⎜   ↳ PixArt USB Optical Mouse                  id=14   [slave  pointer  (2)]
⎜   ↳ PixArt USB Optical Mouse                  id=15   [slave  pointer  (2)]
⎜   ↳ SynPS/2 Synaptics TouchPad                id=17   [slave  pointer  (2)]
⎜   ↳ Wacom Intuos2 12x18 eraser                id=19   [slave  pointer  (2)]
⎜   ↳ Wacom Intuos2 12x18 cursor                id=20   [slave  pointer  (2)]
⎣ Virtual core keyboard                     id=3    [master keyboard (2)]
    ↳ Virtual core XTEST keyboard               id=5    [slave  keyboard (3)]
    ↳ Power Button                              id=6    [slave  keyboard (3)]
    ↳ Video Bus                                 id=7    [slave  keyboard (3)]
    ↳ Power Button                              id=8    [slave  keyboard (3)]
    ↳ CNF7051                                   id=9    [slave  keyboard (3)]
    ↳ CHESEN USB Keyboard                       id=12   [slave  keyboard (3)]
    ↳ CHESEN USB Keyboard                       id=13   [slave  keyboard (3)]
    ↳ AT Translated Set 2 keyboard              id=16   [slave  keyboard (3)]
    ↳ Toshiba input device                      id=18   [slave  keyboard (3)]
    ↳ SIGMACHIP USB Keyboard                    id=22   [slave  keyboard (3)]

Now, what I would like to do is to assign a different layout to the two "CHESEN USB Keyboard" - one is the media keys, that I "physically eliminated" when assembling, whell, no matter - and leave the rest of the keyboards with the current layout (Spanish, with mute tilde).

In particular, the Logitech wireless K400 that I use as main keyboard/pointer (that's very comfy).

Oddly enough, I do not see the K400 keyboard in the xinput list, just an entry for the the Logitech unifying device, listed as a pointer.

So, as a test I tried to insert the command

~$ setxkbmap -device 12 -layout us

And, to be honest, it works as advertised... but for the K400.

Apparently, the K400 has no layout of her own... it just uses the layout of the last keyboard that has been used.

So, if I now press a key on the Chesen, the Logitech suddenly switches to a US layout (with the ñ symbol replaced by a ;), only to revert to a Spanish layout the moment I press a key on the sigmachip keyboard.

What is happening here? Have I a way to fix the behaviour of the K400?

0 Answers0