qudi.util.widgets.scientific_spinbox.ScienDSpinBox

class qudi.util.widgets.scientific_spinbox.ScienDSpinBox(*args, **kwargs)[source]

Bases: PySide2.QtWidgets.QAbstractSpinBox

Wrapper Class from PyQt5 (or QtPy) to display a QDoubleSpinBox in Scientific way. Fully supports prefix and suffix functionality of the QDoubleSpinBox. Has built-in functionality to invoke the displayed number precision from the user input.

This class can be directly used in Qt Designer by promoting the QDoubleSpinBox to ScienDSpinBox. State the path to this file (in python style, i.e. dots are separating the directories) as the header file and use the name of the present class.

__init__(*args, **kwargs)[source]

Methods

__init__(*args, **kwargs)

acceptDrops(self)

accessibleDescription(self)

accessibleName(self)

actionEvent(self, event)

actions(self)

activateWindow(self)

addAction(self, action)

addActions(self, actions)

adjustSize(self)

alignment(self)

autoFillBackground(self)

backgroundRole(self)

backingStore(self)

baseSize(self)

blockSignals(self, b)

buttonSymbols(self)

changeEvent(self, event)

check_range(value)

Helper method to check if the passed value is within the set minimum and maximum value bounds.

childAt(-> PySide2.QtWidgets.QWidget)

childEvent(self, event)

children(self)

childrenRect(self)

childrenRegion(self)

cleanText()

Compliance method from Qt SpinBoxes.

clear(self)

clearFocus(self)

clearMask(self)

close(self)

closeEvent(self, event)

colorCount(self)

connect(...)

connectNotify(self, signal)

contentsMargins(self)

contentsRect(self)

contextMenuEvent(self, event)

contextMenuPolicy(self)

correctionMode(self)

create(self[, arg__1, initializeWindow, ...])

createWinId(self)

createWindowContainer(window[, parent, flags])

cursor(self)

customEvent(self, event)

decimals()

deleteLater(self)

depth(self)

destroy(self[, destroyWindow, destroySubWindows])

devType(self)

devicePixelRatio(self)

devicePixelRatioF(self)

devicePixelRatioFScale()

disconnect(...)

disconnectNotify(self, signal)

dragEnterEvent(self, event)

dragLeaveEvent(self, event)

dragMoveEvent(self, event)

dropEvent(self, event)

dumpObjectInfo(self)

dumpObjectTree(self)

dynamicPropertyNames(self)

effectiveWinId(self)

emit(self, arg__1, *args)

ensurePolished(self)

enterEvent(self, event)

event(self, event)

eventFilter(self, watched, event)

find(arg__1)

findChild(self, arg__1[, arg__2])

findChildren(...)

fixup(text)

Takes an invalid string and tries to fix it in order to pass validation.

focusInEvent(self, event)

focusNextChild(self)

focusNextPrevChild(self, next)

focusOutEvent(self, event)

focusPolicy(self)

focusPreviousChild(self)

focusProxy(self)

focusWidget(self)

font(self)

fontInfo(self)

fontMetrics(self)

foregroundRole(self)

frameGeometry(self)

frameSize(self)

geometry(self)

getContentsMargins(self)

grab(self[, rectangle])

grabGesture(self, type[, flags])

grabKeyboard(self)

grabMouse(-> None)

grabShortcut(self, key[, context])

graphicsEffect(self)

graphicsProxyWidget(self)

hasAcceptableInput(self)

hasFocus(self)

hasFrame(self)

hasHeightForWidth(self)

hasMouseTracking(self)

hasTabletTracking(self)

height(self)

heightForWidth(self, arg__1)

heightMM(self)

hide(self)

hideEvent(self, event)

inherits(self, classname)

initPainter(self, painter)

initStyleOption(self, option)

inputMethodEvent(self, event)

inputMethodHints(self)

inputMethodQuery(self, arg__1)

insertAction(self, before, action)

insertActions(self, before, actions)

installEventFilter(self, filterObj)

internalWinId(self)

interpretText(self)

isAccelerated(self)

isActiveWindow(self)

isAncestorOf(self, child)

isEnabled(self)

isEnabledTo(self, arg__1)

isEnabledToTLW(self)

isFullScreen(self)

isGroupSeparatorShown(self)

isHidden(self)

isLeftToRight(self)

isMaximized(self)

isMinimized(self)

isModal(self)

isReadOnly(self)

isRightToLeft(self)

isSignalConnected(self, signal)

isTopLevel(self)

isVisible(self)

isVisibleTo(self, arg__1)

isWidgetType(self)

isWindow(self)

isWindowModified(self)

isWindowType(self)

keyPressEvent(event)

This method catches all keyboard press events triggered by the user.

keyReleaseEvent(self, event)

keyboardGrabber()

keyboardTracking(self)

killTimer(self, id)

layout(self)

layoutDirection(self)

leaveEvent(self, event)

lineEdit(self)

locale(self)

logicalDpiX(self)

logicalDpiY(self)

lower(self)

mapFrom(self, arg__1, arg__2)

mapFromGlobal(self, arg__1)

mapFromParent(self, arg__1)

mapTo(self, arg__1, arg__2)

mapToGlobal(self, arg__1)

mapToParent(self, arg__1)

mask(self)

maximum()

maximumHeight(self)

maximumSize(self)

maximumWidth(self)

metaObject(self)

metric(self, arg__1)

minimalStep()

minimum()

minimumHeight(self)

minimumSize(self)

minimumSizeHint(self)

minimumWidth(self)

mouseDoubleClickEvent(self, event)

mouseGrabber()

mouseMoveEvent(self, event)

mousePressEvent(self, event)

mouseReleaseEvent(self, event)

move(-> None)

moveEvent(self, event)

moveToThread(self, thread)

nativeEvent(self, eventType, message)

nativeParentWidget(self)

nextInFocusChain(self)

normalGeometry(self)

objectName(self)

overrideWindowFlags(self, type)

overrideWindowState(self, state)

paintEngine(self)

paintEvent(ev)

Add drawing of a red frame around the spinbox if the is_valid flag is False

paintingActive(self)

palette(self)

parent(self)

parentWidget(self)

physicalDpiX(self)

physicalDpiY(self)

pos(self)

prefix()

previousInFocusChain(self)

property(self, name)

raise_(self)

receivers(self, signal)

rect(self)

redirected(self, offset)

registerUserData()

releaseKeyboard(self)

releaseMouse(self)

releaseShortcut(self, id)

removeAction(self, action)

removeEventFilter(self, obj)

render(, renderFlags, sourceRegion, renderFlags)

repaint(-> None  -> None  -> None)

resize(-> None)

resizeEvent(self, event)

restoreGeometry(self, geometry)

saveGeometry(self)

screen(self)

