feat(xrayeye): add separator between shutter/camera-running and smear switches
CI for csaxs_bec / test (push) Successful in 2m28s
CI for csaxs_bec / test (push) Successful in 2m28s
Both rows share one QGridLayout (for column alignment across rows of different label widths) -- insert the separator as a full-width grid row between them rather than a separate widget, and shift the smear-integration and ROI-vertical-lock rows down accordingly. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Lx3KffiFyyDMKT8vvPENUW
This commit is contained in:
1 parent
d237357012
commit
8bdd70eaf4
1 file changed
+15
-12
@@ -377,12 +377,13 @@ class OMNY_XRayEye(BECWidget, QWidget):
|
||||
header_row.addWidget(self.live_preview_toggle, 0, Qt.AlignmentFlag.AlignVCenter)
|
||||
self.control_panel_layout.addLayout(header_row)
|
||||
|
||||
# Shutter/camera-running (row 0) and the smear aid's own status
|
||||
# switches (row 1) share one grid so the toggle columns actually
|
||||
# line up regardless of each row's label text width -- two
|
||||
# independent QHBoxLayouts (the previous approach) each size
|
||||
# themselves from their own labels' widths, so corresponding
|
||||
# switches in different rows land at different x-positions.
|
||||
# Shutter/camera-running (row 0), a separator (row 1), the smear
|
||||
# aid's own status switches (row 2), and the ROI-vertical-lock
|
||||
# toggle (row 3) share one grid so the toggle columns actually line
|
||||
# up regardless of each row's label text width -- independent
|
||||
# QHBoxLayouts per row (the previous approach) each size themselves
|
||||
# from their own labels' widths, so corresponding switches in
|
||||
# different rows would land at different x-positions.
|
||||
self.switch_grid_widget = QWidget(parent=self)
|
||||
switch_grid = QGridLayout(self.switch_grid_widget)
|
||||
switch_grid.setContentsMargins(0, 0, 0, 0)
|
||||
@@ -426,12 +427,14 @@ class OMNY_XRayEye(BECWidget, QWidget):
|
||||
switch_grid.addWidget(self.shutter_toggle, 0, 2, Qt.AlignmentFlag.AlignVCenter)
|
||||
switch_grid.addWidget(self.camera_running_label, 0, 3, _right_vcenter)
|
||||
switch_grid.addWidget(self.camera_running_toggle, 0, 4, Qt.AlignmentFlag.AlignVCenter)
|
||||
switch_grid.addWidget(self.smear_active_label, 1, 1, _right_vcenter)
|
||||
switch_grid.addWidget(self.smear_active_toggle, 1, 2, Qt.AlignmentFlag.AlignVCenter)
|
||||
switch_grid.addWidget(self.smear_preview_label, 1, 3, _right_vcenter)
|
||||
switch_grid.addWidget(self.smear_preview_toggle, 1, 4, Qt.AlignmentFlag.AlignVCenter)
|
||||
switch_grid.addWidget(self.vertical_lock_label, 2, 1, _right_vcenter)
|
||||
switch_grid.addWidget(self.vertical_lock_toggle, 2, 2, Qt.AlignmentFlag.AlignVCenter)
|
||||
# separator: below shutter/camera-running, above the smear-integration switches
|
||||
switch_grid.addWidget(self._create_separator(), 1, 0, 1, 5)
|
||||
switch_grid.addWidget(self.smear_active_label, 2, 1, _right_vcenter)
|
||||
switch_grid.addWidget(self.smear_active_toggle, 2, 2, Qt.AlignmentFlag.AlignVCenter)
|
||||
switch_grid.addWidget(self.smear_preview_label, 2, 3, _right_vcenter)
|
||||
switch_grid.addWidget(self.smear_preview_toggle, 2, 4, Qt.AlignmentFlag.AlignVCenter)
|
||||
switch_grid.addWidget(self.vertical_lock_label, 3, 1, _right_vcenter)
|
||||
switch_grid.addWidget(self.vertical_lock_toggle, 3, 2, Qt.AlignmentFlag.AlignVCenter)
|
||||
|
||||
self.control_panel_layout.addWidget(self.switch_grid_widget)
|
||||
|
||||
|
||||
Reference in new issue
Block a user