• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1<?xml version="1.0" encoding="utf-8"?>
2<!--
3/*
4**
5** Copyright 2011, The Android Open Source Project
6**
7** Licensed under the Apache License, Version 2.0 (the "License");
8** you may not use this file except in compliance with the License.
9** You may obtain a copy of the License at
10**
11**     http://www.apache.org/licenses/LICENSE-2.0
12**
13** Unless required by applicable law or agreed to in writing, software
14** distributed under the License is distributed on an "AS IS" BASIS,
15** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
16** See the License for the specific language governing permissions and
17** limitations under the License.
18*/
19-->
20
21<merge
22    xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin"
23>
24    <switch>
25        <case
26            latin:keyboardLayoutSetElement="alphabetManualShifted|alphabetShiftLockShifted"
27        >
28            <key-style
29                latin:styleName="hasShiftedLetterHintStyle"
30                latin:keyLabelFlags="hasShiftedLetterHint|shiftedLetterActivated" />
31        </case>
32        <default>
33            <key-style
34                latin:styleName="hasShiftedLetterHintStyle"
35                latin:keyLabelFlags="hasShiftedLetterHint" />
36        </default>
37    </switch>
38    <!-- Functional key styles -->
39    <switch>
40        <case
41            latin:keyboardLayoutSetElement="alphabetManualShifted|alphabetAutomaticShifted"
42        >
43            <key-style
44                latin:styleName="shiftKeyStyle"
45                latin:code="!code/key_shift"
46                latin:keyIcon="!icon/shift_key_shifted"
47                latin:keyActionFlags="noKeyPreview"
48                latin:backgroundType="stickyOff" />
49        </case>
50        <case
51            latin:keyboardLayoutSetElement="alphabetShiftLocked|alphabetShiftLockShifted"
52        >
53            <key-style
54                latin:styleName="shiftKeyStyle"
55                latin:code="!code/key_shift"
56                latin:keyIcon="!icon/shift_key_shifted"
57                latin:keyActionFlags="noKeyPreview"
58                latin:backgroundType="stickyOn" />
59        </case>
60        <default>
61            <key-style
62                latin:styleName="shiftKeyStyle"
63                latin:code="!code/key_shift"
64                latin:keyIcon="!icon/shift_key"
65                latin:keyActionFlags="noKeyPreview"
66                latin:backgroundType="stickyOff" />
67        </default>
68    </switch>
69    <key-style
70        latin:styleName="deleteKeyStyle"
71        latin:code="!code/key_delete"
72        latin:keyIcon="!icon/delete_key"
73        latin:keyActionFlags="isRepeatable|noKeyPreview"
74        latin:backgroundType="functional" />
75    <include
76        latin:keyboardLayout="@xml/key_styles_enter" />
77    <!-- Override defaultEnterKeyStyle in key_styles_enter.xml -->
78    <key-style
79        latin:styleName="defaultEnterKeyStyle"
80        latin:code="!code/key_enter"
81        latin:keyIcon="!icon/enter_key"
82        latin:keyLabelFlags="preserveCase|autoXScale|followKeyLargeLabelRatio"
83        latin:keyActionFlags="noKeyPreview"
84        latin:backgroundType="functional"
85        latin:parentStyle="navigateMoreKeysStyle" />
86    <key-style
87        latin:styleName="spaceKeyStyle"
88        latin:code="!code/key_space"
89        latin:keyActionFlags="noKeyPreview|enableLongPress" />
90    <!-- U+200C: ZERO WIDTH NON-JOINER
91         U+200D: ZERO WIDTH JOINER -->
92    <key-style
93        latin:styleName="zwnjKeyStyle"
94        latin:code="0x200C"
95        latin:keyIcon="!icon/zwnj_key"
96        latin:moreKeys="!icon/zwj_key|&#x200D;"
97        latin:keyLabelFlags="hasPopupHint"
98        latin:keyActionFlags="noKeyPreview" />
99    <key-style
100        latin:styleName="smileyKeyStyle"
101        latin:keyLabel=":-)"
102        latin:keyOutputText=":-) "
103        latin:keyLabelFlags="hasPopupHint|preserveCase"
104        latin:moreKeys="!text/more_keys_for_smiley" />
105    <key-style
106        latin:styleName="shortcutKeyStyle"
107        latin:code="!code/key_shortcut"
108        latin:keyIcon="!icon/shortcut_key"
109        latin:keyIconDisabled="!icon/shortcut_key_disabled"
110        latin:keyActionFlags="noKeyPreview"
111        latin:backgroundType="functional" />
112    <key-style
113        latin:styleName="languageSwitchKeyStyle"
114        latin:code="!code/key_language_switch"
115        latin:keyIcon="!icon/language_switch_key"
116        latin:keyActionFlags="noKeyPreview|altCodeWhileTyping|enableLongPress"
117        latin:altCode="!code/key_space" />
118    <key-style
119        latin:styleName="settingsKeyStyle"
120        latin:code="!code/key_settings"
121        latin:keyIcon="!icon/settings_key"
122        latin:keyActionFlags="noKeyPreview"
123        latin:backgroundType="functional" />
124    <switch>
125        <case
126            latin:keyboardLayoutSetElement="alphabetManualShifted|alphabetShiftLockShifted"
127            latin:navigatePrevious="true"
128        >
129            <key-style
130                latin:styleName="tabKeyStyle"
131                latin:code="!code/key_action_previous"
132                latin:keyIcon="!icon/tab_key"
133                latin:keyIconPreview="!icon/tab_key_preview"
134                latin:backgroundType="functional" />
135        </case>
136        <case
137            latin:keyboardLayoutSetElement="alphabet|alphabetAutomaticShifted|alphabetShiftLocked"
138            latin:navigateNext="true"
139        >
140            <key-style
141                latin:styleName="tabKeyStyle"
142                latin:code="!code/key_action_next"
143                latin:keyIcon="!icon/tab_key"
144                latin:keyIconPreview="!icon/tab_key_preview"
145                latin:backgroundType="functional" />
146        </case>
147        <default>
148            <key-style
149                latin:styleName="tabKeyStyle"
150                latin:code="!code/key_tab"
151                latin:keyIcon="!icon/tab_key"
152                latin:keyIconPreview="!icon/tab_key_preview"
153                latin:backgroundType="functional" />
154        </default>
155    </switch>
156    <key-style
157        latin:styleName="toSymbolKeyStyle"
158        latin:code="!code/key_switch_alpha_symbol"
159        latin:keyLabel="!text/label_to_symbol_key"
160        latin:keyLabelFlags="preserveCase"
161        latin:keyActionFlags="noKeyPreview"
162        latin:backgroundType="functional" />
163    <key-style
164        latin:styleName="toAlphaKeyStyle"
165        latin:code="!code/key_switch_alpha_symbol"
166        latin:keyLabel="!text/label_to_alpha_key"
167        latin:keyLabelFlags="preserveCase"
168        latin:keyActionFlags="noKeyPreview"
169        latin:backgroundType="functional" />
170    <key-style
171        latin:styleName="toMoreSymbolKeyStyle"
172        latin:code="!code/key_shift"
173        latin:keyLabel="!text/label_to_more_symbol_for_tablet_key"
174        latin:keyActionFlags="noKeyPreview"
175        latin:backgroundType="functional" />
176    <key-style
177        latin:styleName="backFromMoreSymbolKeyStyle"
178        latin:code="!code/key_shift"
179        latin:keyLabel="!text/label_to_symbol_key"
180        latin:keyActionFlags="noKeyPreview"
181        latin:backgroundType="functional" />
182    <key-style
183        latin:styleName="comKeyStyle"
184        latin:keyLabel="!text/keylabel_for_popular_domain"
185        latin:keyLabelFlags="autoXScale|fontNormal|hasPopupHint|preserveCase"
186        latin:keyOutputText="!text/keylabel_for_popular_domain"
187        latin:moreKeys="!text/more_keys_for_popular_domain" />
188</merge>
189