scroll(-> None)

selectAll(self)

sender(self)

senderSignalIndex(self)

setAccelerated(self, on)

setAcceptDrops(self, on)

setAccessibleDescription(self, description)

setAccessibleName(self, name)

setAlignment(self, flag)

setAttribute(self, arg__1[, on])

setAutoFillBackground(self, enabled)

setBackgroundRole(self, arg__1)

setBaseSize(-> None)

setButtonSymbols(self, bs)

setContentsMargins(-> None)

setContextMenuPolicy(self, policy)

setCorrectionMode(self, cm)

setCursor(self, arg__1)

setDecimals(decimals[, dynamic_precision])

Set the number of displayed digits after the decimal point and specify dynamic precision.

setDisabled(self, arg__1)

setEnabled(self, arg__1)

setFixedHeight(self, h)

setFixedSize(-> None)

setFixedWidth(self, w)

setFocus(-> None)

setFocusPolicy(self, policy)

setFocusProxy(self, arg__1)

setFont(self, arg__1)

setForegroundRole(self, arg__1)

setFrame(self, arg__1)

setGeometry(-> None)

setGraphicsEffect(self, effect)

setGroupSeparatorShown(self, shown)

setHidden(self, hidden)

setInputMethodHints(self, hints)

setKeyboardTracking(self, kt)

setLayout(self, arg__1)

setLayoutDirection(self, direction)

setLineEdit(self, edit)

setLocale(self, locale)

setMask(-> None)

setMaximum(maximum)

Setter method to set the maximum value allowed in the SpinBox.

setMaximumHeight(self, maxh)

setMaximumSize(-> None)

setMaximumWidth(self, maxw)

setMinimalStep(step)

Method used to set a minimal step size.

setMinimum(minimum)

Setter method to set the minimum value allowed in the SpinBox.

setMinimumHeight(self, minh)

setMinimumSize(-> None)

setMinimumWidth(self, minw)

setMouseTracking(self, enable)

setObjectName(self, name)

setPalette(self, arg__1)

setParent(-> None  -> None)

setPrefix(prefix)

Set a string to be shown as non-editable prefix in the spinbox.

setProperty(prop, val)

For compatibility with QtDesigner.

setRange(minimum, maximum)

Convenience method for compliance with Qt SpinBoxes.

setReadOnly(self, r)

setShortcutAutoRepeat(self, id[, enable])

setShortcutEnabled(self, id[, enable])

setSingleStep(step[, dynamic_stepping])

Set the stepping behavior of the spinbox (e.g., when using the mouse wheel).

setSizeIncrement(-> None)

setSizePolicy(-> None)

setSpecialValueText(self, txt)

setStatusTip(self, arg__1)

setStyle(self, arg__1)

setStyleSheet(self, styleSheet)

setSuffix(suffix)

Set a string to be shown as non-editable suffix in the spinbox.

setTabOrder(arg__1, arg__2)

setTabletTracking(self, enable)

setToolTip(self, arg__1)

setToolTipDuration(self, msec)

setUpdatesEnabled(self, enable)

setValue(value)

Setter method to programmatically set the current value.

setVisible(self, visible)

setWhatsThis(self, arg__1)

setWindowFilePath(self, filePath)

setWindowFlag(self, arg__1[, on])

setWindowFlags(self, type)

setWindowIcon(self, icon)

setWindowIconText(self, arg__1)

setWindowModality(self, windowModality)

setWindowModified(self, arg__1)

setWindowOpacity(self, level)

setWindowRole(self, arg__1)

setWindowState(self, state)

setWindowTitle(self, arg__1)

setWrapping(self, w)

sharedPainter(self)

show(self)

showEvent(self, event)

showFullScreen(self)

showMaximized(self)

showMinimized(self)

showNormal(self)

signalsBlocked(self)

singleStep()

size(self)

sizeHint(self)

sizeIncrement(self)

sizePolicy(self)

specialValueText(self)

stackUnder(self, arg__1)

startTimer(self, interval[, timerType])

statusTip(self)

stepBy(steps)

This method is responsible for incrementing the value of the SpinBox when the user triggers a step (by pressing PgUp/PgDown/Up/Down, MouseWheel movement or clicking on the arrows).

stepDown(self)

stepEnabled()

Enables stepping (mouse wheel, arrow up/down, clicking, PgUp/Down) by default.

stepUp(self)

style(self)

styleSheet(self)

suffix()

tabletEvent(self, event)

testAttribute(self, arg__1)

text(self)

textFromValue(value)

This method is responsible for the mapping of the underlying value to a string to display in the SpinBox.

thread(self)

timerEvent(self, event)

toolTip(self)

toolTipDuration(self)

topLevelWidget(self)

tr(self, arg__1[, arg__2, arg__3])

underMouse(self)

ungrabGesture(self, type)

unsetCursor(self)

unsetLayoutDirection(self)

unsetLocale(self)

update(-> None  -> None  -> None)

updateGeometry(self)

updateMicroFocus(self)

update_display()

This helper method updates the shown text based on the current value.

update_value()

This method will grab the currently shown text from the QLineEdit and interpret it.

updatesEnabled(self)

validate(text, position)

Access method to the validator.

value()

Getter method to obtain the current value as float.

valueFromText(text[, use_assumed_unit_prefix])

Convert a string displayed in the SpinBox into a Decimal value.

visibleRegion(self)

whatsThis(self)

wheelEvent(event)

Overwriting wheel event, such that with the class variable disable_wheel = True the stepping with the mouse wheel is turned off and the wheel event is passed to the parent widget.

width(self)

widthMM(self)

winId(self)

window(self)

windowFilePath(self)

windowFlags(self)

windowHandle(self)

windowIcon(self)

windowIconText(self)

windowModality(self)

windowOpacity(self)

windowRole(self)

windowState(self)

windowTitle(self)

windowType(self)

wrapping(self)

x(self)

y(self)

Attributes

AdaptiveDecimalStepType

CorrectToNearestValue

CorrectToPreviousValue

DefaultStepType

DrawChildren

DrawWindowBackground

IgnoreMask

NoButtons

PdmDepth

PdmDevicePixelRatio

PdmDevicePixelRatioScaled

PdmDpiX

PdmDpiY

PdmHeight

PdmHeightMM

PdmNumColors

PdmPhysicalDpiX

PdmPhysicalDpiY

PdmWidth

PdmWidthMM

PlusMinus

StepDownEnabled

StepNone

StepUpEnabled

UpDownArrows

assumed_unit_prefix

Default unit prefix for text input.

customContextMenuRequested

destroyed

dynamic_precision

Flag indicating whether dynamic decimal precision should be used based on user input.

dynamic_stepping

Flag indicating whether dynamic (logarithmic) stepping should be used or fixed steps.

editingFinished

