init commit
This commit is contained in:
@@ -0,0 +1,31 @@
|
||||
"""Application entry point for the PyQt GUI."""
|
||||
|
||||
from __future__ import annotations
|
||||
|
||||
from pathlib import Path
|
||||
import sys
|
||||
|
||||
import pyqtgraph as pg
|
||||
from PyQt6.QtWidgets import QApplication
|
||||
|
||||
# Ensure imports are resolved when started as a script.
|
||||
PROJECT_ROOT = Path(__file__).resolve().parents[2]
|
||||
if str(PROJECT_ROOT) not in sys.path:
|
||||
sys.path.insert(0, str(PROJECT_ROOT))
|
||||
|
||||
from python_app.gui.app_window import AppWindow
|
||||
from python_app.gui.theme import apply_dark_theme
|
||||
|
||||
|
||||
def main() -> int:
|
||||
"""Run Qt event loop and show main radar control window."""
|
||||
app = QApplication(sys.argv)
|
||||
apply_dark_theme(app)
|
||||
pg.setConfigOptions(antialias=True, foreground="#dbe4f1")
|
||||
window = AppWindow(PROJECT_ROOT)
|
||||
window.show()
|
||||
return app.exec()
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
raise SystemExit(main())
|
||||
Reference in New Issue
Block a user