1 <?xml version="1.0" encoding="utf-8"?> 2 <!-- 3 /* 4 ** 5 ** Copyright 2010, 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 <!-- Base key style for the key which may have settings key as more keys. --> 39 <key-style 40 latin:styleName="baseSettingsMoreKeysStyle" /> 41 <include 42 latin:keyboardLayout="@xml/key_styles_settings" /> 43 <!-- Functional key styles --> 44 <!-- Base style for shift key. A single space is used for dummy label in moreKeys. --> 45 <key-style 46 latin:styleName="baseForShiftKeyStyle" 47 latin:keyActionFlags="noKeyPreview" 48 latin:keyLabelFlags="preserveCase" 49 latin:moreKeys="!noPanelAutoMoreKey!, |!code/key_capslock" /> 50 <switch> 51 <case 52 latin:keyboardLayoutSetElement="alphabetManualShifted|alphabetAutomaticShifted" 53 > 54 <key-style 55 latin:styleName="shiftKeyStyle" 56 latin:keySpec="!icon/shift_key_shifted|!code/key_shift" 57 latin:backgroundType="stickyOff" 58 latin:parentStyle="baseForShiftKeyStyle" /> 59 </case> 60 <case 61 latin:keyboardLayoutSetElement="alphabetShiftLocked|alphabetShiftLockShifted" 62 > 63 <key-style 64 latin:styleName="shiftKeyStyle" 65 latin:keySpec="!icon/shift_key_shifted|!code/key_shift" 66 latin:backgroundType="stickyOn" 67 latin:parentStyle="baseForShiftKeyStyle" /> 68 </case> 69 <default> 70 <key-style 71 latin:styleName="shiftKeyStyle" 72 latin:keySpec="!icon/shift_key|!code/key_shift" 73 latin:backgroundType="stickyOff" 74 latin:parentStyle="baseForShiftKeyStyle" /> 75 </default> 76 </switch> 77 <key-style 78 latin:styleName="deleteKeyStyle" 79 latin:keySpec="!icon/delete_key|!code/key_delete" 80 latin:keyActionFlags="isRepeatable|noKeyPreview" 81 latin:backgroundType="functional" /> 82 <!-- emojiKeyStyle must be defined before including @xml/key_syles_enter. --> 83 <switch> 84 <case latin:keyboardTheme="ICS|KLP"> 85 <key-style 86 latin:styleName="emojiKeyStyle" 87 latin:keySpec="!icon/emoji_action_key|!code/key_emoji" 88 latin:keyActionFlags="noKeyPreview" 89 latin:backgroundType="action" /> 90 </case> 91 <!-- keyboardTheme="LXXLight|LXXDark" --> 92 <default> 93 <key-style 94 latin:styleName="emojiKeyStyle" 95 latin:keySpec="!icon/emoji_action_key|!code/key_emoji" 96 latin:keyLabelFlags="keepBackgroundAspectRatio" 97 latin:keyActionFlags="noKeyPreview" 98 latin:backgroundType="action" /> 99 </default> 100 </switch> 101 <include 102 latin:keyboardLayout="@xml/key_styles_enter" /> 103 <!-- TODO: Currently there is no way to specify icon alignment per theme. --> 104 <key-style 105 latin:styleName="spaceKeyStyle" 106 latin:keySpec="!icon/space_key|!code/key_space" 107 latin:backgroundType="spacebar" 108 latin:keyActionFlags="noKeyPreview|enableLongPress" /> 109 <!-- U+200C: ZERO WIDTH NON-JOINER 110 U+200D: ZERO WIDTH JOINER --> 111 <key-style 112 latin:styleName="zwnjKeyStyle" 113 latin:keySpec="!icon/zwnj_key|‌" 114 latin:moreKeys="!icon/zwj_key|‍" 115 latin:keyLabelFlags="hasPopupHint" 116 latin:keyActionFlags="noKeyPreview" /> 117 <key-style 118 latin:styleName="shortcutKeyStyle" 119 latin:keySpec="!icon/shortcut_key|!code/key_shortcut" 120 latin:keyIconDisabled="!icon/shortcut_key_disabled" 121 latin:keyActionFlags="noKeyPreview|altCodeWhileTyping" 122 latin:altCode="!code/key_space" 123 latin:parentStyle="settingsMoreKeysStyle" /> 124 <key-style 125 latin:styleName="settingsKeyStyle" 126 latin:keySpec="!icon/settings_key|!code/key_settings" 127 latin:keyActionFlags="noKeyPreview|altCodeWhileTyping" 128 latin:altCode="!code/key_space" 129 latin:backgroundType="functional" /> 130 <key-style 131 latin:styleName="languageSwitchKeyStyle" 132 latin:keySpec="!icon/language_switch_key|!code/key_language_switch" 133 latin:keyActionFlags="noKeyPreview|altCodeWhileTyping|enableLongPress" 134 latin:altCode="!code/key_space" /> 135 <key-style 136 latin:styleName="tabKeyStyle" 137 latin:keySpec="!icon/tab_key|!code/key_tab" 138 latin:backgroundType="functional" /> 139 <!-- Note: This key style is not for functional tab key. This is used for the tab key which is 140 laid out as normal letter key. --> 141 <key-style 142 latin:styleName="nonSpecialBackgroundTabKeyStyle" 143 latin:keySpec="!icon/tab_key|!code/key_tab" /> 144 <key-style 145 latin:styleName="baseForLayoutSwitchKeyStyle" 146 latin:keyLabelFlags="preserveCase|followFunctionalTextColor" 147 latin:keyActionFlags="noKeyPreview" 148 latin:backgroundType="functional" /> 149 <key-style 150 latin:styleName="toSymbolKeyStyle" 151 latin:keySpec="!text/keylabel_to_symbol|!code/key_switch_alpha_symbol" 152 latin:parentStyle="baseForLayoutSwitchKeyStyle" /> 153 <key-style 154 latin:styleName="toAlphaKeyStyle" 155 latin:keySpec="!text/keylabel_to_alpha|!code/key_switch_alpha_symbol" 156 latin:parentStyle="baseForLayoutSwitchKeyStyle" /> 157 <key-style 158 latin:styleName="toMoreSymbolKeyStyle" 159 latin:keySpec="!text/keylabel_to_more_symbol|!code/key_shift" 160 latin:parentStyle="baseForLayoutSwitchKeyStyle" /> 161 <key-style 162 latin:styleName="backFromMoreSymbolKeyStyle" 163 latin:keySpec="!text/keylabel_to_symbol|!code/key_shift" 164 latin:parentStyle="baseForLayoutSwitchKeyStyle" /> 165 <key-style 166 latin:styleName="comKeyStyle" 167 latin:keySpec="!text/keyspec_popular_domain" 168 latin:keyLabelFlags="autoXScale|fontNormal|hasPopupHint|preserveCase" 169 latin:moreKeys="!text/morekeys_popular_domain" 170 latin:backgroundType="functional" /> 171 </merge> 172