From b49ff787b1655a77c2f237b3eaa82934acbe1be5 Mon Sep 17 00:00:00 2001 From: Alexander Ng <43122649+ngAlexander9@users.noreply.github.com> Date: Fri, 6 Mar 2026 09:02:06 -0800 Subject: [PATCH 1/7] ENH: Set focus on PV line edit after initialization --- trace/widgets/control_panel.py | 1 + 1 file changed, 1 insertion(+) diff --git a/trace/widgets/control_panel.py b/trace/widgets/control_panel.py index 45e9742..260aefd 100644 --- a/trace/widgets/control_panel.py +++ b/trace/widgets/control_panel.py @@ -99,6 +99,7 @@ def __init__(self, theme_manager: ThemeManager = None): self.curve_list_changed.connect(self.formula_dialog.curve_model.refresh) self.update_icons() + QTimer.singleShot(0, self.pv_line_edit.setFocus) def update_icons(self) -> None: """Update all icons based on current theme.""" From 087ba25460190ac2a7512b8e6b0dfc43ea2bb832 Mon Sep 17 00:00:00 2001 From: Alexander Ng <43122649+ngAlexander9@users.noreply.github.com> Date: Fri, 6 Mar 2026 10:19:28 -0800 Subject: [PATCH 2/7] ENH: Style plot button with blue accent color --- trace/widgets/control_panel.py | 23 +++++++++++++++++++++++ 1 file changed, 23 insertions(+) diff --git a/trace/widgets/control_panel.py b/trace/widgets/control_panel.py index 260aefd..43c52c5 100644 --- a/trace/widgets/control_panel.py +++ b/trace/widgets/control_panel.py @@ -78,6 +78,29 @@ def __init__(self, theme_manager: ThemeManager = None): pv_plot_button.clicked.connect(self.add_curve_from_line_edit) pv_plotter_layout.addWidget(pv_plot_button) + # Style the plot button with blue accent color + if self.theme_manager: + blue_color = self.theme_manager.get_icon_color(IconColors.ACCENT) + pv_plot_button.setStyleSheet( + f""" + QPushButton {{ + background-color: {blue_color}; + color: white; + border: none; + padding: 5px 10px; + border-radius: 4px; + }} + QPushButton:hover {{ + background-color: {blue_color}; + opacity: 0.8; + }} + QPushButton:pressed {{ + background-color: {blue_color}; + opacity: 0.6; + }} + """ + ) + self.axis_list = QtWidgets.QVBoxLayout() frame = QtWidgets.QFrame() frame.setLayout(self.axis_list) From 25f9114af7de853dd8e8530767a64744ad9c3afb Mon Sep 17 00:00:00 2001 From: Alexander Ng <43122649+ngAlexander9@users.noreply.github.com> Date: Fri, 6 Mar 2026 10:21:12 -0800 Subject: [PATCH 3/7] ENH: Remove button styling properties for cleaner design --- trace/widgets/control_panel.py | 4 ---- 1 file changed, 4 deletions(-) diff --git a/trace/widgets/control_panel.py b/trace/widgets/control_panel.py index 43c52c5..9be6aae 100644 --- a/trace/widgets/control_panel.py +++ b/trace/widgets/control_panel.py @@ -85,10 +85,6 @@ def __init__(self, theme_manager: ThemeManager = None): f""" QPushButton {{ background-color: {blue_color}; - color: white; - border: none; - padding: 5px 10px; - border-radius: 4px; }} QPushButton:hover {{ background-color: {blue_color}; From d091910106b579db16da5bc2b2477a5d3459abd2 Mon Sep 17 00:00:00 2001 From: Alexander Ng <43122649+ngAlexander9@users.noreply.github.com> Date: Tue, 10 Mar 2026 09:56:48 -0700 Subject: [PATCH 4/7] ENH: Update plot button color to a fixed blue accent --- trace/widgets/control_panel.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/trace/widgets/control_panel.py b/trace/widgets/control_panel.py index 9be6aae..7e95e93 100644 --- a/trace/widgets/control_panel.py +++ b/trace/widgets/control_panel.py @@ -80,7 +80,7 @@ def __init__(self, theme_manager: ThemeManager = None): # Style the plot button with blue accent color if self.theme_manager: - blue_color = self.theme_manager.get_icon_color(IconColors.ACCENT) + blue_color = "#3C9AFF" pv_plot_button.setStyleSheet( f""" QPushButton {{ From 0527301a4a8584e897cf64fb9a5a57c8634eb93e Mon Sep 17 00:00:00 2001 From: Alexander Ng <43122649+ngAlexander9@users.noreply.github.com> Date: Tue, 10 Mar 2026 10:00:23 -0700 Subject: [PATCH 5/7] ENH: Update plot button styling to use theme manager colors --- trace/widgets/control_panel.py | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/trace/widgets/control_panel.py b/trace/widgets/control_panel.py index 7e95e93..360023a 100644 --- a/trace/widgets/control_panel.py +++ b/trace/widgets/control_panel.py @@ -80,18 +80,22 @@ def __init__(self, theme_manager: ThemeManager = None): # Style the plot button with blue accent color if self.theme_manager: - blue_color = "#3C9AFF" + blue_color = self.theme_manager.get_icon_color(IconColors.ACCENT) + text_color = "white" pv_plot_button.setStyleSheet( f""" QPushButton {{ background-color: {blue_color}; + color: {text_color}; }} QPushButton:hover {{ background-color: {blue_color}; + color: {text_color}; opacity: 0.8; }} QPushButton:pressed {{ background-color: {blue_color}; + color: {text_color}; opacity: 0.6; }} """ From 82214e87db2c1e8aba60be3746c270d88b750e3c Mon Sep 17 00:00:00 2001 From: Alexander Ng <43122649+ngAlexander9@users.noreply.github.com> Date: Tue, 10 Mar 2026 10:01:52 -0700 Subject: [PATCH 6/7] ENH: Update plot button text color to hex format for consistency --- trace/widgets/control_panel.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/trace/widgets/control_panel.py b/trace/widgets/control_panel.py index 360023a..a33c24f 100644 --- a/trace/widgets/control_panel.py +++ b/trace/widgets/control_panel.py @@ -81,7 +81,7 @@ def __init__(self, theme_manager: ThemeManager = None): # Style the plot button with blue accent color if self.theme_manager: blue_color = self.theme_manager.get_icon_color(IconColors.ACCENT) - text_color = "white" + text_color = "#FFFFFF" pv_plot_button.setStyleSheet( f""" QPushButton {{ From 923a5e50de3e38605b737f7f02a1e5b205ea72c8 Mon Sep 17 00:00:00 2001 From: Alexander Ng <43122649+ngAlexander9@users.noreply.github.com> Date: Tue, 10 Mar 2026 15:18:51 -0700 Subject: [PATCH 7/7] ENH: Remove hover and pressed button styling for simplified design --- trace/widgets/control_panel.py | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/trace/widgets/control_panel.py b/trace/widgets/control_panel.py index a33c24f..f6fcc3f 100644 --- a/trace/widgets/control_panel.py +++ b/trace/widgets/control_panel.py @@ -88,16 +88,6 @@ def __init__(self, theme_manager: ThemeManager = None): background-color: {blue_color}; color: {text_color}; }} - QPushButton:hover {{ - background-color: {blue_color}; - color: {text_color}; - opacity: 0.8; - }} - QPushButton:pressed {{ - background-color: {blue_color}; - color: {text_color}; - opacity: 0.6; - }} """ )