Tool Box Widget (toolbox)¶
Tool Box Widget¶
A reimplementation of the QToolBox widget that keeps all the tabs
in a single QScrollArea instance and can keep multiple open tabs.
-
class
orangecanvas.gui.toolbox.ToolBox(parent=None, **kwargs)¶ Bases:
PyQt4.QtGui.QFrameA tool box widget.
-
tabToogled(index, state)¶ Signal emitted when a tab at index is toggled.
-
setExclusive(exclusive)¶ Set exclusive tabs (only one tab can be open at a time).
-
exclusive()¶ Are the tabs in the toolbox exclusive.
-
exclusive_¶ Exclusive tabs
-
setTabButtonHeight(height)¶ Set the tab button height.
-
tabButtonHeight()¶ Return the tab button height.
-
setTabIconSize(size)¶ Set the tab button icon size.
-
tabIconSize()¶ Return the tab icon size.
-
tabButton(index)¶ Return the tab button at index
-
tabAction(index)¶ Return open/close action for the tab at index.
-
addItem(widget, text, icon=None, toolTip=None)¶ Append the widget in a new tab and return its index.
Parameters: - widget (
QWidget) – A widget to be inserted. The toolbox takes ownership of the widget. - text (str) – Name/title of the new tab.
- icon (
QIcon, optional) – An icon for the tab button. - toolTip (str, optional) – Tool tip for the tab button.
- widget (
-
insertItem(index, widget, text, icon=None, toolTip=None)¶ Insert the widget in a new tab at position index.
See also
-
removeItem(index)¶ Remove the widget at index.
Note
The widget hidden but is is not deleted.
-
count()¶ Return the number of widgets inserted in the toolbox.
-
widget(index)¶ Return the widget at index.
-
createTabButton(widget, text, icon=None, toolTip=None)¶ Create the tab button for widget.
-
ensureWidgetVisible(child, xmargin=50, ymargin=50)¶ Scroll the contents so child widget instance is visible inside the viewport.
-