is_valid

Flag indicating if the currently available value is valid.

objectNameChanged

painters

staticMetaObject

valueChanged

windowIconChanged

windowIconTextChanged

windowTitleChanged

AdaptiveDecimalStepType = PySide2.QtWidgets.QAbstractSpinBox.StepType.AdaptiveDecimalStepType
class ButtonSymbols

Bases: builtins.object

NoButtons = PySide2.QtWidgets.QAbstractSpinBox.ButtonSymbols.NoButtons
PlusMinus = PySide2.QtWidgets.QAbstractSpinBox.ButtonSymbols.PlusMinus
UpDownArrows = PySide2.QtWidgets.QAbstractSpinBox.ButtonSymbols.UpDownArrows
name

!! processed by numpydoc !!

values = {'NoButtons': PySide2.QtWidgets.QAbstractSpinBox.ButtonSymbols.NoButtons, 'PlusMinus': PySide2.QtWidgets.QAbstractSpinBox.ButtonSymbols.PlusMinus, 'UpDownArrows': PySide2.QtWidgets.QAbstractSpinBox.ButtonSymbols.UpDownArrows}
CorrectToNearestValue = PySide2.QtWidgets.QAbstractSpinBox.CorrectionMode.CorrectToNearestValue
CorrectToPreviousValue = PySide2.QtWidgets.QAbstractSpinBox.CorrectionMode.CorrectToPreviousValue
class CorrectionMode

Bases: builtins.object

CorrectToNearestValue = PySide2.QtWidgets.QAbstractSpinBox.CorrectionMode.CorrectToNearestValue
CorrectToPreviousValue = PySide2.QtWidgets.QAbstractSpinBox.CorrectionMode.CorrectToPreviousValue
name

!! processed by numpydoc !!

values = {'CorrectToNearestValue': PySide2.QtWidgets.QAbstractSpinBox.CorrectionMode.CorrectToNearestValue, 'CorrectToPreviousValue': PySide2.QtWidgets.QAbstractSpinBox.CorrectionMode.CorrectToPreviousValue}
DefaultStepType = PySide2.QtWidgets.QAbstractSpinBox.StepType.DefaultStepType
DrawChildren = PySide2.QtWidgets.QWidget.RenderFlag.DrawChildren
DrawWindowBackground = PySide2.QtWidgets.QWidget.RenderFlag.DrawWindowBackground
IgnoreMask = PySide2.QtWidgets.QWidget.RenderFlag.IgnoreMask
NoButtons = PySide2.QtWidgets.QAbstractSpinBox.ButtonSymbols.NoButtons
class PaintDeviceMetric

Bases: builtins.object

PdmDepth = PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmDepth
PdmDevicePixelRatio = PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmDevicePixelRatio
PdmDevicePixelRatioScaled = PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmDevicePixelRatioScaled
PdmDpiX = PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmDpiX
PdmDpiY = PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmDpiY
PdmHeight = PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmHeight
PdmHeightMM = PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmHeightMM
PdmNumColors = PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmNumColors
PdmPhysicalDpiX = PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmPhysicalDpiX
PdmPhysicalDpiY = PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmPhysicalDpiY
PdmWidth = PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmWidth
PdmWidthMM = PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmWidthMM
name

!! processed by numpydoc !!

values = {'PdmDepth': PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmDepth, 'PdmDevicePixelRatio': PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmDevicePixelRatio, 'PdmDevicePixelRatioScaled': PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmDevicePixelRatioScaled, 'PdmDpiX': PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmDpiX, 'PdmDpiY': PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmDpiY, 'PdmHeight': PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmHeight, 'PdmHeightMM': PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmHeightMM, 'PdmNumColors': PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmNumColors, 'PdmPhysicalDpiX': PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmPhysicalDpiX, 'PdmPhysicalDpiY': PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmPhysicalDpiY, 'PdmWidth': PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmWidth, 'PdmWidthMM': PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmWidthMM}
PdmDepth = PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmDepth
PdmDevicePixelRatio = PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmDevicePixelRatio
PdmDevicePixelRatioScaled = PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmDevicePixelRatioScaled
PdmDpiX = PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmDpiX
PdmDpiY = PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmDpiY
PdmHeight = PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmHeight
PdmHeightMM = PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmHeightMM
PdmNumColors = PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmNumColors
PdmPhysicalDpiX = PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmPhysicalDpiX
PdmPhysicalDpiY = PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmPhysicalDpiY
PdmWidth = PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmWidth
PdmWidthMM = PySide2.QtGui.QPaintDevice.PaintDeviceMetric.PdmWidthMM
PlusMinus = PySide2.QtWidgets.QAbstractSpinBox.ButtonSymbols.PlusMinus
class RenderFlag

Bases: builtins.object

DrawChildren = PySide2.QtWidgets.QWidget.RenderFlag.DrawChildren
DrawWindowBackground = PySide2.QtWidgets.QWidget.RenderFlag.DrawWindowBackground
IgnoreMask = PySide2.QtWidgets.QWidget.RenderFlag.IgnoreMask
name

!! processed by numpydoc !!

values = {'DrawChildren': PySide2.QtWidgets.QWidget.RenderFlag.DrawChildren, 'DrawWindowBackground': PySide2.QtWidgets.QWidget.RenderFlag.DrawWindowBackground, 'IgnoreMask': PySide2.QtWidgets.QWidget.RenderFlag.IgnoreMask}
class RenderFlags

Bases: builtins.object

StepDownEnabled = PySide2.QtWidgets.QAbstractSpinBox.StepEnabledFlag.StepDownEnabled
class StepEnabled

Bases: builtins.object

class StepEnabledFlag

Bases: builtins.object

StepDownEnabled = PySide2.QtWidgets.QAbstractSpinBox.StepEnabledFlag.StepDownEnabled
StepNone = PySide2.QtWidgets.QAbstractSpinBox.StepEnabledFlag.StepNone
StepUpEnabled = PySide2.QtWidgets.QAbstractSpinBox.StepEnabledFlag.StepUpEnabled
name

!! processed by numpydoc !!

values = {'StepDownEnabled': PySide2.QtWidgets.QAbstractSpinBox.StepEnabledFlag.StepDownEnabled, 'StepNone': PySide2.QtWidgets.QAbstractSpinBox.StepEnabledFlag.StepNone, 'StepUpEnabled': PySide2.QtWidgets.QAbstractSpinBox.StepEnabledFlag.StepUpEnabled}
StepNone = PySide2.QtWidgets.QAbstractSpinBox.StepEnabledFlag.StepNone
class StepType

Bases: builtins.object

AdaptiveDecimalStepType = PySide2.QtWidgets.QAbstractSpinBox.StepType.AdaptiveDecimalStepType
DefaultStepType = PySide2.QtWidgets.QAbstractSpinBox.StepType.DefaultStepType
name

