修改Calman灰阶中结果图显示、修改UI主题样式应用
This commit is contained in:
@@ -757,13 +757,10 @@ def create_test_type_frame(self: "PQAutomationApp"):
|
||||
# 测试版水印标签(版本 x.x.0.0 时显示)
|
||||
from app_version import is_beta_version, APP_VERSION
|
||||
if is_beta_version():
|
||||
beta_lbl = tk.Label(
|
||||
beta_lbl = ttk.Label(
|
||||
self.sidebar_frame,
|
||||
text=f"[测试版] v{APP_VERSION}",
|
||||
foreground="#ffffff",
|
||||
background="#cc3300",
|
||||
font=("微软雅黑", 8, "bold"),
|
||||
anchor="center",
|
||||
style="SidebarBadge.TLabel",
|
||||
)
|
||||
beta_lbl.pack(fill=tk.X, side=tk.BOTTOM, padx=4, pady=(6, 4))
|
||||
|
||||
@@ -809,6 +806,7 @@ def _on_toggle_theme(self: "PQAutomationApp") -> None:
|
||||
"""切换主题:重新应用 ttk 样式并刷新所有自定义样式相关的标签。"""
|
||||
from app.views.theme_manager import toggle_theme
|
||||
toggle_theme()
|
||||
# apply_modern_styles()
|
||||
_refresh_theme_toggle_label(self)
|
||||
if hasattr(self, "apply_result_chart_theme"):
|
||||
try:
|
||||
@@ -820,6 +818,21 @@ def _on_toggle_theme(self: "PQAutomationApp") -> None:
|
||||
self.log_gui.refresh_log_theme()
|
||||
except Exception:
|
||||
pass
|
||||
if hasattr(self, "refresh_ai_image_theme"):
|
||||
try:
|
||||
self.refresh_ai_image_theme()
|
||||
except Exception:
|
||||
pass
|
||||
if hasattr(self, "refresh_single_step_theme"):
|
||||
try:
|
||||
self.refresh_single_step_theme()
|
||||
except Exception:
|
||||
pass
|
||||
if hasattr(self, "refresh_custom_template_theme"):
|
||||
try:
|
||||
self.refresh_custom_template_theme()
|
||||
except Exception:
|
||||
pass
|
||||
if hasattr(self, "refresh_calman_theme"):
|
||||
try:
|
||||
self.refresh_calman_theme()
|
||||
|
||||
Reference in New Issue
Block a user