1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #include "ui/events/ozone/layout/xkb/xkb_keyboard_code_conversion.h"
7 #include "ui/events/keycodes/dom/dom_key.h"
11 base::char16
DeadXkbKeySymToCombiningCharacter(xkb_keysym_t keysym
) {
13 case XKB_KEY_dead_grave
:
14 return 0x0300; // combining grave accent
15 case XKB_KEY_dead_acute
:
16 return 0x0301; // combining acute accent
17 case XKB_KEY_dead_circumflex
:
18 return 0x0302; // combining circumflex accent
19 case XKB_KEY_dead_tilde
:
20 return 0x0303; // combining tilde
21 case XKB_KEY_dead_macron
:
22 return 0x0304; // combining macron
23 case XKB_KEY_dead_breve
:
24 return 0x0306; // combining breve
25 case XKB_KEY_dead_abovedot
:
26 return 0x0307; // combining dot above
27 case XKB_KEY_dead_diaeresis
:
28 return 0x0308; // combining diaeresis
29 case XKB_KEY_dead_abovering
:
30 return 0x030A; // combining ring above
31 case XKB_KEY_dead_doubleacute
:
32 return 0x030B; // combining double acute accent
33 case XKB_KEY_dead_caron
:
34 return 0x030C; // combining caron
35 case XKB_KEY_dead_cedilla
:
36 return 0x0327; // combining cedilla
37 case XKB_KEY_dead_ogonek
:
38 return 0x0328; // combining ogonek
39 case XKB_KEY_dead_iota
:
40 return 0x0345; // combining greek ypogegrammeni
41 case XKB_KEY_dead_voiced_sound
:
42 return 0x3099; // combining katakana-hiragana voiced sound mark
43 case XKB_KEY_dead_semivoiced_sound
:
44 return 0x309A; // combining katakana-hiragana semi-voiced sound mark
45 case XKB_KEY_dead_belowdot
:
46 return 0x0323; // combining dot below
47 case XKB_KEY_dead_hook
:
48 return 0x0309; // combining hook above
49 case XKB_KEY_dead_horn
:
50 return 0x031B; // combining horn
51 case XKB_KEY_dead_stroke
:
52 return 0x0338; // combining long solidus overlay
53 case XKB_KEY_dead_abovecomma
:
54 return 0x0313; // combining comma above
55 case XKB_KEY_dead_abovereversedcomma
:
56 return 0x0314; // combining reversed comma above
57 case XKB_KEY_dead_doublegrave
:
58 return 0x030F; // combining double grave accent
59 case XKB_KEY_dead_belowring
:
60 return 0x0325; // combining ring below
61 case XKB_KEY_dead_belowmacron
:
62 return 0x0331; // combining macron below
63 case XKB_KEY_dead_belowcircumflex
:
64 return 0x032D; // combining circumflex accent below
65 case XKB_KEY_dead_belowtilde
:
66 return 0x0330; // combining tilde below
67 case XKB_KEY_dead_belowbreve
:
68 return 0x032E; // combining breve below
69 case XKB_KEY_dead_belowdiaeresis
:
70 return 0x0324; // combining diaeresis below
71 case XKB_KEY_dead_invertedbreve
:
72 return 0x0311; // combining inverted breve
73 case XKB_KEY_dead_belowcomma
:
74 return 0x0326; // combining comma below
75 case XKB_KEY_dead_currency
:
76 return 0x00A4; // currency sign
77 case XKB_KEY_dead_greek
:
78 return 0x037E; // greek question mark