!! processed by numpydoc !!

values = {'AdaptiveDecimalStepType': PySide2.QtWidgets.QAbstractSpinBox.StepType.AdaptiveDecimalStepType, 'DefaultStepType': PySide2.QtWidgets.QAbstractSpinBox.StepType.DefaultStepType}
StepUpEnabled = PySide2.QtWidgets.QAbstractSpinBox.StepEnabledFlag.StepUpEnabled
UpDownArrows = PySide2.QtWidgets.QAbstractSpinBox.ButtonSymbols.UpDownArrows
acceptDrops(self) bool
accessibleDescription(self) str
accessibleName(self) str
actionEvent(self, event: PySide2.QtGui.QActionEvent) None
actions(self) List[PySide2.QtWidgets.QAction]
activateWindow(self) None
addAction(self, action: PySide2.QtWidgets.QAction) None
addActions(self, actions: Sequence[PySide2.QtWidgets.QAction]) None
adjustSize(self) None
alignment(self) PySide2.QtCore.Qt.Alignment
property assumed_unit_prefix

Default unit prefix for text input.

Returns:
str or None

The default unit prefix string if set, otherwise None.

autoFillBackground(self) bool
backgroundRole(self) PySide2.QtGui.QPalette.ColorRole
backingStore(self) PySide2.QtGui.QBackingStore
baseSize(self) PySide2.QtCore.QSize
blockSignals(self, b: bool) bool
buttonSymbols(self) PySide2.QtWidgets.QAbstractSpinBox.ButtonSymbols
changeEvent(self, event: PySide2.QtCore.QEvent) None
check_range(value)[source]

Helper method to check if the passed value is within the set minimum and maximum value bounds.

If outside of bounds, the returned value will be clipped to the nearest boundary.

Parameters:
valuefloat or Decimal

Number to be checked.

Returns:
Decimal

The corrected value.

bool

Flag indicating if the value has been changed (True) or not (False).

childAt(self, p: PySide2.QtCore.QPoint) PySide2.QtWidgets.QWidget
childAt(self, x: int, y: int) PySide2.QtWidgets.QWidget
childEvent(self, event: PySide2.QtCore.QChildEvent) None
children(self) List[PySide2.QtCore.QObject]
childrenRect(self) PySide2.QtCore.QRect
childrenRegion(self) PySide2.QtGui.QRegion
cleanText()[source]

Compliance method from Qt SpinBoxes.

Returns the currently shown text from the QLineEdit without prefix and suffix and stripped from leading or trailing whitespaces.

Returns:
str

Currently shown text stripped from suffix and prefix.

clear(self) None
clearFocus(self) None
clearMask(self) None
close(self) bool
closeEvent(self, event: PySide2.QtGui.QCloseEvent) None
colorCount(self) int
static connect(arg__1: PySide2.QtCore.QObject, arg__2: bytes, arg__3: Callable, type: PySide2.QtCore.Qt.ConnectionType = PySide2.QtCore.Qt.ConnectionType.AutoConnection) bool
static connect(self, arg__1: bytes, arg__2: Callable, type: PySide2.QtCore.Qt.ConnectionType = PySide2.QtCore.Qt.ConnectionType.AutoConnection) bool
static connect(self, arg__1: bytes, arg__2: PySide2.QtCore.QObject, arg__3: bytes, type: PySide2.QtCore.Qt.ConnectionType = PySide2.QtCore.Qt.ConnectionType.AutoConnection) bool
static connect(self, sender: PySide2.QtCore.QObject, signal: bytes, member: bytes, type: PySide2.QtCore.Qt.ConnectionType = PySide2.QtCore.Qt.ConnectionType.AutoConnection) PySide2.QtCore.QMetaObject.Connection
static connect(sender: PySide2.QtCore.QObject, signal: PySide2.QtCore.QMetaMethod, receiver: PySide2.QtCore.QObject, method: PySide2.QtCore.QMetaMethod, type: PySide2.QtCore.Qt.ConnectionType = PySide2.QtCore.Qt.ConnectionType.AutoConnection) PySide2.QtCore.QMetaObject.Connection
static connect(sender: PySide2.QtCore.QObject, signal: bytes, receiver: PySide2.QtCore.QObject, member: bytes, type: PySide2.QtCore.Qt.ConnectionType = PySide2.QtCore.Qt.ConnectionType.AutoConnection) PySide2.QtCore.QMetaObject.Connection
connectNotify(self, signal: PySide2.QtCore.QMetaMethod) None
contentsMargins(self) PySide2.QtCore.QMargins
contentsRect(self) PySide2.QtCore.QRect
contextMenuEvent(self, event: PySide2.QtGui.QContextMenuEvent) None
contextMenuPolicy(self) PySide2.QtCore.Qt.ContextMenuPolicy
correctionMode(self) PySide2.QtWidgets.QAbstractSpinBox.CorrectionMode
create(self, arg__1: int = 0, initializeWindow: bool = True, destroyOldWindow: bool = True) None
createWinId(self) None
static createWindowContainer(window: PySide2.QtGui.QWindow, parent: Optional[PySide2.QtWidgets.QWidget] = None, flags: PySide2.QtCore.Qt.WindowFlags = Default(Qt.WindowFlags)) PySide2.QtWidgets.QWidget
cursor(self) PySide2.QtGui.QCursor
customContextMenuRequested

!! processed by numpydoc !!

customEvent(self, event: PySide2.QtCore.QEvent) None
decimals()[source]
deleteLater(self) None
depth(self) int
destroy(self, destroyWindow: bool = True, destroySubWindows: bool = True) None
destroyed

!! processed by numpydoc !!

devType(self) int
devicePixelRatio(self) int
devicePixelRatioF(self) float
static devicePixelRatioFScale() float
static disconnect(arg__1: PySide2.QtCore.QMetaObject.Connection) bool
static disconnect(arg__1: PySide2.QtCore.QObject, arg__2: bytes, arg__3: Callable) bool
static disconnect(self, arg__1: bytes, arg__2: Callable) bool
static disconnect(self, receiver: PySide2.QtCore.QObject, member: Optional[bytes] = None) bool
static disconnect(self, signal: bytes, receiver: PySide2.QtCore.QObject, member: bytes) bool
static disconnect(sender: PySide2.QtCore.QObject, signal: PySide2.QtCore.QMetaMethod, receiver: PySide2.QtCore.QObject, member: PySide2.QtCore.QMetaMethod) bool
static disconnect(sender: PySide2.QtCore.QObject, signal: bytes, receiver: PySide2.QtCore.QObject, member: bytes) bool
disconnectNotify(self, signal: PySide2.QtCore.QMetaMethod) None
dragEnterEvent(self, event: PySide2.QtGui.QDragEnterEvent) None
dragLeaveEvent(self, event: PySide2.QtGui.QDragLeaveEvent) None
dragMoveEvent(self, event: PySide2.QtGui.QDragMoveEvent) None
dropEvent(self, event: PySide2.QtGui.QDropEvent) None
dumpObjectInfo(self) None
dumpObjectTree(self) None
dynamicPropertyNames(self) List[PySide2.QtCore.QByteArray]
property dynamic_precision

