IntEdit (hwx.gui)¶
A widget that can display/edit an integer.
- Inherits:
Properties¶
Public Methods¶
addChildren (self, children)
destroy (self)
enableGlobalActions (self, enable)
get (self)
getMousePosition (self)
getRelativeMousePosition (self)
hide (self)
saveAsPng (self, fname)
setF1HelpTopic (self, helptopic)
setProperties (self, kwds)
show (self)
validate (self, widget)
Property Details¶
- property maxValue¶
The upper bound of the IntEdit
- property minValue¶
The lower bound of the IntEdit
Method Details¶
- addChildren(self, children)¶
Add child widgets/layouts into this widget.
Widget children get layed out using a VBoxLayout.
Typically, you’ll pass the parent/children into the constructor instead of calling this function directly.
- param children
- type children
list[Widget] | Layout
- 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
- get(self)¶
Overloaded method that returns the value as in integer.
- 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.
- show(self)¶
Shows the widget.
- validate(self, widget)¶
Validates whether the value entered is an integer and in [minValue, maxValue] range.
- param widget
The widget where the value is entered.
- type widget
Widget
- returns
True if the widget value entered is an int, otherwise False.
- rtype
bool