Lenient dead keys

Andre Majorel aym-11x at teaser.fr
Mon Jan 2 04:32:52 PST 2012


On 2012-01-02 13:09 +0200, Simos Xenitellis wrote:
> On Mon, Jan 2, 2012 at 10:57 AM, Andre Majorel <aym-11x at teaser.fr> wrote:
> 
> > Is there is a way to have a dead key output itself and the next
> > key if there is no valid combination ?
> >
> > E.G. with [^] mapped to dead_circumflex, have [^][a] output "â"
> > but [^][b] output "^b" instead of nothing.
> >
> >
> I think this would require to change the source code and recompile.
> You would either do this at the Xorg level (recompile Xorg) or the GTK+
> level (assuming you use the GNOME desktop environment, which replicates the
> Xorg functionality; recompile gtk+).
> For GNOME, you would need to make changes around
> http://git.gnome.org/browse/gtk+/tree/gtk/gtkimcontextsimple.c#n711

Thank you. No KnomeCE or QTK here, just FVWM and a bunch of
Xterms.

> There might be an easier workaround if you can give a description of what
> you are trying to achieve.
> For example, if you want to write a language that has a ^ over b, then you
> can use combining diacritics
> and write b?? (b + 0x302).

LC_CTYPE=en_US (ISO 8859-1).
        Driver          "evdev"
        Option          "XkbModel"      "pc105"
        Option          "XkbLayout"     "fr"

I type mainly code and French or English prose. The fr keyboard
layout comes with dead_circumflex, which is good because French
uses â, ê, î, ô, û and their upper case counterparts. But it
means one extra keystroke to go to column 1 in vi, negate a
character class, anchor a regexp, etc.

Since even in uxterm, [^][b] is a no-op, it's not clear what the
advantage of requiring an extra keystroke is.

-- 
André Majorel http://www.teaser.fr/~amajorel/



More information about the xorg mailing list