systempanel.widgets
import systempanel.widgets
class systempanel.widgets.Led(obj_name, color=None)
A standard LED.
A LED, which can be on or off. Driven by the signal interface. The parameter color specifies the color of the LED. Supported colors are listed below:
The look-and-feel of the LED is frontend specific.
class systempanel.widgets.Button(obj_name, label)
A standard button.
A button, that can be pressed. The button state is propagated using the signal interface, and can be raised or lowered. Raising and lowering the signal is frontend specific.
class systempanel.widgets.ToggleButton(obj_name, label)
A toggle button.
A toggle button, that can be pressed or released. The button state is propagated using the signal interface. When button is pressed, signal is raised. When button is released, signal is lowered. The button must have a label indicating its purpose.
class systempanel.widgets.NumberInput(obj_name)
An input text field for integer numbers.
An input text field for integer numbers, provided by the panel user. The value is propagated to the model using the uint64_state interface.
class systempanel.widgets.NumberOutput(obj_name)
An output text field for integer numbers.
An output text field for integer numbers, presenting integer state from the model. Driven by the uint64_state interface.
class systempanel.widgets.Canvas(contents)
A canvas (i.e bitmap container).
A canvas for painting bitmap-based widgets. A canvas contains multiple bitmap-based widgets, each drawn at a specified offset. The contents parameter is a list of elements on the form (x, y, widget). Here x and y are integers, and widget is an instance of one of systempanel.widgets.Image, systempanel.widgets.BitmapLed, systempanel.widgets.BitmapButton, systempanel.widgets.BitmapToggleButton, systempanel.widgets.MultiImageOutput, systempanel.widgets.Canvas, or a subclass thereof. The items are rendered in the same order as they appear in the list; this means that if any widgets overlap, the last one will be drawn on top.
class systempanel.widgets.Grid(contents, columns)
A two-dimensional widget container.
A two-dimensional widget container. Containers are used to group other widgets, and enforce a specific layout scheme. The contents constructor parameter is a list of widget objects; it can contain any other widget except for bitmap-based ones. Widgets are laid out from left to right, top to bottom. Use the systempanel.widgets.Empty class to fill empty cells. The number of rows in a systempanel.widgets.Grid container is implicitly defined by the length of the contents list and the number of columns specified when creating the container. See also the systempanel.widgets.Column and systempanel.widgets.Row containers, which are convenience classes for the one-dimensional cases. Containers can contain other containers.
class systempanel.widgets.Column(contents)
A one-dimensional widget container.
A container for normal (non bitmap-based) widgets. The systempanel.widgets.Column container is a special case of systempanel.widgets.Grid container; the contained widgets are laid out vertically.
class systempanel.widgets.Row(contents)
A one-dimensional widget container.
A container for normal (non bitmap-based) widgets. The systempanel.widgets.Row container is a special case of systempanel.widgets.Grid container; the contained widgets are laid out horizontally.
class systempanel.widgets.Empty()
An empty widget.
An empty widget, used to fill containers for layout purposes.
class systempanel.widgets.Label(label)
An label.
A label, used to present static text.
class systempanel.widgets.LabeledBox(label, container)
A container with a label and box drawn around it.
A single-element container with a text label and a box drawn around it. The single widget given by the container parameter can be of any widget type, but it is typically of a container type.
class systempanel.widgets.MultiImageOutput(obj_name, images)
A bitmap-based output that toggles between multiple images.
An output that toggles between multiple custom images. This can be used, among other things, for multi-coloured LEDs or seven-segment display elements. The images parameter is a list of paths to image filenames, each one given on the same form as in the systempanel.widgets.Image class. Numeric input to the panel object via the uint64_state interface is used as a 0-based index in the image list.
class systempanel.widgets.BitmapButton(obj_name, offBitmap, onBitmap)
A bitmap-based button.
A bitmap-based button. Similar to the standard systempanel.widgets.Button class, but can be put inside a systempanel.widgets.Canvas, and the appearance is based on custom images. The bitmap parameters are filenames of the same type as in the systempanel.widgets.Image class.
class systempanel.widgets.BitmapToggleButton(obj_name, offBitmap, onBitmap)
A bitmap-based toggle button.
A bitmap-based toggle button. Similar to the standard systempanel.widgets.ToggleButton class, but can be put inside a systempanel.widgets.Canvas, and the appearance is based on custom images. The bitmap parameters are file names of the same type as in the systempanel.widgets.Image class.
class systempanel.widgets.BitmapLed(obj_name, offBitmap, onBitmap)
A bitmap-based LED.
A bitmap-based LED. Same as the standard systempanel.widgets.Led class, but can be put inside a systempanel.widgets.Canvas, and custom images can be supplied. The bitmap constructor parameters are file names of the same type as in the systempanel.widgets.Image class.
class systempanel.widgets.Image(filename)
An image.
An image, that can be put inside a systempanel.widgets.Canvas class. Currently the only supported file format is PNG, but with full support for transparency. See systempanel.widgets.Canvas class for more information.
systempanel.widgets.BLUE
Blue standard widget color.
systempanel.widgets.GREEN
Green standard widget color.
systempanel.widgets.PURPLE
Purple standard widget color.
systempanel.widgets.RED
Red standard widget color.
systempanel.widgets.WHITE
White standard widget color.
systempanel.widgets.YELLOW
Yellow standard widget color.