site  contact  subhomenews

Kmap layout for Latin-American

October 18, 2017 — BarryK

It has been a long time since I worked with the keyboard layout files, had to relearn a few things.

In Quirky 8.3, Forum member ottod reported difficulty with selecting the Latin-American keyboard layout. I responded here:

http://murga-linux.com/puppy/viewtopic.php?p=971181#971181

But then it got me thinking. Quirky and Easy use Busybox "kmap" layout files, and these were originally converted from the format used in the "kbd" package (by the Tiny Core developers). A PET of these converted kmap files is here:

http://murga-linux.com/puppy/viewtopic.php?t=40658

Quirky and Easy have the kmap files in /lib/keymaps. Looking in the PET (from above link), I found "la-latin1.kmap", which is Latin-American!

So, I have put that into woofQ, at rootfs-skeleton/lib/keymaps/la-latin1,gz, and have modified QuickSetup (/usr/sbin/quicksetup) to show that in the keyboard layout drop-down list, identifying it as Latin-American.

/lib/keymaps has console layouts. This is different from layout when Xorg is running. Xorg layouts are in /etc/X11/xkb, and the Latin-American layout is named "latam" -- see /etc/X11/xkb/symbols/latam.

QuickSetup handles the mapping of console layout names to Xorg names, and I have added automatic mapping of "la-latin1" to "latam" when X starts.

Just for the record, any layout file from the "kbd" package can be converted to Busybox kmap format:

You can get kbd from here:

https://www.kernel.org/pub/linux/utils/kbd/

Or install it via the package manager.

The conversion goes something like this:

# loadkeys /usr/share/kbd/keymaps/i386/something.map.gz
# dumpkmap > something.kmap
# mv something.kmap /lib/keymaps/something
# cd /lib/keymaps
# gzip something

...I think that looks right, haven't tried it, not for a zillion years.

Tags: easy