xkbmap with combining diacritics

Joshua Crowgey jcrowgey at uw.edu
Thu Feb 21 12:41:40 PST 2013


On 02/18/2013 12:52 PM, Simos Xenitellis wrote:
> On Mon, Feb 18, 2013 at 10:25 PM, Joshua Crowgey<jcrowgey at uw.edu>  wrote:
>> Hi xorg,
>>
>> It was recommended to me in #xorg on irc that I should post this question to
>> your list.  I hope this is appropriate.
>>
>> I have been attempting to define a keyboard mapping for typing Lushootseed
>> (aka, Puget Salish) [iso639-3:lut].  Ideally, I will use the layout that
>> Dave Sienko at Tulalip has already implemented in Tauvlesoft.
>>
>> http://www.tulaliplushootseed.com/NWIC-103-2009/Lushootseed%20Font%20&%20Keyboard.htm
>>
>> To do so, I created a lut.symbols file which handles much of the job
>> (attached).  Here's a snippet:
>>
>> key<AD01>   { [         q,          Q,           U0251, U252 ]  };
>> key<AD02>   { [         w,          W,      U01BF,      U01F7 ] };
>> key<AD03>   { [         schwa,      E,  schwa,          SCHWA]  };
>> key<AD04>   { [         U0161,          R,    U0279,   U027E ]  };
>>
>> However, I was unable to implement the mapping (shown in the link to
>> tulaliplushootseed.com) completely because the output of many of the upper
>> case (shifted) keystrokes should be a series of unicode characters rather
>> than a single one.  That is, I have to use combining diacritics.  However, I
>> was unable to define a series of characters in this file without generating
>> an error.  For example, each of the following attempts fail because, from
>> what I can tell, there's no way to include more than a single unicode
>> code-point as one of the values in the array.  I haven't discovered any
>> quoting or grouping mechanism.
>>
>> ---
>> key<AD01>   { [         q,      q̓,     U0251, U252 ]  };
>> ---
>> ---
>> key<AD01>   { [         q,      "q̓",   U0251, U252 ]  };
>> ---
>> ---
>> key<AD01>   { [         q,      qU0313, U0251, U252 ]  };
>> ---
>> ---
>> key<AD01>   { [         q,      U0071U0313,     U0251, U252 ]  };
>> ---
>> ---
>> key<AD01>   { [         q,      U0071+U0313,    U0251, U252 ]  };
>> ---
>>
>> The question is this:  is there a way to define keyboards that implement
>> characters that include combining diacritics in the output of specific keys?
>> Where can I find out more about what steps I should undertake to define an
>> official keyboard for typing Lushootseed on xorg?
>>
>> Please let me know if this question is more appropriate for another list or
>> if I should refine the question in some way.
>>
>
> Hello,
> For your requirements and the complexity of the keyboard layout, you
> may have a better chance to create a keyboard layout for iBus. See
> more at http://code.google.com/p/ibus/
>
> It is possible to create a keyboard layout with XKB, however I think
> it will be more complicated than necessary.
>
> If you are happy to make something quick and dirty, you can create the
> necessary compose sequences and put them in ~/.Xcompose
>
> Simos

Hello Simos,

Thank you for the suggestions.  In fact, I did get something working by 
creating an .XCompose file (should it be .Xcompose with lower c?).  And 
at one point, I even got that working.  I had to set some environment 
variables such as GTK_IM_MODULE=xim and I think I had to run imswitch 
and set it to SCIM?  In any case, I went away for a week and haven't 
gotten that approach working again.  It would be nice if there was a 
setxcompose command that let me dynamically set the xcompose file or 
not.  When typing in English, for example, I don't want the XCompose 
file to be active.  I want it active after switching to Lushootseed.

I also played around with ibus but it seems to be a bit tricky to get 
working on debian testing at the moment.  My package manager is chocking 
on an ibus dependency of im-clutter, which seems to have some sort of 
error as of the last time I tried to install it.

In short, I appreciate the reply and I'll try renaming my ~/.XCompose to 
~/.Xcompose to see if that makes a difference with automatically finding it.

Best regards,
--Joshua

PS: here is my XCompose file as I have authored it:

jcrowgey at citrus:~$ cat ~/.XCompose
<Q> : "q̓"
<W> : "w̓"
<E> : "q̓ʷ"
<R> : ""
<T> : "t̕"
<Y> : "y̓"
<U> : ""
<I> : "kʷ"
<O> : ""
<P> : "p̓"
<A> : "qʷ"
<S> : ""
<D> : "dᶻ"
<F> : ""
<G> : "gʷ"
<H> : ""
<J> : "k̓ʷ"
<K> : "k̓"
<L> : "l̕"
<colon> : "ƛ̕"
<z> : "x̌"
<Z> : "x̌ʷ"
<X> : "xʷ"
<C> : "c̓"
<V> : "č̓"
<B> : ""
<N> : "n̓"
<M> : "m̓"

The one time I got this working, I ran 'setxkbmap lut' to set the keys 
that didn't require combining diacritics.


More information about the xorg mailing list