SpinBox (hwx.gui)

A SpinBox Widget.

SpinBox allows to choose a value by clicking the up/down buttons or pressing up/down on the keyboard to increase/decrease the displayed value.

The upper and lower bounds are defined by the min and max properties. The user can also type the value manually. The SpinBox supports integer values and invokes the callback command every time the value is changed.

Inherits:

Properties

Public Methods

destroy (self)
enableGlobalActions (self, enable)
getMousePosition (self)
getRelativeMousePosition (self)
hide (self)
saveAsPng (self, fname)
setF1HelpTopic (self, helptopic)
setProperties (self, kwds)
setValue (self, value)
show (self)

Property Details

The maximum integer value.

The minimum integer value.

The text that appears before the int.

The value by which SpinBox is increased/decreased when you click the arrows.

The text that appears after the int.

Method Details

destroy(self)

Deletes this and all its children.

enableGlobalActions(self, enable)

Sets the state of Global Actions.

Disable the global actions to get key events.

param enable:Determines whether to enable or disable global actions.
type enable:bool
getMousePosition(self)

Returns the mouse position.

getRelativeMousePosition(self)

Returns the mouse position relative to this widget.

hide(self)

Hides the widget.

saveAsPng(self, fname)

Saves the widget as a .png file.

param fname:The file name for the .png
type fname:str
returns:True if it was saved succesfully, False otherwise.
rtype:bool
setF1HelpTopic(self, helptopic)

Popup web-browser helps when the user hits F1 when over this.

param helptopic:
 Topic name user needs help in.
type helptopic:str
setProperties(self, kwds)

Internal method called from constructors.

setValue(self, value)

Sets the specified value after converting it into an integer.

param value:The numeric value to be set for the SpinBox.
type value:int
show(self)

Shows the widget.