diff --git a/srcs/compose/compile.py b/srcs/compose/compile.py index 5744eaf..125e18c 100644 --- a/srcs/compose/compile.py +++ b/srcs/compose/compile.py @@ -99,9 +99,12 @@ def strip_cstyle_comments(inp): # Parse from a json file containing a dictionary sequence → result string. def parse_sequences_file_json(fname): - with open(fname, "r") as inp: - seqs = json.loads(strip_cstyle_comments(inp)) - return list(seqs.items()) + try: + with open(fname, "r") as inp: + seqs = json.loads(strip_cstyle_comments(inp)) + return list(seqs.items()) + except Exception as e: + print("Failed parsing '%s': %s" % (fname, str(e)), file=sys.stderr) # Format of the sequences file is determined by its extension def parse_sequences_file(fname, xkb_char_extra_names={}): diff --git a/srcs/compose/compose/cyrillic.json b/srcs/compose/compose/cyrillic.json new file mode 100644 index 0000000..f6f2f1f --- /dev/null +++ b/srcs/compose/compose/cyrillic.json @@ -0,0 +1,138 @@ +{ + "\"": { + "і": "ї" + }, + ",": { + "г": "ӻ", + "к": "ӄ", + "л": "ԓ", + "н": "ӈ", + "х": "ӽ" + }, + ".": { + "г": "ӷ", + "ж": "җ", + "й": "ҋ", + "к": "қ", + "м": "ӎ", + "н": "ӊ", + "і": "ї" + }, + "а": { + "е": "ѣ", + "у": "ѡ", + "ъ": "ѣ", + "ы": "ѣ", + "ь": "ꙙ", + "э": "ѣ", + "є": "ѣ", + "ꙑ": "ѣ" + }, + "г": { + ",": "ӻ", + ".": "ӷ", + "й": "ғ", + "х": "ҁ", + "ј": "ғ" + }, + "д": { + "е": "ꙉ", + "ж": "џ", + "з": "ꙃ", + "й": "ꙉ", + "ј": "ꙉ" + }, + "е": { + "о": "ё" + }, + "ж": { + ".": "җ" + }, + "з": { + "ф": "ҙ" + }, + "и": { + "и": "ӣ", + "й": "ӣ", + "у": "ѵ", + "ј": "ӣ" + }, + "й": { + ".": "ҋ" + }, + "к": { + ",": "ӄ", + ".": "қ", + "г": "ґ", + "с": "ѯ", + "х": "ҁ", + "ш": "ѯ" + }, + "л": { + ",": "ԓ", + "ь": "љ" + }, + "м": { + ".": "ӎ" + }, + "н": { + ",": "ӈ", + ".": "ӊ", + "ь": "њ" + }, + "о": { + "т": "ѿ", + "у": "ѹ" + }, + "п": { + "с": "ѱ", + "ш": "ѱ" + }, + "т": { + "й": "ћ", + "ф": "ѳ", + "ј": "ћ" + }, + "у": { + "у": "ӯ", + "ъ": "ў" + }, + "х": { + ",": "ӽ", + "й": "ҳ", + "ь": "ҳ", + "ј": "ҳ" + }, + "ш": { + "ч": "щ" + }, + "ы": { + "у": "ѡ", + "ъ": "ꙑ" + }, + "ю": { + "а": "ꙓ", + "е": "ѥ", + "м": "ѭ", + "н": "ѩ", + "э": "ѥ" + }, + "я": { + "ь": "ꙝ" + }, + "і": { + "\"": "ї", + ".": "ї", + "й": "ӣ", + "у": "ѵ", + "і": "ӣ", + "ј": "ӣ" + }, + "ѡ": { + "т": "ѿ" + }, + "ꙑ": { + "ь": "ы", + "у": "ѡ" + } +} diff --git a/srcs/compose/fn.json b/srcs/compose/fn.json index 5a977ba..70fc061 100644 --- a/srcs/compose/fn.json +++ b/srcs/compose/fn.json @@ -37,6 +37,7 @@ "†": "‡", "×": "∙", " ": "nbsp", + // arrows "↖": "⇖", "↑": "⇑", @@ -87,6 +88,7 @@ "⊂": "⊆", "⊃": "⊇", "±": "∓", + // hebrew niqqud "ק": "qamats", // kamatz "ר": "hataf_qamats", // reduced kamatz @@ -101,6 +103,7 @@ "ס": "segol", "ב": "hataf_segol", // reduced segol "צ": "tsere", + // Devanagari symbols "ए": "ऍ", "े": "ॅ", @@ -157,6 +160,7 @@ "ं": "ॕ", "़": "ॎ", "ऽ": "ॽ", + // Persian numbers "۱": "f1", "۲": "f2", @@ -178,5 +182,38 @@ "٧": "f7", "٨": "f8", "٩": "f9", - "٠": "f10" + "٠": "f10", + + // Cyrillic + "ꙑ": "ы", + "ы": "ꙑ", + "ш": "ѱ", + "з": "ꙁ", + "и": "і", + "і": "и", + "я": "ꙗ", + "е": "ѥ", + "ѡ": "ꙍ", + "о": "ѻ", + "а": "ѣ", + "э": "є", + "ъ": "ь", + "ь": "ъ", + "й": "ј", + "ꙉ": "ђ", + "ч": "ћ", + "ҁ": "қ", + "қ": "ҁ", + "џ": "ҷ", + "ҷ": "џ", + "ј": "й", + "у": "ꙋ", + "м": "ѫ", + "н": "ѧ", + "с": "ѕ", + "л": "ԯ", + "ԓ": "ԯ", + "\ua67d": "\u0483", + "\u0487": "\ua66f", + "ӈ": "ԩ" } diff --git a/srcs/juloo.keyboard2/ComposeKeyData.java b/srcs/juloo.keyboard2/ComposeKeyData.java index 8a876ac..afac294 100644 Binary files a/srcs/juloo.keyboard2/ComposeKeyData.java and b/srcs/juloo.keyboard2/ComposeKeyData.java differ