• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1// Keyboard layouts for the Ukraine.
2// AEN <aen@logic.ru> & Leon Kanter <leon@geon.donetsk.ua>
3// last changes 2007/10/03 by Andriy Rysin <arysin@yahoo.com>
4
5// Oleksiy Protas <elfy.ua@gmail.com>:
6// - Added Serbian Cyrillics support
7
8// The legacy WinKeys layout extended on the third and fourth level with
9// some Unicode symbols (typographic quotes, m-dash, n-dash, ...), some
10// often-used Cyrillics from other Slavic languages, and some often-used
11// ASCII symbols (slash, brackets, ...).
12default partial alphanumeric_keys
13xkb_symbols "unicode" {
14
15    include "ua(winkeys)"
16    name[Group1]= "Ukrainian";
17
18    key <TLDE> { [      apostrophe,           U02BC,          U0301,          asciitilde  ] };  // Apostrophe and Stress symbol
19    key <AE01> { [               1,          exclam,    onesuperior                       ] };
20    key <AE02> { [               2,        quotedbl,    twosuperior,               U2019  ] };  // single quote used often as an apostrophe (deprecated)
21    key <AE03> { [               3,      numerosign,          U00A7,               U20B4  ] };  // Paragraph and Hryvnia sign
22    key <AE04> { [               4,       semicolon,         dollar,            EuroSign  ] };
23    key <AE05> { [               5,         percent,         degree                       ] };
24    key <AE06> { [               6,           colon,           less                       ] };
25    key <AE07> { [               7,        question,        greater                       ] };
26    key <AE08> { [               8,        asterisk, enfilledcircbullet                   ] };
27    key <AE09> { [               9,       parenleft,    bracketleft,           braceleft  ] };
28    key <AE10> { [               0,      parenright,   bracketright,          braceright  ] };
29    key <AE11> { [           minus,      underscore,         emdash,              endash  ] };
30    key <AE12> { [           equal,            plus,       notequal,           plusminus  ] };
31
32    key <AD03> { [      Cyrillic_u,      Cyrillic_U, Byelorussian_shortu, Byelorussian_SHORTU  ] };
33    key <AD04> { [     Cyrillic_ka,     Cyrillic_KA,     registered                       ] };  // Registered tm
34    key <AD05> { [     Cyrillic_ie,     Cyrillic_IE,    Cyrillic_io,         Cyrillic_IO  ] };
35    key <AD12> { [    Ukrainian_yi,    Ukrainian_YI, Cyrillic_hardsign,Cyrillic_HARDSIGN  ] };
36    key <AC02> { [     Ukrainian_i,     Ukrainian_I,  Cyrillic_yeru,       Cyrillic_YERU  ] };
37    key <AC11> { [    Ukrainian_ie,    Ukrainian_IE,     Cyrillic_e,          Cyrillic_E  ] };
38
39    key <BKSL> { [ Ukrainian_ghe_with_upturn, Ukrainian_GHE_WITH_UPTURN, backslash,  bar  ] };
40
41    key <AB03> { [     Cyrillic_es,     Cyrillic_ES,      copyright                       ] };
42    key <AB06> { [     Cyrillic_te,     Cyrillic_TE,      trademark                       ] };
43    key <AB08> { [     Cyrillic_be,     Cyrillic_BE,  guillemotleft,  doublelowquotemark  ] };
44    key <AB09> { [     Cyrillic_yu,     Cyrillic_YU, guillemotright, leftdoublequotemark  ] };
45    key <AB10> { [          period,           comma,          slash,            ellipsis  ] };
46
47    // Serbian Vukovica
48    key <AD01> { [ Cyrillic_shorti, Cyrillic_SHORTI,    Cyrillic_je,         Cyrillic_JE  ] };
49    key <AD02> { [    Cyrillic_tse,    Cyrillic_TSE,  Cyrillic_dzhe,       Cyrillic_DZHE  ] };
50    key <AC09> { [     Cyrillic_de,     Cyrillic_DE,    Serbian_dje,         Serbian_DJE  ] };
51    key <AB02> { [    Cyrillic_che,    Cyrillic_CHE,   Serbian_tshe,        Serbian_TSHE  ] };
52    key <AC08> { [     Cyrillic_el,     Cyrillic_EL,   Cyrillic_lje,        Cyrillic_LJE  ] };
53    key <AD06> { [     Cyrillic_en,     Cyrillic_EN,   Cyrillic_nje,        Cyrillic_NJE  ] };
54
55    include "level3(ralt_switch)"
56};
57
58partial alphanumeric_keys
59xkb_symbols "legacy" {
60
61    name[Group1]= "Ukrainian (legacy)";
62
63    key <TLDE> { [      apostrophe,      asciitilde  ] };
64    key <AE01> { [               1,         exclam   ] };
65    key <AE02> { [               2,        quotedbl  ] };
66    key <AE03> { [               3,      numbersign  ] };
67    key <AE04> { [               4,        asterisk  ] };
68    key <AE05> { [               5,           colon  ] };
69    key <AE06> { [               6,           comma  ] };
70    key <AE07> { [               7,          period  ] };
71    key <AE08> { [               8,       semicolon  ] };
72    key <AE09> { [               9,       parenleft  ] };
73    key <AE10> { [               0,      parenright  ] };
74    key <AE11> { [           minus,      underscore  ] };
75    key <AE12> { [           equal,            plus  ] };
76
77    key <AD01> { [ Cyrillic_shorti, Cyrillic_SHORTI  ] };
78    key <AD02> { [    Cyrillic_tse,    Cyrillic_TSE  ] };
79    key <AD03> { [      Cyrillic_u,      Cyrillic_U  ] };
80    key <AD04> { [     Cyrillic_ka,     Cyrillic_KA  ] };
81    key <AD05> { [     Cyrillic_ie,     Cyrillic_IE  ] };
82    key <AD06> { [     Cyrillic_en,     Cyrillic_EN  ] };
83    key <AD07> { [    Cyrillic_ghe,    Cyrillic_GHE  ] };
84    key <AD08> { [    Cyrillic_sha,    Cyrillic_SHA  ] };
85    key <AD09> { [  Cyrillic_shcha,  Cyrillic_SHCHA  ] };
86    key <AD10> { [     Cyrillic_ze,     Cyrillic_ZE  ] };
87    key <AD11> { [     Cyrillic_ha,     Cyrillic_HA  ] };
88    key <AD12> { [    Ukrainian_yi,    Ukrainian_YI  ] };
89    key <BKSL> { [ Ukrainian_ghe_with_upturn, Ukrainian_GHE_WITH_UPTURN ] };
90
91    key <AC01> { [     Cyrillic_ef,     Cyrillic_EF  ] };
92    key <AC02> { [     Ukrainian_i,     Ukrainian_I  ] };
93    key <AC03> { [     Cyrillic_ve,     Cyrillic_VE  ] };
94    key <AC04> { [      Cyrillic_a,     Cyrillic_A   ] };
95    key <AC05> { [     Cyrillic_pe,     Cyrillic_PE  ] };
96    key <AC06> { [     Cyrillic_er,     Cyrillic_ER  ] };
97    key <AC07> { [      Cyrillic_o,     Cyrillic_O   ] };
98    key <AC08> { [     Cyrillic_el,     Cyrillic_EL  ] };
99    key <AC09> { [     Cyrillic_de,     Cyrillic_DE  ] };
100    key <AC10> { [    Cyrillic_zhe,    Cyrillic_ZHE  ] };
101    key <AC11> { [    Ukrainian_ie,    Ukrainian_IE  ] };
102
103    key <AB01> { [     Cyrillic_ya,     Cyrillic_YA  ] };
104    key <AB02> { [    Cyrillic_che,    Cyrillic_CHE  ] };
105    key <AB03> { [     Cyrillic_es,     Cyrillic_ES  ] };
106    key <AB04> { [     Cyrillic_em,     Cyrillic_EM  ] };
107    key <AB06> { [     Cyrillic_te,     Cyrillic_TE  ] };
108    key <AB05> { [      Cyrillic_i,      Cyrillic_I  ] };
109    key <AB07> {[Cyrillic_softsign,Cyrillic_SOFTSIGN ] };
110    key <AB08> { [     Cyrillic_be,     Cyrillic_BE  ] };
111    key <AB09> { [     Cyrillic_yu,     Cyrillic_YU  ] };
112    key <AB10> { [           slash,        question  ] };
113
114    key <LSGT> { [           slash,             bar  ] };
115};
116
117partial alphanumeric_keys
118xkb_symbols "winkeys" {
119
120    include "ua(legacy)"
121    name[Group1]= "Ukrainian (Windows)";
122
123    key <AE03> { [               3,      numerosign  ] };
124    key <AE04> { [               4,       semicolon  ] };
125    key <AE05> { [               5,         percent  ] };
126    key <AE06> { [               6,           colon  ] };
127    key <AE07> { [               7,        question  ] };
128    key <AE08> { [               8,        asterisk  ] };
129    key <AB10> { [          period,           comma  ] };
130};
131
132partial alphanumeric_keys
133xkb_symbols "typewriter" {
134
135    include "ua(legacy)"
136    name[Group1]= "Ukrainian (typewriter)";
137
138    key <TLDE> { [      apostrophe,        quotedbl  ] };
139    key <AE01> { [          exclam,               1  ] };
140    key <AE02> { [      numerosign,               2  ] };
141    key <AE03> { [           slash,               3  ] };
142    key <AE04> { [       semicolon,               4  ] };
143    key <AE05> { [           colon,               5  ] };
144    key <AE06> { [           comma,               6  ] };
145    key <AE07> { [          period,               7  ] };
146    key <AE08> { [      underscore,               8  ] };
147    key <AE09> { [        question,               9  ] };
148    key <AE10> { [         percent,               0  ] };
149
150    key <AD12> { [ Ukrainian_ghe_with_upturn, Ukrainian_GHE_WITH_UPTURN ] };
151
152    key <AC02> { [      Cyrillic_i,      Cyrillic_I  ] };
153
154    key <AB05> { [     Ukrainian_i,     Ukrainian_I  ] };
155    key <AB10> { [    Ukrainian_yi,    Ukrainian_YI  ] };
156
157    key <BKSL> { [       parenleft,      parenright  ] };
158};
159
160partial alphanumeric_keys
161xkb_symbols "phonetic" {
162
163  include "ua(legacy)"
164  name[Group1]= "Ukrainian (phonetic)";
165
166    key <LatQ> { [ Cyrillic_ya,       Cyrillic_YA        ] };
167    key <LatW> { [ Cyrillic_ve,       Cyrillic_VE        ] };
168    key <LatE> { [ Cyrillic_ie,       Cyrillic_IE        ] };
169    key <LatR> { [ Cyrillic_er,       Cyrillic_ER        ] };
170    key <LatT> { [ Cyrillic_te,       Cyrillic_TE        ] };
171    key <LatY> { [ Cyrillic_i,        Cyrillic_I         ] };
172    key <LatU> { [ Cyrillic_u,        Cyrillic_U         ] };
173    key <LatI> { [ Ukrainian_i,       Ukrainian_I        ] };
174    key <LatO> { [ Cyrillic_o,        Cyrillic_O         ] };
175    key <LatP> { [ Cyrillic_pe,       Cyrillic_PE        ] };
176    key <AD11> { [ Cyrillic_sha,      Cyrillic_SHA       ] };
177    key <AD12> { [ Cyrillic_shcha,    Cyrillic_SHCHA     ] };
178
179    key <LatA> { [ Cyrillic_a,        Cyrillic_A         ] };
180    key <LatS> { [ Cyrillic_es,       Cyrillic_ES        ] };
181    key <LatD> { [ Cyrillic_de,       Cyrillic_DE        ] };
182    key <LatF> { [ Cyrillic_ef,       Cyrillic_EF        ] };
183    key <LatG> { [ Cyrillic_ghe,      Cyrillic_GHE       ] };
184    key <LatH> { [ Cyrillic_ha,       Cyrillic_HA        ] };
185    key <LatJ> { [ Cyrillic_shorti,   Cyrillic_SHORTI    ] };
186    key <LatK> { [ Cyrillic_ka,       Cyrillic_KA        ] };
187    key <LatL> { [ Cyrillic_el,       Cyrillic_EL        ] };
188    key <AC10> { [ Ukrainian_ghe_with_upturn, Ukrainian_GHE_WITH_UPTURN ] };
189    key <AC11> { [ Cyrillic_che,      Cyrillic_CHE       ] };
190    key <BKSL> { [ Cyrillic_yu,       Cyrillic_YU        ] };
191
192    key <LatZ> { [ Cyrillic_ze,       Cyrillic_ZE        ] };
193    key <LatX> { [ Cyrillic_softsign, Cyrillic_SOFTSIGN  ] };
194    key <LatC> { [ Cyrillic_tse,      Cyrillic_TSE       ] };
195    key <LatV> { [ Cyrillic_zhe,      Cyrillic_ZHE       ] };
196    key <LatB> { [ Cyrillic_be,       Cyrillic_BE        ] };
197    key <LatN> { [ Cyrillic_en,       Cyrillic_EN        ] };
198    key <LatM> { [ Cyrillic_em,       Cyrillic_EM        ] };
199    key <AB08> { [ Ukrainian_yi,      Ukrainian_YI       ] };
200    key <AB09> { [ Ukrainian_ie,      Ukrainian_IE       ] };
201    key <AB10> { [ slash,             question           ] };
202};
203
204// Ukrainian RSTU 2019-91 keyboard layout (Respublikanskij STandart Ukrajiny).
205// Andrew Porokhnyak <aop@porokhnyak.org>
206partial alphanumeric_keys
207xkb_symbols "rstu" {
208
209    include "ua(legacy)"
210    name[Group1]= "Ukrainian (standard RSTU)";
211
212    key <TLDE> { [      apostrophe,        question  ] };
213    key <AE01> { [          exclam,               1  ] };
214    key <AE02> { [        quotedbl,               2  ] };
215    key <AE03> { [      numbersign,               3  ] };
216    key <AE04> { [       semicolon,               4  ] };
217    key <AE05> { [           colon,               5  ] };
218    key <AE06> { [           comma,               6  ] };
219    key <AE07> { [          period,               7  ] };
220    key <AE08> { [        asterisk,               8  ] };
221    key <AE09> { [       parenleft,               9  ] };
222    key <AE10> { [      parenright,               0  ] };
223
224    key <AD12> { [ Ukrainian_ghe_with_upturn, Ukrainian_GHE_WITH_UPTURN ] };
225
226    key <AC02> { [      Cyrillic_i,      Cyrillic_I  ] };
227
228    key <AB05> { [     Ukrainian_i,     Ukrainian_I  ] };
229    key <AB10> { [    Ukrainian_yi,    Ukrainian_YI  ] };
230
231    key <BKSL> { [           slash,         percent  ] };
232};
233
234// Russian RSTU 2019-91 keyboard layout (Respublikanskij STandart Ukrajiny).
235// Andrew Porokhnyak <aop@porokhnyak.org>
236partial alphanumeric_keys
237xkb_symbols "rstu_ru" {
238
239    include "ru(common)"
240    name[Group1]= "Russian (Ukraine, standard RSTU)";
241
242    key <TLDE> { [      apostrophe,        question  ] };
243    key <AE01> { [          exclam,               1  ] };
244    key <AE02> { [        quotedbl,               2  ] };
245    key <AE03> { [      numbersign,               3  ] };
246    key <AE04> { [       semicolon,               4  ] };
247    key <AE05> { [           colon,               5  ] };
248    key <AE06> { [           comma,               6  ] };
249    key <AE07> { [          period,               7  ] };
250    key <AE08> { [        asterisk,               8  ] };
251    key <AE09> { [       parenleft,               9  ] };
252    key <AE10> { [      parenright,               0  ] };
253    key <BKSL> { [           slash,         percent  ] };
254
255    key.type[group1]="ALPHABETIC";
256
257    key <AB10> { [     Cyrillic_io,     Cyrillic_IO  ] };
258};
259
260// Homophonic keyboard layout (by Tomas Marko Miljenović),
261// based on the Ukrainian National Transliteration,
262// commonly used phonetic layouts for Mac and Win.
263partial alphanumeric_keys
264xkb_symbols "homophonic" {
265
266  include "ua(legacy)"
267  name[Group1]= "Ukrainian (homophonic)";
268
269    key <TLDE> { [        grave,        underscore       ] };
270    key <AE01> { [            1,            exclam       ] };
271    key <AE02> { [            2,                at       ] };
272    key <AE03> { [            3,         semicolon       ] };
273    key <AE04> { [            4,             colon       ] };
274    key <AE05> { [            5,           percent       ] };
275    key <AE06> { [            6,        apostrophe       ] };
276    key <AE07> { [            7,          quotedbl       ] };
277    key <AE08> { [            8,          asterisk       ] };
278    key <AE09> { [            9,         parenleft       ] };
279    key <AE10> { [            0,        parenright       ] };
280    key <AE11> { [ Ukrainian_ie,      Ukrainian_IE       ] };
281    key <AE12> { [ Ukrainian_yi,      Ukrainian_YI       ] };
282
283    key <LatQ> { [ Cyrillic_ya,       Cyrillic_YA        ] };
284    key <LatW> { [ Cyrillic_sha,      Cyrillic_SHA       ] };
285    key <LatE> { [ Cyrillic_ie,       Cyrillic_IE        ] };
286    key <LatR> { [ Cyrillic_er,       Cyrillic_ER        ] };
287    key <LatT> { [ Cyrillic_te,       Cyrillic_TE        ] };
288    key <LatY> { [ Cyrillic_i,        Cyrillic_I         ] };
289    key <LatU> { [ Cyrillic_u,        Cyrillic_U         ] };
290    key <LatI> { [ Ukrainian_i,       Ukrainian_I        ] };
291    key <LatO> { [ Cyrillic_o,        Cyrillic_O         ] };
292    key <LatP> { [ Cyrillic_pe,       Cyrillic_PE        ] };
293    key <AD11> { [ Cyrillic_yu,       Cyrillic_YU        ] };
294    key <AD12> { [ Cyrillic_shcha,    Cyrillic_SHCHA     ] };
295
296    key <LatA> { [ Cyrillic_a,        Cyrillic_A         ] };
297    key <LatS> { [ Cyrillic_es,       Cyrillic_ES        ] };
298    key <LatD> { [ Cyrillic_de,       Cyrillic_DE        ] };
299    key <LatF> { [ Cyrillic_ef,       Cyrillic_EF        ] };
300    key <LatG> { [ Ukrainian_ghe_with_upturn, Ukrainian_GHE_WITH_UPTURN ] };
301    key <LatH> { [ Cyrillic_ghe,      Cyrillic_GHE       ] };
302    key <LatJ> { [ Cyrillic_shorti,   Cyrillic_SHORTI    ] };
303    key <LatK> { [ Cyrillic_ka,       Cyrillic_KA        ] };
304    key <LatL> { [ Cyrillic_el,       Cyrillic_EL        ] };
305    key <AC10> { [ Cyrillic_che,      Cyrillic_CHE       ] };
306    key <AC11> { [ Cyrillic_zhe,      Cyrillic_ZHE       ] };
307    key <BKSL> { [ Cyrillic_softsign, Cyrillic_SOFTSIGN  ] };
308
309    key <LatZ> { [ Cyrillic_ze,       Cyrillic_ZE        ] };
310    key <LatX> { [ Cyrillic_ha,       Cyrillic_HA        ] };
311    key <LatC> { [ Cyrillic_tse,      Cyrillic_TSE       ] };
312    key <LatV> { [ Cyrillic_ve,       Cyrillic_VE        ] };
313    key <LatB> { [ Cyrillic_be,       Cyrillic_BE        ] };
314    key <LatN> { [ Cyrillic_en,       Cyrillic_EN        ] };
315    key <LatM> { [ Cyrillic_em,       Cyrillic_EM        ] };
316    key <AB08> { [ comma,             less               ] };
317    key <AB09> { [ period,            greater            ] };
318    key <AB10> { [ slash,             question           ] };
319};
320
321// EXTRAS:
322
323partial alphanumeric_keys
324	xkb_symbols "sun_type6" {
325	include "sun_vndr/ua(sun_type6)"
326};
327