Flag indicating whether dynamic decimal precision should be used based on user input.

Returns:
bool

True to use dynamic decimal precision, False to use fixed precision.

property dynamic_stepping

Flag indicating whether dynamic (logarithmic) stepping should be used or fixed steps.

Returns:
bool

True if dynamic stepping is enabled, False otherwise.

editingFinished

!! processed by numpydoc !!

effectiveWinId(self) int
emit(self, arg__1: bytes, *args: None) bool
ensurePolished(self) None
enterEvent(self, event: PySide2.QtCore.QEvent) None
event(self, event: PySide2.QtCore.QEvent) bool
eventFilter(self, watched: PySide2.QtCore.QObject, event: PySide2.QtCore.QEvent) bool
static find(arg__1: int) PySide2.QtWidgets.QWidget
findChild(self, arg__1: type, arg__2: str = '') object
findChildren(self, arg__1: type, arg__2: PySide2.QtCore.QRegExp) Iterable
findChildren(self, arg__1: type, arg__2: PySide2.QtCore.QRegularExpression) Iterable
findChildren(self, arg__1: type, arg__2: str = '') Iterable
fixup(text)[source]

Takes an invalid string and tries to fix it in order to pass validation. The returned string is not guaranteed to pass validation.

Parameters:
textstr

A string that has not passed validation and needs to be fixed.

Returns:
str

The resulting string from the fix attempt.

focusInEvent(self, event: PySide2.QtGui.QFocusEvent) None[source]
focusNextChild(self) bool
focusNextPrevChild(self, next: bool) bool
focusOutEvent(self, event: PySide2.QtGui.QFocusEvent) None[source]
focusPolicy(self) PySide2.QtCore.Qt.FocusPolicy
focusPreviousChild(self) bool
focusProxy(self) PySide2.QtWidgets.QWidget
focusWidget(self) PySide2.QtWidgets.QWidget
font(self) PySide2.QtGui.QFont
fontInfo(self) PySide2.QtGui.QFontInfo
fontMetrics(self) PySide2.QtGui.QFontMetrics
foregroundRole(self) PySide2.QtGui.QPalette.ColorRole
frameGeometry(self) PySide2.QtCore.QRect
frameSize(self) PySide2.QtCore.QSize
geometry(self) PySide2.QtCore.QRect
getContentsMargins(self) Tuple[int, int, int, int]
grab(self, rectangle: PySide2.QtCore.QRect = PySide2.QtCore.QRect(0, 0, -1, -1)) PySide2.QtGui.QPixmap
grabGesture(self, type: PySide2.QtCore.Qt.GestureType, flags: PySide2.QtCore.Qt.GestureFlags = Default(Qt.GestureFlags)) None
grabKeyboard(self) None
grabMouse(self) None
grabMouse(self, arg__1: PySide2.QtGui.QCursor) None
grabShortcut(self, key: PySide2.QtGui.QKeySequence, context: PySide2.QtCore.Qt.ShortcutContext = PySide2.QtCore.Qt.ShortcutContext.WindowShortcut) int
graphicsEffect(self) PySide2.QtWidgets.QGraphicsEffect
graphicsProxyWidget(self) PySide2.QtWidgets.QGraphicsProxyWidget
hasAcceptableInput(self) bool
hasFocus(self) bool
hasFrame(self) bool
hasHeightForWidth(self) bool
hasMouseTracking(self) bool
hasTabletTracking(self) bool
height(self) int
heightForWidth(self, arg__1: int) int
heightMM(self) int
hide(self) None
hideEvent(self, event: PySide2.QtGui.QHideEvent) None
inherits(self, classname: bytes) bool
initPainter(self, painter: PySide2.QtGui.QPainter) None
initStyleOption(self, option: PySide2.QtWidgets.QStyleOptionSpinBox) None
inputMethodEvent(self, event: PySide2.QtGui.QInputMethodEvent) None
inputMethodHints(self) PySide2.QtCore.Qt.InputMethodHints
inputMethodQuery(self, arg__1: PySide2.QtCore.Qt.InputMethodQuery) Any
insertAction(self, before: PySide2.QtWidgets.QAction, action: PySide2.QtWidgets.QAction) None
insertActions(self, before: PySide2.QtWidgets.QAction, actions: Sequence[PySide2.QtWidgets.QAction]) None
installEventFilter(self, filterObj: PySide2.QtCore.QObject) None
internalWinId(self) int
interpretText(self) None
isAccelerated(self) bool
isActiveWindow(self) bool
isAncestorOf(self, child: PySide2.QtWidgets.QWidget) bool
isEnabled(self) bool
isEnabledTo(self, arg__1: PySide2.QtWidgets.QWidget) bool
isEnabledToTLW(self) bool
isFullScreen(self) bool
isGroupSeparatorShown(self) bool
isHidden(self) bool
isLeftToRight(self) bool
isMaximized(self) bool
isMinimized(self) bool
isModal(self) bool
isReadOnly(self) bool
isRightToLeft(self) bool
isSignalConnected(self, signal: PySide2.QtCore.QMetaMethod) bool
isTopLevel(self) bool
isVisible(self) bool
isVisibleTo(self, arg__1: PySide2.QtWidgets.QWidget) bool
isWidgetType(self) bool
isWindow(self) bool
isWindowModified(self) bool
isWindowType(self) bool
property is_valid

Flag indicating if the currently available value is valid.

Returns:
bool

True if the current value is valid, False otherwise. Returns False if there has been an attempt to set NaN as the current value; True after a valid value has been set.

keyPressEvent(event)[source]

This method catches all keyboard press events triggered by the user.

Can be used to alter the behaviour of certain key events from the default implementation of QAbstractSpinBox.

Parameters:
eventQKeyEvent

A Qt QKeyEvent instance holding the event information

