vispy.scene.widgets.widget.
Widget
Bases: vispy.scene.visuals.Compound
vispy.scene.visuals.Compound
A widget takes up a rectangular space, intended for use in a 2D pixel coordinate frame.
The widget is positioned using the transform attribute (as any node), and its extent (size) is kept as a separate property.
A 2-element tuple to specify the top left corner of the widget.
A 2-element tuple to spicify the size of the widget.
The color of the border.
The width of the border line in pixels.
The background color.
The amount of padding in the widget (i.e. the space reserved between the contents and the border).
The margin to keep outside the widget’s border.
add_grid
Create a new Grid and add it as a child widget.
All arguments are given to Grid().
add_view
Create a new ViewBox and add it as a child widget.
All arguments are given to ViewBox().
add_widget
Add a Widget as a managed child of this Widget.
The child will be automatically positioned and sized to fill the entire space inside this Widget (unless _update_child_widgets is redefined).
The widget to add.
The widget.
bgcolor
The background color of the Widget.
border_color
height
The actual height of the widget
height_max
The maximum height of the widget
height_min
The minimum height of the widget
inner_rect
The rectangular area inside the margin, border, and padding.
Generally widgets should avoid drawing or placing sub-widgets outside this rectangle.
margin
padding
picking
Boolean that determines whether this node (and its children) are drawn in picking mode.
pos
rect
remove_widget
Remove a Widget as a managed child of this Widget.
The widget to remove.
size
The size (w, h) of this widget.
If the widget is a child of another widget, then its size is assigned automatically by its parent.
stretch
Stretch factors (w, h) used when determining how much space to allocate to this widget in a layout.
If either stretch factor is None, then it will be assigned when the widget is added to a layout based on the number of columns or rows it occupies.
width
The actual width of this widget
width_max
The maximum width the widget can have
width_min
The minimum width the widget can have