mirror of
https://git.hiabuto.net/C3MA/CCMA.git
synced 2026-07-01 11:14:52 +02:00
feat: use branded splash background
This commit is contained in:
+7
-1
@@ -33,7 +33,13 @@ include-package-data = true
|
||||
where = ["src"]
|
||||
|
||||
[tool.setuptools.package-data]
|
||||
ccma = ["VERSION", "assets/CHANGELOG.json", "assets/themes/forest/**/*", "assets/themes/forest/*"]
|
||||
ccma = [
|
||||
"VERSION",
|
||||
"assets/CHANGELOG.json",
|
||||
"assets/splash.png",
|
||||
"assets/themes/forest/**/*",
|
||||
"assets/themes/forest/*",
|
||||
]
|
||||
|
||||
[tool.pytest.ini_options]
|
||||
testpaths = ["tests"]
|
||||
|
||||
@@ -26,6 +26,7 @@
|
||||
"Forderungen besitzen eigene Tabs mit Positionen, Teilzahlungen, GnuCash-Referenzen, Zahlungszuordnungen, Mahnungen und Gebühren.",
|
||||
"Dropdowns zeigen deutsche Begriffe bei weiterhin englischen Speicher-Keys; der Hausmeisterstatus liegt einheitlich in housekeeper.json.",
|
||||
"Mehrstufiger Mahnworkflow mit Hausmeister-Regel, Entwurf, Versandbestätigung, Zahlungsfrist, optionaler Gebühr und Mahnsperre ergänzt.",
|
||||
"Splash-Screen auf das eingebettete CCMA-Hintergrundmotiv umgestellt und redundante Titeltexte entfernt.",
|
||||
"Hausmeister um konfigurierbare Geburtstags- und Mitgliedsjubiläumsmeldungen erweitert.",
|
||||
"Statusänderungen werden mit altem und neuem Klartextwert in der Mitgliederchronik protokolliert.",
|
||||
"Fensterposition, normaler Fensterzustand und Maximierung werden gespeichert; der Splash startet auf dem zuletzt verwendeten Monitor.",
|
||||
|
||||
Binary file not shown.
|
After Width: | Height: | Size: 1.6 MiB |
+16
-32
@@ -4,6 +4,7 @@ import threading
|
||||
import tkinter as tk
|
||||
from collections.abc import Callable
|
||||
from dataclasses import dataclass
|
||||
from pathlib import Path
|
||||
from queue import Empty, Queue
|
||||
from tkinter import ttk
|
||||
|
||||
@@ -51,7 +52,7 @@ class SplashScreen(tk.Toplevel):
|
||||
self.after(120, self._start)
|
||||
|
||||
def _build_ui(self) -> None:
|
||||
width, height = 620, 330
|
||||
width, height = 768, 512
|
||||
self.geometry(f"{width}x{height}")
|
||||
self.canvas = tk.Canvas(
|
||||
self,
|
||||
@@ -61,44 +62,27 @@ class SplashScreen(tk.Toplevel):
|
||||
background="#0b1117",
|
||||
)
|
||||
self.canvas.pack(fill="both", expand=True)
|
||||
self.canvas.create_rectangle(0, 0, width, 6, fill="#00d084", outline="")
|
||||
image_path = Path(__file__).resolve().parent.parent / "assets" / "splash.png"
|
||||
self.background_image = tk.PhotoImage(master=self, file=str(image_path)).subsample(2, 2)
|
||||
self.background_item = self.canvas.create_image(0, 0, anchor="nw", image=self.background_image)
|
||||
self.canvas.create_text(
|
||||
34,
|
||||
58,
|
||||
anchor="w",
|
||||
text="CCMA",
|
||||
fill="#00d084",
|
||||
font=("TkFixedFont", 30, "bold"),
|
||||
)
|
||||
self.canvas.create_text(
|
||||
34,
|
||||
101,
|
||||
anchor="w",
|
||||
text="CHAOTIC CREATURE MEMBER ADMINISTRATION",
|
||||
fill="#d7e0e8",
|
||||
font=("TkFixedFont", 12, "bold"),
|
||||
)
|
||||
self.canvas.create_text(
|
||||
34,
|
||||
139,
|
||||
anchor="w",
|
||||
text="Chaos Computer Club Mannheim e.V.",
|
||||
fill="#7f8e9b",
|
||||
font=("TkDefaultFont", 10),
|
||||
)
|
||||
self.canvas.create_text(
|
||||
width - 34, 58, anchor="e", text=f"v{__version__}", fill="#7f8e9b", font=("TkFixedFont", 10)
|
||||
width - 24,
|
||||
24,
|
||||
anchor="ne",
|
||||
text=f"v{__version__}",
|
||||
fill="#b8c5d0",
|
||||
font=("TkFixedFont", 10),
|
||||
)
|
||||
self.status_item = self.canvas.create_text(
|
||||
34,
|
||||
245,
|
||||
anchor="w",
|
||||
30,
|
||||
450,
|
||||
anchor="sw",
|
||||
text="Initialisiere …",
|
||||
fill="#d7e0e8",
|
||||
fill="#e8edf2",
|
||||
font=("TkFixedFont", 10),
|
||||
)
|
||||
self.progress = ttk.Progressbar(self, mode="indeterminate")
|
||||
self.canvas.create_window(34, 280, anchor="w", width=552, window=self.progress)
|
||||
self.canvas.create_window(30, 476, anchor="nw", width=708, window=self.progress)
|
||||
|
||||
def _center(self) -> None:
|
||||
self.update_idletasks()
|
||||
|
||||
Reference in New Issue
Block a user