keyReleaseEvent(self, event: PySide2.QtGui.QKeyEvent) None
static keyboardGrabber() PySide2.QtWidgets.QWidget
keyboardTracking(self) bool
killTimer(self, id: int) None
layout(self) PySide2.QtWidgets.QLayout
layoutDirection(self) PySide2.QtCore.Qt.LayoutDirection
leaveEvent(self, event: PySide2.QtCore.QEvent) None
lineEdit(self) PySide2.QtWidgets.QLineEdit
locale(self) PySide2.QtCore.QLocale
logicalDpiX(self) int
logicalDpiY(self) int
lower(self) None
mapFrom(self, arg__1: PySide2.QtWidgets.QWidget, arg__2: PySide2.QtCore.QPoint) PySide2.QtCore.QPoint
mapFromGlobal(self, arg__1: PySide2.QtCore.QPoint) PySide2.QtCore.QPoint
mapFromParent(self, arg__1: PySide2.QtCore.QPoint) PySide2.QtCore.QPoint
mapTo(self, arg__1: PySide2.QtWidgets.QWidget, arg__2: PySide2.QtCore.QPoint) PySide2.QtCore.QPoint
mapToGlobal(self, arg__1: PySide2.QtCore.QPoint) PySide2.QtCore.QPoint
mapToParent(self, arg__1: PySide2.QtCore.QPoint) PySide2.QtCore.QPoint
mask(self) PySide2.QtGui.QRegion
maximum()[source]
maximumHeight(self) int
maximumSize(self) PySide2.QtCore.QSize
maximumWidth(self) int
metaObject(self) PySide2.QtCore.QMetaObject
metric(self, arg__1: PySide2.QtGui.QPaintDevice.PaintDeviceMetric) int
minimalStep()[source]
minimum()[source]
minimumHeight(self) int
minimumSize(self) PySide2.QtCore.QSize
minimumSizeHint(self) PySide2.QtCore.QSize
minimumWidth(self) int
mouseDoubleClickEvent(self, event: PySide2.QtGui.QMouseEvent) None
static mouseGrabber() PySide2.QtWidgets.QWidget
mouseMoveEvent(self, event: PySide2.QtGui.QMouseEvent) None
mousePressEvent(self, event: PySide2.QtGui.QMouseEvent) None
mouseReleaseEvent(self, event: PySide2.QtGui.QMouseEvent) None
move(self, arg__1: PySide2.QtCore.QPoint) None
move(self, x: int, y: int) None
moveEvent(self, event: PySide2.QtGui.QMoveEvent) None
moveToThread(self, thread: PySide2.QtCore.QThread) None
nativeEvent(self, eventType: PySide2.QtCore.QByteArray, message: int) Tuple[bool, int]
nativeParentWidget(self) PySide2.QtWidgets.QWidget
nextInFocusChain(self) PySide2.QtWidgets.QWidget
normalGeometry(self) PySide2.QtCore.QRect
objectName(self) str
objectNameChanged

!! processed by numpydoc !!

overrideWindowFlags(self, type: PySide2.QtCore.Qt.WindowFlags) None
overrideWindowState(self, state: PySide2.QtCore.Qt.WindowStates) None
paintEngine(self) PySide2.QtGui.QPaintEngine
paintEvent(ev)[source]

Add drawing of a red frame around the spinbox if the is_valid flag is False

painters

!! processed by numpydoc !!

paintingActive(self) bool
palette(self) PySide2.QtGui.QPalette
parent(self) PySide2.QtCore.QObject
parentWidget(self) PySide2.QtWidgets.QWidget
physicalDpiX(self) int
physicalDpiY(self) int
pos(self) PySide2.QtCore.QPoint
prefix()[source]
previousInFocusChain(self) PySide2.QtWidgets.QWidget
property(self, name: bytes) Any
raise_(self) None
receivers(self, signal: bytes) int
rect(self) PySide2.QtCore.QRect
redirected(self, offset: PySide2.QtCore.QPoint) PySide2.QtGui.QPaintDevice
static registerUserData() int
releaseKeyboard(self) None
releaseMouse(self) None
releaseShortcut(self, id: int) None
removeAction(self, action: PySide2.QtWidgets.QAction) None
removeEventFilter(self, obj: PySide2.QtCore.QObject) None
render(self, painter: PySide2.QtGui.QPainter, targetOffset: PySide2.QtCore.QPoint, sourceRegion: PySide2.QtGui.QRegion = Default(QRegion), renderFlags: PySide2.QtWidgets.QWidget.RenderFlags = Instance(QWidget.RenderFlags(QWidget.DrawWindowBackground | QWidget.DrawChildren))) None
render(self, target: PySide2.QtGui.QPaintDevice, targetOffset: PySide2.QtCore.QPoint = Default(QPoint), sourceRegion: PySide2.QtGui.QRegion = Default(QRegion), renderFlags: PySide2.QtWidgets.QWidget.RenderFlags = Instance(QWidget.RenderFlags(QWidget.DrawWindowBackground | QWidget.DrawChildren))) None
repaint(self) None
repaint(self, arg__1: PySide2.QtCore.QRect) None
repaint(self, arg__1: PySide2.QtGui.QRegion) None
repaint(self, x: int, y: int, w: int, h: int) None
resize(self, arg__1: PySide2.QtCore.QSize) None
resize(self, w: int, h: int) None
resizeEvent(self, event: PySide2.QtGui.QResizeEvent) None
restoreGeometry(self, geometry: PySide2.QtCore.QByteArray) bool
saveGeometry(self) PySide2.QtCore.QByteArray
screen(self) PySide2.QtGui.QScreen
scroll(self, dx: int, dy: int) None
scroll(self, dx: int, dy: int, arg__3: PySide2.QtCore.QRect) None
selectAll(self) None[source]
sender(self) PySide2.QtCore.QObject
senderSignalIndex(self) int
setAccelerated(self, on: bool) None
setAcceptDrops(self, on: bool) None
setAccessibleDescription(self, description: str) None
setAccessibleName(self, name: str) None
setAlignment(self, flag: PySide2.QtCore.Qt.Alignment) None
setAttribute(self, arg__1: PySide2.QtCore.Qt.WidgetAttribute, on: bool = True) None
setAutoFillBackground(self, enabled: bool) None
setBackgroundRole(self, arg__1: PySide2.QtGui.QPalette.ColorRole) None
setBaseSize(self, arg__1: PySide2.QtCore.QSize) None
setBaseSize(self, basew: int, baseh: int) None
setButtonSymbols(self, bs: PySide2.QtWidgets.QAbstractSpinBox.ButtonSymbols) None
setContentsMargins(self, left: int, top: int, right: int, bottom: int) None
setContentsMargins(self, margins: PySide2.QtCore.QMargins) None
setContextMenuPolicy(self, policy: PySide2.QtCore.Qt.ContextMenuPolicy) None
setCorrectionMode(self, cm: PySide2.QtWidgets.QAbstractSpinBox.CorrectionMode) None
setCursor(self, arg__1: PySide2.QtGui.QCursor) None
setDecimals(decimals, dynamic_precision=True)[source]

Set the number of displayed digits after the decimal point and specify dynamic precision.

Parameters:
decimalsint

The number of decimals to be displayed.

dynamic_precisionbool

