添加手动设置窗口亮度、曲线图生成
This commit is contained in:
@@ -60,6 +60,50 @@ def create_local_dimming_panel(self: "PQAutomationApp"):
|
||||
style="SuccessState.TLabel",
|
||||
).pack(pady=(0, 8))
|
||||
|
||||
window_level_row = ttk.Frame(window_frame)
|
||||
window_level_row.pack(fill=tk.X, pady=(0, 8))
|
||||
|
||||
ttk.Label(window_level_row, text="窗口(%):").pack(side=tk.LEFT)
|
||||
self.ld_window_percentage_var = tk.StringVar(value="10")
|
||||
ld_window_percentage_entry = ttk.Entry(
|
||||
window_level_row,
|
||||
textvariable=self.ld_window_percentage_var,
|
||||
width=8,
|
||||
)
|
||||
ld_window_percentage_entry.pack(side=tk.LEFT, padx=(6, 10))
|
||||
|
||||
ttk.Label(window_level_row, text="窗口亮度(%):").pack(side=tk.LEFT)
|
||||
self.ld_window_luminance_var = tk.StringVar(value="100")
|
||||
ld_window_luminance_entry = ttk.Entry(
|
||||
window_level_row,
|
||||
textvariable=self.ld_window_luminance_var,
|
||||
width=8,
|
||||
)
|
||||
ld_window_luminance_entry.pack(side=tk.LEFT, padx=(6, 10))
|
||||
|
||||
ttk.Button(
|
||||
window_level_row,
|
||||
text="生成窗口",
|
||||
command=self.send_ld_manual_window,
|
||||
bootstyle="success-outline",
|
||||
width=12,
|
||||
).pack(side=tk.LEFT)
|
||||
|
||||
ld_window_percentage_entry.bind(
|
||||
"<Return>",
|
||||
lambda _event: self.send_ld_manual_window(),
|
||||
)
|
||||
ld_window_luminance_entry.bind(
|
||||
"<Return>",
|
||||
lambda _event: self.send_ld_manual_window(),
|
||||
)
|
||||
|
||||
ttk.Label(
|
||||
window_level_row,
|
||||
text="输入后可直接点生成或回车",
|
||||
style="InfoState.TLabel",
|
||||
).pack(side=tk.LEFT, padx=(8, 0))
|
||||
|
||||
# 第一行:1%, 2%, 5%, 10%, 18%
|
||||
row1 = ttk.Frame(window_frame)
|
||||
row1.pack(fill=tk.X, pady=(0, 5))
|
||||
@@ -118,14 +162,6 @@ def create_local_dimming_panel(self: "PQAutomationApp"):
|
||||
width=14,
|
||||
).pack(side=tk.LEFT, padx=3)
|
||||
|
||||
ttk.Button(
|
||||
pattern_row,
|
||||
text="瞬时峰值",
|
||||
command=self.send_ld_instant_peak,
|
||||
bootstyle="warning",
|
||||
width=12,
|
||||
).pack(side=tk.LEFT, padx=3)
|
||||
|
||||
ttk.Button(
|
||||
pattern_row,
|
||||
text="全黑画面",
|
||||
@@ -285,6 +321,15 @@ def create_local_dimming_panel(self: "PQAutomationApp"):
|
||||
)
|
||||
self.ld_save_btn.pack(side=tk.LEFT)
|
||||
|
||||
self.ld_plot_btn = ttk.Button(
|
||||
bottom_frame,
|
||||
text="📈 生成峰值曲线",
|
||||
command=self.plot_ld_instant_peak_curve,
|
||||
bootstyle="warning-outline",
|
||||
width=14,
|
||||
)
|
||||
self.ld_plot_btn.pack(side=tk.LEFT, padx=(5, 0))
|
||||
|
||||
# 默认隐藏
|
||||
self.local_dimming_visible = False
|
||||
|
||||
|
||||
Reference in New Issue
Block a user