TabDockButton

A simple push button to open pydm screens in the TabDock widget.

../../../_images/tab_dock_button.png
class pcdswidgets.common.dock.tab_dock_button.TabDockButton(parent: QWidget | None = None)[source]

A QPushButton that opens a PyDM screen in the TabDock when clicked.

The user must set the “filename” property to the path of the screen to use, and may optionally set the “macro” property to the macro string used to substitute values into the fields.

Parameters:

parent (QWidget, optional) – Standard qt parent argument

class ScreenSource(*values)

Options for how we should interpret the filename and macro properties.

build_widget() → QWidget[source]

Create the widget and return it, or re-use an existing widget if possible.

build_widget_from_filepath(is_screen_name: bool) → QWidget[source]

Create or re-use the widget defined by the pydm file.

build_widget_from_widget_name() → QWidget[source]

Create the named widget from pcdswidgets.

contextMenuEvent(event: QContextMenuEvent) → None[source]

On right-click, open a menu to decide where the widget should go.

enterEvent(self, a0: Optional[QEvent])[source]
open_in_dock()[source]

Place the widget defined by this button into the dock based on the key modifiers.

open_in_window() → None[source]

Open our widget in a simple window.

open_menu(pos: QPoint)[source]

Open a menu to decide whether to open the widget in the dock or not.

open_widget()[source]

Pick open method based on whether or not the dock exists.