Flag indicating whether dynamic precision functionality should be used: - If True, the number of decimals will be determined dynamically from user input until

explicitly set by calling this method or entering user text.

  • If False, the specified number of decimals will be fixed and will not change automatically.

Returns:
None
setDisabled(self, arg__1: bool) None
setEnabled(self, arg__1: bool) None
setFixedHeight(self, h: int) None
setFixedSize(self, arg__1: PySide2.QtCore.QSize) None
setFixedSize(self, w: int, h: int) None
setFixedWidth(self, w: int) None
setFocus(self) None
setFocus(self, reason: PySide2.QtCore.Qt.FocusReason) None
setFocusPolicy(self, policy: PySide2.QtCore.Qt.FocusPolicy) None
setFocusProxy(self, arg__1: PySide2.QtWidgets.QWidget) None
setFont(self, arg__1: PySide2.QtGui.QFont) None
setForegroundRole(self, arg__1: PySide2.QtGui.QPalette.ColorRole) None
setFrame(self, arg__1: bool) None
setGeometry(self, arg__1: PySide2.QtCore.QRect) None
setGeometry(self, x: int, y: int, w: int, h: int) None
setGraphicsEffect(self, effect: PySide2.QtWidgets.QGraphicsEffect) None
setGroupSeparatorShown(self, shown: bool) None
setHidden(self, hidden: bool) None
setInputMethodHints(self, hints: PySide2.QtCore.Qt.InputMethodHints) None
setKeyboardTracking(self, kt: bool) None
setLayout(self, arg__1: PySide2.QtWidgets.QLayout) None
setLayoutDirection(self, direction: PySide2.QtCore.Qt.LayoutDirection) None
setLineEdit(self, edit: PySide2.QtWidgets.QLineEdit) None
setLocale(self, locale: PySide2.QtCore.QLocale) None
setMask(self, arg__1: PySide2.QtGui.QBitmap) None
setMask(self, arg__1: PySide2.QtGui.QRegion) None
setMaximum(maximum)[source]

Setter method to set the maximum value allowed in the SpinBox.

Parameters:
maximumfloat

The maximum value to be set. Input will be converted to float before being stored.

setMaximumHeight(self, maxh: int) None
setMaximumSize(self, arg__1: PySide2.QtCore.QSize) None
setMaximumSize(self, maxw: int, maxh: int) None
setMaximumWidth(self, maxw: int) None
setMinimalStep(step)[source]

Method used to set a minimal step size.

When the absolute step size has been calculated in either dynamic or constant step mode, this value is checked against the minimal step size. If it is smaller then the minimal step size is chosen over the calculated step size. This ensures that no step taken can be smaller than minimalStep.

Set this value to 0 for no minimal step size.

For maximum roboustness and consistency it is strongly recommended to pass step as Decimal or string in order to be converted lossless to Decimal.

Parameters:
stepDecimal|str

The minimal step size to be set.

Returns:
None
setMinimum(minimum)[source]

Setter method to set the minimum value allowed in the SpinBox.

Parameters:
minimumfloat

The minimum value to be set. Input will be converted to float before being stored.

setMinimumHeight(self, minh: int) None
setMinimumSize(self, arg__1: PySide2.QtCore.QSize) None
setMinimumSize(self, minw: int, minh: int) None
setMinimumWidth(self, minw: int) None
setMouseTracking(self, enable: bool) None
setObjectName(self, name: str) None
setPalette(self, arg__1: PySide2.QtGui.QPalette) None
setParent(self, parent: PySide2.QtCore.QObject) None
setParent(self, parent: PySide2.QtWidgets.QWidget) None
setParent(self, parent: PySide2.QtWidgets.QWidget, f: PySide2.QtCore.Qt.WindowFlags) None
setPrefix(prefix)[source]

Set a string to be shown as non-editable prefix in the spinbox.

Parameters:
prefixstr

The prefix string to be displayed.

Returns:
None
setProperty(prop, val)[source]

For compatibility with QtDesigner. Initializes the value through this method.

Parameters:
proptype

Description of the parameter ‘prop’.

valtype

Description of the parameter ‘val’.

setRange(minimum, maximum)[source]

Convenience method for compliance with Qt SpinBoxes. Essentially a wrapper to call both self.setMinimum and self.setMaximum.

Parameters:
minimumfloat

The minimum value to be set.

maximumfloat

The maximum value to be set.

setReadOnly(self, r: bool) None
setShortcutAutoRepeat(self, id: int, enable: bool = True) None
setShortcutEnabled(self, id: int, enable: bool = True) None
setSingleStep(step, dynamic_stepping=True)[source]

Set the stepping behavior of the spinbox (e.g., when using the mouse wheel).

When dynamic_stepping=True, the spinbox will perform logarithmic steps according to the current order of magnitude of the values. The step parameter then specifies the step size relative to the value’s order of magnitude. For example, step=0.1 would increment the second most significant digit by one.

When dynamic_stepping=False, the step parameter specifies an absolute step size. This means that each time a step is performed, this value is added or subtracted from the current value.

For maximum robustness and consistency, it is strongly recommended to pass step as a Decimal or string to ensure lossless conversion to Decimal.

Parameters:
stepDecimal or str

The (relative) step size to set. For dynamic_stepping=True, this is relative to the order of magnitude of the current value. For dynamic_stepping=False, this is an absolute step size.

dynamic_steppingbool

Flag indicating the use of dynamic stepping (True) or constant stepping (False).

Returns:
None
setSizeIncrement(self, arg__1: PySide2.QtCore.QSize) None
setSizeIncrement(self, w: int, h: int) None
setSizePolicy(self, arg__1: PySide2.QtWidgets.QSizePolicy) None
setSizePolicy(self, horizontal: PySide2.QtWidgets.QSizePolicy.Policy, vertical: PySide2.QtWidgets.QSizePolicy.Policy) None
setSpecialValueText(self, txt: str) None
setStatusTip(self, arg__1: str) None
setStyle(self, arg__1: PySide2.QtWidgets.QStyle) None
setStyleSheet(self, styleSheet: str) None
setSuffix(suffix)[source]

Set a string to be shown as non-editable suffix in the spinbox. This suffix will come right after the si-prefix.

Parameters:
suffixstr

The suffix string to be displayed after the si-prefix.

Returns:
None
static setTabOrder(arg__1: PySide2.QtWidgets.QWidget, arg__2: PySide2.QtWidgets.QWidget) None
setTabletTracking(self, enable: bool) None
setToolTip(self, arg__1: str) None
setToolTipDuration(self, msec: int) None
setUpdatesEnabled(self, enable: bool) None
setValue(value)[source]

Setter method to programmatically set the current value. For best robustness pass the value as string or Decimal in order to be lossless cast into Decimal. Will perform range checking and ignore NaN values. Will emit valueChanged if the new value is different from the old one. When using dynamic decimals precision, this method will also try to invoke the optimal display precision by checking for a change in the displayed text.

