From 976f0a6e37bed4714c995723acd7b9532d52f0bf Mon Sep 17 00:00:00 2001
From: jranaraki <jrahimipour@gmail.com>
Date: Sun, 27 Dec 2020 01:08:07 -0500
Subject: [PATCH] Farsi/Persian keyboard layout

---
 data/keyboards/ir.yaml      | 78 +++++++++++++++++++++++++++++++++++++
 data/keyboards/ir_wide.yaml | 78 +++++++++++++++++++++++++++++++++++++
 2 files changed, 156 insertions(+)
 create mode 100644 data/keyboards/ir.yaml
 create mode 100644 data/keyboards/ir_wide.yaml

diff --git a/data/keyboards/ir.yaml b/data/keyboards/ir.yaml
new file mode 100644
index 00000000..5f5fe5e4
--- /dev/null
+++ b/data/keyboards/ir.yaml
@@ -0,0 +1,78 @@
+---
+outlines:
+    default: { width: 35.33, height: 52 }
+    altline: { width: 52.67, height: 52 }
+    wide: { width: 62, height: 52 }
+    spaceline: { width: 142, height: 52 }
+    special: { width: 44, height: 52 }
+
+views:
+    base:
+        - "ض ص ث ق ف غ ع ه خ ح"
+        - "ش س ی ب ل ا ت ن م"
+        - "Shift_L   ظ ط ز ر ذ د پ  BackSpace"
+        - "show_numbers preferences         space        period Return"
+    upper:
+        - "ْ ٌ ٍ ً ُ ِ َ ّ ] ["
+        - "و ئ ي إ أ آ ة » «"
+        - "Shift_L   ك گ ژ ٰ ‌ ٔ ء  BackSpace"
+        - "show_numbers preferences         space        period Return"
+    numbers:
+        - "Û± Û² Û³ Û´ Ûµ Û¶ Û· Û¸ Û¹ Û°"
+        - "@ # ï·¼ % & - _ + ( )"
+        - "show_symbols   , \" ' colon Ø› ! ?  BackSpace"
+        - "show_letters preferences         space        period Return"
+    symbols:
+        - "~ ` | · √ π τ ÷ × ¶"
+        - "© ® £ € ¥ ^ ° * { }"
+        - "show_numbers_from_symbols   \\ / < > = [ ]  BackSpace"
+        - "show_letters preferences         space        period Return"
+
+buttons:
+    Shift_L:
+        action:
+            locking:
+                lock_view: "upper"
+                unlock_view: "base"
+        outline: "altline"
+        icon: "key-shift"
+    BackSpace:
+        outline: "altline"
+        icon: "edit-clear-symbolic"
+        action: erase
+    preferences:
+        action: show_prefs
+        outline: "special"
+        icon: "keyboard-mode-symbolic"
+    show_numbers:
+        action:
+            set_view: "numbers"
+        outline: "wide"
+        label: "123"
+    show_numbers_from_symbols:
+        action:
+            set_view: "numbers"
+        outline: "altline"
+        label: "123"
+    show_letters:
+        action:
+            set_view: "base"
+        outline: "wide"
+        label: "ABC"
+    show_symbols:
+        action:
+            set_view: "symbols"
+        outline: "altline"
+        label: "*/="
+    period:
+        outline: "special"
+        text: "."
+    space:
+        outline: "spaceline"
+        text: " "
+    Return:
+        outline: "wide"
+        icon: "key-enter"
+        keysym: "Return"
+    colon:
+        text: ":"
diff --git a/data/keyboards/ir_wide.yaml b/data/keyboards/ir_wide.yaml
new file mode 100644
index 00000000..984f364d
--- /dev/null
+++ b/data/keyboards/ir_wide.yaml
@@ -0,0 +1,78 @@
+---
+outlines:
+    default: { width: 54, height: 42 }
+    altline: { width: 81, height: 42 }
+    wide: { width: 108, height: 42 }
+    spaceline: { width: 216, height: 42 }
+    special: { width: 54, height: 42 }
+
+views:
+    base:
+        - "ض ص ث ق ف غ ع ه خ ح"
+        - "ش س ی ب ل ا ت ن م"
+        - "Shift_L   ظ ط ز ر ذ د پ  BackSpace"
+        - "show_numbers preferences         space        period Return"
+    upper:
+        - "ْ ٌ ٍ ً ُ ِ َ ّ ] ["
+        - "و ئ ي إ أ آ ة » «"
+        - "Shift_L   ك گ ژ ٰ ‌ ٔ ء  BackSpace"
+        - "show_numbers preferences         space        period Return"
+    numbers:
+        - "Û± Û² Û³ Û´ Ûµ Û¶ Û· Û¸ Û¹ Û°"
+        - "@ # ï·¼ % & - _ + ( )"
+        - "show_symbols   , \" ' colon Ø› ! ?  BackSpace"
+        - "show_letters preferences         space        period Return"
+    symbols:
+        - "~ ` | · √ π τ ÷ × ¶"
+        - "© ® £ € ¥ ^ ° * { }"
+        - "show_numbers_from_symbols   \\ / < > = [ ]  BackSpace"
+        - "show_letters preferences         space        period Return"
+
+buttons:
+    Shift_L:
+        action:
+            locking:
+                lock_view: "upper"
+                unlock_view: "base"
+        outline: "altline"
+        icon: "key-shift"
+    BackSpace:
+        outline: "altline"
+        icon: "edit-clear-symbolic"
+        action: "erase"
+    preferences:
+        action: "show_prefs"
+        outline: "special"
+        icon: "keyboard-mode-symbolic"
+    show_numbers:
+        action:
+            set_view: "numbers"
+        outline: "wide"
+        label: "123"
+    show_numbers_from_symbols:
+        action:
+            set_view: "numbers"
+        outline: "altline"
+        label: "123"
+    show_letters:
+        action:
+            set_view: "base"
+        outline: "wide"
+        label: "ABC"
+    show_symbols:
+        action:
+            set_view: "symbols"
+        outline: "altline"
+        label: "*/="
+    ".":
+        outline: "special"
+        text: "."
+    space:
+        outline: "spaceline"
+        text: " "
+    Return:
+        outline: "wide"
+        icon: "key-enter"
+        keysym: "Return"
+    colon:
+        text: ":"
-- 
GitLab