From e624419a0103b0df4569478125165f892236a368 Mon Sep 17 00:00:00 2001 From: lm Date: Fri, 17 Oct 2025 15:35:38 +0200 Subject: [PATCH] Tint titlebar close button on hover --- app/gui/ui.py | 34 ++++++++++++++++++---------------- 1 file changed, 18 insertions(+), 16 deletions(-) diff --git a/app/gui/ui.py b/app/gui/ui.py index 0900629..046b946 100644 --- a/app/gui/ui.py +++ b/app/gui/ui.py @@ -383,22 +383,24 @@ class UIBuilderMixin: ) title_label.pack(side=tk.LEFT, padx=6) - close_btn = tk.Button( - title_bar, - text="✕", - command=self._close_app, - bg=bar_bg, - fg="#f5f5f5", - activebackground="#ff3b30", - activeforeground="#ffffff", - borderwidth=0, - highlightthickness=0, - relief="flat", - font=("Segoe UI", 10, "bold"), - cursor="hand2", - width=3, - ) - close_btn.pack(side=tk.RIGHT, padx=8, pady=4) + close_btn = tk.Button( + title_bar, + text="✕", + command=self._close_app, + bg=bar_bg, + fg="#f5f5f5", + activebackground="#ff3b30", + activeforeground="#ffffff", + borderwidth=0, + highlightthickness=0, + relief="flat", + font=("Segoe UI", 10, "bold"), + cursor="hand2", + width=3, + ) + close_btn.pack(side=tk.RIGHT, padx=8, pady=4) + close_btn.bind("", lambda _e: close_btn.configure(bg="#cf212f")) + close_btn.bind("", lambda _e: close_btn.configure(bg=bar_bg)) for widget in (title_bar, title_label): widget.bind("", self._start_window_drag)