Base Widgets¶
This file contains the definitions of the fundamental widgets upon which all other QtPyVCP widgets are based.
-
class
qtpyvcp.widgets.base_widgets.base_widget.
ChanList
[source]¶ Channel value list.
This list is intended to hold lambda functions for retrieving the current data channel values. When the list is indexed the function is called and the resulting value is returned.
-
class
qtpyvcp.widgets.base_widgets.base_widget.
VCPPrimitiveWidget
(parent=None)[source]¶ VCPPrimitiveWidget.
Class on which all QtPyVCP widgets should be based.
-
class
qtpyvcp.widgets.base_widgets.base_widget.
VCPBaseWidget
(parent=None)[source]¶ QtPyVCP Base Widget.
This class handles the rules and other things that apply to QtPyVCP widgets regardless of use.
-
style
¶ QSS style class selector property.
This property can be changed dynamically to update the QSS style applied to the widget.
Example
The
style
property can be used as a selector in QSS to apply different styles depending on the value./* This will be applied when the `style` is set to "error" */ WidgetClass[style="error"] { color: red; } /* This will be applied when the `style` is not set */ WidgetClass { color: black; }
Returns: str
-
rules
¶ JSON formatted list of dictionaries, defining the widget rules.
Returns: str
-
-
class
qtpyvcp.widgets.base_widgets.base_widget.
VCPWidget
(parent=None)[source]¶ VCP Widget
This is a general purpose widget for displaying data and other uses that do not involve user interaction.
-
class
qtpyvcp.widgets.base_widgets.base_widget.
CMDWidget
(parent=None)[source]¶ Command Widget
This widget should be used as the base class for all widgets that control the machine. Eventually additional functionality will be added to this class.
-
class
qtpyvcp.widgets.base_widgets.base_widget.
HALWidget
(parent=None)[source]¶ HAL Widget
This widget should be used as the base class for HAL widgets. ToDo: Implement HAL functionality.
-
pinBaseName
¶ The base name to use for the generated HAL pins.
If not specified the widgets objectName will be used.
Returns: str
-