2025-05-20 11:24:07 +02:00
|
|
|
import sys
|
2025-05-23 11:09:47 +02:00
|
|
|
|
2025-05-20 11:24:07 +02:00
|
|
|
from PySide6.QtWidgets import QApplication
|
2025-05-23 11:09:47 +02:00
|
|
|
|
2025-06-09 17:17:53 +02:00
|
|
|
from ui.MainWindow import MainWindow
|
2025-06-12 20:43:31 +02:00
|
|
|
from ui.AppSettings import AppSettingsDlg
|
|
|
|
|
from conf import app_settings
|
2025-05-20 11:24:07 +02:00
|
|
|
|
2025-06-01 16:36:47 +02:00
|
|
|
#import qdarktheme
|
2025-05-30 17:19:22 +02:00
|
|
|
|
2025-05-20 11:24:07 +02:00
|
|
|
|
|
|
|
|
def main():
|
|
|
|
|
"""Haupteinstiegspunkt der Anwendung."""
|
|
|
|
|
# QApplication-Instanz erstellen
|
|
|
|
|
app = QApplication(sys.argv)
|
2025-05-30 17:19:22 +02:00
|
|
|
|
|
|
|
|
# Dark Theme aktivieren
|
2025-06-01 16:36:47 +02:00
|
|
|
# qdarktheme.setup_theme("auto")
|
2025-05-23 11:09:47 +02:00
|
|
|
|
2025-05-20 11:24:07 +02:00
|
|
|
# Hauptfenster erstellen
|
|
|
|
|
window = MainWindow()
|
2025-05-23 11:09:47 +02:00
|
|
|
|
2025-05-20 11:24:07 +02:00
|
|
|
# Hauptfenster anzeigen
|
|
|
|
|
window.show()
|
2025-06-12 20:43:31 +02:00
|
|
|
|
|
|
|
|
if len(app_settings.apache_fops) == 0 or len(app_settings.diff_pdfs) == 0 or len(app_settings.java_vms) == 0 or len(app_settings.saxon_jars):
|
|
|
|
|
# Als Modal Dialog öffnen!
|
|
|
|
|
dlg = AppSettingsDlg(window, app_settings)
|
|
|
|
|
dlg.exec()
|
2025-05-23 11:09:47 +02:00
|
|
|
|
2025-05-20 11:24:07 +02:00
|
|
|
# Anwendung ausführen und Rückgabewert zurückgeben
|
|
|
|
|
return app.exec()
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
if __name__ == "__main__":
|
|
|
|
|
sys.exit(main())
|