4

I know it is relatively easy creating a custom keyboard layout, but it seems like I have to do that for both two desktop environments installed on my Ubuntu 14.04 laptop (Unity and KDE). And what is more important - I already have a .klc (microsoft keyboard layer creator) file with desired layout done in windows. Is there some tool that offers importing keyboard layout out from windows available for linux and especially for Ubuntu?

UPDATE:

@Helio, just realized that .klc is not binary but a text file, so I do now include its contents:

KBD Glagolic    "Glagolotsa BG phonetic - new"

COPYRIGHT   "(c) 2012 Company"

COMPANY "mycomp"

LOCALENAME  "bg-BG"

LOCALEID    "00000402"

VERSION 1.0

SHIFTSTATE

0   //Column 4
1   //Column 5 : Shft
2   //Column 6 :       Ctrl

LAYOUT      ;an extra '@' at the end is a dead key

//SC    VK_     Cap 0   1   2
//--    ----        ----    ----    ----    ----

1e  A       0   e0d6    -1  -1      // Private Use , <none>, <none>
1f  S       0   e192    -1  -1      // Private Use , <none>, <none>
20  D       0   e133    -1  -1      // Private Use , <none>, <none>
21  F       0   e0f1    -1  -1      // Private Use , <none>, <none>
22  G       0   e037    -1  -1      // Private Use , <none>, <none>
23  H       0   e073    -1  -1      // Private Use , <none>, <none>
24  J       0   e1c4    -1  -1      // Private Use , <none>, <none>
25  K       0   e0f9    -1  -1      // Private Use , <none>, <none>
26  L       0   e130    -1  -1      // Private Use , <none>, <none>
2c  Z       0   e1c0    -1  -1      // Private Use , <none>, <none>
2d  X       0   e167    -1  -1      // Private Use , <none>, <none>
2e  C       0   e00e    -1  -1      // Private Use , <none>, <none>
2f  V       0   e147    -1  -1      // Private Use , <none>, <none>
30  B       0   e102    -1  -1      // Private Use , <none>, <none>
31  N       0   e04b    -1  -1      // Private Use , <none>, <none>
32  M       0   e002    -1  -1      // Private Use , <none>, <none>
39  SPACE       0   0020    0020    -1      // SPACE, SPACE, <none>
53  DECIMAL 0   002e    002e    -1      // FULL STOP, FULL STOP, 


KEYNAME

01  Esc
0e  Backspace
0f  Tab
1c  Enter
1d  Ctrl
2a  Shift
36  "Right Shift"
37  "Num *"
38  Alt
39  Space
3a  "Caps Lock"
3b  F1
3c  F2
3d  F3
3e  F4
3f  F5
40  F6
41  F7
42  F8
43  F9
44  F10
45  Pause
46  "Scroll Lock"
47  "Num 7"
48  "Num 8"
49  "Num 9"
4a  "Num -"
4b  "Num 4"
4c  "Num 5"
4d  "Num 6"
4e  "Num +"
4f  "Num 1"
50  "Num 2"
51  "Num 3"
52  "Num 0"
53  "Num Del"
54  "Sys Req"
57  F11
58  F12
7c  F13
7d  F14
7e  F15
7f  F16
80  F17
81  F18
82  F19
83  F20
84  F21
85  F22
86  F23
87  F24

KEYNAME_EXT

1c  "Num Enter"
1d  "Right Ctrl"
35  "Num /"
37  "Prnt Scrn"
38  "Right Alt"
45  "Num Lock"
46  Break
47  Home
48  Up
49  "Page Up"
4b  Left
4d  Right
4f  End
50  Down
51  "Page Down"
52  Insert
53  Delete
54  <00>
56  Help
5b  "Left Windows"
5c  "Right Windows"
5d  Application

DESCRIPTIONS

0409    Glagolotsa BG phonetic - new
LANGUAGENAMES

0409    Bulgarian (Bulgaria)
ENDKBD

This example (halfly) implements glagolitic alphabet as custom keyboard layout.

2
  • Can you put a example file?
    – 0x2b3bfa0
    Apr 28, 2015 at 18:04
  • I have an example file (incomplete but still working as general example), but what is the reliable file - hosting provider Ask Ubuntu recommends (or is used here most frequently) for I haven't uploaded files but only their contents on the SO platform (assuming it's the same as Ask Ubuntu's one)? The .klc file contains random characters mainly from the private use unicode space, which shall enable characters (viewable by using particular font) to get assigned to keyboard keys and thus making it possible to type them using the newly created keyboard layout.
    – lrd
    Apr 29, 2015 at 9:30

1 Answer 1

1

The answer is no.

Mind though that a topic related to this already exists on AskUbuntu: Create my own keyboard input layout and it has not got an answer on how to import a .klc. It only states alternatives.

And our own help on creating a new keyboard lay-out also does not mention any import tool.

The best way to create a new lay-out is by copying an existing one from Ubuntu to a new name and then edit the changes into this new lay-out. So it is all manual work.

3
  • That's true, I have done it this way already, just have to copy the character codes from the .klc to a new xkb keyboard layout. However, I am sure it will be easier with the script and I may try to write one (probably it will be in php for it is the language I most often use). Meanwhile I will add an example on what one have to replace as an answer.
    – lrd
    Apr 30, 2015 at 8:46
  • @lrd cool but you probably need to do that with another q and a (since this specifically asks for an import tool ;))
    – Rinzwind
    Apr 30, 2015 at 8:47
  • @all + be careful am not sure, but M$ realized now the power of some coding languages in Linux too so they seem to try spyware-injections too into linux-codes only for a new image for whatever-M$-distro (10 or 11 or 12 or 1x ... ) + by this when you import all sorts of M$-fileformats the risk then would be higher ... that Linux-Distro is behaving like a samba-distro or similiar ... May 3, 2015 at 12:52

You must log in to answer this question.

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