Skip to content

Commit

Permalink
Fix dispay of AxisOrderWidget in dark mode
Browse files Browse the repository at this point in the history
plus some black autoformatting for long lines
  • Loading branch information
k-dominik committed Aug 28, 2024
1 parent 42984bf commit 2818aee
Showing 1 changed file with 31 additions and 7 deletions.
38 changes: 31 additions & 7 deletions volumina/widgets/dataExportOptionsDlg.py
Original file line number Diff line number Diff line change
Expand Up @@ -231,12 +231,36 @@ def _handleConvertDtypeChecked():

self.convertDtypeCheckbox.toggled.connect(_handleConvertDtypeChecked)
dtypes = [
("integer 8-bit", "uint8", "Stores data as integers. More bits per value increase precision but require more storage and processing time."),
("integer 16-bit", "uint16", "Stores data as integers. More bits per value increase precision but require more storage and processing time."),
("integer 32-bit", "uint32", "Stores data as integers. More bits per value increase precision but require more storage and processing time."),
("integer 64-bit", "uint64", "Stores data as integers. More bits per value increase precision but require more storage and processing time."),
("floating-point 32-bit", "float32", "Stores data as numbers with a decimal point. More bits per value increase precision but require more storage and processing time."),
("floating-point 64-bit", "float64", "Stores data as numbers with a decimal point. More bits per value increase precision but require more storage and processing time."),
(
"integer 8-bit",
"uint8",
"Stores data as integers. More bits per value increase precision but require more storage and processing time.",
),
(
"integer 16-bit",
"uint16",
"Stores data as integers. More bits per value increase precision but require more storage and processing time.",
),
(
"integer 32-bit",
"uint32",
"Stores data as integers. More bits per value increase precision but require more storage and processing time.",
),
(
"integer 64-bit",
"uint64",
"Stores data as integers. More bits per value increase precision but require more storage and processing time.",
),
(
"floating-point 32-bit",
"float32",
"Stores data as numbers with a decimal point. More bits per value increase precision but require more storage and processing time.",
),
(
"floating-point 64-bit",
"float64",
"Stores data as numbers with a decimal point. More bits per value increase precision but require more storage and processing time.",
),
]

for i, (name, dtype, tooltip) in enumerate(dtypes):
Expand Down Expand Up @@ -394,7 +418,7 @@ def _updateAxisOrderColor(self, allow_intermediate):
if invalidAxes:
self.outputAxisOrderEdit.setStyleSheet("QLineEdit {background-color: red}")
else:
self.outputAxisOrderEdit.setStyleSheet("QLineEdit {background-color: white}")
self.outputAxisOrderEdit.setStyleSheet("QLineEdit {background-color: palette(base)}")

Check warning on line 421 in volumina/widgets/dataExportOptionsDlg.py

View check run for this annotation

Codecov / codecov/patch

volumina/widgets/dataExportOptionsDlg.py#L421

Added line #L421 was not covered by tests

class _AxisOrderEventFilter(QObject):
def __init__(self, parent):
Expand Down

0 comments on commit 2818aee

Please sign in to comment.