• You are not logged in.

    Ubuntu intl layout for Colemak

    • Started by kupkovski
    • 7 Replies:
    • Reputation: 0
    • From: Brazil
    • Registered: 21-Sep-2021
    • Posts: 1

    Hi all. My first post here!

    Do you know any ways of setting intl layout for Colemak in Ubuntu (gnome) ?
    I am from Brasil, and use accented letters all the time, but I've got a us layout keyboard.
    I recon there's a workaround (like using ALTgr + t, and the letter). However I'm used to type like

    ' + a

    to get

    á

    like on a normal intl layout like English Intl 

    Any tips?

    Offline
    • 0
    • Reputation: 214
    • From: Viken, Norway
    • Registered: 13-Dec-2006
    • Posts: 5,364

    What you're describing is an accent Dead Key. These are in the Colemak layout, but not in good positions for Portuguese. As you say, AltGr is a sucky solution for languages with many accents as for instance the A key should ideally have all of the letters ÁáÀàÂâÃã on it and that won't fit!

    In the BigBag, I've made locale solutions with accessible dead keys for many languages. Hope you like it! The Forum XKB topic has the best explanations for Linux so far.

    Another method is to use the Compose key. You can set it in Ubuntu. Then you hit Compose and type for instance e' for é, or you can have the actual acute accent somewhere and auto-compose with that like a dead key.

    ( Θώθ)  ~(  See "DreymaR's Big Bag Of Keyboard Tricks"  )
      https://dreymar.colemak.org

    Last edited by DreymaR (23-Sep-2021 10:02:07)

    *** Learn Colemak in 2–5 steps with Tarmak! ***
    *** Check out my Big Bag of Keyboard Tricks for Win/Linux/TMK... ***

    Offline
    • 0
    • Reputation: 23
    • From: Belgium
    • Registered: 26-Feb-2008
    • Posts: 482

    You can also define your own compose sequences in an .XCompose file in your homedir.  You can create arbitrary sequences, with or without compose key, and they are independent of the keyboard layout.

    For example for á (and corresponding capital Á), you can add the following lines:

    <acute> <a>                 : "á"   aacute
    <acute> <A>                 : "Á"   Aacute

    (what the "us intl" layout actually does is map the <'> key to <dead_acute>, for which many pre-defined compose sequences exist.)

    Offline
    • 1
    • Reputation: 214
    • From: Viken, Norway
    • Registered: 13-Dec-2006
    • Posts: 5,364

    I forgot what else you had to do to get your private .XCompose file sourced reliably. There were some problems, as I remember.

    Those lines you mention are already in the standard Compose tables as Compose key sequences. Using them without the dedicated key would lead to trouble when you want to write for instance markdown `code` tags and get `codè with a grave accent instead. Just be aware.

    Furthermore, I think OP wanted to use the apostrophe which is even more commonly involved in bigrams you don't want to auto-compose. So I suggest another tack. In XKB, you can define a mapping as for instance `dead_acute` to have it auto-compose. These sequences are also already in the standard Compose tables.

    Last edited by DreymaR (23-Sep-2021 10:53:24)

    *** Learn Colemak in 2–5 steps with Tarmak! ***
    *** Check out my Big Bag of Keyboard Tricks for Win/Linux/TMK... ***

    Offline
    • 0
    • Reputation: 23
    • From: Belgium
    • Registered: 26-Feb-2008
    • Posts: 482

    The US intl layout kupkovski was using before, has the same effect as you describe (which is why many dislike it).
    But typically acute+acute (or in us intl case dead_acute+dead_acute) yields the actual, non-modifier acute character, so you can enter ''a'' to get 'a' (and not 'á'' or something like that, as the first complete combination wins).

    Proper deadkeys would indeed be more predictable, but this requires editing the colemak layout file.

    Last edited by ghen (24-Sep-2021 17:47:34)
    Offline
    • 0
    • Reputation: 214
    • From: Viken, Norway
    • Registered: 13-Dec-2006
    • Posts: 5,364

    Back to my question: What does it take to make your ~/.XCompose file get sourced robustly without hassle? Is that a thing of the past, that works perfectly these days, or are there still trip-ups? Was it something about Gnome? I don't quite remember.

    Last edited by DreymaR (23-Sep-2021 13:32:21)

    *** Learn Colemak in 2–5 steps with Tarmak! ***
    *** Check out my Big Bag of Keyboard Tricks for Win/Linux/TMK... ***

    Offline
    • 0
    • Reputation: 23
    • From: Belgium
    • Registered: 26-Feb-2008
    • Posts: 482

    I used it quite extensively, for example to get Colemak AltrGr+\ mappings , but also for my own list of exotic Cyrillic characters via compose sequences (which I am still to finalize and submit upstream, some day).

    It works out of the box for standard X11 apps, but GTK+ (incl. Gnome) apps may use their own IME, bypassing this.  Setting GTK_IM_MODULE=xim fixes this, see our conversation in this thread for more info. (a topic from 2009 ;-))

    Offline
    • 1
    • Reputation: 214
    • From: Viken, Norway
    • Registered: 13-Dec-2006
    • Posts: 5,364

    Yes, I do remember that thread! I think that somehow the include for the normal composes in the local file didn't work for me. I wasn't so experienced with Linux back then. I see that I did a fair bit of work on creating sequences for my DK mappings and then just abandoned it in frustration. Ugh.

    *** Learn Colemak in 2–5 steps with Tarmak! ***
    *** Check out my Big Bag of Keyboard Tricks for Win/Linux/TMK... ***

    Offline
    • 0