setVisible(self, visible: bool) None
setWhatsThis(self, arg__1: str) None
setWindowFilePath(self, filePath: str) None
setWindowFlag(self, arg__1: PySide2.QtCore.Qt.WindowType, on: bool = True) None
setWindowFlags(self, type: PySide2.QtCore.Qt.WindowFlags) None
setWindowIcon(self, icon: PySide2.QtGui.QIcon) None
setWindowIconText(self, arg__1: str) None
setWindowModality(self, windowModality: PySide2.QtCore.Qt.WindowModality) None
setWindowModified(self, arg__1: bool) None
setWindowOpacity(self, level: float) None
setWindowRole(self, arg__1: str) None
setWindowState(self, state: PySide2.QtCore.Qt.WindowStates) None
setWindowTitle(self, arg__1: str) None
setWrapping(self, w: bool) None
sharedPainter(self) PySide2.QtGui.QPainter
show(self) None
showEvent(self, event: PySide2.QtGui.QShowEvent) None
showFullScreen(self) None
showMaximized(self) None
showMinimized(self) None
showNormal(self) None
signalsBlocked(self) bool
singleStep()[source]
size(self) PySide2.QtCore.QSize
sizeHint(self) PySide2.QtCore.QSize
sizeIncrement(self) PySide2.QtCore.QSize
sizePolicy(self) PySide2.QtWidgets.QSizePolicy
specialValueText(self) str
stackUnder(self, arg__1: PySide2.QtWidgets.QWidget) None
startTimer(self, interval: int, timerType: PySide2.QtCore.Qt.TimerType = PySide2.QtCore.Qt.TimerType.CoarseTimer) int
staticMetaObject = <PySide2.QtCore.QMetaObject object>
statusTip(self) str
stepBy(steps)[source]

This method is responsible for incrementing the value of the SpinBox when the user triggers a step (by pressing PgUp/PgDown/Up/Down, MouseWheel movement or clicking on the arrows). It should handle the case when the new to-set value is out of bounds. Also, the absolute value of a single step increment should be handled here. It is essential to avoid accumulating rounding errors and/or discrepancies between self.value and the displayed text.

Parameters:
stepsint

Number of steps to increment (NOT the absolute step size).

stepDown(self) None
stepEnabled()[source]

Enables stepping (mouse wheel, arrow up/down, clicking, PgUp/Down) by default.

stepUp(self) None
style(self) PySide2.QtWidgets.QStyle
styleSheet(self) str
suffix()[source]
tabletEvent(self, event: PySide2.QtGui.QTabletEvent) None
testAttribute(self, arg__1: PySide2.QtCore.Qt.WidgetAttribute) bool
text(self) str
textFromValue(value)[source]

This method is responsible for the mapping of the underlying value to a string to display in the SpinBox. Suffix and Prefix must not be handled here, just the si-Prefix.

The main problem here is, that a scaled float with a suffix is represented by a different machine precision than the total value. This method is so complicated because it represents the actual precision of the value as float and not the precision of the scaled si float. ‘{:.20f}’.format(value) shows different digits than ‘{:.20f} {}’.format(scaled_value, si_prefix)

Parameters:
valuefloat or decimal.Decimal

The numeric value to be formatted into a string.

Returns:
str

The formatted string representing the input value.

thread(self) PySide2.QtCore.QThread
timerEvent(self, event: PySide2.QtCore.QTimerEvent) None
toolTip(self) str
toolTipDuration(self) int
topLevelWidget(self) PySide2.QtWidgets.QWidget
tr(self, arg__1: bytes, arg__2: bytes = b'', arg__3: int = -1) str
underMouse(self) bool
ungrabGesture(self, type: PySide2.QtCore.Qt.GestureType) None
unsetCursor(self) None
unsetLayoutDirection(self) None
unsetLocale(self) None
update(self) None
update(self, arg__1: PySide2.QtCore.QRect) None
update(self, arg__1: PySide2.QtGui.QRegion) None
update(self, x: int, y: int, w: int, h: int) None
updateGeometry(self) None
updateMicroFocus(self) None
update_display()[source]

This helper method updates the shown text based on the current value. Because this method is only called upon finishing an editing procedure, the eventually cached value gets deleted.

update_value()[source]

This method will grab the currently shown text from the QLineEdit and interpret it. Range checking is performed on the value afterwards. If a valid value can be derived, it will set this value as the current value (if it has changed) and emit the valueChanged signal. Note that the comparison between old and new value is done by comparing the float representations of both values and not by comparing them as Decimals. The valueChanged signal will only emit if the actual float representation has changed since Decimals are only internally used and the rest of the program won’t notice a slight change in the Decimal that can’t be resolved in a float. In addition it will cache the old value provided the cache is empty to be able to restore it later on.

updatesEnabled(self) bool
validate(text, position)[source]

Access method to the validator. See FloatValidator class for more information.

Parameters:
textstr

String to be validated.

positionint

Current text cursor position.

Returns:
QValidator::State

The returned validator state.

str

The input string.

int

The cursor position.

value()[source]

Getter method to obtain the current value as float.

Returns:
float

The current value of the SpinBox as a float.

valueChanged

!! processed by numpydoc !!

valueFromText(text, use_assumed_unit_prefix=False)[source]

Convert a string displayed in the SpinBox into a Decimal value.

The input string is already stripped of prefix and suffix. Only the si-prefix may be present.

Parameters:
textstr

The display string to be converted into a numeric value. This string must conform to the validator.

Returns:
Decimal

The numeric value converted from the input string.

visibleRegion(self) PySide2.QtGui.QRegion
whatsThis(self) str
wheelEvent(event)[source]

Overwriting wheel event, such that with the class variable disable_wheel = True the stepping with the mouse wheel is turned off and the wheel event is passed to the parent widget. :param event:

width(self) int
widthMM(self) int
winId(self) int
window(self) PySide2.QtWidgets.QWidget
windowFilePath(self) str
windowFlags(self) PySide2.QtCore.Qt.WindowFlags
windowHandle(self) PySide2.QtGui.QWindow
windowIcon(self) PySide2.QtGui.QIcon
windowIconChanged

!! processed by numpydoc !!

windowIconText(self) str
windowIconTextChanged

!! processed by numpydoc !!

windowModality(self) PySide2.QtCore.Qt.WindowModality
windowOpacity(self) float
windowRole(self) str
windowState(self) PySide2.QtCore.Qt.WindowStates
windowTitle(self) str
windowTitleChanged

!! processed by numpydoc !!

windowType(self) PySide2.QtCore.Qt.WindowType
wrapping(self) bool
x(self) int
y(self) int