Breakdown Arabic keyboard into rows

Change-Id: Ie2215d8baf501dc7dd87c464deb47fe4267171f6
diff --git a/java/res/xml-sw600dp/rowkeys_arabic1.xml b/java/res/xml-sw600dp/rowkeys_arabic1.xml
new file mode 100644
index 0000000..44fdc67
--- /dev/null
+++ b/java/res/xml-sw600dp/rowkeys_arabic1.xml
@@ -0,0 +1,71 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+**
+** Copyright 2012, 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"
+>
+    <!-- U+0636: "ض" ARABIC LETTER DAD -->
+    <Key
+        latin:keyLabel="&#x0636;" />
+    <!-- U+0635: "ص" ARABIC LETTER SAD -->
+    <Key
+        latin:keyLabel="&#x0635;" />
+    <!-- U+062B: "ث" ARABIC LETTER THEH -->
+    <Key
+        latin:keyLabel="&#x062B;" />
+    <!-- U+0642: "ق" ARABIC LETTER QAF
+         U+06A8: "ڨ" ARABIC LETTER QAF WITH THREE DOTS ABOVE -->
+    <!-- TODO: DroidSansArabic lacks the glyph of U+06A8 ARABIC LETTER QAF WITH THREE DOTS ABOVE -->
+    <Key
+        latin:keyLabel="&#x0642;"
+        latin:moreKeys="&#x06A8;" />
+    <!-- U+0641: "ف" ARABIC LETTER FEH
+         U+06A4: "ڤ" ARABIC LETTER VEH
+         U+06A2: "ڢ" ARABIC LETTER FEH WITH DOT MOVED BELOW
+         U+06A5: "ڥ" ARABIC LETTER FEH WITH THREE DOTS BELOW -->
+    <!-- TODO: DroidSansArabic lacks the glyph of U+06A2 ARABIC LETTER FEH WITH DOT MOVED BELOW -->
+    <!-- TODO: DroidSansArabic lacks the glyph of U+06A5 ARABIC LETTER FEH WITH THREE DOTS BELOW -->
+    <Key
+        latin:keyLabel="&#x0641;"
+        latin:moreKeys="&#x06A4;,&#x06A2;,&#x06A5;" />
+    <!-- U+063A: "غ" ARABIC LETTER GHAIN -->
+    <Key
+        latin:keyLabel="&#x063A;" />
+    <!-- U+0639: "ع" ARABIC LETTER AIN -->
+    <Key
+        latin:keyLabel="&#x0639;" />
+    <!-- U+0647: "ه" ARABIC LETTER HEH
+         U+FEEB: "ﻫ" ARABIC LETTER HEH INITIAL FORM
+         U+0647 U+200D: ARABIC LETTER HEH + ZERO WIDTH JOINER -->
+    <Key
+        latin:keyLabel="&#x0647;"
+        latin:moreKeys="&#xFEEB;|&#x0647;&#x200D;" />
+    <!-- U+062E: "خ" ARABIC LETTER KHAH -->
+    <Key
+        latin:keyLabel="&#x062E;" />
+    <!-- U+062D: "ح" ARABIC LETTER HAH -->
+    <Key
+        latin:keyLabel="&#x062D;" />
+    <!-- U+062C: "ج" ARABIC LETTER JEEM
+         U+0686: "چ" ARABIC LETTER TCHEH -->
+    <Key
+        latin:keyLabel="&#x062C;"
+        latin:moreKeys="&#x0686;" />
+</merge>
diff --git a/java/res/xml-sw600dp/rowkeys_arabic2.xml b/java/res/xml-sw600dp/rowkeys_arabic2.xml
new file mode 100644
index 0000000..3eba2fb
--- /dev/null
+++ b/java/res/xml-sw600dp/rowkeys_arabic2.xml
@@ -0,0 +1,83 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+**
+** Copyright 2012, 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"
+>
+    <!-- U+0634: "ش" ARABIC LETTER SHEEN
+         U+069C: "ڜ" ARABIC LETTER SEEN WITH THREE DOTS BELOW AND THREE DOTS ABOVE -->
+    <!-- TODO: DroidSansArabic lacks the glyph of U+069C ARABIC LETTER SEEN WITH THREE DOTS BELOW AND THREE DOTS ABOVE -->
+    <Key
+        latin:keyLabel="&#x0634;"
+        latin:moreKeys="&#x069C;" />
+    <!-- U+0633: "س" ARABIC LETTER SEEN -->
+    <Key
+        latin:keyLabel="&#x0633;" />
+    <!-- U+064A: "ي" ARABIC LETTER YEH
+         U+0626: "ئ" ARABIC LETTER YEH WITH HAMZA ABOVE
+         U+0649: "ى" ARABIC LETTER ALEF MAKSURA -->
+    <Key
+        latin:keyLabel="&#x064A;"
+        latin:moreKeys="&#x0626;,&#x0649;" />
+    <!-- U+0628: "ب" ARABIC LETTER BEH
+         U+067E: "پ" ARABIC LETTER PEH -->
+    <Key
+        latin:keyLabel="&#x0628;"
+        latin:moreKeys="&#x067E;" />
+    <!-- U+0644: "ل" ARABIC LETTER LAM
+         U+FEFB: "ﻻ" ARABIC LIGATURE LAM WITH ALEF ISOLATED FORM
+         U+0627: "ا" ARABIC LETTER ALEF
+         U+FEF7: "ﻷ" ARABIC LIGATURE LAM WITH ALEF WITH HAMZA ABOVE ISOLATED FORM
+         U+0623: "أ" ARABIC LETTER ALEF WITH HAMZA ABOVE
+         U+FEF9: "ﻹ" ARABIC LIGATURE LAM WITH ALEF WITH HAMZA BELOW ISOLATED FORM
+         U+0625: "إ" ARABIC LETTER ALEF WITH HAMZA BELOW
+         U+FEF5: "ﻵ" ARABIC LIGATURE LAM WITH ALEF WITH MADDA ABOVE ISOLATED FORM
+         U+0622: "آ" ARABIC LETTER ALEF WITH MADDA ABOVE -->
+    <Key
+        latin:keyLabel="&#x0644;"
+        latin:moreKeys="&#xFEFB;|&#x0644;&#x0627;,&#xFEF7;|&#x0644;&#x0623;,&#xFEF9;|&#x0644;&#x0625;,&#xFEF5;|&#x0644;&#x0622;" />
+    <!-- U+0627: "ا" ARABIC LETTER ALEF
+         U+0621: "ء" ARABIC LETTER HAMZA
+         U+0671: "ٱ" ARABIC LETTER ALEF WASLA
+         U+0623: "أ" ARABIC LETTER ALEF WITH HAMZA ABOVE
+         U+0625: "إ" ARABIC LETTER ALEF WITH HAMZA BELOW
+         U+0622: "آ" ARABIC LETTER ALEF WITH MADDA ABOVE -->
+    <Key
+        latin:keyLabel="&#x0627;"
+        latin:moreKeys="&#x0621;,&#x0671;,&#x0623;,&#x0625;,&#x0622;" />
+    <!-- U+062A: "ت" ARABIC LETTER TEH -->
+    <Key
+        latin:keyLabel="&#x062A;" />
+    <!-- U+0646: "ن" ARABIC LETTER NOON -->
+    <Key
+        latin:keyLabel="&#x0646;" />
+    <!-- U+0645: "م" ARABIC LETTER MEEM -->
+    <Key
+        latin:keyLabel="&#x0645;" />
+    <!-- U+0643: "ك" ARABIC LETTER KAF
+         U+06AF: "گ" ARABIC LETTER GAF
+         U+06A9: "ک" ARABIC LETTER KEHEH -->
+    <Key
+        latin:keyLabel="&#x0643;"
+        latin:moreKeys="&#x06AF;,&#x06A9;" />
+    <!-- U+0637: "ط" ARABIC LETTER TAH -->
+    <Key
+        latin:keyLabel="&#x0637;" />
+</merge>
diff --git a/java/res/xml-sw600dp/rowkeys_arabic3.xml b/java/res/xml-sw600dp/rowkeys_arabic3.xml
new file mode 100644
index 0000000..911550f
--- /dev/null
+++ b/java/res/xml-sw600dp/rowkeys_arabic3.xml
@@ -0,0 +1,59 @@
+<?xml version="1.0" encoding="utf-8"?>
+<!--
+/*
+**
+** Copyright 2012, 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"
+>
+    <!-- U+0626: "ئ" ARABIC LETTER YEH WITH HAMZA ABOVE -->
+    <Key
+        latin:keyLabel="&#x0626;" />
+    <!-- U+0621: "ء" ARABIC LETTER HAMZA -->
+    <Key
+        latin:keyLabel="&#x0621;" />
+    <!-- U+0624: "ؤ" ARABIC LETTER WAW WITH HAMZA ABOVE -->
+    <Key
+        latin:keyLabel="&#x0624;" />
+    <!-- U+0631: "ر" ARABIC LETTER REH -->
+    <Key
+        latin:keyLabel="&#x0631;" />
+    <!-- U+0630: "ذ" ARABIC LETTER THAL -->
+    <Key
+        latin:keyLabel="&#x0630;" />
+    <!-- U+0649: "ى" ARABIC LETTER ALEF MAKSURA -->
+    <Key
+        latin:keyLabel="&#x0649;" />
+    <!-- U+0629: "ة" ARABIC LETTER TEH MARBUTA -->
+    <Key
+        latin:keyLabel="&#x0629;" />
+    <!-- U+0648: "و" ARABIC LETTER WAW -->
+    <Key
+        latin:keyLabel="&#x0648;" />
+    <!-- U+0632: "ز" ARABIC LETTER ZAIN
+         U+0698: "ژ" ARABIC LETTER JEH -->
+    <Key
+        latin:keyLabel="&#x0632;"
+        latin:moreKeys="&#x0698;" />
+    <!-- U+0638: "ظ" ARABIC LETTER ZAH -->
+    <Key
+        latin:keyLabel="&#x0638;" />
+    <!-- U+062F: "د" ARABIC LETTER DAL -->
+    <Key
+        latin:keyLabel="&#x062F;" />
+</merge>
diff --git a/java/res/xml-sw600dp/rows_arabic.xml b/java/res/xml-sw600dp/rows_arabic.xml
index 60ad45e..9aecaa6 100644
--- a/java/res/xml-sw600dp/rows_arabic.xml
+++ b/java/res/xml-sw600dp/rows_arabic.xml
@@ -26,53 +26,8 @@
     <Row
         latin:keyWidth="8.0%p"
     >
-        <!-- U+0636: "ض" ARABIC LETTER DAD -->
-        <Key
-            latin:keyLabel="&#x0636;" />
-        <!-- U+0635: "ص" ARABIC LETTER SAD -->
-        <Key
-            latin:keyLabel="&#x0635;" />
-        <!-- U+062B: "ث" ARABIC LETTER THEH -->
-        <Key
-            latin:keyLabel="&#x062B;" />
-        <!-- U+0642: "ق" ARABIC LETTER QAF
-             U+06A8: "ڨ" ARABIC LETTER QAF WITH THREE DOTS ABOVE -->
-        <!-- TODO: DroidSansArabic lacks the glyph of U+06A8 ARABIC LETTER QAF WITH THREE DOTS ABOVE -->
-        <Key
-            latin:keyLabel="&#x0642;"
-            latin:moreKeys="&#x06A8;" />
-        <!-- U+0641: "ف" ARABIC LETTER FEH
-             U+06A4: "ڤ" ARABIC LETTER VEH
-             U+06A2: "ڢ" ARABIC LETTER FEH WITH DOT MOVED BELOW
-             U+06A5: "ڥ" ARABIC LETTER FEH WITH THREE DOTS BELOW -->
-        <!-- TODO: DroidSansArabic lacks the glyph of U+06A2 ARABIC LETTER FEH WITH DOT MOVED BELOW -->
-        <!-- TODO: DroidSansArabic lacks the glyph of U+06A5 ARABIC LETTER FEH WITH THREE DOTS BELOW -->
-        <Key
-            latin:keyLabel="&#x0641;"
-            latin:moreKeys="&#x06A4;,&#x06A2;,&#x06A5;" />
-        <!-- U+063A: "غ" ARABIC LETTER GHAIN -->
-        <Key
-            latin:keyLabel="&#x063A;" />
-        <!-- U+0639: "ع" ARABIC LETTER AIN -->
-        <Key
-            latin:keyLabel="&#x0639;" />
-        <!-- U+0647: "ه" ARABIC LETTER HEH
-             U+FEEB: "ﻫ" ARABIC LETTER HEH INITIAL FORM
-             U+0647 U+200D: ARABIC LETTER HEH + ZERO WIDTH JOINER -->
-        <Key
-            latin:keyLabel="&#x0647;"
-            latin:moreKeys="&#xFEEB;|&#x0647;&#x200D;" />
-        <!-- U+062E: "خ" ARABIC LETTER KHAH -->
-        <Key
-            latin:keyLabel="&#x062E;" />
-        <!-- U+062D: "ح" ARABIC LETTER HAH -->
-        <Key
-            latin:keyLabel="&#x062D;" />
-        <!-- U+062C: "ج" ARABIC LETTER JEEM
-             U+0686: "چ" ARABIC LETTER TCHEH -->
-        <Key
-            latin:keyLabel="&#x062C;"
-            latin:moreKeys="&#x0686;" />
+        <include
+            latin:keyboardLayout="@xml/rowkeys_arabic1" />
         <Key
             latin:keyStyle="deleteKeyStyle"
             latin:keyXPos="-10.0%p"
@@ -81,66 +36,9 @@
     <Row
         latin:keyWidth="8.0%p"
     >
-        <!-- U+0634: "ش" ARABIC LETTER SHEEN
-             U+069C: "ڜ" ARABIC LETTER SEEN WITH THREE DOTS BELOW AND THREE DOTS ABOVE -->
-        <!-- TODO: DroidSansArabic lacks the glyph of U+069C ARABIC LETTER SEEN WITH THREE DOTS BELOW AND THREE DOTS ABOVE -->
-        <Key
-            latin:keyLabel="&#x0634;"
-            latin:moreKeys="&#x069C;"
+        <include
+            latin:keyboardLayout="@xml/rowkeys_arabic2"
             latin:keyXPos="3.0%p" />
-        <!-- U+0633: "س" ARABIC LETTER SEEN -->
-        <Key
-            latin:keyLabel="&#x0633;" />
-        <!-- U+064A: "ي" ARABIC LETTER YEH
-             U+0626: "ئ" ARABIC LETTER YEH WITH HAMZA ABOVE
-             U+0649: "ى" ARABIC LETTER ALEF MAKSURA -->
-        <Key
-            latin:keyLabel="&#x064A;"
-            latin:moreKeys="&#x0626;,&#x0649;" />
-        <!-- U+0628: "ب" ARABIC LETTER BEH
-             U+067E: "پ" ARABIC LETTER PEH -->
-        <Key
-            latin:keyLabel="&#x0628;"
-            latin:moreKeys="&#x067E;" />
-        <!-- U+0644: "ل" ARABIC LETTER LAM
-             U+FEFB: "ﻻ" ARABIC LIGATURE LAM WITH ALEF ISOLATED FORM
-             U+0627: "ا" ARABIC LETTER ALEF
-             U+FEF7: "ﻷ" ARABIC LIGATURE LAM WITH ALEF WITH HAMZA ABOVE ISOLATED FORM
-             U+0623: "أ" ARABIC LETTER ALEF WITH HAMZA ABOVE
-             U+FEF9: "ﻹ" ARABIC LIGATURE LAM WITH ALEF WITH HAMZA BELOW ISOLATED FORM
-             U+0625: "إ" ARABIC LETTER ALEF WITH HAMZA BELOW
-             U+FEF5: "ﻵ" ARABIC LIGATURE LAM WITH ALEF WITH MADDA ABOVE ISOLATED FORM
-             U+0622: "آ" ARABIC LETTER ALEF WITH MADDA ABOVE -->
-        <Key
-            latin:keyLabel="&#x0644;"
-            latin:moreKeys="&#xFEFB;|&#x0644;&#x0627;,&#xFEF7;|&#x0644;&#x0623;,&#xFEF9;|&#x0644;&#x0625;,&#xFEF5;|&#x0644;&#x0622;" />
-        <!-- U+0627: "ا" ARABIC LETTER ALEF
-             U+0621: "ء" ARABIC LETTER HAMZA
-             U+0671: "ٱ" ARABIC LETTER ALEF WASLA
-             U+0623: "أ" ARABIC LETTER ALEF WITH HAMZA ABOVE
-             U+0625: "إ" ARABIC LETTER ALEF WITH HAMZA BELOW
-             U+0622: "آ" ARABIC LETTER ALEF WITH MADDA ABOVE -->
-        <Key
-            latin:keyLabel="&#x0627;"
-            latin:moreKeys="&#x0621;,&#x0671;,&#x0623;,&#x0625;,&#x0622;" />
-        <!-- U+062A: "ت" ARABIC LETTER TEH -->
-        <Key
-            latin:keyLabel="&#x062A;" />
-        <!-- U+0646: "ن" ARABIC LETTER NOON -->
-        <Key
-            latin:keyLabel="&#x0646;" />
-        <!-- U+0645: "م" ARABIC LETTER MEEM -->
-        <Key
-            latin:keyLabel="&#x0645;" />
-        <!-- U+0643: "ك" ARABIC LETTER KAF
-             U+06AF: "گ" ARABIC LETTER GAF
-             U+06A9: "ک" ARABIC LETTER KEHEH -->
-        <Key
-            latin:keyLabel="&#x0643;"
-            latin:moreKeys="&#x06AF;,&#x06A9;" />
-        <!-- U+0637: "ط" ARABIC LETTER TAH -->
-        <Key
-            latin:keyLabel="&#x0637;" />
         <Key
             latin:keyStyle="enterKeyStyle"
             latin:keyXPos="-14.6%p"
@@ -151,41 +49,8 @@
     >
         <include
             latin:keyboardLayout="@xml/key_smiley" />
-        <!-- U+0626: "ئ" ARABIC LETTER YEH WITH HAMZA ABOVE -->
-        <Key
-            latin:keyLabel="&#x0626;" />
-        <!-- U+0621: "ء" ARABIC LETTER HAMZA -->
-        <Key
-            latin:keyLabel="&#x0621;" />
-        <!-- U+0624: "ؤ" ARABIC LETTER WAW WITH HAMZA ABOVE -->
-        <Key
-            latin:keyLabel="&#x0624;" />
-        <!-- U+0631: "ر" ARABIC LETTER REH -->
-        <Key
-            latin:keyLabel="&#x0631;" />
-        <!-- U+0630: "ذ" ARABIC LETTER THAL -->
-        <Key
-            latin:keyLabel="&#x0630;" />
-        <!-- U+0649: "ى" ARABIC LETTER ALEF MAKSURA -->
-        <Key
-            latin:keyLabel="&#x0649;" />
-        <!-- U+0629: "ة" ARABIC LETTER TEH MARBUTA -->
-        <Key
-            latin:keyLabel="&#x0629;" />
-        <!-- U+0648: "و" ARABIC LETTER WAW -->
-        <Key
-            latin:keyLabel="&#x0648;" />
-        <!-- U+0632: "ز" ARABIC LETTER ZAIN
-             U+0698: "ژ" ARABIC LETTER JEH -->
-        <Key
-            latin:keyLabel="&#x0632;"
-            latin:moreKeys="&#x0698;" />
-        <!-- U+0638: "ظ" ARABIC LETTER ZAH -->
-        <Key
-            latin:keyLabel="&#x0638;" />
-        <!-- U+062F: "د" ARABIC LETTER DAL -->
-        <Key
-            latin:keyLabel="&#x062F;" />
+        <include
+            latin:keyboardLayout="@xml/rowkeys_arabic3" />
     </Row>
     <include
         latin:keyboardLayout="@xml/row_qwerty4" />