1
0
Fork 0
mirror of https://github.com/EdgeTX/edgetx.git synced 2025-07-24 16:55:15 +03:00

fix chars continued

This commit is contained in:
3djc 2020-12-18 20:37:11 +01:00
parent acdc2343dd
commit 7d2178cb5c
11 changed files with 34 additions and 43 deletions

View file

@ -54,7 +54,7 @@ subset_lowercase = {
def get_chars(subset):
result = standard_chars + extra_chars
if subset == "all":
if False: # subset == "all":
for key, chars in special_chars.items():
result += "".join([char for char in chars if char not in result])
else:
@ -65,11 +65,11 @@ def get_chars(subset):
def get_chars_encoding(subset):
result = {}
if subset == "all":
if subset in ("cn", "tw"):
chars = get_chars(subset)
for char in chars:
if char in special_chars["cn"]:
index = special_chars["cn"].index(char) + 1
if char in special_chars[subset]:
index = special_chars[subset].index(char) + 1
if index >= 0x100:
index += 1
result[char] = "\\%03o\\%03o" % (0xFE + ((index >> 8) & 0x01), index & 0xFF)