Compare commits
2 Commits
cd3688b0b3
...
e06cc1d4fc
Author | SHA1 | Date | |
---|---|---|---|
e06cc1d4fc | |||
aae5152288 |
@ -37,7 +37,10 @@ def load_config(file="config.ini"): # load config from configparser.ConfigParse
|
|||||||
if "file" in to_load['DEFAULT']:
|
if "file" in to_load['DEFAULT']:
|
||||||
filename = to_load['DEFAULT']['file']
|
filename = to_load['DEFAULT']['file']
|
||||||
if filename != "":
|
if filename != "":
|
||||||
|
try:
|
||||||
tab1_load_file()
|
tab1_load_file()
|
||||||
|
except FileNotFoundError:
|
||||||
|
tab1_clear()
|
||||||
if "inline" in to_load['DEFAULT']:
|
if "inline" in to_load['DEFAULT']:
|
||||||
window.tab2_plainTextEdit.setPlainText(to_load['DEFAULT']['inline'])
|
window.tab2_plainTextEdit.setPlainText(to_load['DEFAULT']['inline'])
|
||||||
if "action" in to_load['DEFAULT']:
|
if "action" in to_load['DEFAULT']:
|
||||||
@ -142,7 +145,7 @@ def select_toggle():
|
|||||||
if __name__ == "__main__":
|
if __name__ == "__main__":
|
||||||
app = QApplication(sys.argv)
|
app = QApplication(sys.argv)
|
||||||
|
|
||||||
ui_file_name = "tasmotonov_gui.ui"
|
ui_file_name = "tasmotonov-gui.ui"
|
||||||
ui_file = QFile(ui_file_name)
|
ui_file = QFile(ui_file_name)
|
||||||
if not ui_file.open(QIODevice.ReadOnly):
|
if not ui_file.open(QIODevice.ReadOnly):
|
||||||
print(f"Cannot open {ui_file_name}: {ui_file.errorString()}")
|
print(f"Cannot open {ui_file_name}: {ui_file.errorString()}")
|
||||||
|
Loading…
x
Reference in New Issue
Block a user