Classes List Preview widget just displays a list of classes. It can be used to display classes that were selected by the user in the Classes List Selector widget for example.
Text that will be displayed when there are no classes in widget
type:str
defaultNone
empty_text ="No classes to preview"classes_list_preview =ClassesListPreview( classes=[], empty_text=empty_text,)
show_shape_title
If True show name of the shape next to class name.
type:bool
defaultTrue
empty_text ="No classes to preview"classes_list_preview =ClassesListPreview( classes=[], empty_text=empty_text,)
show_shape_icon
If True show icon of the shape near class name.
type:bool
defaultTrue
empty_text ="No classes to preview"classes_list_preview =ClassesListPreview( classes=[], empty_text=empty_text,)
widget_id
ID of the widget.
type:str
default value:None
Methods and attributes
Attributes and Methods
Description
set()
Set classes to widget and determine wheter to display shape icon and title.
get()
Return list of classes.
Mini App Example
In this example we will create a mini app with ClassesListPreview widget. We will create a ClassesListSelector widget and display selected classes with ClassesListPreview widget.
You can find this example in our Github repository: