7

I'm a workman user, and I've really grown to like the dead-key variant on osx.

The idea of using 'dead' keys is based on assumption that pressing 2 easy keys is better than pressing 1 hard key. So to make it easier to type (programming) characters/symbols, we're going to press an easily reachable key (which will NOT output any character), release it and then press another easily reachable key to produce, say, @ character.

In this layout the COMMA key is a dead key, pressing it will cause keyboard enter a state in which a single stroke of other keys will output a different character than normal state. After that single stroke, the keyboard returns to its normal state.

For example, you'd press COMMA to enter the special state. Now if you strike the A key the output will be a forward slash "/". To see how to create other characters, refer to following images for more info.

To produce the COMMA character itself, just hit SPACE after entering 'dead' state.

I'd like to achieve this functionality on Lubuntu (19.04) too, but I don't even know where to start... or if something like this is even possible. Could you please give me some pointers?

5
  • 1
    Are you running LXDE or LXQt? (we can't know unless you tell us, or at least tell us the release of Lubuntu).
    – guiverc
    Aug 4, 2019 at 22:44
  • I updated the question, 19.04, so I'm guessing LXQt?
    – tpv
    Aug 5, 2019 at 7:14
  • 1
    The compose key feature is kind of related to what you are after, but still different. And I'm not sure if that applies to qt... Aug 5, 2019 at 8:33
  • 1
    I've read about the compose key, but that seems to be quite different from a dead-key, as far as I understand, you'd have to keep it held down during the sequence.
    – tpv
    Aug 5, 2019 at 16:02
  • I've personally solved the problem changing the letters layout updating the firmware of my keyboard like this: github.com/herod2k/olkb_pianck_workman And I've left my OS on keyboard US INTL with dead keys. It works perfectly.
    – Herod2k
    Nov 22, 2020 at 18:16

3 Answers 3

0

From the site you provided

https://github.com/workman-layout/Workman/blob/master/linux_console/workman.iso15.kmap

This gets fed into xmodmap

xmodmap - utility for modifying keymaps and pointer button mappings in X

   The xmodmap program is used to edit and display the keyboard modifier map and keymap table
   that are used by client applications to  convert  event  keycodes  into  keysyms.   It  is
   usually  run from the user's session startup script to configure the keyboard according to
   personal tastes.

(http://manpages.ubuntu.com/manpages/disco/man1/xmodmap.1.html)

(Pointers only, For LXQt Lubuntu you maybe able to use the Keyboard and Mouse settings (Keyboard Layout) found through menu search using "keyb")

For more information :

Problems with xmodmap How do I set Xmodmap on login?

2
  • 1
    I am able to use this base layout, the thing I'm struggling with is how to modify comma to be a dead key as described above.
    – tpv
    Aug 5, 2019 at 7:16
  • @tpv You can force map ',' key to AltGr, next map the keys you to output (for example A for slash as AltGr + A)
    – Domo N Car
    Aug 7, 2019 at 12:57
0

You can do this potentially by changing the workman keymap in the following ways:

Change:

keycode  51 =          comma          less     dead_cedilla        asciitilde

to

keycode  51 =          Alt          less     dead_cedilla        asciitilde

Next, (for A to act as slash), add / as the action number 8 (example attached):

keycode  30 =              a             A           aacute            Aacute    Control_a  #   #    #    /

Test and you can add and modify the keyboard output to your desired layout.

1
  • Same as XIM/XKB files declaration. I suspect dead_cedillais hard coded some where?
    – user.dz
    Mar 2 at 9:24
0

I don't even know where to start... or if something like this is even possible. Could you please give me some pointers?

The easiest way for Lubuntu would be: LXDE ubuntu 17.04 - The use of dead keys to type accents does not seem to work, to ensure that you have ibus; assuming the proper setup below.

Pointers of where to start:

The readme for Workman in the tree/master/xmodmap directory says:

Go directory where you have unpacked Workman
  Type: setxkbmap us; xmodmap xmodmap/xmodmap.workman && xset r 66
  To switch back to QWERTY type: setxkbmap us; xset -r 66

The website "Shinobu's Secrets" webpage "Xorg: Switching Keyboard Layouts Consistenly and Reliably from Userspace" offers a complete set of scripts to switch your keyboard layout on the fly (without restarting X), that allows you to test your changes easily.

Another of the webpages "Xorg: Using the US International (altgr-intl variant) Keyboard Layout" explains how to set everything up using a US 104-key keyboard with the altgr-intl variant. That makes your right Alt key into your dead key.

On Romano Giannetti's blog his webpage "How to modify a keyboard layout in Linux" details instructions for Xubuntu in a country where laptops are not sold with US layout keyboards.

Finally, our question: How to have programmer-friendly Dvorak with deadkeys in Ubuntu? explains dead keys for a Dvorak layout, but is nowhere near as helpful as the above links.

Combining the instructions above to modify the xmodmap.workman script and related files should put you well on your way towards getting everything working.

Each of the above links are Waybacked here, so the links won't rot:

2
  • AltGr/RightAlt in (altgr-intl) is 3rd level shift/modifier key, not a dead-key. Some keyboard also set it as Composer key which also not a dead-key feature.
    – user.dz
    Mar 2 at 9:29
  • @user.dz, your comment here is misplaced. When we use a link to a StackExchange post the server automatically uses the title of the post as the text for the link If you have any information or corrections to offer it should be there.
    – Rob
    Mar 2 at 18:19

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .