summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorkkard2 <[email protected]>2024-09-09 20:38:45 +0200
committerkkard2 <[email protected]>2024-09-09 20:38:45 +0200
commit5ce42838678d408dd8a38a604c6d9516cb2c2ec0 (patch)
tree596cbffba70be23a5b55f3fef338049246678d5c
parent214ea4f455b104f1c66e97e196f3690956b9f28f (diff)
but why do i do this
-rwxr-xr-xkanata/chords.py13
1 files changed, 11 insertions, 2 deletions
diff --git a/kanata/chords.py b/kanata/chords.py
index 38ab562..7b6fbb2 100755
--- a/kanata/chords.py
+++ b/kanata/chords.py
@@ -3,6 +3,7 @@
chord_data = {
"praw": "prawdopodobnie",
"pro": "probably",
+ "com": "co masz na myśli",
}
output = "(defchordsv2-experimental\n"
@@ -12,11 +13,19 @@ for keys, macro in chord_data.items():
first_char_macro = macro[0]
# The rest of the macro characters are used in (unshift x)
- macro_formatted = " ".join([f"(unshift {char})" for char in macro[1:]])
+ macro_formatted = ""
+ for char in macro[1:]:
+ if char == " ":
+ macro_formatted += "(unshift spc) "
+ else:
+ macro_formatted += f"(unicode {char}) "
+
+ macro_formatted = macro_formatted.strip()
release = "all-released"
- chord_line = f" ({keys_formatted}) (macro {first_char_macro} {macro_formatted}) 75 {release} (arrows)\n"
+ chord_line = f" ({keys_formatted}) (macro {first_char_macro} {
+ macro_formatted}) 75 {release} (arrows)\n"
output += chord_line
output += ")\n"