Added a scientific notation argument.

This commit is contained in:
jupfi 2024-06-05 09:43:20 +02:00
parent 16638e2b15
commit 3cf8000389

View file

@ -146,6 +146,7 @@ class IntSetting(NumericalSetting):
max_value : The maximum value of the setting max_value : The maximum value of the setting
slider : If the setting should be displayed as a slider (only in the GUI not used in this GUI) slider : If the setting should be displayed as a slider (only in the GUI not used in this GUI)
suffix : The suffix that is added to the value of the QSpinBox suffix : The suffix that is added to the value of the QSpinBox
scientific_notation : If the value should be displayed in scientific notation
""" """
def __init__( def __init__(
@ -158,11 +159,13 @@ class IntSetting(NumericalSetting):
max_value=None, max_value=None,
slider=False, slider=False,
suffix="", suffix="",
scientific_notation=False,
) -> None: ) -> None:
"""Create a new int setting.""" """Create a new int setting."""
super().__init__(name, category, description, default, min_value, max_value) super().__init__(name, category, description, default, min_value, max_value)
self.slider = slider self.slider = slider
self.suffix = suffix self.suffix = suffix
self.scientific_notation = scientific_notation
@property @property
def value(self): def value(self):