GUI API
Last updated
Last updated
QtBind
is what I have decided to call my small Python -> Qt wrapper. It creates a translation layer between Python and C++ for the GUI.
Initializes the GUI. Only call this when the module first loads. You must save the return value in order to create widgets on the interface. You must keep the module name as __name__
. This is so GUI events are passed to the script.
Creates a button on the UI. The callback parameter is a string containing your function name.
Creates a check box on the UI. The callback parameter is a string containing your function name. The callback will be passed the check state. True/False.
Creates a label on the UI.
Creates a line edit on the UI. To get the text a user has typed in the box, use the text()
function.
Creates a list widget on the UI. To get the current selected item text, use the text()
function.
Creates a combox on the UI. To get the current selected item text, use the text()
function.
Sets the text of a widget.
Sets the checked state of a check box.
Returns the text of a widget. Or returns the current selected item text in a list widget.
Destroys a widget.
Moves a widget.
Returns the checked state of a check box. Do NOT call this function on anything but a check box!
Erases the text in a widget or clears the entire widget if it is a list widget.
Appends text to a list widget.
Returns the currently selected index of a list widget.
Removes all items with the value specified in a list widget.
Removes an item at a specified index in a list widget.
Returns a list of all items in a list widget.