This commit is contained in:
kornerr committed 2024-07-13 22:51:32 +03:00
1 parent 6a4a3228fe
commit f0209fda73
6 files changed
+137

No files matched your search

+14
View File
@@ -1,6 +1,12 @@
import os
import sys
if len(sys.argv) < 2:
print("Usage: python3 /path/to/main.py /path/to/ht.config")
sys.exit(1)
CFG = os.path.realpath(sys.argv[1])
SCRIPT_DIR = os.path.dirname(os.path.realpath(sys.argv[0]))
sys.path.append(f"{SCRIPT_DIR}/../cross-language-dialect/ctx")
@@ -8,14 +14,19 @@ sys.path.append(f"{SCRIPT_DIR}/../cross-language-dialect/lib")
sys.path.append(f"{SCRIPT_DIR}/py")
import arcade
from cfg import *
from cld import *
from ctx import *
from fs import *
from desktop_Platform import *
from desktop_Window import *
from ht_Context import *
ctrl = ctx_Controller(ht_createContext())
ctrl.registerFunctions([
cfg_parseConfigTree,
fs_locateConfigDir,
fs_readConfig,
])
def printDbg(c):
@@ -34,6 +45,9 @@ def process(c):
### desktop_deselectMismatchedTiles(p)
ctrl.registerCallback(process)
ctrl.set("cfgPath", CFG)
ctrl.set("scriptDir", SCRIPT_DIR)
ctrl.set("windowWidth", 900)
ctrl.set("windowHeight", 600)
ctrl.set("windowAntialiasing", False)