Popdown Labels

Popdown labels are labels that are shown with a menu indicator arrow, and that can be clicked to show a menu with certain menu items.

The classes listed here are all derived from QT4Widgets.PopdownLabel. Each class defines a buildMenu() function that populates the respective menu when a label defined by the respective class has been clicked.

UI4.Widgets.AssetIDLabel

class UI4.Widgets.AssetIDLabel

Bases: PopdownLabel

Class implementing a “popdown label” (label which shows a menu when clicked) for use in the application’s main menu bar for showing which asset is currently loaded. When clicked, the label shows a menu allowing the user to copy the asset ID or underlying filesystem path to the clipboard.

Example Screenshot:

Screenshot of an AssetIDLabel widget

__init__(parent=None)

Initializes an instance of the class.

Parameters:

parent (QtWidgets.QWidget or None) – The parent widget to own the new instance. Passed verbatim to the base class initializer.

buildMenu(menu)

Called by PopdownLabel to add items to the menu that is shown when clicking the widget.

Parameters:

menu (QtWidgets.QMenu) – The menu to add items to.

UI4.Widgets.ProxyResCombo

class UI4.Widgets.ProxyResCombo

Bases: PopdownLabel

Example Screenshot:

Screenshot of a ProxyResCombo widget

__init__(*args)
buildMenu(menu)

Called by PopdownLabel to add items to the menu that is shown when clicking the widget.

Parameters:

menu (QtWidgets.QMenu) – The menu to add items to.

updateState()

UI4.Widgets.RoiCombo

class UI4.Widgets.RoiCombo

Bases: PopdownLabel

Example Screenshot:

Screenshot of a RoiCombo widget

__init__(parent)
buildMenu(menu)

Called by PopdownLabel to add items to the menu that is shown when clicking the widget.

Parameters:

menu (QtWidgets.QMenu) – The menu to add items to.

getRoiVisible()
roiVisibilityChanged

pyqtSignal(*types, name: str = …, revision: int = …, arguments: Sequence = …) -> PYQT_SIGNAL

types is normally a sequence of individual types. Each type is either a type object or a string that is the name of a C++ type. Alternatively each type could itself be a sequence of types each describing a different overloaded signal. name is the optional C++ name of the signal. If it is not specified then the name of the class attribute that is bound to the signal is used. revision is the optional revision of the signal that is exported to QML. If it is not specified then 0 is used. arguments is the optional sequence of the names of the signal’s arguments.

setRoiVisible(isVisible)
updateState()