1/*
2 * Copyright (c) 2005 Alexander Gottwald
3 *
4 * Permission is hereby granted, free of charge, to any person obtaining a
5 * copy of this software and associated documentation files (the "Software"),
6 * to deal in the Software without restriction, including without limitation
7 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
8 * and/or sell copies of the Software, and to permit persons to whom the
9 * Software is furnished to do so, subject to the following conditions:
10 *
11 * The above copyright notice and this permission notice shall be included in
12 * all copies or substantial portions of the Software.
13 *
14 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
17 * THE ABOVE LISTED COPYRIGHT HOLDER(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR
18 * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
19 * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
20 * DEALINGS IN THE SOFTWARE.
21 *
22 * Except as contained in this notice, the name(s) of the above copyright
23 * holders shall not be used in advertising or otherwise to promote the sale,
24 * use or other dealings in this Software without prior written authorization.
25 */
26/* Definitions for various keyboard layouts from windows and their
27 * XKB settings.
28 */
29
30typedef struct {
31    unsigned int winlayout;
32    int winkbtype;
33    const char *xkbmodel;
34    const char *xkblayout;
35    const char *xkbvariant;
36    const char *xkboptions;
37    const char *layoutname;
38} WinKBLayoutRec, *WinKBLayoutPtr;
39
40/*
41   This table is sorted by low byte of winlayout, then by next byte, etc.
42*/
43
44WinKBLayoutRec winKBLayouts[] = {
45    {0x00000404, -1, "pc105", "cn", NULL, NULL, "Chinese (Traditional)"},
46    {0x00000804, -1, "pc105", "cn", NULL, NULL, "Chinese (Simplified)"},
47    {0x00000405, -1, "pc105", "cz", NULL, NULL, "Czech"},
48    {0x00010405, -1, "pc105", "cz_qwerty", NULL, NULL, "Czech (QWERTY)"},
49    {0x00000406, -1, "pc105", "dk", NULL, NULL, "Danish"},
50    {0x00000407, -1, "pc105", "de", NULL, NULL, "German (Germany)"},
51    {0x00010407, -1, "pc105", "de", NULL, NULL, "German (Germany,IBM)"},
52    {0x00000807, -1, "pc105", "ch", "de", NULL, "German (Switzerland)"},
53    {0x00000409, -1, "pc105", "us", NULL, NULL, "English (USA)"},
54    {0x00010409, -1, "pc105", "dvorak", NULL, NULL, "English (USA,Dvorak)"},
55    {0x00020409, -1, "pc105", "us_intl", NULL, NULL,
56     "English (USA,International)"},
57    {0x00000809, -1, "pc105", "gb", NULL, NULL, "English (United Kingdom)"},
58    {0x00001009, -1, "pc105", "ca", "fr", NULL, "French (Canada)"},
59    {0x00011009, -1, "pc105", "ca", "multix", NULL,
60     "Canadian Multilingual Standard"},
61    {0x00001809, -1, "pc105", "ie", NULL, NULL, "Irish"},
62    {0x0000040a, -1, "pc105", "es", NULL, NULL,
63     "Spanish (Spain,Traditional Sort)"},
64    {0x0000080a, -1, "pc105", "latam", NULL, NULL, "Latin American"},
65    {0x0000040b, -1, "pc105", "fi", NULL, NULL, "Finnish"},
66    {0x0000040c, -1, "pc105", "fr", NULL, NULL, "French (Standard)"},
67    {0x0000080c, -1, "pc105", "be", NULL, NULL, "French (Belgian)"},
68    {0x0001080c, -1, "pc105", "be", NULL, NULL, "Belgian (Comma)"},
69    {0x00000c0c, -1, "pc105", "ca", "fr-legacy", NULL,
70     "French (Canada, Legacy)"},
71    {0x0000100c, -1, "pc105", "ch", "fr", NULL, "French (Switzerland)"},
72    {0x0000040d, -1, "pc105", "il", NULL, NULL, "Hebrew"},
73    {0x0000040e, -1, "pc105", "hu", NULL, NULL, "Hungarian"},
74    {0x0000040f, -1, "pc105", "is", NULL, NULL, "Icelandic"},
75    {0x00000410, -1, "pc105", "it", NULL, NULL, "Italian"},
76    {0x00010410, -1, "pc105", "it", NULL, NULL, "Italian (142)"},
77    {0x00000411, 7, "jp106", "jp", NULL, NULL, "Japanese"},
78    {0x00000412, -1, "kr106", "kr", NULL, NULL, "Korean"},
79    {0x00000413, -1, "pc105", "nl", NULL, NULL, "Dutch"},
80    {0x00000813, -1, "pc105", "be", NULL, NULL, "Dutch (Belgian)"},
81    {0x00000414, -1, "pc105", "no", NULL, NULL, "Norwegian"},
82    {0x00000415, -1, "pc105", "pl", NULL, NULL, "Polish (Programmers)"},
83    {0x00000416, -1, "pc105", "br", NULL, NULL, "Portuguese (Brazil,ABNT)"},
84    {0x00010416, -1, "abnt2", "br", NULL, NULL, "Portuguese (Brazil,ABNT2)"},
85    {0x00000816, -1, "pc105", "pt", NULL, NULL, "Portuguese (Portugal)"},
86    {0x00000419, -1, "pc105", "ru", NULL, NULL, "Russian"},
87    {0x0000041a, -1, "pc105", "hr", NULL, NULL, "Croatian"},
88    {0x0000041d, -1, "pc105", "se", NULL, NULL, "Swedish (Sweden)"},
89    {0x0000041f, -1, "pc105", "tr", NULL, NULL, "Turkish (Q)"},
90    {0x0001041f, -1, "pc105", "tr", "f", NULL, "Turkish (F)"},
91    {0x00000424, -1, "pc105", "si", NULL, NULL, "Slovenian"},
92    {0x00000425, -1, "pc105", "ee", NULL, NULL, "Estonian"},
93    {0x00000452, -1, "pc105", "gb", "intl", NULL, "United Kingdom (Extended)"},
94    {-1, -1, NULL, NULL, NULL, NULL, NULL}
95};
96
97/*
98  See http://technet.microsoft.com/en-us/library/cc766503%28WS.10%29.aspx
99  for a listing of input locale (keyboard layout) codes
100*/
101