diff options
Diffstat (limited to 'java/res/xml')
37 files changed, 2061 insertions, 2269 deletions
diff --git a/java/res/xml/kbd_azerty_rows.xml b/java/res/xml/kbd_azerty_rows.xml new file mode 100644 index 000000000..71109ab67 --- /dev/null +++ b/java/res/xml/kbd_azerty_rows.xml @@ -0,0 +1,137 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- +/* +** +** Copyright 2010, The Android Open Source Project +** +** Licensed under the Apache License, Version 2.0 (the "License"); +** you may not use this file except in compliance with the License. +** You may obtain a copy of the License at +** +** http://www.apache.org/licenses/LICENSE-2.0 +** +** Unless required by applicable law or agreed to in writing, software +** distributed under the License is distributed on an "AS IS" BASIS, +** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +** See the License for the specific language governing permissions and +** limitations under the License. +*/ +--> + +<merge + xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin" +> + <include + latin:keyboardLayout="@xml/kbd_key_styles" /> + <Row + latin:keyWidth="10%p" + latin:rowEdgeFlags="top" + > + <Key + latin:keyLabel="a" + latin:keyHintIcon="@drawable/keyboard_hint_1" + latin:popupCharacters="@string/alternates_for_a" + latin:keyEdgeFlags="left" /> + <Key + latin:keyLabel="z" + latin:keyHintIcon="@drawable/keyboard_hint_2" + latin:popupCharacters="@string/alternates_for_z" /> + <Key + latin:keyLabel="e" + latin:keyHintIcon="@drawable/keyboard_hint_3" + latin:popupCharacters="@string/alternates_for_e" /> + <Key + latin:keyLabel="r" + latin:keyHintIcon="@drawable/keyboard_hint_4" + latin:popupCharacters="@string/alternates_for_r" /> + <Key + latin:keyLabel="t" + latin:keyHintIcon="@drawable/keyboard_hint_5" + latin:popupCharacters="@string/alternates_for_t" /> + <Key + latin:keyLabel="y" + latin:keyHintIcon="@drawable/keyboard_hint_6" + latin:popupCharacters="@string/alternates_for_y" /> + <Key + latin:keyLabel="u" + latin:keyHintIcon="@drawable/keyboard_hint_7" + latin:popupCharacters="@string/alternates_for_u" /> + <Key + latin:keyLabel="i" + latin:keyHintIcon="@drawable/keyboard_hint_8" + latin:popupCharacters="@string/alternates_for_i" /> + <Key + latin:keyLabel="o" + latin:keyHintIcon="@drawable/keyboard_hint_9" + latin:popupCharacters="@string/alternates_for_o" /> + <Key + latin:keyLabel="p" + latin:keyHintIcon="@drawable/keyboard_hint_0" + latin:popupCharacters="@string/alternates_for_p" + latin:keyEdgeFlags="right" /> + </Row> + <Row + latin:keyWidth="10%p" + > + <Key + latin:keyLabel="q" + latin:popupCharacters="@string/alternates_for_q" + latin:keyEdgeFlags="left" /> + <Key + latin:keyLabel="s" + latin:popupCharacters="@string/alternates_for_s" /> + <Key + latin:keyLabel="d" + latin:popupCharacters="@string/alternates_for_d" /> + <Key + latin:keyLabel="f" /> + <Key + latin:keyLabel="g" + latin:popupCharacters="@string/alternates_for_g" /> + <Key + latin:keyLabel="h" /> + <Key + latin:keyLabel="j" /> + <Key + latin:keyLabel="k" /> + <Key + latin:keyLabel="l" + latin:popupCharacters="@string/alternates_for_l" /> + <Key + latin:keyLabel="m" + latin:keyEdgeFlags="right" /> + </Row> + <Row + latin:keyWidth="10%p" + > + <Key + latin:keyStyle="shiftKeyStyle" + latin:keyWidth="15%p" + latin:keyEdgeFlags="left" /> + <Key + latin:keyLabel="w" + latin:popupCharacters="@string/alternates_for_w" /> + <Key + latin:keyLabel="x" /> + <Key + latin:keyLabel="c" + + latin:popupCharacters="@string/alternates_for_c" /> + <Key + latin:keyLabel="v" + latin:popupCharacters="@string/alternates_for_v" /> + <Key + latin:keyLabel="b" /> + <Key + latin:keyLabel="n" + latin:popupCharacters="@string/alternates_for_n" /> + <Key + latin:keyLabel="\'" /> + <Key + latin:keyStyle="deleteKeyStyle" + latin:keyWidth="15%p" + latin:keyEdgeFlags="right" /> + </Row> + <include + latin:keyboardLayout="@xml/kbd_qwerty_row4" /> +</merge> diff --git a/java/res/xml/kbd_key_styles.xml b/java/res/xml/kbd_key_styles.xml new file mode 100644 index 000000000..3b35f3560 --- /dev/null +++ b/java/res/xml/kbd_key_styles.xml @@ -0,0 +1,290 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- +/* +** +** Copyright 2010, The Android Open Source Project +** +** Licensed under the Apache License, Version 2.0 (the "License"); +** you may not use this file except in compliance with the License. +** You may obtain a copy of the License at +** +** http://www.apache.org/licenses/LICENSE-2.0 +** +** Unless required by applicable law or agreed to in writing, software +** distributed under the License is distributed on an "AS IS" BASIS, +** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +** See the License for the specific language governing permissions and +** limitations under the License. +*/ +--> + +<merge + xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin" +> + <!-- Functional key styles --> + <switch> + <case + latin:colorScheme="white" + > + <key-style + latin:styleName="functionalKeyStyle" + latin:isModifier="true" /> + <key-style + latin:styleName="shiftKeyStyle" + latin:code="@integer/key_shift" + latin:keyIcon="@drawable/sym_keyboard_shift" + latin:shiftedIcon="@drawable/sym_keyboard_shift_locked" + latin:iconPreview="@drawable/sym_keyboard_feedback_shift" + latin:parentStyle="functionalKeyStyle" + latin:isSticky="true" /> + <key-style + latin:styleName="deleteKeyStyle" + latin:code="@integer/key_delete" + latin:keyIcon="@drawable/sym_keyboard_delete" + latin:iconPreview="@drawable/sym_keyboard_feedback_delete" + latin:parentStyle="functionalKeyStyle" + latin:isRepeatable="true" /> + <switch> + <!-- When this qwerty keyboard has no voice key but voice key is enabled, then + symbol keyboard will have mic key. That means we should use "?123mic" key + here. --> + <case + latin:voiceKeyEnabled="true" + latin:hasVoiceKey="false" + > + <key-style + latin:styleName="toSymbolKeyStyle" + latin:code="@integer/key_switch_alpha_symbol" + latin:keyIcon="@drawable/sym_keyboard_123_mic" + latin:iconPreview="@drawable/sym_keyboard_feedback_123_mic" + latin:parentStyle="functionalKeyStyle" /> + </case> + <default> + <key-style + latin:styleName="toSymbolKeyStyle" + latin:code="@integer/key_switch_alpha_symbol" + latin:keyLabel="@string/label_to_symbol_key" + latin:parentStyle="functionalKeyStyle" /> + </default> + </switch> + <key-style + latin:styleName="settingsKeyStyle" + latin:code="@integer/key_settings" + latin:keyIcon="@drawable/sym_keyboard_settings" + latin:iconPreview="@drawable/sym_keyboard_feedback_settings" + latin:parentStyle="functionalKeyStyle" /> + <key-style + latin:styleName="spaceKeyStyle" + latin:code="@integer/key_space" + latin:keyIcon="@drawable/sym_keyboard_space" + latin:iconPreview="@drawable/sym_keyboard_feedback_space" + latin:parentStyle="functionalKeyStyle" /> + <key-style + latin:styleName="tabKeyStyle" + latin:code="@integer/key_tab" + latin:keyIcon="@drawable/sym_keyboard_tab" + latin:iconPreview="@drawable/sym_keyboard_feedback_tab" + latin:parentStyle="functionalKeyStyle" /> + <key-style + latin:styleName="micKeyStyle" + latin:code="@integer/key_voice" + latin:keyIcon="@drawable/sym_keyboard_mic" + latin:iconPreview="@drawable/sym_keyboard_feedback_mic" + latin:keyHintIcon="@drawable/hint_popup" + latin:popupCharacters="@string/alternates_for_mic" + latin:parentStyle="functionalKeyStyle" /> + <!-- Note: This key style is not for functional tab key. This is used for the tab key + which is laid out as normal letter key. --> + <key-style + latin:styleName="nonSpecialBackgroundTabKeyStyle" + latin:code="@integer/key_tab" + latin:keyIcon="@drawable/sym_keyboard_tab" + latin:iconPreview="@drawable/sym_keyboard_feedback_tab" /> + </case> + <case + latin:colorScheme="black" + > + <key-style + latin:styleName="functionalKeyStyle" /> + <key-style + latin:styleName="shiftKeyStyle" + latin:code="@integer/key_shift" + latin:keyIcon="@drawable/sym_bkeyboard_shift" + latin:shiftedIcon="@drawable/sym_bkeyboard_shift_locked" + latin:iconPreview="@drawable/sym_keyboard_feedback_shift" + latin:parentStyle="functionalKeyStyle" + latin:isSticky="true" /> + <key-style + latin:styleName="deleteKeyStyle" + latin:code="@integer/key_delete" + latin:keyIcon="@drawable/sym_bkeyboard_delete" + latin:iconPreview="@drawable/sym_keyboard_feedback_delete" + latin:parentStyle="functionalKeyStyle" + latin:isRepeatable="true" /> + <switch> + <!-- When this qwerty keyboard has no voice key but voice key is enabled, then + symbol keyboard will have mic key. That means we should use "?123mic" key + here. --> + <case + latin:voiceKeyEnabled="true" + latin:hasVoiceKey="false" + > + <key-style + latin:styleName="toSymbolKeyStyle" + latin:code="@integer/key_switch_alpha_symbol" + latin:keyIcon="@drawable/sym_bkeyboard_123_mic" + latin:iconPreview="@drawable/sym_keyboard_feedback_123_mic" + latin:parentStyle="functionalKeyStyle" /> + </case> + <default> + <key-style + latin:styleName="toSymbolKeyStyle" + latin:code="@integer/key_switch_alpha_symbol" + latin:keyLabel="@string/label_to_symbol_key" + latin:parentStyle="functionalKeyStyle" /> + </default> + </switch> + <key-style + latin:styleName="settingsKeyStyle" + latin:code="@integer/key_settings" + latin:keyIcon="@drawable/sym_bkeyboard_settings" + latin:iconPreview="@drawable/sym_keyboard_feedback_settings" + latin:parentStyle="functionalKeyStyle" /> + <key-style + latin:styleName="spaceKeyStyle" + latin:code="@integer/key_space" + latin:keyIcon="@drawable/sym_bkeyboard_space" + latin:iconPreview="@drawable/sym_keyboard_feedback_space" + latin:parentStyle="functionalKeyStyle" /> + <key-style + latin:styleName="tabKeyStyle" + latin:code="@integer/key_tab" + latin:keyIcon="@drawable/sym_bkeyboard_tab" + latin:iconPreview="@drawable/sym_keyboard_feedback_tab" + latin:parentStyle="functionalKeyStyle" /> + <key-style + latin:styleName="micKeyStyle" + latin:code="@integer/key_voice" + latin:keyIcon="@drawable/sym_bkeyboard_mic" + latin:iconPreview="@drawable/sym_keyboard_feedback_mic" + latin:keyHintIcon="@drawable/hint_popup" + latin:popupCharacters="@string/alternates_for_mic" + latin:parentStyle="functionalKeyStyle" /> + <!-- Note: This key style is not for functional tab key. This is used for the tab key + which is laid out as normal letter key. --> + <key-style + latin:styleName="nonSpecialBackgroundTabKeyStyle" + latin:code="@integer/key_tab" + latin:keyIcon="@drawable/sym_bkeyboard_tab" + latin:iconPreview="@drawable/sym_keyboard_feedback_tab" /> + </case> + </switch> + <!-- Return key style --> + <switch> + <case + latin:imeOptions="actionGo" + > + <key-style + latin:styleName="returnKeyStyle" + latin:code="@integer/key_return" + latin:keyLabel="@string/label_go_key" + latin:parentStyle="functionalKeyStyle" /> + </case> + <case + latin:imeOptions="actionNext" + > + <key-style + latin:styleName="returnKeyStyle" + latin:code="@integer/key_return" + latin:keyLabel="@string/label_next_key" + latin:parentStyle="functionalKeyStyle" /> + </case> + <case + latin:imeOptions="actionDone" + > + <key-style + latin:styleName="returnKeyStyle" + latin:code="@integer/key_return" + latin:keyLabel="@string/label_done_key" + latin:parentStyle="functionalKeyStyle" /> + </case> + <case + latin:imeOptions="actionSend" + > + <key-style + latin:styleName="returnKeyStyle" + latin:code="@integer/key_return" + latin:keyLabel="@string/label_send_key" + latin:parentStyle="functionalKeyStyle" /> + </case> + <case + latin:imeOptions="actionSearch" + > + <switch> + <case + latin:colorScheme="white" + > + <key-style + latin:styleName="returnKeyStyle" + latin:code="@integer/key_return" + latin:keyIcon="@drawable/sym_keyboard_search" + latin:iconPreview="@drawable/sym_keyboard_feedback_search" + latin:parentStyle="functionalKeyStyle" /> + </case> + <case + latin:colorScheme="black" + > + <key-style + latin:styleName="returnKeyStyle" + latin:code="@integer/key_return" + latin:keyIcon="@drawable/sym_bkeyboard_search" + latin:iconPreview="@drawable/sym_keyboard_feedback_search" + latin:parentStyle="functionalKeyStyle" /> + </case> + </switch> + </case> + <default> + <switch> + <case + latin:colorScheme="white" + > + <key-style + latin:styleName="returnKeyStyle" + latin:code="@integer/key_return" + latin:keyIcon="@drawable/sym_keyboard_return" + latin:iconPreview="@drawable/sym_keyboard_feedback_return" + latin:parentStyle="functionalKeyStyle" /> + </case> + <case + latin:colorScheme="black" + > + <key-style + latin:styleName="returnKeyStyle" + latin:code="@integer/key_return" + latin:keyIcon="@drawable/sym_bkeyboard_return" + latin:iconPreview="@drawable/sym_keyboard_feedback_return" + latin:parentStyle="functionalKeyStyle" /> + </case> + </switch> + </default> + </switch> + <key-style + latin:styleName="toAlphaKeyStyle" + latin:code="@integer/key_switch_alpha_symbol" + latin:keyLabel="@string/label_to_alpha_key" + latin:parentStyle="functionalKeyStyle" /> + <key-style + latin:styleName="altKeyStyle" + latin:code="@integer/key_shift" + latin:keyLabel="@string/label_alt_key" + latin:parentStyle="functionalKeyStyle" + latin:isSticky="true" /> + <key-style + latin:styleName="smileyKeyStyle" + latin:keyLabel=":-)" + latin:keyOutputText=":-) " + latin:keyHintIcon="@drawable/hint_popup" + latin:popupCharacters="@string/alternates_for_smiley" + latin:maxPopupKeyboardColumn="5" + latin:parentStyle="functionalKeyStyle" /> +</merge>
\ No newline at end of file diff --git a/java/res/xml/kbd_number.xml b/java/res/xml/kbd_number.xml new file mode 100644 index 000000000..f4fe8401a --- /dev/null +++ b/java/res/xml/kbd_number.xml @@ -0,0 +1,112 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- +/* +** +** Copyright 2008, The Android Open Source Project +** +** Licensed under the Apache License, Version 2.0 (the "License"); +** you may not use this file except in compliance with the License. +** You may obtain a copy of the License at +** +** http://www.apache.org/licenses/LICENSE-2.0 +** +** Unless required by applicable law or agreed to in writing, software +** distributed under the License is distributed on an "AS IS" BASIS, +** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +** See the License for the specific language governing permissions and +** limitations under the License. +*/ +--> + +<Keyboard + xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin" + latin:keyboardHeight="@dimen/keyboardHeight" + latin:maxKeyboardHeight="50%p" + latin:rowHeight="25%p" + latin:keyWidth="26.67%p" + latin:horizontalGap="@dimen/key_horizontal_gap" + latin:verticalGap="@dimen/key_bottom_gap" + latin:popupKeyboardTemplate="@xml/kbd_popup_template" + latin:maxPopupKeyboardColumn="@integer/config_max_popup_keyboard_column" +> + <include + latin:keyboardLayout="@xml/kbd_key_styles" /> + <switch> + <case + latin:colorScheme="white" + > + <key-style + latin:styleName="numSpaceKeyStyle" + latin:code="@integer/key_space" + latin:keyIcon="@drawable/sym_keyboard_space" + latin:iconPreview="@drawable/sym_keyboard_feedback_space" /> + </case> + <case + latin:colorScheme="black" + > + <key-style + latin:styleName="numSpaceKeyStyle" + latin:code="@integer/key_space" + latin:keyIcon="@drawable/sym_bkeyboard_space" + latin:iconPreview="@drawable/sym_keyboard_feedback_space" /> + </case> + </switch> + <Row + latin:rowEdgeFlags="top" + > + <Key + latin:keyLabel="1" + latin:keyEdgeFlags="left" /> + <Key + latin:keyLabel="2" /> + <Key + latin:keyLabel="3" /> + <Key + latin:keyLabel="-" + latin:keyStyle="functionalKeyStyle" + latin:keyWidth="20%p" + latin:keyEdgeFlags="right" /> + </Row> + <Row> + <Key + latin:keyLabel="4" + latin:keyEdgeFlags="left" /> + <Key + latin:keyLabel="5" /> + <Key + latin:keyLabel="6" /> + <Key + latin:keyLabel="," + latin:keyStyle="functionalKeyStyle" + latin:keyWidth="20%p" + latin:keyEdgeFlags="right" /> + </Row> + <Row> + <Key + latin:keyLabel="7" + latin:keyEdgeFlags="left" /> + <Key + latin:keyLabel="8" /> + <Key + latin:keyLabel="9" /> + <Key + latin:keyStyle="deleteKeyStyle" + latin:keyWidth="20%p" + latin:keyEdgeFlags="right" /> + </Row> + <Row + latin:rowEdgeFlags="bottom" + > + <Key + latin:keyStyle="numSpaceKeyStyle" + latin:keyEdgeFlags="left" /> + <Key + latin:keyLabel="0" /> + <Key + latin:keyLabel="." /> + <Key + latin:keyStyle="returnKeyStyle" + latin:keyWidth="20%p" + latin:keyEdgeFlags="right" /> + </Row> +</Keyboard> diff --git a/java/res/xml/kbd_numkey_styles.xml b/java/res/xml/kbd_numkey_styles.xml new file mode 100644 index 000000000..2f9ae325a --- /dev/null +++ b/java/res/xml/kbd_numkey_styles.xml @@ -0,0 +1,150 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- +/* +** +** Copyright 2010, The Android Open Source Project +** +** Licensed under the Apache License, Version 2.0 (the "License"); +** you may not use this file except in compliance with the License. +** You may obtain a copy of the License at +** +** http://www.apache.org/licenses/LICENSE-2.0 +** +** Unless required by applicable law or agreed to in writing, software +** distributed under the License is distributed on an "AS IS" BASIS, +** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +** See the License for the specific language governing permissions and +** limitations under the License. +*/ +--> + +<merge + xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin" +> + <switch> + <case + latin:colorScheme="white" + > + <key-style + latin:styleName="num0KeyStyle" + latin:code="48" + latin:keyIcon="@drawable/sym_keyboard_num0" /> + <key-style + latin:styleName="num1KeyStyle" + latin:code="49" + latin:keyIcon="@drawable/sym_keyboard_num1" /> + <key-style + latin:styleName="num2KeyStyle" + latin:code="50" + latin:keyIcon="@drawable/sym_keyboard_num2" /> + <key-style + latin:styleName="num3KeyStyle" + latin:code="51" + latin:keyIcon="@drawable/sym_keyboard_num3" /> + <key-style + latin:styleName="num4KeyStyle" + latin:code="52" + latin:keyIcon="@drawable/sym_keyboard_num4" /> + <key-style + latin:styleName="num5KeyStyle" + latin:code="53" + latin:keyIcon="@drawable/sym_keyboard_num5" /> + <key-style + latin:styleName="num6KeyStyle" + latin:code="54" + latin:keyIcon="@drawable/sym_keyboard_num6" /> + <key-style + latin:styleName="num7KeyStyle" + latin:code="55" + latin:keyIcon="@drawable/sym_keyboard_num7" /> + <key-style + latin:styleName="num8KeyStyle" + latin:code="56" + latin:keyIcon="@drawable/sym_keyboard_num8" /> + <key-style + latin:styleName="num9KeyStyle" + latin:code="57" + latin:keyIcon="@drawable/sym_keyboard_num9" /> + <key-style + latin:styleName="numStarKeyStyle" + latin:code="42" + latin:keyIcon="@drawable/sym_keyboard_numstar" /> + <key-style + latin:styleName="numPoundKeyStyle" + latin:code="35" + latin:keyIcon="@drawable/sym_keyboard_numpound" /> + <key-style + latin:styleName="numAltKeyStyle" + latin:code="@integer/key_switch_alpha_symbol" + latin:keyIcon="@drawable/sym_keyboard_numalt" + latin:iconPreview="@drawable/sym_keyboard_feedback_numalt" /> + <key-style + latin:styleName="numSpaceKeyStyle" + latin:code="@integer/key_space" + latin:keyIcon="@drawable/sym_keyboard_space" + latin:iconPreview="@drawable/sym_keyboard_feedback_space" /> + </case> + <case + latin:colorScheme="black" + > + <key-style + latin:styleName="num0KeyStyle" + latin:code="48" + latin:keyIcon="@drawable/sym_bkeyboard_num0" /> + <key-style + latin:styleName="num1KeyStyle" + latin:code="49" + latin:keyIcon="@drawable/sym_bkeyboard_num1" /> + <key-style + latin:styleName="num2KeyStyle" + latin:code="50" + latin:keyIcon="@drawable/sym_bkeyboard_num2" /> + <key-style + latin:styleName="num3KeyStyle" + latin:code="51" + latin:keyIcon="@drawable/sym_bkeyboard_num3" /> + <key-style + latin:styleName="num4KeyStyle" + latin:code="52" + latin:keyIcon="@drawable/sym_bkeyboard_num4" /> + <key-style + latin:styleName="num5KeyStyle" + latin:code="53" + latin:keyIcon="@drawable/sym_bkeyboard_num5" /> + <key-style + latin:styleName="num6KeyStyle" + latin:code="54" + latin:keyIcon="@drawable/sym_bkeyboard_num6" /> + <key-style + latin:styleName="num7KeyStyle" + latin:code="55" + latin:keyIcon="@drawable/sym_bkeyboard_num7" /> + <key-style + latin:styleName="num8KeyStyle" + latin:code="56" + latin:keyIcon="@drawable/sym_bkeyboard_num8" /> + <key-style + latin:styleName="num9KeyStyle" + latin:code="57" + latin:keyIcon="@drawable/sym_bkeyboard_num9" /> + <key-style + latin:styleName="numStarKeyStyle" + latin:code="42" + latin:keyIcon="@drawable/sym_bkeyboard_numstar" /> + <key-style + latin:styleName="numPoundKeyStyle" + latin:code="35" + latin:keyIcon="@drawable/sym_bkeyboard_numpound" /> + <key-style + latin:styleName="numAltKeyStyle" + latin:code="@integer/key_switch_alpha_symbol" + latin:keyIcon="@drawable/sym_bkeyboard_numalt" + latin:iconPreview="@drawable/sym_keyboard_feedback_numalt" /> + <key-style + latin:styleName="numSpaceKeyStyle" + latin:code="@integer/key_space" + latin:keyIcon="@drawable/sym_bkeyboard_space" + latin:iconPreview="@drawable/sym_keyboard_feedback_space" /> + </case> + </switch> +</merge> diff --git a/java/res/xml/kbd_phone.xml b/java/res/xml/kbd_phone.xml index 10774c666..62fbdeeec 100644 --- a/java/res/xml/kbd_phone.xml +++ b/java/res/xml/kbd_phone.xml @@ -19,88 +19,76 @@ --> <Keyboard - xmlns:android="http://schemas.android.com/apk/res/android" - android:keyWidth="26.67%p" - android:horizontalGap="0px" - android:verticalGap="@dimen/key_bottom_gap" - android:keyHeight="@dimen/key_height" + xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin" + latin:keyboardHeight="@dimen/keyboardHeight" + latin:maxKeyboardHeight="50%p" + latin:rowHeight="25%p" + latin:keyWidth="26.67%p" + latin:horizontalGap="@dimen/key_horizontal_gap" + latin:verticalGap="@dimen/key_bottom_gap" + latin:popupKeyboardTemplate="@xml/kbd_popup_template" + latin:maxPopupKeyboardColumn="@integer/config_max_popup_keyboard_column" > + <include + latin:keyboardLayout="@xml/kbd_key_styles" /> + <include + latin:keyboardLayout="@xml/kbd_numkey_styles" /> <Row - android:rowEdgeFlags="top" + latin:rowEdgeFlags="top" > <Key - android:codes="49" - android:keyIcon="@drawable/sym_keyboard_num1" - android:keyEdgeFlags="left" /> + latin:keyStyle="num1KeyStyle" + latin:keyEdgeFlags="left" /> <Key - android:codes="50" - android:keyIcon="@drawable/sym_keyboard_num2" /> + latin:keyStyle="num2KeyStyle" /> <Key - android:codes="51" - android:keyIcon="@drawable/sym_keyboard_num3" /> + latin:keyStyle="num3KeyStyle" /> <Key - android:keyLabel="-" - android:keyWidth="20%p" - android:isModifier="true" - android:keyEdgeFlags="right" /> + latin:keyLabel="-" + latin:keyStyle="functionalKeyStyle" + latin:keyWidth="20%p" + latin:keyEdgeFlags="right" /> </Row> <Row> <Key - android:codes="52" - android:keyIcon="@drawable/sym_keyboard_num4" - android:keyEdgeFlags="left" /> + latin:keyStyle="num4KeyStyle" + latin:keyEdgeFlags="left" /> <Key - android:codes="53" - android:keyIcon="@drawable/sym_keyboard_num5" /> + latin:keyStyle="num5KeyStyle" /> <Key - android:codes="54" - android:keyIcon="@drawable/sym_keyboard_num6" /> + latin:keyStyle="num6KeyStyle" /> <Key - android:keyLabel="." - android:keyWidth="20%p" - android:isModifier="true" - android:keyEdgeFlags="right" /> + latin:keyLabel="." + latin:keyStyle="functionalKeyStyle" + latin:keyWidth="20%p" + latin:keyEdgeFlags="right" /> </Row> <Row> <Key - android:codes="55" - android:keyIcon="@drawable/sym_keyboard_num7" - android:keyEdgeFlags="left" /> + latin:keyStyle="num7KeyStyle" + latin:keyEdgeFlags="left" /> <Key - android:codes="56" - android:keyIcon="@drawable/sym_keyboard_num8" /> + latin:keyStyle="num8KeyStyle" /> <Key - android:codes="57" - android:keyIcon="@drawable/sym_keyboard_num9" /> + latin:keyStyle="num9KeyStyle" /> <Key - android:codes="@integer/key_delete" - android:keyIcon="@drawable/sym_keyboard_delete" - android:iconPreview="@drawable/sym_keyboard_feedback_delete" - android:keyWidth="20%p" - android:isModifier="true" - android:isRepeatable="true" - android:keyEdgeFlags="right" /> + latin:keyStyle="deleteKeyStyle" + latin:keyWidth="20%p" + latin:keyEdgeFlags="right" /> </Row> <Row - android:rowEdgeFlags="bottom" + latin:rowEdgeFlags="bottom" > <Key - android:codes="@integer/key_symbol" - android:keyIcon="@drawable/sym_keyboard_numalt" - android:iconPreview="@drawable/sym_keyboard_feedback_numalt" - android:keyEdgeFlags="left" /> + latin:keyStyle="numAltKeyStyle" + latin:keyEdgeFlags="left" /> <Key - android:codes="48" - android:keyIcon="@drawable/sym_keyboard_num0" /> + latin:keyStyle="num0KeyStyle" /> <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_keyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" /> + latin:keyStyle="numSpaceKeyStyle" /> <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_keyboard_return" - android:keyWidth="20%p" - android:isModifier="true" - android:keyEdgeFlags="right" /> + latin:keyStyle="returnKeyStyle" + latin:keyWidth="20%p" + latin:keyEdgeFlags="right" /> </Row> </Keyboard> diff --git a/java/res/xml/kbd_phone_black.xml b/java/res/xml/kbd_phone_black.xml deleted file mode 100644 index 5afa9a194..000000000 --- a/java/res/xml/kbd_phone_black.xml +++ /dev/null @@ -1,101 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- -/* -** -** Copyright 2010, The Android Open Source Project -** -** Licensed under the Apache License, Version 2.0 (the "License"); -** you may not use this file except in compliance with the License. -** You may obtain a copy of the License at -** -** http://www.apache.org/licenses/LICENSE-2.0 -** -** Unless required by applicable law or agreed to in writing, software -** distributed under the License is distributed on an "AS IS" BASIS, -** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -** See the License for the specific language governing permissions and -** limitations under the License. -*/ ---> - -<Keyboard - xmlns:android="http://schemas.android.com/apk/res/android" - android:keyWidth="26.67%p" - android:horizontalGap="0px" - android:verticalGap="@dimen/key_bottom_gap" - android:keyHeight="@dimen/key_height" -> - <Row - android:rowEdgeFlags="top" - > - <Key - android:codes="49" - android:keyIcon="@drawable/sym_bkeyboard_num1" - android:keyEdgeFlags="left" /> - <Key - android:codes="50" - android:keyIcon="@drawable/sym_bkeyboard_num2" /> - <Key - android:codes="51" - android:keyIcon="@drawable/sym_bkeyboard_num3" /> - <Key - android:keyLabel="-" - android:keyWidth="20%p" - android:keyEdgeFlags="right" /> - </Row> - <Row> - <Key - android:codes="52" - android:keyIcon="@drawable/sym_bkeyboard_num4" - android:keyEdgeFlags="left" /> - <Key - android:codes="53" - android:keyIcon="@drawable/sym_bkeyboard_num5" /> - <Key - android:codes="54" - android:keyIcon="@drawable/sym_bkeyboard_num6" /> - <Key - android:keyLabel="." - android:keyWidth="20%p" - android:keyEdgeFlags="right" /> - </Row> - <Row> - <Key - android:codes="55" - android:keyIcon="@drawable/sym_bkeyboard_num7" - android:keyEdgeFlags="left" /> - <Key - android:codes="56" - android:keyIcon="@drawable/sym_bkeyboard_num8" /> - <Key - android:codes="57" - android:keyIcon="@drawable/sym_bkeyboard_num9" /> - <Key - android:codes="@integer/key_delete" - android:keyIcon="@drawable/sym_bkeyboard_delete" - android:iconPreview="@drawable/sym_keyboard_feedback_delete" - android:keyWidth="20%p" - android:isRepeatable="true" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyIcon="@drawable/sym_bkeyboard_numalt" - android:iconPreview="@drawable/sym_keyboard_feedback_numalt" /> - <Key - android:codes="48" - android:keyIcon="@drawable/sym_bkeyboard_num0" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_bkeyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" /> - <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_bkeyboard_return" - android:keyWidth="20%p" - android:keyEdgeFlags="right" /> - </Row> -</Keyboard> diff --git a/java/res/xml/kbd_phone_symbols.xml b/java/res/xml/kbd_phone_symbols.xml index 4c928a8d8..67cd330e7 100644 --- a/java/res/xml/kbd_phone_symbols.xml +++ b/java/res/xml/kbd_phone_symbols.xml @@ -19,84 +19,82 @@ --> <Keyboard - xmlns:android="http://schemas.android.com/apk/res/android" - android:keyWidth="26.67%p" - android:horizontalGap="0px" - android:verticalGap="@dimen/key_bottom_gap" - android:keyHeight="@dimen/key_height" + xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin" + latin:keyboardHeight="@dimen/keyboardHeight" + latin:maxKeyboardHeight="50%p" + latin:rowHeight="25%p" + latin:keyWidth="26.67%p" + latin:horizontalGap="@dimen/key_horizontal_gap" + latin:verticalGap="@dimen/key_bottom_gap" + latin:popupKeyboardTemplate="@xml/kbd_popup_template" + latin:maxPopupKeyboardColumn="@integer/config_max_popup_keyboard_column" > + <include + latin:keyboardLayout="@xml/kbd_key_styles" /> + <include + latin:keyboardLayout="@xml/kbd_numkey_styles" /> <Row - android:rowEdgeFlags="top" + latin:rowEdgeFlags="top" > <Key - android:keyLabel="(" - android:keyEdgeFlags="left" /> + latin:keyLabel="(" + latin:keyEdgeFlags="left" /> <Key - android:keyLabel="/" /> + latin:keyLabel="/" /> <Key - android:keyLabel=")" /> + latin:keyLabel=")" /> <Key - android:keyLabel="-" - android:keyWidth="20%p" - android:isModifier="true" - android:keyEdgeFlags="right" /> + latin:keyLabel="-" + latin:keyStyle="functionalKeyStyle" + latin:keyWidth="20%p" + latin:keyEdgeFlags="right" /> </Row> <Row> <Key - android:keyLabel="N" - android:keyEdgeFlags="left" /> + latin:keyLabel="N" + latin:keyEdgeFlags="left" /> <!-- Pause is a comma. Check PhoneNumberUtils.java to see if this has changed. --> <Key - android:codes="44" - android:keyLabel="Pause" /> + latin:code="44" + latin:keyLabel="Pause" /> <Key - android:keyLabel="," /> + latin:keyLabel="," /> <Key - android:keyLabel="." - android:keyWidth="20%p" - android:isModifier="true" - android:keyEdgeFlags="right" /> + latin:keyLabel="." + latin:keyStyle="functionalKeyStyle" + latin:keyWidth="20%p" + latin:keyEdgeFlags="right" /> </Row> <Row> <Key - android:codes="42" - android:keyIcon="@drawable/sym_keyboard_numstar" - android:keyEdgeFlags="left" /> + latin:keyStyle="numStarKeyStyle" + latin:keyEdgeFlags="left" /> <!-- Wait is a semicolon. --> <Key - android:codes="59" - android:keyLabel="Wait" /> + latin:code="59" + latin:keyLabel="Wait" /> <Key - android:codes="35" - android:keyIcon="@drawable/sym_keyboard_numpound" /> + latin:keyStyle="numPoundKeyStyle" /> <Key - android:codes="@integer/key_delete" - android:keyIcon="@drawable/sym_keyboard_delete" - android:iconPreview="@drawable/sym_keyboard_feedback_delete" - android:keyWidth="20%p" - android:isModifier="true" - android:isRepeatable="true" - android:keyEdgeFlags="right" /> + latin:keyStyle="deleteKeyStyle" + latin:keyWidth="20%p" + latin:keyEdgeFlags="right" /> </Row> <Row - android:rowEdgeFlags="bottom" + latin:rowEdgeFlags="bottom" > <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_phone_key" - android:keyEdgeFlags="left" /> + latin:code="@integer/key_switch_alpha_symbol" + latin:keyLabel="@string/label_to_numeric_key" + latin:keyEdgeFlags="left" /> <Key - android:keyLabel="+" /> + latin:keyLabel="+" /> <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_keyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" /> + latin:keyStyle="numSpaceKeyStyle" /> <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_keyboard_return" - android:keyWidth="20%p" - android:isModifier="true" - android:keyEdgeFlags="right" /> + latin:keyStyle="returnKeyStyle" + latin:keyWidth="20%p" + latin:keyEdgeFlags="right" /> </Row> </Keyboard> diff --git a/java/res/xml/kbd_phone_symbols_black.xml b/java/res/xml/kbd_phone_symbols_black.xml deleted file mode 100644 index 4d686e145..000000000 --- a/java/res/xml/kbd_phone_symbols_black.xml +++ /dev/null @@ -1,98 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- -/* -** -** Copyright 2010, The Android Open Source Project -** -** Licensed under the Apache License, Version 2.0 (the "License"); -** you may not use this file except in compliance with the License. -** You may obtain a copy of the License at -** -** http://www.apache.org/licenses/LICENSE-2.0 -** -** Unless required by applicable law or agreed to in writing, software -** distributed under the License is distributed on an "AS IS" BASIS, -** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -** See the License for the specific language governing permissions and -** limitations under the License. -*/ ---> - -<Keyboard - xmlns:android="http://schemas.android.com/apk/res/android" - android:keyWidth="26.67%p" - android:horizontalGap="0px" - android:verticalGap="@dimen/key_bottom_gap" - android:keyHeight="@dimen/key_height" -> - <Row - android:rowEdgeFlags="top" - > - <Key - android:keyLabel="(" - android:keyEdgeFlags="left" /> - <Key - android:keyLabel="/" /> - <Key - android:keyLabel=")" /> - <Key - android:keyLabel="-" - android:keyWidth="20%p" - android:keyEdgeFlags="right" /> - </Row> - <Row> - <Key - android:keyLabel="N" - android:keyEdgeFlags="left" /> - <!-- Pause is a comma. Check PhoneNumberUtils.java to see if this - has changed. --> - <Key - android:codes="44" - android:keyLabel="Pause" /> - <Key - android:keyLabel="," /> - <Key - android:keyLabel="." - android:keyWidth="20%p" - android:keyEdgeFlags="right" /> - </Row> - <Row> - <Key - android:codes="42" - android:keyIcon="@drawable/sym_bkeyboard_numstar" - android:keyEdgeFlags="left" /> - <!-- Wait is a semicolon. --> - <Key - android:codes="59" - android:keyLabel="Wait" /> - <Key - android:codes="35" - android:keyIcon="@drawable/sym_bkeyboard_numpound" /> - <Key - android:codes="@integer/key_delete" - android:keyIcon="@drawable/sym_bkeyboard_delete" - android:iconPreview="@drawable/sym_keyboard_feedback_delete" - android:keyWidth="20%p" - android:isRepeatable="true" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_phone_key" - android:keyEdgeFlags="left" /> - <Key - android:keyLabel="+" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_bkeyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" /> - <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_bkeyboard_return" - android:keyWidth="20%p" - android:keyEdgeFlags="right" /> - </Row> -</Keyboard> diff --git a/java/res/xml/kbd_popup_narrow_template.xml b/java/res/xml/kbd_popup_narrow_template.xml index 23c686e8b..36caf1c15 100644 --- a/java/res/xml/kbd_popup_narrow_template.xml +++ b/java/res/xml/kbd_popup_narrow_template.xml @@ -18,10 +18,10 @@ */ --> -<Keyboard xmlns:android="http://schemas.android.com/apk/res/android" - android:keyWidth="9.45%p" - android:horizontalGap="0px" - android:verticalGap="0px" - android:keyHeight="@dimen/popup_key_height" +<Keyboard xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin" + latin:keyWidth="9.45%p" + latin:horizontalGap="0px" + latin:verticalGap="0px" + latin:rowHeight="@dimen/popup_key_height" > </Keyboard> diff --git a/java/res/xml/kbd_popup_template.xml b/java/res/xml/kbd_popup_template.xml index a287be1fd..9ee27493d 100644 --- a/java/res/xml/kbd_popup_template.xml +++ b/java/res/xml/kbd_popup_template.xml @@ -18,10 +18,10 @@ */ --> -<Keyboard xmlns:android="http://schemas.android.com/apk/res/android" - android:keyWidth="10%p" - android:horizontalGap="0px" - android:verticalGap="0px" - android:keyHeight="@dimen/popup_key_height" +<Keyboard xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin" + latin:keyWidth="10%p" + latin:horizontalGap="@dimen/key_horizontal_gap" + latin:verticalGap="0px" + latin:rowHeight="@dimen/popup_key_height" > </Keyboard> diff --git a/java/res/xml/kbd_qwerty.xml b/java/res/xml/kbd_qwerty.xml index a4ab0f8fe..92d92f0e6 100644 --- a/java/res/xml/kbd_qwerty.xml +++ b/java/res/xml/kbd_qwerty.xml @@ -19,487 +19,16 @@ --> <Keyboard - xmlns:android="http://schemas.android.com/apk/res/android" - android:keyWidth="10%p" - android:horizontalGap="0px" - android:verticalGap="@dimen/key_bottom_gap" - android:keyHeight="@dimen/key_height" + xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin" + latin:keyboardHeight="@dimen/keyboardHeight" + latin:maxKeyboardHeight="50%p" + latin:rowHeight="25%p" + latin:keyWidth="10%p" + latin:horizontalGap="@dimen/key_horizontal_gap" + latin:verticalGap="@dimen/key_bottom_gap" + latin:popupKeyboardTemplate="@xml/kbd_popup_template" + latin:maxPopupKeyboardColumn="@integer/config_max_popup_keyboard_column" > - <Row - android:rowEdgeFlags="top" - > - <Key - android:keyLabel="q" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_q" - android:keyEdgeFlags="left" /> - <Key - android:keyLabel="w" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_w" /> - <Key - android:keyLabel="e" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_e" /> - <Key - android:keyLabel="r" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_r" /> - <Key - android:keyLabel="t" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_t" /> - <Key - android:keyLabel="y" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_y" /> - <Key - android:keyLabel="u" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_u" /> - <Key - android:keyLabel="i" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_i" /> - <Key - android:keyLabel="o" - android:popupKeyboard="@xml/kbd_popup_narrow_template" - android:popupCharacters="@string/alternates_for_o" /> - <Key - android:keyLabel="p" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_p" - android:keyEdgeFlags="right" /> - </Row> - <Row> - <Key - android:keyLabel="a" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_a" - android:horizontalGap="5%p" - android:keyEdgeFlags="left" /> - <Key - android:keyLabel="s" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_s" /> - <Key - android:keyLabel="d" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_d" /> - <Key - android:keyLabel="f" /> - <Key - android:keyLabel="g" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_g" /> - <Key - android:keyLabel="h" /> - <Key - android:keyLabel="j" /> - <Key - android:keyLabel="k" /> - <Key - android:keyLabel="l" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_l" - android:keyEdgeFlags="right" /> - </Row> - <Row> - <Key - android:codes="@integer/key_shift" - android:keyIcon="@drawable/sym_keyboard_shift" - android:iconPreview="@drawable/sym_keyboard_feedback_shift" - android:keyWidth="15%p" - android:isModifier="true" - android:isSticky="true" - android:keyEdgeFlags="left" /> - <Key - android:keyLabel="z" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_z" /> - <Key - android:keyLabel="x" /> - <Key - android:keyLabel="c" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_c" /> - <Key - android:keyLabel="v" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_v" /> - <Key - android:keyLabel="b" /> - <Key - android:keyLabel="n" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_n" /> - <Key - android:keyLabel="m" /> - <Key - android:codes="@integer/key_delete" - android:keyIcon="@drawable/sym_keyboard_delete" - android:iconPreview="@drawable/sym_keyboard_feedback_delete" - android:keyWidth="15%p" - android:isModifier="true" - android:isRepeatable="true" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_normal" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_symbol_key" - android:keyWidth="20%p" - android:isModifier="true" - android:keyEdgeFlags="left" /> - <Key - android:codes="@integer/key_f1" - android:isModifier="true" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_keyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="40%p" - android:isModifier="true" /> - <Key - android:keyLabel="." - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_punctuation" - android:isModifier="true" /> - <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_keyboard_return" - android:iconPreview="@drawable/sym_keyboard_feedback_return" - android:keyWidth="20%p" - android:isModifier="true" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_url" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_symbol_key" - android:keyWidth="20%p" - android:isModifier="true" - android:keyEdgeFlags="left" /> - <Key - android:codes="@integer/key_f1" - android:isModifier="true" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_keyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="40%p" - android:isModifier="true" /> - <Key - android:keyLabel="." - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_punctuation" - android:isModifier="true" /> - <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_keyboard_return" - android:iconPreview="@drawable/sym_keyboard_feedback_return" - android:keyWidth="20%p" - android:isModifier="true" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_email" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_symbol_key" - android:keyWidth="20%p" - android:isModifier="true" - android:keyEdgeFlags="left" /> - <Key - android:codes="@integer/key_f1" - android:isModifier="true" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_keyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="40%p" - android:isModifier="true" /> - <Key - android:keyLabel="." - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_punctuation" - android:isModifier="true" /> - <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_keyboard_return" - android:iconPreview="@drawable/sym_keyboard_feedback_return" - android:keyWidth="20%p" - android:isModifier="true" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_im" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_symbol_key" - android:keyWidth="20%p" - android:isModifier="true" - android:keyEdgeFlags="left" /> - <Key - android:codes="@integer/key_f1" - android:isModifier="true" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_keyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="40%p" - android:isModifier="true" /> - <Key - android:keyLabel="." - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_punctuation" - android:isModifier="true" /> - <Key - android:keyLabel=":-)" - android:keyOutputText=":-) " - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_smileys" - android:keyWidth="20%p" - android:isModifier="true" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_webentry" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_symbol_key" - android:keyWidth="20%p" - android:isModifier="true" - android:keyEdgeFlags="left" /> - <Key - android:codes="@integer/key_f1" - android:isModifier="true" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_keyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="20%p" - android:isModifier="true" /> - <Key - android:codes="@integer/key_tab" - android:keyIcon="@drawable/sym_keyboard_tab" - android:iconPreview="@drawable/sym_keyboard_feedback_tab" - android:keyWidth="20%p" - android:isModifier="true" /> - <Key - android:keyLabel="." - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_punctuation" - android:isModifier="true" /> - <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_keyboard_return" - android:iconPreview="@drawable/sym_keyboard_feedback_return" - android:keyWidth="20%p" - android:isModifier="true" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_normal_with_settings_key" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_symbol_key" - android:keyWidth="15%p" - android:isModifier="true" - android:keyEdgeFlags="left" /> - <Key - android:codes="@integer/key_settings" - android:keyIcon="@drawable/sym_keyboard_settings" - android:iconPreview="@drawable/sym_keyboard_feedback_settings" - android:isModifier="true" /> - <Key - android:codes="@integer/key_f1" - android:isModifier="true" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_keyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="30%p" - android:isModifier="true" /> - <Key - android:keyLabel="." - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_punctuation" - android:isModifier="true" /> - <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_keyboard_return" - android:iconPreview="@drawable/sym_keyboard_feedback_return" - android:keyWidth="25%p" - android:isModifier="true" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_url_with_settings_key" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_symbol_key" - android:keyWidth="15%p" - android:isModifier="true" - android:keyEdgeFlags="left" /> - <Key - android:codes="@integer/key_settings" - android:keyIcon="@drawable/sym_keyboard_settings" - android:iconPreview="@drawable/sym_keyboard_feedback_settings" - android:isModifier="true" /> - <Key - android:codes="@integer/key_f1" - android:isModifier="true" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_keyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="30%p" - android:isModifier="true" /> - <Key - android:keyLabel="." - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_punctuation" - android:isModifier="true" /> - <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_keyboard_return" - android:iconPreview="@drawable/sym_keyboard_feedback_return" - android:keyWidth="25%p" - android:isModifier="true" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_email_with_settings_key" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_symbol_key" - android:keyWidth="15%p" - android:isModifier="true" - android:keyEdgeFlags="left" /> - <Key - android:codes="@integer/key_settings" - android:keyIcon="@drawable/sym_keyboard_settings" - android:iconPreview="@drawable/sym_keyboard_feedback_settings" - android:isModifier="true" /> - <Key - android:codes="@integer/key_f1" - android:isModifier="true" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_keyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="30%p" - android:isModifier="true" /> - <Key - android:keyLabel="." - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_punctuation" - android:isModifier="true" /> - <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_keyboard_return" - android:iconPreview="@drawable/sym_keyboard_feedback_return" - android:keyWidth="25%p" - android:isModifier="true" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_im_with_settings_key" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_symbol_key" - android:keyWidth="15%p" - android:isModifier="true" - android:keyEdgeFlags="left" /> - <Key - android:codes="@integer/key_settings" - android:keyIcon="@drawable/sym_keyboard_settings" - android:iconPreview="@drawable/sym_keyboard_feedback_settings" - android:isModifier="true" /> - <Key - android:codes="@integer/key_f1" - android:isModifier="true" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_keyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="30%p" - android:isModifier="true" /> - <Key - android:keyLabel="." - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_punctuation" - android:isModifier="true" /> - <Key - android:keyLabel=":-)" - android:keyOutputText=":-) " - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_smileys" - android:keyWidth="25%p" - android:isModifier="true" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_webentry_with_settings_key" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_symbol_key" - android:keyWidth="15%p" - android:isModifier="true" - android:keyEdgeFlags="left" /> - <Key - android:codes="@integer/key_settings" - android:keyIcon="@drawable/sym_keyboard_settings" - android:iconPreview="@drawable/sym_keyboard_feedback_settings" - android:isModifier="true" /> - <Key - android:codes="@integer/key_f1" - android:isModifier="true" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_keyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="30%p" - android:isModifier="true" /> - <Key - android:codes="@integer/key_tab" - android:keyIcon="@drawable/sym_keyboard_tab" - android:iconPreview="@drawable/sym_keyboard_feedback_tab" - android:isModifier="true" /> - <Key - android:keyLabel="." - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_punctuation" - android:isModifier="true" /> - <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_keyboard_return" - android:iconPreview="@drawable/sym_keyboard_feedback_return" - android:keyWidth="15%p" - android:isModifier="true" - android:keyEdgeFlags="right" /> - </Row> + <include + latin:keyboardLayout="@xml/kbd_qwerty_rows" /> </Keyboard> diff --git a/java/res/xml/kbd_qwerty_black.xml b/java/res/xml/kbd_qwerty_black.xml deleted file mode 100644 index 787e4ef7c..000000000 --- a/java/res/xml/kbd_qwerty_black.xml +++ /dev/null @@ -1,447 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- -/* -** -** Copyright 2008, The Android Open Source Project -** -** Licensed under the Apache License, Version 2.0 (the "License"); -** you may not use this file except in compliance with the License. -** You may obtain a copy of the License at -** -** http://www.apache.org/licenses/LICENSE-2.0 -** -** Unless required by applicable law or agreed to in writing, software -** distributed under the License is distributed on an "AS IS" BASIS, -** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -** See the License for the specific language governing permissions and -** limitations under the License. -*/ ---> - -<Keyboard - xmlns:android="http://schemas.android.com/apk/res/android" - android:keyWidth="10%p" - android:horizontalGap="0px" - android:verticalGap="@dimen/key_bottom_gap" - android:keyHeight="@dimen/key_height" -> - <Row - android:rowEdgeFlags="top" - > - <Key - android:keyLabel="q" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_q" - android:keyEdgeFlags="left" /> - <Key - android:keyLabel="w" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_w" /> - <Key - android:keyLabel="e" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_e" /> - <Key - android:keyLabel="r" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_r" /> - <Key - android:keyLabel="t" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_t" /> - <Key - android:keyLabel="y" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_y" /> - <Key - android:keyLabel="u" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_u" /> - <Key - android:keyLabel="i" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_i" /> - <Key - android:keyLabel="o" - android:popupKeyboard="@xml/kbd_popup_narrow_template" - android:popupCharacters="@string/alternates_for_o" /> - <Key - android:keyLabel="p" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_p" - android:keyEdgeFlags="right" /> - </Row> - <Row> - <Key - android:keyLabel="a" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_a" - android:horizontalGap="5%p" - android:keyEdgeFlags="left" /> - <Key - android:keyLabel="s" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_s" /> - <Key - android:keyLabel="d" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_d" /> - <Key - android:keyLabel="f" /> - <Key - android:keyLabel="g" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_g" /> - <Key - android:keyLabel="h" /> - <Key - android:keyLabel="j" /> - <Key - android:keyLabel="k" /> - <Key - android:keyLabel="l" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_l" - android:keyEdgeFlags="right" /> - </Row> - <Row> - <Key - android:codes="@integer/key_shift" - android:keyIcon="@drawable/sym_bkeyboard_shift" - android:iconPreview="@drawable/sym_keyboard_feedback_shift" - android:keyWidth="15%p" - android:isModifier="true" - android:isSticky="true" - android:keyEdgeFlags="left" /> - <Key - android:keyLabel="z" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_z" /> - <Key - android:keyLabel="x" /> - <Key - android:keyLabel="c" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_c" /> - <Key - android:keyLabel="v" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_v" /> - <Key - android:keyLabel="b" /> - <Key - android:keyLabel="n" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="@string/alternates_for_n" /> - <Key - android:keyLabel="m" /> - <Key - android:codes="@integer/key_delete" - android:keyIcon="@drawable/sym_bkeyboard_delete" - android:iconPreview="@drawable/sym_keyboard_feedback_delete" - android:keyWidth="15%p" - android:isRepeatable="true" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_normal" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_symbol_key" - android:keyWidth="20%p" - android:keyEdgeFlags="left" /> - <Key - android:codes="@integer/key_f1" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_bkeyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="40%p" /> - <Key - android:keyLabel="." - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_punctuation" /> - <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_bkeyboard_return" - android:iconPreview="@drawable/sym_keyboard_feedback_return" - android:keyWidth="20%p" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_url" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_symbol_key" - android:keyWidth="20%p" - android:keyEdgeFlags="left" /> - <Key - android:codes="@integer/key_f1" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_bkeyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="40%p" /> - <Key - android:keyLabel="." - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_punctuation" /> - <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_bkeyboard_return" - android:iconPreview="@drawable/sym_keyboard_feedback_return" - android:keyWidth="20%p" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_email" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_symbol_key" - android:keyWidth="20%p" - android:keyEdgeFlags="left" /> - <Key - android:codes="@integer/key_f1" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_bkeyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="40%p" /> - <Key - android:keyLabel="." - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_punctuation" /> - <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_bkeyboard_return" - android:iconPreview="@drawable/sym_keyboard_feedback_return" - android:keyWidth="20%p" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_im" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_symbol_key" - android:keyWidth="20%p" - android:keyEdgeFlags="left" /> - <Key - android:codes="@integer/key_f1" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_bkeyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="40%p" /> - <Key - android:keyLabel="." - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_punctuation" /> - <Key - android:keyLabel=":-)" - android:keyOutputText=":-) " - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_smileys" - android:keyWidth="20%p" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_webentry" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_symbol_key" - android:keyWidth="20%p" - android:keyEdgeFlags="left" /> - <Key - android:codes="@integer/key_f1" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_bkeyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="20%p" /> - <Key - android:codes="@integer/key_tab" - android:keyIcon="@drawable/sym_bkeyboard_tab" - android:iconPreview="@drawable/sym_keyboard_feedback_tab" - android:keyWidth="20%p" /> - <Key - android:keyLabel="." - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_punctuation" /> - <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_bkeyboard_return" - android:iconPreview="@drawable/sym_keyboard_feedback_return" - android:keyWidth="20%p" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_normal_with_settings_key" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_symbol_key" - android:keyWidth="15%p" - android:keyEdgeFlags="left" /> - <Key - android:codes="@integer/key_settings" - android:keyIcon="@drawable/sym_bkeyboard_settings" - android:iconPreview="@drawable/sym_keyboard_feedback_settings" /> - <Key - android:codes="@integer/key_f1" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_bkeyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="30%p" /> - <Key - android:keyLabel="." - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_punctuation" /> - <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_bkeyboard_return" - android:iconPreview="@drawable/sym_keyboard_feedback_return" - android:keyWidth="25%p" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_url_with_settings_key" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_symbol_key" - android:keyWidth="15%p" - android:keyEdgeFlags="left" /> - <Key - android:codes="@integer/key_settings" - android:keyIcon="@drawable/sym_bkeyboard_settings" - android:iconPreview="@drawable/sym_keyboard_feedback_settings" /> - <Key - android:codes="@integer/key_f1" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_bkeyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="30%p" /> - <Key - android:keyLabel="." - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_punctuation" /> - <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_bkeyboard_return" - android:iconPreview="@drawable/sym_keyboard_feedback_return" - android:keyWidth="25%p" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_email_with_settings_key" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_symbol_key" - android:keyWidth="15%p" - android:keyEdgeFlags="left" /> - <Key - android:codes="@integer/key_settings" - android:keyIcon="@drawable/sym_bkeyboard_settings" - android:iconPreview="@drawable/sym_keyboard_feedback_settings" /> - <Key - android:codes="@integer/key_f1" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_bkeyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="30%p" /> - <Key - android:keyLabel="." - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_punctuation" /> - <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_bkeyboard_return" - android:iconPreview="@drawable/sym_keyboard_feedback_return" - android:keyWidth="25%p" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_im_with_settings_key" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_symbol_key" - android:keyWidth="15%p" - android:keyEdgeFlags="left" /> - <Key - android:codes="@integer/key_settings" - android:keyIcon="@drawable/sym_bkeyboard_settings" - android:iconPreview="@drawable/sym_keyboard_feedback_settings" /> - <Key - android:codes="@integer/key_f1" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_bkeyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="30%p" /> - <Key - android:keyLabel="." - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_punctuation" /> - <Key - android:keyLabel=":-)" - android:keyOutputText=":-) " - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_smileys" - android:keyWidth="25%p" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_webentry_with_settings_key" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_symbol_key" - android:keyWidth="15%p" - android:keyEdgeFlags="left" /> - <Key - android:codes="@integer/key_settings" - android:keyIcon="@drawable/sym_bkeyboard_settings" - android:iconPreview="@drawable/sym_keyboard_feedback_settings" /> - <Key - android:codes="@integer/key_f1" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_bkeyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="30%p" /> - <Key - android:codes="@integer/key_tab" - android:keyIcon="@drawable/sym_bkeyboard_tab" - android:iconPreview="@drawable/sym_keyboard_feedback_tab" /> - <Key - android:keyLabel="." - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_punctuation" /> - <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_bkeyboard_return" - android:iconPreview="@drawable/sym_keyboard_feedback_return" - android:keyWidth="15%p" - android:keyEdgeFlags="right" /> - </Row> -</Keyboard> diff --git a/java/res/xml/kbd_qwerty_black_symbol.xml b/java/res/xml/kbd_qwerty_black_symbol.xml new file mode 100644 index 000000000..6e45c12bf --- /dev/null +++ b/java/res/xml/kbd_qwerty_black_symbol.xml @@ -0,0 +1,84 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- +/* +** +** Copyright 2010, The Android Open Source Project +** +** Licensed under the Apache License, Version 2.0 (the "License"); +** you may not use this file except in compliance with the License. +** You may obtain a copy of the License at +** +** http://www.apache.org/licenses/LICENSE-2.0 +** +** Unless required by applicable law or agreed to in writing, software +** distributed under the License is distributed on an "AS IS" BASIS, +** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +** See the License for the specific language governing permissions and +** limitations under the License. +*/ +--> + +<merge + xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin" +> + <switch> + <case + latin:hasSettingsKey="false" + > + <switch> + <!-- When this qwerty keyboard has no voice key but voice key is enabled, then + symbol keyboard will have mic key. That means we should use "?123mic" key here. + --> + <case + latin:voiceKeyEnabled="true" + latin:hasVoiceKey="false" + > + <Key + latin:code="@integer/key_switch_alpha_symbol" + latin:keyIcon="@drawable/sym_bkeyboard_123_mic" + latin:iconPreview="@drawable/sym_keyboard_feedback_123_mic" + latin:keyWidth="20%p" + latin:isModifier="true" + latin:keyEdgeFlags="left" /> + </case> + <default> + <Key + latin:code="@integer/key_switch_alpha_symbol" + latin:keyLabel="@string/label_to_symbol_key" + latin:keyWidth="20%p" + latin:isModifier="true" + latin:keyEdgeFlags="left" /> + </default> + </switch> + </case> + <case + latin:hasSettingsKey="true" + > + <switch> + <!-- When this qwerty keyboard has no voice key but voice key is enabled, then + symbol keyboard will have mic key. That means we should use "?123mic" key here. + --> + <case + latin:voiceKeyEnabled="true" + latin:hasVoiceKey="false" + > + <Key + latin:code="@integer/key_switch_alpha_symbol" + latin:keyIcon="@drawable/sym_bkeyboard_123_mic" + latin:iconPreview="@drawable/sym_keyboard_feedback_123_mic" + latin:keyWidth="15%p" + latin:isModifier="true" + latin:keyEdgeFlags="left" /> + </case> + <default> + <Key + latin:code="@integer/key_switch_alpha_symbol" + latin:keyLabel="@string/label_to_symbol_key" + latin:keyWidth="15%p" + latin:isModifier="true" + latin:keyEdgeFlags="left" /> + </default> + </switch> + </case> + </switch> +</merge> diff --git a/java/res/xml/kbd_qwerty_f1.xml b/java/res/xml/kbd_qwerty_f1.xml new file mode 100644 index 000000000..cbdb8c09a --- /dev/null +++ b/java/res/xml/kbd_qwerty_f1.xml @@ -0,0 +1,63 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- +/* +** +** Copyright 2010, The Android Open Source Project +** +** Licensed under the Apache License, Version 2.0 (the "License"); +** you may not use this file except in compliance with the License. +** You may obtain a copy of the License at +** +** http://www.apache.org/licenses/LICENSE-2.0 +** +** Unless required by applicable law or agreed to in writing, software +** distributed under the License is distributed on an "AS IS" BASIS, +** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +** See the License for the specific language governing permissions and +** limitations under the License. +*/ +--> + +<merge + xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin" +> + <switch> + <case + latin:mode="url" + > + <Key + latin:keyLabel="/" + latin:keyHintIcon="@drawable/hint_popup" + latin:popupCharacters="@string/alternates_for_settings_slash" + latin:isModifier="true" /> + </case> + <case + latin:mode="email" + > + <Key + latin:keyLabel="\@" + latin:keyHintIcon="@drawable/hint_popup" + latin:popupCharacters="@string/alternates_for_settings_at" + latin:isModifier="true" /> + </case> + <default> + <switch> + <case + latin:hasVoiceKey="true" + > + <Key + latin:keyStyle="micKeyStyle" /> + </case> + <case + latin:hasVoiceKey="false" + > + <Key + latin:keyLabel="," + latin:keyHintIcon="@drawable/hint_popup" + latin:popupCharacters="@string/alternates_for_settings_comma" + latin:isModifier="true" /> + </case> + </switch> + </default> + </switch> +</merge> diff --git a/java/res/xml/kbd_qwerty_row1.xml b/java/res/xml/kbd_qwerty_row1.xml new file mode 100644 index 000000000..d9249657e --- /dev/null +++ b/java/res/xml/kbd_qwerty_row1.xml @@ -0,0 +1,71 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- +/* +** +** Copyright 2010, The Android Open Source Project +** +** Licensed under the Apache License, Version 2.0 (the "License"); +** you may not use this file except in compliance with the License. +** You may obtain a copy of the License at +** +** http://www.apache.org/licenses/LICENSE-2.0 +** +** Unless required by applicable law or agreed to in writing, software +** distributed under the License is distributed on an "AS IS" BASIS, +** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +** See the License for the specific language governing permissions and +** limitations under the License. +*/ +--> + +<merge + xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin" +> + <Row + latin:keyWidth="10%p" + latin:rowEdgeFlags="top" + > + <Key + latin:keyLabel="q" + latin:keyHintIcon="@drawable/keyboard_hint_1" + latin:popupCharacters="@string/alternates_for_q" + latin:keyEdgeFlags="left" /> + <Key + latin:keyLabel="w" + latin:keyHintIcon="@drawable/keyboard_hint_2" + latin:popupCharacters="@string/alternates_for_w" /> + <Key + latin:keyLabel="e" + latin:keyHintIcon="@drawable/keyboard_hint_3" + latin:popupCharacters="@string/alternates_for_e" /> + <Key + latin:keyLabel="r" + latin:keyHintIcon="@drawable/keyboard_hint_4" + latin:popupCharacters="@string/alternates_for_r" /> + <Key + latin:keyLabel="t" + latin:keyHintIcon="@drawable/keyboard_hint_5" + latin:popupCharacters="@string/alternates_for_t" /> + <Key + latin:keyLabel="y" + latin:keyHintIcon="@drawable/keyboard_hint_6" + latin:popupCharacters="@string/alternates_for_y" /> + <Key + latin:keyLabel="u" + latin:keyHintIcon="@drawable/keyboard_hint_7" + latin:popupCharacters="@string/alternates_for_u" /> + <Key + latin:keyLabel="i" + latin:keyHintIcon="@drawable/keyboard_hint_8" + latin:popupCharacters="@string/alternates_for_i" /> + <Key + latin:keyLabel="o" + latin:keyHintIcon="@drawable/keyboard_hint_9" + latin:popupCharacters="@string/alternates_for_o" /> + <Key + latin:keyLabel="p" + latin:keyHintIcon="@drawable/keyboard_hint_0" + latin:popupCharacters="@string/alternates_for_p" + latin:keyEdgeFlags="right" /> + </Row> +</merge> diff --git a/java/res/xml/kbd_qwerty_row2.xml b/java/res/xml/kbd_qwerty_row2.xml new file mode 100644 index 000000000..dd0035d93 --- /dev/null +++ b/java/res/xml/kbd_qwerty_row2.xml @@ -0,0 +1,55 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- +/* +** +** Copyright 2010, The Android Open Source Project +** +** Licensed under the Apache License, Version 2.0 (the "License"); +** you may not use this file except in compliance with the License. +** You may obtain a copy of the License at +** +** http://www.apache.org/licenses/LICENSE-2.0 +** +** Unless required by applicable law or agreed to in writing, software +** distributed under the License is distributed on an "AS IS" BASIS, +** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +** See the License for the specific language governing permissions and +** limitations under the License. +*/ +--> + +<merge + xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin" +> + <Row + latin:keyWidth="10%p" + > + <Spacer + latin:horizontalGap="5%p" /> + <Key + latin:keyLabel="a" + latin:popupCharacters="@string/alternates_for_a" + latin:keyEdgeFlags="left" /> + <Key + latin:keyLabel="s" + latin:popupCharacters="@string/alternates_for_s" /> + <Key + latin:keyLabel="d" + latin:popupCharacters="@string/alternates_for_d" /> + <Key + latin:keyLabel="f" /> + <Key + latin:keyLabel="g" + latin:popupCharacters="@string/alternates_for_g" /> + <Key + latin:keyLabel="h" /> + <Key + latin:keyLabel="j" /> + <Key + latin:keyLabel="k" /> + <Key + latin:keyLabel="l" + latin:popupCharacters="@string/alternates_for_l" + latin:keyEdgeFlags="right" /> + </Row> +</merge> diff --git a/java/res/xml/kbd_qwerty_row3.xml b/java/res/xml/kbd_qwerty_row3.xml new file mode 100644 index 000000000..26608fd71 --- /dev/null +++ b/java/res/xml/kbd_qwerty_row3.xml @@ -0,0 +1,54 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- +/* +** +** Copyright 2010, The Android Open Source Project +** +** Licensed under the Apache License, Version 2.0 (the "License"); +** you may not use this file except in compliance with the License. +** You may obtain a copy of the License at +** +** http://www.apache.org/licenses/LICENSE-2.0 +** +** Unless required by applicable law or agreed to in writing, software +** distributed under the License is distributed on an "AS IS" BASIS, +** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +** See the License for the specific language governing permissions and +** limitations under the License. +*/ +--> + +<merge + xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin" +> + <Row + latin:keyWidth="10%p" + > + <Key + latin:keyStyle="shiftKeyStyle" + latin:keyWidth="15%p" + latin:keyEdgeFlags="left" /> + <Key + latin:keyLabel="z" + latin:popupCharacters="@string/alternates_for_z" /> + <Key + latin:keyLabel="x" /> + <Key + latin:keyLabel="c" + latin:popupCharacters="@string/alternates_for_c" /> + <Key + latin:keyLabel="v" + latin:popupCharacters="@string/alternates_for_v" /> + <Key + latin:keyLabel="b" /> + <Key + latin:keyLabel="n" + latin:popupCharacters="@string/alternates_for_n" /> + <Key + latin:keyLabel="m" /> + <Key + latin:keyStyle="deleteKeyStyle" + latin:keyWidth="15%p" + latin:keyEdgeFlags="right" /> + </Row> +</merge> diff --git a/java/res/xml/kbd_qwerty_row4.xml b/java/res/xml/kbd_qwerty_row4.xml new file mode 100644 index 000000000..0db011672 --- /dev/null +++ b/java/res/xml/kbd_qwerty_row4.xml @@ -0,0 +1,138 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- +/* +** +** Copyright 2010, The Android Open Source Project +** +** Licensed under the Apache License, Version 2.0 (the "License"); +** you may not use this file except in compliance with the License. +** You may obtain a copy of the License at +** +** http://www.apache.org/licenses/LICENSE-2.0 +** +** Unless required by applicable law or agreed to in writing, software +** distributed under the License is distributed on an "AS IS" BASIS, +** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +** See the License for the specific language governing permissions and +** limitations under the License. +*/ +--> + +<merge + xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin" +> + <Row + latin:keyWidth="10%p" + latin:rowEdgeFlags="bottom" + > + <switch> + <case + latin:hasSettingsKey="false" + > + <Key + latin:keyStyle="toSymbolKeyStyle" + latin:keyWidth="20%p" + latin:keyEdgeFlags="left" /> + <include + latin:keyboardLayout="@xml/kbd_qwerty_f1" /> + <switch> + <case + latin:mode="web" + > + <Key + latin:keyStyle="spaceKeyStyle" + latin:keyWidth="20%p" /> + <Key + latin:keyStyle="tabKeyStyle" + latin:keyWidth="20%p" /> + </case> + <default> + <Key + latin:keyStyle="spaceKeyStyle" + latin:keyWidth="40%p" /> + </default> + </switch> + <Key + latin:keyLabel="." + latin:keyHintIcon="@drawable/hint_popup" + latin:popupCharacters="@string/alternates_for_punctuation" + latin:maxPopupKeyboardColumn="7" + latin:keyStyle="functionalKeyStyle" /> + <switch> + <case + latin:mode="im" + > + <Key + latin:keyStyle="smileyKeyStyle" + latin:keyWidth="20%p" + latin:keyEdgeFlags="right" /> + </case> + <default> + <Key + latin:keyStyle="returnKeyStyle" + latin:keyWidth="20%p" + latin:keyEdgeFlags="right" /> + </default> + </switch> + </case> + <case + latin:hasSettingsKey="true" + > + <Key + latin:keyStyle="toSymbolKeyStyle" + latin:keyWidth="15%p" + latin:keyEdgeFlags="left" /> + <Key + latin:keyStyle="settingsKeyStyle" /> + <include + latin:keyboardLayout="@xml/kbd_qwerty_f1" /> + <switch> + <case + latin:mode="web" + > + <Key + latin:keyStyle="spaceKeyStyle" + latin:keyWidth="30%p" /> + <Key + latin:keyStyle="tabKeyStyle" /> + </case> + <default> + <Key + latin:keyStyle="spaceKeyStyle" + latin:keyWidth="30%p" /> + </default> + </switch> + <Key + latin:keyLabel="." + latin:keyHintIcon="@drawable/hint_popup" + latin:popupCharacters="@string/alternates_for_punctuation" + latin:maxPopupKeyboardColumn="7" + latin:keyStyle="functionalKeyStyle" /> + <switch> + <case + latin:mode="im" + > + <Key + latin:keyStyle="smileyKeyStyle" + latin:keyWidth="25%p" + latin:keyEdgeFlags="right" /> + </case> + <case + latin:mode="web" + > + <Key + latin:keyStyle="returnKeyStyle" + latin:keyWidth="15%p" + latin:keyEdgeFlags="right" /> + </case> + <default> + <Key + latin:keyStyle="returnKeyStyle" + latin:keyWidth="25%p" + latin:keyEdgeFlags="right" /> + </default> + </switch> + </case> + </switch> + </Row> +</merge> diff --git a/java/res/xml/dictionary.xml b/java/res/xml/kbd_qwerty_rows.xml index 7b770a8b4..6237712f6 100644 --- a/java/res/xml/dictionary.xml +++ b/java/res/xml/kbd_qwerty_rows.xml @@ -18,6 +18,17 @@ */ --> -<dictionary> - <part name = "main" /> -</dictionary>
\ No newline at end of file +<merge + xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin" +> + <include + latin:keyboardLayout="@xml/kbd_key_styles" /> + <include + latin:keyboardLayout="@xml/kbd_qwerty_row1" /> + <include + latin:keyboardLayout="@xml/kbd_qwerty_row2" /> + <include + latin:keyboardLayout="@xml/kbd_qwerty_row3" /> + <include + latin:keyboardLayout="@xml/kbd_qwerty_row4" /> +</merge> diff --git a/java/res/xml/kbd_qwerty_rows_scandinavia.xml b/java/res/xml/kbd_qwerty_rows_scandinavia.xml new file mode 100644 index 000000000..490652663 --- /dev/null +++ b/java/res/xml/kbd_qwerty_rows_scandinavia.xml @@ -0,0 +1,118 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- +/* +** +** Copyright 2010, The Android Open Source Project +** +** Licensed under the Apache License, Version 2.0 (the "License"); +** you may not use this file except in compliance with the License. +** You may obtain a copy of the License at +** +** http://www.apache.org/licenses/LICENSE-2.0 +** +** Unless required by applicable law or agreed to in writing, software +** distributed under the License is distributed on an "AS IS" BASIS, +** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +** See the License for the specific language governing permissions and +** limitations under the License. +*/ +--> + +<merge + xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin" +> + <include + latin:keyboardLayout="@xml/kbd_key_styles" /> + <Row + latin:keyWidth="9.09%p" + latin:rowEdgeFlags="top" + > + <Key + latin:keyLabel="q" + latin:keyHintIcon="@drawable/keyboard_hint_1" + latin:popupCharacters="@string/alternates_for_q" + latin:keyWidth="8.75%p" + latin:keyEdgeFlags="left" /> + <Key + latin:keyLabel="w" + latin:keyHintIcon="@drawable/keyboard_hint_2" + latin:popupCharacters="@string/alternates_for_w" /> + <Key + latin:keyLabel="e" + latin:keyHintIcon="@drawable/keyboard_hint_3" + latin:popupCharacters="@string/alternates_for_e" /> + <Key + latin:keyLabel="r" + latin:keyHintIcon="@drawable/keyboard_hint_4" + latin:popupCharacters="@string/alternates_for_r" /> + <Key + latin:keyLabel="t" + latin:keyHintIcon="@drawable/keyboard_hint_5" + latin:popupCharacters="@string/alternates_for_t" /> + <Key + latin:keyLabel="y" + latin:keyHintIcon="@drawable/keyboard_hint_6" + latin:popupCharacters="@string/alternates_for_y" /> + <Key + latin:keyLabel="u" + latin:keyHintIcon="@drawable/keyboard_hint_7" + latin:popupCharacters="@string/alternates_for_u" /> + <Key + latin:keyLabel="i" + latin:keyHintIcon="@drawable/keyboard_hint_8" + latin:popupCharacters="@string/alternates_for_i" /> + <Key + latin:keyLabel="o" + latin:keyHintIcon="@drawable/keyboard_hint_9" + latin:popupCharacters="@string/alternates_for_o" /> + <Key + latin:keyLabel="p" + latin:keyHintIcon="@drawable/keyboard_hint_0" + latin:popupCharacters="@string/alternates_for_p" /> + <Key + latin:keyLabel="å" + latin:keyWidth="8.75%p" + latin:keyEdgeFlags="right" /> + </Row> + <Row + latin:keyWidth="9.09%p" + > + <Key + latin:keyLabel="a" + latin:popupCharacters="@string/alternates_for_a" + latin:keyWidth="8.75%p" + latin:keyEdgeFlags="left" /> + <Key + latin:keyLabel="s" + latin:popupCharacters="@string/alternates_for_s" /> + <Key + latin:keyLabel="d" + latin:popupCharacters="@string/alternates_for_d" /> + <Key + latin:keyLabel="f" /> + <Key + latin:keyLabel="g" + latin:popupCharacters="@string/alternates_for_g" /> + <Key + latin:keyLabel="h" /> + <Key + latin:keyLabel="j" /> + <Key + latin:keyLabel="k" /> + <Key + latin:keyLabel="l" + latin:popupCharacters="@string/alternates_for_l" /> + <Key + latin:keyLabel="@string/keylabel_for_scandinavia_row2_10" + latin:popupCharacters="@string/alternates_for_scandinavia_row2_10" /> + <Key + latin:keyLabel="@string/keylabel_for_scandinavia_row2_11" + latin:popupCharacters="@string/alternates_for_scandinavia_row2_11" + latin:keyWidth="8.75%p" + latin:keyEdgeFlags="right" /> + </Row> + <include + latin:keyboardLayout="@xml/kbd_qwerty_row3" /> + <include + latin:keyboardLayout="@xml/kbd_qwerty_row4" /> +</merge> diff --git a/java/res/xml/kbd_qwertz_rows.xml b/java/res/xml/kbd_qwertz_rows.xml new file mode 100644 index 000000000..375f12335 --- /dev/null +++ b/java/res/xml/kbd_qwertz_rows.xml @@ -0,0 +1,107 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- +/* +** +** Copyright 2010, The Android Open Source Project +** +** Licensed under the Apache License, Version 2.0 (the "License"); +** you may not use this file except in compliance with the License. +** You may obtain a copy of the License at +** +** http://www.apache.org/licenses/LICENSE-2.0 +** +** Unless required by applicable law or agreed to in writing, software +** distributed under the License is distributed on an "AS IS" BASIS, +** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +** See the License for the specific language governing permissions and +** limitations under the License. +*/ +--> + +<merge + xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin" +> + <include + latin:keyboardLayout="@xml/kbd_key_styles" /> + <Row + latin:keyWidth="10%p" + latin:rowEdgeFlags="top" + > + <Key + latin:keyLabel="q" + latin:keyHintIcon="@drawable/keyboard_hint_1" + latin:popupCharacters="@string/alternates_for_q" + latin:keyEdgeFlags="left" /> + <Key + latin:keyLabel="w" + latin:keyHintIcon="@drawable/keyboard_hint_2" + latin:popupCharacters="@string/alternates_for_w" /> + <Key + latin:keyLabel="e" + latin:keyHintIcon="@drawable/keyboard_hint_3" + latin:popupCharacters="@string/alternates_for_e" /> + <Key + latin:keyLabel="r" + latin:keyHintIcon="@drawable/keyboard_hint_4" + latin:popupCharacters="@string/alternates_for_r" /> + <Key + latin:keyLabel="t" + latin:keyHintIcon="@drawable/keyboard_hint_5" + latin:popupCharacters="@string/alternates_for_t" /> + <Key + latin:keyLabel="z" + latin:keyHintIcon="@drawable/keyboard_hint_6" + latin:popupCharacters="@string/alternates_for_z" /> + <Key + latin:keyLabel="u" + latin:keyHintIcon="@drawable/keyboard_hint_7" + latin:popupCharacters="@string/alternates_for_u" /> + <Key + latin:keyLabel="i" + latin:keyHintIcon="@drawable/keyboard_hint_8" + latin:popupCharacters="@string/alternates_for_i" /> + <Key + latin:keyLabel="o" + latin:keyHintIcon="@drawable/keyboard_hint_9" + latin:popupCharacters="@string/alternates_for_o" /> + <Key + latin:keyLabel="p" + latin:keyHintIcon="@drawable/keyboard_hint_0" + latin:popupCharacters="@string/alternates_for_p" + latin:keyEdgeFlags="right" /> + </Row> + <include + latin:keyboardLayout="@xml/kbd_qwerty_row2" /> + <Row + latin:keyWidth="10%p" + > + <Key + latin:keyStyle="shiftKeyStyle" + latin:keyWidth="15%p" + latin:keyEdgeFlags="left" /> + <Key + latin:keyLabel="y" + latin:popupCharacters="@string/alternates_for_y" /> + <Key + latin:keyLabel="x" /> + <Key + latin:keyLabel="c" + latin:popupCharacters="@string/alternates_for_c" /> + <Key + latin:keyLabel="v" + latin:popupCharacters="@string/alternates_for_v" /> + <Key + latin:keyLabel="b" /> + <Key + latin:keyLabel="n" + latin:popupCharacters="@string/alternates_for_n" /> + <Key + latin:keyLabel="m" /> + <Key + latin:keyStyle="deleteKeyStyle" + latin:keyWidth="15%p" + latin:keyEdgeFlags="right" /> + </Row> + <include + latin:keyboardLayout="@xml/kbd_qwerty_row4" /> +</merge> diff --git a/java/res/xml/kbd_symbols.xml b/java/res/xml/kbd_symbols.xml index bcb6e8ae8..5d62deaa4 100644 --- a/java/res/xml/kbd_symbols.xml +++ b/java/res/xml/kbd_symbols.xml @@ -19,196 +19,109 @@ --> <Keyboard - xmlns:android="http://schemas.android.com/apk/res/android" - android:keyWidth="10%p" - android:horizontalGap="0px" - android:verticalGap="@dimen/key_bottom_gap" - android:keyHeight="@dimen/key_height" + xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin" + latin:keyboardHeight="@dimen/keyboardHeight" + latin:maxKeyboardHeight="50%p" + latin:rowHeight="25%p" + latin:keyWidth="10%p" + latin:horizontalGap="@dimen/key_horizontal_gap" + latin:verticalGap="@dimen/key_bottom_gap" + latin:popupKeyboardTemplate="@xml/kbd_popup_template" + latin:maxPopupKeyboardColumn="@integer/config_max_popup_keyboard_column" > + <include + latin:keyboardLayout="@xml/kbd_key_styles" /> <Row - android:rowEdgeFlags="top" + latin:rowEdgeFlags="top" > <Key - android:keyLabel="1" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="¹½⅓¼⅛" - android:keyEdgeFlags="left" /> + latin:keyLabel="1" + latin:popupCharacters="¹,½,⅓,¼,⅛" + latin:keyEdgeFlags="left" /> <Key - android:keyLabel="2" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="²⅔" /> + latin:keyLabel="2" + latin:popupCharacters="²,⅔" /> <Key - android:keyLabel="3" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="³¾⅜" /> + latin:keyLabel="3" + latin:popupCharacters="³,¾,⅜" /> <Key - android:keyLabel="4" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="⁴" /> + latin:keyLabel="4" + latin:popupCharacters="⁴" /> <Key - android:keyLabel="5" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="⅝" /> + latin:keyLabel="5" + latin:popupCharacters="⅝" /> <Key - android:keyLabel="6" /> + latin:keyLabel="6" /> <Key - android:keyLabel="7" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="⅞" /> + latin:keyLabel="7" + latin:popupCharacters="⅞" /> <Key - android:keyLabel="8" /> + latin:keyLabel="8" /> <Key - android:keyLabel="9" /> + latin:keyLabel="9" /> <Key - android:keyLabel="0" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="ⁿ∅" - android:keyEdgeFlags="right" /> + latin:keyLabel="0" + latin:popupCharacters="ⁿ,∅" + latin:keyEdgeFlags="right" /> </Row> <Row> <Key - android:keyLabel="\@" - android:keyEdgeFlags="left" /> + latin:keyLabel="\@" + latin:keyEdgeFlags="left" /> <Key - android:keyLabel="\#" /> + latin:keyLabel="\#" /> <Key - android:keyLabel="$" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="¢£€¥₣₤₱" /> + latin:keyLabel="$" + latin:popupCharacters="¢,£,€,¥,₣,₤,₱" /> <Key - android:keyLabel="%" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="‰" /> + latin:keyLabel="%" + latin:popupCharacters="‰" /> <Key - android:keyLabel="&" /> + latin:keyLabel="&" /> <Key - android:keyLabel="*" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="†‡★" /> + latin:keyLabel="*" + latin:popupCharacters="†,‡,★" /> <Key - android:keyLabel="-" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="_–—" /> + latin:keyLabel="-" + latin:popupCharacters="_,–,—" /> <Key - android:keyLabel="+" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="±" /> + latin:keyLabel="+" + latin:popupCharacters="±" /> <Key - android:keyLabel="(" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="[{<" /> + latin:keyLabel="(" + latin:popupCharacters="[,{,<" /> <Key - android:keyLabel=")" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="]}>" - android:keyEdgeFlags="right" /> + latin:keyLabel=")" + latin:popupCharacters="],},>" + latin:keyEdgeFlags="right" /> </Row> <Row> <Key - android:codes="@integer/key_shift" - android:keyLabel="@string/label_alt_key" - android:keyWidth="15%p" - android:isModifier="true" - android:isSticky="true" - android:keyEdgeFlags="left" /> + latin:keyStyle="altKeyStyle" + latin:keyWidth="15%p" + latin:keyEdgeFlags="left" /> <Key - android:keyLabel="!" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="¡" /> + latin:keyLabel="!" + latin:popupCharacters="¡" /> <Key - android:keyLabel=""" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="“”«»˝" /> + latin:keyLabel=""" + latin:popupCharacters="“,”,«,»,˝" /> <Key - android:keyLabel="\'" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="‘’" /> + latin:keyLabel="\'" + latin:popupCharacters="‘,’" /> <Key - android:keyLabel=":" /> + latin:keyLabel=":" /> <Key - android:keyLabel=";" /> + latin:keyLabel=";" /> <Key - android:keyLabel="/" /> + latin:keyLabel="/" /> <Key - android:keyLabel="\?" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="¿" /> + latin:keyLabel="\?" + latin:popupCharacters="¿" /> <Key - android:codes="@integer/key_delete" - android:keyIcon="@drawable/sym_keyboard_delete" - android:iconPreview="@drawable/sym_keyboard_feedback_delete" - android:keyWidth="15%p" - android:isModifier="true" - android:isRepeatable="true" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_symbols" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_alpha_key" - android:keyWidth="20%p" - android:isModifier="true" - android:keyEdgeFlags="left" /> - <Key - android:codes="@integer/key_f1" - android:isModifier="true" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_keyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="40%p" - android:isModifier="true" /> - <Key - android:keyLabel="." - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_punctuation" - android:isModifier="true" /> - <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_keyboard_return" - android:iconPreview="@drawable/sym_keyboard_feedback_return" - android:keyWidth="20%p" - android:isModifier="true" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_symbols_with_settings_key" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_alpha_key" - android:keyWidth="15%p" - android:isModifier="true" - android:keyEdgeFlags="left" /> - <Key - android:codes="@integer/key_settings" - android:keyIcon="@drawable/sym_keyboard_settings" - android:iconPreview="@drawable/sym_keyboard_feedback_settings" - android:isModifier="true" /> - <Key - android:codes="@integer/key_f1" - android:isModifier="true" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_keyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="30%p" - android:isModifier="true" /> - <Key - android:keyLabel="." - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_punctuation" - android:isModifier="true" /> - <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_keyboard_return" - android:iconPreview="@drawable/sym_keyboard_feedback_return" - android:keyWidth="25%p" - android:isModifier="true" - android:keyEdgeFlags="right" /> + latin:keyStyle="deleteKeyStyle" + latin:keyWidth="15%p" + latin:keyEdgeFlags="right" /> </Row> + <include latin:keyboardLayout="@xml/kbd_symbols_row4" /> </Keyboard> diff --git a/java/res/xml/kbd_symbols_black.xml b/java/res/xml/kbd_symbols_black.xml deleted file mode 100644 index add6c01c5..000000000 --- a/java/res/xml/kbd_symbols_black.xml +++ /dev/null @@ -1,202 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- -/* -** -** Copyright 2010, The Android Open Source Project -** -** Licensed under the Apache License, Version 2.0 (the "License"); -** you may not use this file except in compliance with the License. -** You may obtain a copy of the License at -** -** http://www.apache.org/licenses/LICENSE-2.0 -** -** Unless required by applicable law or agreed to in writing, software -** distributed under the License is distributed on an "AS IS" BASIS, -** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -** See the License for the specific language governing permissions and -** limitations under the License. -*/ ---> - -<Keyboard - xmlns:android="http://schemas.android.com/apk/res/android" - android:keyWidth="10%p" - android:horizontalGap="0px" - android:verticalGap="@dimen/key_bottom_gap" - android:keyHeight="@dimen/key_height" -> - <Row - android:rowEdgeFlags="top" - > - <Key - android:keyLabel="1" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="¹½⅓¼⅛" - android:keyEdgeFlags="left" /> - <Key - android:keyLabel="2" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="²⅔" /> - <Key - android:keyLabel="3" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="³¾⅜" /> - <Key - android:keyLabel="4" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="⁴" /> - <Key - android:keyLabel="5" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="⅝" /> - <Key - android:keyLabel="6" /> - <Key - android:keyLabel="7" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="⅞" /> - <Key - android:keyLabel="8" /> - <Key - android:keyLabel="9" /> - <Key - android:keyLabel="0" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="ⁿ∅" - android:keyEdgeFlags="right" /> - </Row> - <Row> - <Key - android:keyLabel="\@" - android:keyEdgeFlags="left" /> - <Key - android:keyLabel="\#" /> - <Key - android:keyLabel="$" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="¢£€¥₣₤₱" /> - <Key - android:keyLabel="%" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="‰" /> - <Key - android:keyLabel="&" /> - <Key - android:keyLabel="*" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="†‡★" /> - <Key - android:keyLabel="-" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="_–—" /> - <Key - android:keyLabel="+" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="±" /> - <Key - android:keyLabel="(" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="[{<" /> - <Key - android:keyLabel=")" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="]}>" - android:keyEdgeFlags="right" /> - </Row> - <Row> - <Key - android:codes="@integer/key_shift" - android:keyLabel="@string/label_alt_key" - android:keyWidth="15%p" - android:isModifier="true" - android:isSticky="true" - android:keyEdgeFlags="left" /> - <Key - android:keyLabel="!" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="¡" /> - <Key - android:keyLabel=""" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="“”«»˝" /> - <Key - android:keyLabel="\'" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="‘’" /> - <Key - android:keyLabel=":" /> - <Key - android:keyLabel=";" /> - <Key - android:keyLabel="/" /> - <Key - android:keyLabel="\?" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="¿" /> - <Key - android:codes="@integer/key_delete" - android:keyIcon="@drawable/sym_bkeyboard_delete" - android:iconPreview="@drawable/sym_keyboard_feedback_delete" - android:keyWidth="15%p" - android:isRepeatable="true" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_symbols" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_alpha_key" - android:keyWidth="20%p" - android:keyEdgeFlags="left" /> - <Key - android:codes="@integer/key_f1" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_bkeyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="40%p" /> - <Key - android:keyLabel="." - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_punctuation" /> - <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_bkeyboard_return" - android:iconPreview="@drawable/sym_keyboard_feedback_return" - android:keyWidth="20%p" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_symbols_with_settings_key" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_alpha_key" - android:keyWidth="15%p" - android:keyEdgeFlags="left" /> - <Key - android:codes="@integer/key_settings" - android:keyIcon="@drawable/sym_bkeyboard_settings" - android:iconPreview="@drawable/sym_keyboard_feedback_settings" /> - <Key - android:codes="@integer/key_f1" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_bkeyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="30%p" /> - <Key - android:keyLabel="." - android:keyIcon="@drawable/hint_popup" - android:popupKeyboard="@xml/popup_punctuation" /> - <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_bkeyboard_return" - android:iconPreview="@drawable/sym_keyboard_feedback_return" - android:keyWidth="25%p" - android:keyEdgeFlags="right" /> - </Row> -</Keyboard> diff --git a/java/res/xml/popup_at.xml b/java/res/xml/kbd_symbols_f1.xml index 197eea445..8487b6158 100644 --- a/java/res/xml/popup_at.xml +++ b/java/res/xml/kbd_symbols_f1.xml @@ -18,22 +18,24 @@ */ --> -<Keyboard - xmlns:android="http://schemas.android.com/apk/res/android" - android:keyWidth="10%p" - android:horizontalGap="0px" - android:verticalGap="0px" - android:keyHeight="@dimen/popup_key_height" +<merge + xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin" > - <Row - android:rowEdgeFlags="top|bottom" - > - <Key - android:codes="@integer/key_settings" - android:keyIcon="@drawable/sym_keyboard_settings" - android:keyEdgeFlags="left" /> - <Key - android:keyLabel="\@" - android:keyEdgeFlags="right" /> - </Row> -</Keyboard> + <switch> + <case + latin:hasVoiceKey="true" + > + <Key + latin:keyStyle="micKeyStyle" /> + </case> + <case + latin:hasVoiceKey="false" + > + <Key + latin:keyLabel="," + latin:keyHintIcon="@drawable/hint_popup" + latin:popupCharacters="@string/alternates_for_settings_comma" + latin:keyStyle="functionalKeyStyle" /> + </case> + </switch> +</merge> diff --git a/java/res/xml/kbd_symbols_row4.xml b/java/res/xml/kbd_symbols_row4.xml new file mode 100644 index 000000000..b330095af --- /dev/null +++ b/java/res/xml/kbd_symbols_row4.xml @@ -0,0 +1,102 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- +/* +** +** Copyright 2010, The Android Open Source Project +** +** Licensed under the Apache License, Version 2.0 (the "License"); +** you may not use this file except in compliance with the License. +** You may obtain a copy of the License at +** +** http://www.apache.org/licenses/LICENSE-2.0 +** +** Unless required by applicable law or agreed to in writing, software +** distributed under the License is distributed on an "AS IS" BASIS, +** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +** See the License for the specific language governing permissions and +** limitations under the License. +*/ +--> + +<merge + xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin" +> + <Row + latin:rowEdgeFlags="bottom" + > + <switch> + <case + latin:hasSettingsKey="false" + > + <Key + latin:keyStyle="toAlphaKeyStyle" + latin:keyWidth="20%p" + latin:keyEdgeFlags="left" /> + <include + latin:keyboardLayout="@xml/kbd_symbols_f1" /> + <Key + latin:keyStyle="spaceKeyStyle" + latin:keyWidth="40%p" /> + <Key + latin:keyLabel="." + latin:keyHintIcon="@drawable/hint_popup" + latin:popupCharacters="@string/alternates_for_punctuation" + latin:maxPopupKeyboardColumn="7" + latin:keyStyle="functionalKeyStyle" /> + <switch> + <case + latin:mode="im" + > + <Key + latin:keyStyle="smileyKeyStyle" + latin:keyWidth="20%p" + latin:keyEdgeFlags="right" /> + </case> + <default> + <Key + latin:keyStyle="returnKeyStyle" + latin:keyWidth="20%p" + latin:keyEdgeFlags="right" /> + </default> + </switch> + </case> + <case + latin:hasSettingsKey="true" + > + <Key + latin:keyStyle="toAlphaKeyStyle" + latin:keyWidth="15%p" + latin:keyEdgeFlags="left" /> + <Key + latin:keyStyle="settingsKeyStyle" /> + <include + latin:keyboardLayout="@xml/kbd_symbols_f1" /> + <Key + latin:keyStyle="spaceKeyStyle" + latin:keyWidth="30%p" /> + <Key + latin:keyLabel="." + latin:keyHintIcon="@drawable/hint_popup" + latin:popupCharacters="@string/alternates_for_punctuation" + latin:maxPopupKeyboardColumn="7" + latin:keyStyle="functionalKeyStyle" /> + <switch> + <case + latin:mode="im" + > + <Key + latin:keyStyle="smileyKeyStyle" + latin:keyWidth="25%p" + latin:keyEdgeFlags="right" /> + </case> + <default> + <Key + latin:keyStyle="returnKeyStyle" + latin:keyWidth="25%p" + latin:keyEdgeFlags="right" /> + </default> + </switch> + </case> + </switch> + </Row> +</merge> diff --git a/java/res/xml/kbd_symbols_shift.xml b/java/res/xml/kbd_symbols_shift.xml index 9bee22069..368ee805b 100644 --- a/java/res/xml/kbd_symbols_shift.xml +++ b/java/res/xml/kbd_symbols_shift.xml @@ -19,171 +19,98 @@ --> <Keyboard - xmlns:android="http://schemas.android.com/apk/res/android" - android:keyWidth="10%p" - android:horizontalGap="0px" - android:verticalGap="@dimen/key_bottom_gap" - android:keyHeight="@dimen/key_height" + xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin" + latin:keyboardHeight="@dimen/keyboardHeight" + latin:maxKeyboardHeight="50%p" + latin:rowHeight="25%p" + latin:keyWidth="10%p" + latin:horizontalGap="@dimen/key_horizontal_gap" + latin:verticalGap="@dimen/key_bottom_gap" + latin:popupKeyboardTemplate="@xml/kbd_popup_template" + latin:maxPopupKeyboardColumn="@integer/config_max_popup_keyboard_column" > + <include + latin:keyboardLayout="@xml/kbd_key_styles" /> <Row - android:rowEdgeFlags="top" + latin:rowEdgeFlags="top" > <Key - android:keyLabel="~" - android:keyEdgeFlags="left" /> + latin:keyLabel="~" + latin:keyEdgeFlags="left" /> <Key - android:keyLabel="`" /> + latin:keyLabel="`" /> <Key - android:keyLabel="|" /> + latin:keyLabel="|" /> <Key - android:keyLabel="•" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="♪♥♠♦♣" /> + latin:keyLabel="•" + latin:popupCharacters="♪,♥,♠,♦,♣" /> <Key - android:keyLabel="√" /> + latin:keyLabel="√" /> <Key - android:keyLabel="π" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="Π" /> + latin:keyLabel="π" + latin:popupCharacters="Π" /> <Key - android:keyLabel="÷" /> + latin:keyLabel="÷" /> <Key - android:keyLabel="×" /> + latin:keyLabel="×" /> <Key - android:keyLabel="{" /> + latin:keyLabel="{" /> <Key - android:keyLabel="}" - android:keyEdgeFlags="right" /> + latin:keyLabel="}" + latin:keyEdgeFlags="right" /> </Row> <Row> <Key - android:codes="@integer/key_tab" - android:keyLabel="\u21E5" - android:keyEdgeFlags="left" /> + latin:keyStyle="nonSpecialBackgroundTabKeyStyle" + latin:keyEdgeFlags="left" /> <Key - android:keyLabel="£" /> + latin:keyLabel="£" /> <Key - android:keyLabel="¢" /> + latin:keyLabel="¢" /> <Key - android:keyLabel="€" /> + latin:keyLabel="€" /> <Key - android:keyLabel="°" /> + latin:keyLabel="°" /> <Key - android:keyLabel="^" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="↑↓←→" /> + latin:keyLabel="^" + latin:popupCharacters="↑,↓,←,→" /> <Key - android:keyLabel="_" /> + latin:keyLabel="_" /> <Key - android:keyLabel="=" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="≠≈∞" /> + latin:keyLabel="=" + latin:popupCharacters="≠,≈,∞" /> <Key - android:keyLabel="[" /> + latin:keyLabel="[" /> <Key - android:keyLabel="]" - android:keyEdgeFlags="right" /> + latin:keyLabel="]" + latin:keyEdgeFlags="right" /> </Row> <Row> <Key - android:codes="@integer/key_shift" - android:keyLabel="@string/label_alt_key" - android:keyWidth="15%p" - android:isModifier="true" - android:isSticky="true" - android:keyEdgeFlags="left" /> + latin:keyStyle="shiftKeyStyle" + latin:keyWidth="15%p" + latin:keyEdgeFlags="left" /> <Key - android:keyLabel="™" /> + latin:keyLabel="™" /> <Key - android:keyLabel="®" /> + latin:keyLabel="®" /> <Key - android:keyLabel="©" /> + latin:keyLabel="©" /> <Key - android:keyLabel="¶" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="§" /> + latin:keyLabel="¶" + latin:popupCharacters="§" /> <Key - android:keyLabel="\\" /> + latin:keyLabel="\\" /> <Key - android:keyLabel="<" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="≤«‹" /> + latin:keyLabel="<" + latin:popupCharacters="≤,«,‹" /> <Key - android:keyLabel=">" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="≥»›" /> + latin:keyLabel=">" + latin:popupCharacters="≥,»,›" /> <Key - android:codes="@integer/key_delete" - android:keyIcon="@drawable/sym_keyboard_delete" - android:iconPreview="@drawable/sym_keyboard_feedback_delete" - android:keyWidth="15%p" - android:isModifier="true" - android:isRepeatable="true" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_symbols" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_alpha_key" - android:keyWidth="20%p" - android:isModifier="true" - android:keyEdgeFlags="left" /> - <Key - android:keyLabel="„" - android:isModifier="true" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_keyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="40%p" - android:isModifier="true" /> - <Key - android:keyLabel="…" - android:isModifier="true" /> - <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_keyboard_return" - android:iconPreview="@drawable/sym_keyboard_feedback_return" - android:keyWidth="20%p" - android:isModifier="true" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_symbols_with_settings_key" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_alpha_key" - android:keyWidth="15%p" - android:isModifier="true" - android:keyEdgeFlags="left" /> - <Key - android:codes="@integer/key_settings" - android:keyIcon="@drawable/sym_keyboard_settings" - android:iconPreview="@drawable/sym_keyboard_feedback_settings" - android:isModifier="true" /> - <Key - android:keyLabel="„" - android:isModifier="true" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_keyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="30%p" - android:isModifier="true" /> - <Key - android:keyLabel="…" - android:isModifier="true" /> - <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_keyboard_return" - android:iconPreview="@drawable/sym_keyboard_feedback_return" - android:keyWidth="25%p" - android:isModifier="true" - android:keyEdgeFlags="right" /> + latin:keyStyle="deleteKeyStyle" + latin:keyWidth="15%p" + latin:keyEdgeFlags="right" /> </Row> + <include latin:keyboardLayout="@xml/kbd_symbols_shift_row4" /> </Keyboard> diff --git a/java/res/xml/kbd_symbols_shift_black.xml b/java/res/xml/kbd_symbols_shift_black.xml deleted file mode 100644 index 52b67c3de..000000000 --- a/java/res/xml/kbd_symbols_shift_black.xml +++ /dev/null @@ -1,177 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- -/* -** -** Copyright 2010, The Android Open Source Project -** -** Licensed under the Apache License, Version 2.0 (the "License"); -** you may not use this file except in compliance with the License. -** You may obtain a copy of the License at -** -** http://www.apache.org/licenses/LICENSE-2.0 -** -** Unless required by applicable law or agreed to in writing, software -** distributed under the License is distributed on an "AS IS" BASIS, -** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -** See the License for the specific language governing permissions and -** limitations under the License. -*/ ---> - -<Keyboard - xmlns:android="http://schemas.android.com/apk/res/android" - android:keyWidth="10%p" - android:horizontalGap="0px" - android:verticalGap="@dimen/key_bottom_gap" - android:keyHeight="@dimen/key_height" -> - <Row - android:rowEdgeFlags="top" - > - <Key - android:keyLabel="~" - android:keyEdgeFlags="left" /> - <Key - android:keyLabel="`" /> - <Key - android:keyLabel="|" /> - <Key - android:keyLabel="•" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="♪♥♠♦♣" /> - <Key - android:keyLabel="√" /> - <Key - android:keyLabel="π" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="Π" /> - <Key - android:keyLabel="÷" /> - <Key - android:keyLabel="×" /> - <Key - android:keyLabel="{" /> - <Key - android:keyLabel="}" - android:keyEdgeFlags="right" /> - </Row> - <Row> - <Key - android:codes="@integer/key_tab" - android:keyLabel="\u21E5" - android:keyEdgeFlags="left" /> - <Key - android:keyLabel="£" /> - <Key - android:keyLabel="¢" /> - <Key - android:keyLabel="€" /> - <Key - android:keyLabel="°" /> - <Key - android:keyLabel="^" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="↑↓←→" /> - <Key - android:keyLabel="_" /> - <Key - android:keyLabel="=" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="≠≈∞" /> - <Key - android:keyLabel="[" /> - <Key - android:keyLabel="]" - android:keyEdgeFlags="right" /> - </Row> - <Row> - <Key - android:codes="@integer/key_shift" - android:keyLabel="@string/label_alt_key" - android:keyWidth="15%p" - android:isModifier="true" - android:isSticky="true" - android:keyEdgeFlags="left" /> - <Key - android:keyLabel="™" /> - <Key - android:keyLabel="®" /> - <Key - android:keyLabel="©" /> - <Key - android:keyLabel="¶" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="§" /> - <Key - android:keyLabel="\\" /> - <Key - android:keyLabel="<" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="≤«‹" /> - <Key - android:keyLabel=">" - android:popupKeyboard="@xml/kbd_popup_template" - android:popupCharacters="≥»›" /> - <Key - android:codes="@integer/key_delete" - android:keyIcon="@drawable/sym_bkeyboard_delete" - android:iconPreview="@drawable/sym_keyboard_feedback_delete" - android:keyWidth="15%p" - android:isRepeatable="true" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_symbols" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_alpha_key" - android:keyWidth="20%p" - android:keyEdgeFlags="left" /> - <Key - android:keyLabel="„" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_bkeyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="40%p" /> - <Key - android:keyLabel="…" /> - <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_bkeyboard_return" - android:iconPreview="@drawable/sym_keyboard_feedback_return" - android:keyWidth="20%p" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:keyboardMode="@+id/mode_symbols_with_settings_key" - android:rowEdgeFlags="bottom" - > - <Key - android:codes="@integer/key_symbol" - android:keyLabel="@string/label_alpha_key" - android:keyWidth="15%p" - android:keyEdgeFlags="left" /> - <Key - android:codes="@integer/key_settings" - android:keyIcon="@drawable/sym_bkeyboard_settings" - android:iconPreview="@drawable/sym_keyboard_feedback_settings" /> - <Key - android:keyLabel="„" /> - <Key - android:codes="@integer/key_space" - android:keyIcon="@drawable/sym_bkeyboard_space" - android:iconPreview="@drawable/sym_keyboard_feedback_space" - android:keyWidth="30%p" /> - <Key - android:keyLabel="…" /> - <Key - android:codes="@integer/key_return" - android:keyIcon="@drawable/sym_bkeyboard_return" - android:iconPreview="@drawable/sym_keyboard_feedback_return" - android:keyWidth="25%p" - android:keyEdgeFlags="right" /> - </Row> -</Keyboard> diff --git a/java/res/xml/kbd_symbols_shift_row4.xml b/java/res/xml/kbd_symbols_shift_row4.xml new file mode 100644 index 000000000..9159bab24 --- /dev/null +++ b/java/res/xml/kbd_symbols_shift_row4.xml @@ -0,0 +1,98 @@ +<?xml version="1.0" encoding="utf-8"?> +<!-- +/* +** +** Copyright 2010, The Android Open Source Project +** +** Licensed under the Apache License, Version 2.0 (the "License"); +** you may not use this file except in compliance with the License. +** You may obtain a copy of the License at +** +** http://www.apache.org/licenses/LICENSE-2.0 +** +** Unless required by applicable law or agreed to in writing, software +** distributed under the License is distributed on an "AS IS" BASIS, +** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +** See the License for the specific language governing permissions and +** limitations under the License. +*/ +--> + +<merge + xmlns:latin="http://schemas.android.com/apk/res/com.android.inputmethod.latin" +> + <Row + latin:rowEdgeFlags="bottom" + > + <switch> + <case + latin:hasSettingsKey="false" + > + <Key + latin:keyStyle="toAlphaKeyStyle" + latin:keyWidth="20%p" + latin:keyEdgeFlags="left" /> + <Key + latin:keyLabel="„" + latin:keyStyle="functionalKeyStyle" /> + <Key + latin:keyStyle="spaceKeyStyle" + latin:keyWidth="40%p" /> + <Key + latin:keyLabel="…" + latin:keyStyle="functionalKeyStyle" /> + <switch> + <case + latin:mode="im" + > + <Key + latin:keyStyle="smileyKeyStyle" + latin:keyWidth="20%p" + latin:keyEdgeFlags="right" /> + </case> + <default> + <Key + latin:keyStyle="returnKeyStyle" + latin:keyWidth="20%p" + latin:keyEdgeFlags="right" /> + </default> + </switch> + </case> + <case + latin:hasSettingsKey="true" + > + <Key + latin:keyStyle="toAlphaKeyStyle" + latin:keyWidth="15%p" + latin:keyEdgeFlags="left" /> + <Key + latin:keyStyle="settingsKeyStyle" /> + <Key + latin:keyLabel="„" + latin:keyStyle="functionalKeyStyle" /> + <Key + latin:keyStyle="spaceKeyStyle" + latin:keyWidth="30%p" /> + <Key + latin:keyLabel="…" + latin:keyStyle="functionalKeyStyle" /> + <switch> + <case + latin:mode="im" + > + <Key + latin:keyStyle="smileyKeyStyle" + latin:keyWidth="25%p" + latin:keyEdgeFlags="right" /> + </case> + <default> + <Key + latin:keyStyle="returnKeyStyle" + latin:keyWidth="25%p" + latin:keyEdgeFlags="right" /> + </default> + </switch> + </case> + </switch> + </Row> +</merge> diff --git a/java/res/xml/method.xml b/java/res/xml/method.xml index e5654e96d..482b35f4c 100644 --- a/java/res/xml/method.xml +++ b/java/res/xml/method.xml @@ -20,7 +20,178 @@ <!-- The attributes in this XML file provide configuration information --> <!-- for the Input Method Manager. --> +<!-- Keyboard: en_US, cs, da, de, en_GB, es, es_US, fr, fr_CA, fr_CH, it, nb, nl, sr, sv --> +<!-- Voice: cs, da, de, en_AU, en_GB, en_IN, en_NZ, en_US, es, fr, ko, ja, pl, pt, ru, tr, zh_CN, zh_TW --> +<!-- TODO: use <lang>_keyboard icon instead of a common keyboard icon. --> +<!-- TODO: use <lang>_mic icon instead of a common mic icon. --> <input-method xmlns:android="http://schemas.android.com/apk/res/android" - android:settingsActivity="com.android.inputmethod.latin.LatinIMESettings" - android:isDefault="@bool/im_is_default" -/> + android:settingsActivity="com.android.inputmethod.latin.Settings" + android:isDefault="@bool/im_is_default"> + <!-- If IME doesn't have an applicable subtype, the first subtype will be used as a default + subtype.--> + <subtype android:icon="@drawable/ic_subtype_keyboard_en_gb" + android:label="@string/subtype_mode_en_US_keyboard" + android:imeSubtypeLocale="en_US" + android:imeSubtypeMode="keyboard" + /> + <subtype android:icon="@drawable/ic_subtype_keyboard_cs" + android:label="@string/subtype_mode_cs_keyboard" + android:imeSubtypeLocale="cs" + android:imeSubtypeMode="keyboard" + /> + <subtype android:icon="@drawable/ic_subtype_keyboard_da" + android:label="@string/subtype_mode_da_keyboard" + android:imeSubtypeLocale="da" + android:imeSubtypeMode="keyboard" + /> + <subtype android:icon="@drawable/ic_subtype_keyboard_de" + android:label="@string/subtype_mode_de_keyboard" + android:imeSubtypeLocale="de" + android:imeSubtypeMode="keyboard" + /> + <subtype android:icon="@drawable/ic_subtype_keyboard_en_gb" + android:label="@string/subtype_mode_en_GB_keyboard" + android:imeSubtypeLocale="en_GB" + android:imeSubtypeMode="keyboard" + /> + <subtype android:icon="@drawable/ic_subtype_keyboard_es" + android:label="@string/subtype_mode_es_keyboard" + android:imeSubtypeLocale="es" + android:imeSubtypeMode="keyboard" + /> + <subtype android:icon="@drawable/ic_subtype_keyboard_es_us" + android:label="@string/subtype_mode_es_US_keyboard" + android:imeSubtypeLocale="es_US" + android:imeSubtypeMode="keyboard" + /> + <subtype android:icon="@drawable/ic_subtype_keyboard_fr" + android:label="@string/subtype_mode_fr_keyboard" + android:imeSubtypeLocale="fr" + android:imeSubtypeMode="keyboard" + /> + <subtype android:icon="@drawable/ic_subtype_keyboard_fr_ca" + android:label="@string/subtype_mode_fr_CA_keyboard" + android:imeSubtypeLocale="fr_CA" + android:imeSubtypeMode="keyboard" + /> + <subtype android:icon="@drawable/ic_subtype_keyboard_fr_ch" + android:label="@string/subtype_mode_fr_CH_keyboard" + android:imeSubtypeLocale="fr_CH" + android:imeSubtypeMode="keyboard" + /> + <subtype android:icon="@drawable/ic_subtype_keyboard_it" + android:label="@string/subtype_mode_it_keyboard" + android:imeSubtypeLocale="it" + android:imeSubtypeMode="keyboard" + /> + <subtype android:icon="@drawable/ic_subtype_keyboard_nb" + android:label="@string/subtype_mode_nb_keyboard" + android:imeSubtypeLocale="nb" + android:imeSubtypeMode="keyboard" + /> + <subtype android:icon="@drawable/ic_subtype_keyboard_nl" + android:label="@string/subtype_mode_nl_keyboard" + android:imeSubtypeLocale="nl" + android:imeSubtypeMode="keyboard" + /> + <subtype android:icon="@drawable/ic_subtype_keyboard_ru" + android:label="@string/subtype_mode_ru_keyboard" + android:imeSubtypeLocale="ru" + android:imeSubtypeMode="keyboard" + /> + <subtype android:icon="@drawable/ic_subtype_keyboard_sr" + android:label="@string/subtype_mode_sr_keyboard" + android:imeSubtypeLocale="sr" + android:imeSubtypeMode="keyboard" + /> + <subtype android:icon="@drawable/ic_subtype_keyboard_sv" + android:label="@string/subtype_mode_sv_keyboard" + android:imeSubtypeLocale="sv" + android:imeSubtypeMode="keyboard" + /> + <subtype android:icon="@drawable/ic_subtype_mic_cs" + android:label="@string/subtype_mode_cs_voice" + android:imeSubtypeLocale="cs" + android:imeSubtypeMode="voice" + /> + <subtype android:icon="@drawable/ic_subtype_mic_de" + android:label="@string/subtype_mode_de_voice" + android:imeSubtypeLocale="de" + android:imeSubtypeMode="voice" + /> + <subtype android:icon="@drawable/ic_subtype_mic_en_au" + android:label="@string/subtype_mode_en_AU_voice" + android:imeSubtypeLocale="en_AU" + android:imeSubtypeMode="voice" + /> + <subtype android:icon="@drawable/ic_subtype_mic_en_gb" + android:label="@string/subtype_mode_en_GB_voice" + android:imeSubtypeLocale="en_GB" + android:imeSubtypeMode="voice" + /> + <subtype android:icon="@drawable/ic_subtype_mic_en_in" + android:label="@string/subtype_mode_en_IN_voice" + android:imeSubtypeLocale="en_IN" + android:imeSubtypeMode="voice" + /> + <subtype android:icon="@drawable/ic_subtype_mic_en_nz" + android:label="@string/subtype_mode_en_NZ_voice" + android:imeSubtypeLocale="en_NZ" + android:imeSubtypeMode="voice" + /> + <subtype android:icon="@drawable/ic_subtype_mic_en_us" + android:label="@string/subtype_mode_en_US_voice" + android:imeSubtypeLocale="en_US" + android:imeSubtypeMode="voice" + /> + <subtype android:icon="@drawable/ic_subtype_mic_es" + android:label="@string/subtype_mode_es_voice" + android:imeSubtypeLocale="es" + android:imeSubtypeMode="voice" + /> + <subtype android:icon="@drawable/ic_subtype_mic_fr" + android:label="@string/subtype_mode_fr_voice" + android:imeSubtypeLocale="fr" + android:imeSubtypeMode="voice" + /> + <subtype android:icon="@drawable/ic_subtype_mic_ko" + android:label="@string/subtype_mode_ko_voice" + android:imeSubtypeLocale="ko" + android:imeSubtypeMode="voice" + /> + <subtype android:icon="@drawable/ic_subtype_mic_ja" + android:label="@string/subtype_mode_ja_voice" + android:imeSubtypeLocale="ja" + android:imeSubtypeMode="voice" + /> + <subtype android:icon="@drawable/ic_subtype_mic_pl" + android:label="@string/subtype_mode_pl_voice" + android:imeSubtypeLocale="pl" + android:imeSubtypeMode="voice" + /> + <subtype android:icon="@drawable/ic_subtype_mic_pt" + android:label="@string/subtype_mode_pt_voice" + android:imeSubtypeLocale="pt" + android:imeSubtypeMode="voice" + /> + <subtype android:icon="@drawable/ic_subtype_mic_ru" + android:label="@string/subtype_mode_ru_voice" + android:imeSubtypeLocale="ru" + android:imeSubtypeMode="voice" + /> + <subtype android:icon="@drawable/ic_subtype_mic_tr" + android:label="@string/subtype_mode_tr_voice" + android:imeSubtypeLocale="tr" + android:imeSubtypeMode="voice" + /> + <subtype android:icon="@drawable/ic_subtype_mic_zh_cn" + android:label="@string/subtype_mode_zh_CN_voice" + android:imeSubtypeLocale="zh_CN" + android:imeSubtypeMode="voice" + /> + <subtype android:icon="@drawable/ic_subtype_mic_zh_tw" + android:label="@string/subtype_mode_zh_TW_voice" + android:imeSubtypeLocale="zh_TW" + android:imeSubtypeMode="voice" + /> +</input-method> diff --git a/java/res/xml/popup_comma.xml b/java/res/xml/popup_comma.xml deleted file mode 100644 index 7666f4b62..000000000 --- a/java/res/xml/popup_comma.xml +++ /dev/null @@ -1,39 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- -/* -** -** Copyright 2010, The Android Open Source Project -** -** Licensed under the Apache License, Version 2.0 (the "License"); -** you may not use this file except in compliance with the License. -** You may obtain a copy of the License at -** -** http://www.apache.org/licenses/LICENSE-2.0 -** -** Unless required by applicable law or agreed to in writing, software -** distributed under the License is distributed on an "AS IS" BASIS, -** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -** See the License for the specific language governing permissions and -** limitations under the License. -*/ ---> - -<Keyboard - xmlns:android="http://schemas.android.com/apk/res/android" - android:keyWidth="10%p" - android:horizontalGap="0px" - android:verticalGap="0px" - android:keyHeight="@dimen/popup_key_height" -> - <Row - android:rowEdgeFlags="top|bottom" - > - <Key - android:codes="@integer/key_settings" - android:keyIcon="@drawable/sym_keyboard_settings" - android:keyEdgeFlags="left" /> - <Key - android:keyLabel="," - android:keyEdgeFlags="right" /> - </Row> -</Keyboard> diff --git a/java/res/xml/popup_domains.xml b/java/res/xml/popup_domains.xml deleted file mode 100644 index 4e9789ff7..000000000 --- a/java/res/xml/popup_domains.xml +++ /dev/null @@ -1,46 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- -/* -** -** Copyright 2008, The Android Open Source Project -** -** Licensed under the Apache License, Version 2.0 (the "License"); -** you may not use this file except in compliance with the License. -** You may obtain a copy of the License at -** -** http://www.apache.org/licenses/LICENSE-2.0 -** -** Unless required by applicable law or agreed to in writing, software -** distributed under the License is distributed on an "AS IS" BASIS, -** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -** See the License for the specific language governing permissions and -** limitations under the License. -*/ ---> - -<Keyboard - xmlns:android="http://schemas.android.com/apk/res/android" - android:keyWidth="15%p" - android:horizontalGap="0px" - android:verticalGap="0px" - android:keyHeight="@dimen/popup_key_height" -> - <Row - android:rowEdgeFlags="top|bottom" - > - <Key - android:keyLabel="@string/popular_domain_1" - android:keyOutputText="@string/popular_domain_1" - android:keyEdgeFlags="left" /> - <Key - android:keyLabel="@string/popular_domain_2" - android:keyOutputText="@string/popular_domain_2" /> - <Key - android:keyLabel="@string/popular_domain_3" - android:keyOutputText="@string/popular_domain_3" /> - <Key - android:keyLabel="@string/popular_domain_4" - android:keyOutputText="@string/popular_domain_4" - android:keyEdgeFlags="right" /> - </Row> -</Keyboard> diff --git a/java/res/xml/popup_mic.xml b/java/res/xml/popup_mic.xml deleted file mode 100644 index 5bbd7dfa5..000000000 --- a/java/res/xml/popup_mic.xml +++ /dev/null @@ -1,40 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- -/* -** -** Copyright 2010, The Android Open Source Project -** -** Licensed under the Apache License, Version 2.0 (the "License"); -** you may not use this file except in compliance with the License. -** You may obtain a copy of the License at -** -** http://www.apache.org/licenses/LICENSE-2.0 -** -** Unless required by applicable law or agreed to in writing, software -** distributed under the License is distributed on an "AS IS" BASIS, -** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -** See the License for the specific language governing permissions and -** limitations under the License. -*/ ---> - -<Keyboard - xmlns:android="http://schemas.android.com/apk/res/android" - android:keyWidth="10%p" - android:horizontalGap="0px" - android:verticalGap="0px" - android:keyHeight="@dimen/popup_key_height" -> - <Row - android:rowEdgeFlags="top|bottom" - > - <Key - android:codes="@integer/key_settings" - android:keyIcon="@drawable/sym_keyboard_settings" - android:keyEdgeFlags="left" /> - <Key - android:codes="@integer/key_voice" - android:keyIcon="@drawable/sym_keyboard_mic" - android:keyEdgeFlags="right" /> - </Row> -</Keyboard> diff --git a/java/res/xml/popup_punctuation.xml b/java/res/xml/popup_punctuation.xml deleted file mode 100644 index c429e38bc..000000000 --- a/java/res/xml/popup_punctuation.xml +++ /dev/null @@ -1,68 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- -/* -** -** Copyright 2008, The Android Open Source Project -** -** Licensed under the Apache License, Version 2.0 (the "License"); -** you may not use this file except in compliance with the License. -** You may obtain a copy of the License at -** -** http://www.apache.org/licenses/LICENSE-2.0 -** -** Unless required by applicable law or agreed to in writing, software -** distributed under the License is distributed on an "AS IS" BASIS, -** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -** See the License for the specific language governing permissions and -** limitations under the License. -*/ ---> - -<Keyboard - xmlns:android="http://schemas.android.com/apk/res/android" - android:keyWidth="10%p" - android:horizontalGap="0px" - android:verticalGap="0px" - android:keyHeight="@dimen/popup_key_height" -> - <Row - android:rowEdgeFlags="top" - > - <Key - android:keyLabel=":" - android:keyEdgeFlags="left" /> - <Key - android:keyLabel="/" /> - <Key - android:keyLabel="&" /> - <Key - android:keyLabel="(" /> - <Key - android:keyLabel=")" /> - <Key - android:keyLabel="-" /> - <Key - android:keyLabel="+" - android:keyEdgeFlags="right" /> - </Row> - <Row - android:rowEdgeFlags="bottom" - > - <Key - android:keyLabel=";" - android:keyEdgeFlags="left" /> - <Key - android:keyLabel="\@" /> - <Key - android:keyLabel="\'" /> - <Key - android:keyLabel=""" /> - <Key - android:keyLabel="\?" /> - <Key - android:keyLabel="!" /> - <Key - android:keyLabel="," - android:keyEdgeFlags="right" /> - </Row> -</Keyboard> diff --git a/java/res/xml/popup_slash.xml b/java/res/xml/popup_slash.xml deleted file mode 100644 index a38fde0e4..000000000 --- a/java/res/xml/popup_slash.xml +++ /dev/null @@ -1,39 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- -/* -** -** Copyright 2010, The Android Open Source Project -** -** Licensed under the Apache License, Version 2.0 (the "License"); -** you may not use this file except in compliance with the License. -** You may obtain a copy of the License at -** -** http://www.apache.org/licenses/LICENSE-2.0 -** -** Unless required by applicable law or agreed to in writing, software -** distributed under the License is distributed on an "AS IS" BASIS, -** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -** See the License for the specific language governing permissions and -** limitations under the License. -*/ ---> - -<Keyboard - xmlns:android="http://schemas.android.com/apk/res/android" - android:keyWidth="10%p" - android:horizontalGap="0px" - android:verticalGap="0px" - android:keyHeight="@dimen/popup_key_height" -> - <Row - android:rowEdgeFlags="top|bottom" - > - <Key - android:codes="@integer/key_settings" - android:keyIcon="@drawable/sym_keyboard_settings" - android:keyEdgeFlags="left" /> - <Key - android:keyLabel="/" - android:keyEdgeFlags="right" /> - </Row> -</Keyboard> diff --git a/java/res/xml/popup_smileys.xml b/java/res/xml/popup_smileys.xml deleted file mode 100644 index 1a14e1df1..000000000 --- a/java/res/xml/popup_smileys.xml +++ /dev/null @@ -1,89 +0,0 @@ -<?xml version="1.0" encoding="utf-8"?> -<!-- -/* -** -** Copyright 2008, The Android Open Source Project -** -** Licensed under the Apache License, Version 2.0 (the "License"); -** you may not use this file except in compliance with the License. -** You may obtain a copy of the License at -** -** http://www.apache.org/licenses/LICENSE-2.0 -** -** Unless required by applicable law or agreed to in writing, software -** distributed under the License is distributed on an "AS IS" BASIS, -** WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -** See the License for the specific language governing permissions and -** limitations under the License. -*/ ---> - -<Keyboard - xmlns:android="http://schemas.android.com/apk/res/android" - android:keyWidth="15%p" - android:horizontalGap="0px" - android:verticalGap="0px" - android:keyHeight="@dimen/popup_key_height" -> - <Row - android:rowEdgeFlags="top" - > - <Key - android:keyLabel=":-)" - android:keyOutputText=":-) " - android:keyEdgeFlags="left" /> - <Key - android:keyLabel=":-(" - android:keyOutputText=":-( " /> - <Key - android:keyLabel=";-)" - android:keyOutputText=";-) " /> - <Key - android:keyLabel=":-P" - android:keyOutputText=":-P " /> - <Key - android:keyLabel="=-O" - android:keyOutputText="=-O " - android:keyEdgeFlags="right" /> - </Row> - <Row> - <Key - android:keyLabel=":-*" - android:keyOutputText=":-* " - android:keyEdgeFlags="left" /> - <Key - android:keyLabel=":O" - android:keyOutputText=":O " /> - <Key - android:keyLabel="B-)" - android:keyOutputText="B-) " /> - <Key - android:keyLabel=":-$" - android:keyOutputText=":-$ " /> - <Key - android:keyLabel=":-!" - android:keyOutputText=":-! " - android:keyEdgeFlags="right" /> - </Row> - <Row - android:rowEdgeFlags="bottom" - > - <Key - android:keyLabel=":-[" - android:keyOutputText=":-[ " - android:keyEdgeFlags="left" /> - <Key - android:keyLabel="O:-)" - android:keyOutputText="O:-) " /> - <Key - android:keyLabel=":-\\" - android:keyOutputText=":-\\ " /> - <Key - android:keyLabel=":'(" - android:keyOutputText=":'( " /> - <Key - android:keyLabel=":-D" - android:keyOutputText=":-D " - android:keyEdgeFlags="right" /> - </Row> -</Keyboard> diff --git a/java/res/xml/prefs.xml b/java/res/xml/prefs.xml index 9348e954a..3b20298d2 100644 --- a/java/res/xml/prefs.xml +++ b/java/res/xml/prefs.xml @@ -34,7 +34,7 @@ android:key="popup_on" android:title="@string/popup_on_keypress" android:persistent="true" - android:defaultValue="@bool/default_popup_preview" + android:defaultValue="@bool/config_default_popup_preview" /> <CheckBoxPreference @@ -70,12 +70,14 @@ android:defaultValue="@string/voice_mode_main" /> - + <!-- TODO: Filter subtypes by IME in SubtypeEnabler --> + <!-- TODO: Maybe use this only for phone? --> <PreferenceScreen + android:key="subtype_settings" android:title="@string/language_selection_title" android:summary="@string/language_selection_summary"> <intent - android:action="com.android.inputmethod.latin.INPUT_LANGUAGE_SELECTION"/> + android:action="android.settings.INPUT_METHOD_AND_SUBTYPE_ENABLER"/> </PreferenceScreen> <PreferenceCategory @@ -90,22 +92,40 @@ android:defaultValue="true" /> + <ListPreference + android:key="show_suggestions_setting" + android:summary="@string/prefs_show_suggestions_summary" + android:title="@string/prefs_show_suggestions" + android:persistent="true" + android:entryValues="@array/prefs_suggestion_visibility_values" + android:entries="@array/prefs_suggestion_visibilities" + android:defaultValue="@string/prefs_suggestion_visibility_default_value" + /> + + <ListPreference + android:key="auto_correction_threshold" + android:title="@string/auto_correction" + android:summary="@string/auto_correction_summary" + android:persistent="true" + android:entryValues="@array/auto_correction_threshold_mode_indexes" + android:entries="@array/auto_correction_threshold_modes" + android:defaultValue="@string/auto_correction_threshold_mode_index_modest" + /> + <CheckBoxPreference - android:key="show_suggestions" - android:title="@string/show_suggestions" - android:summary="@string/show_suggestions_summary" + android:key="bigram_suggestion" + android:title="@string/bigram_suggestion" + android:summary="@string/bigram_suggestion_summary" android:persistent="true" android:defaultValue="true" /> + </PreferenceCategory> - <CheckBoxPreference - android:key="auto_complete" - android:title="@string/auto_complete" - android:summary="@string/auto_complete_summary" - android:persistent="true" - android:defaultValue="@bool/enable_autocorrect" - android:dependency="show_suggestions" + <CheckBoxPreference + android:key="usability_study_mode" + android:title="@string/prefs_usability_study_mode" + android:persistent="true" + android:defaultValue="false" /> - </PreferenceCategory> </PreferenceScreen> diff --git a/java/res/xml/prefs_for_debug.xml b/java/res/xml/prefs_for_debug.xml index 8177d3c6a..2dad17148 100644 --- a/java/res/xml/prefs_for_debug.xml +++ b/java/res/xml/prefs_for_debug.xml @@ -32,7 +32,7 @@ android:persistent="true" android:entryValues="@array/keyboard_layout_modes_values" android:entries="@array/keyboard_layout_modes" - android:defaultValue="4" + android:defaultValue="@string/config_default_keyboard_theme_id" /> <CheckBoxPreference |