![]() |
Workspace 6.21.5
|
Class for creating widgets connected to input/output data. More...
#include <Workspace/Widgets/widgetcreators.h>
Public Member Functions | |
WidgetCreators (const WidgetCreators &c) | |
~WidgetCreators () | |
QWidget * | createWidget (int index, QWidget *parent=nullptr, bool readOnly=false) |
bool | empty () const |
const Creator & | getCreator (int index) const |
QString | getName (int index) const |
WidgetCreators & | operator= (const WidgetCreators &c) |
void | setPreferred (const QString &name, const QString &adaptType=QString()) |
unsigned | size () const |
This class acts somewhat like a container except that it doesn't provide any means to use its objects directly. Instead, it allows clients to specify which object to use to create a widget, then the class will invoke the specified object internally to carry out the task. Alternatively, it allows the Creator object at a particular index to be retrieved so that it can be passed to something else, but clients may not use the Creator object directly (the class definition of Creator is not part of the public API). The only queryable information WidgetCreators provides is the number of items in the container and the name of the object at any given index.
WidgetCreators | ( | const WidgetCreators & | c | ) |
~WidgetCreators | ( | ) |
QWidget * createWidget | ( | int | index, |
QWidget * | parent = nullptr , |
||
bool | readOnly = false |
||
) |
bool empty | ( | ) | const |
const Creator & getCreator | ( | int | index | ) | const |
QString getName | ( | int | index | ) | const |
WidgetCreators & operator= | ( | const WidgetCreators & | c | ) |
void setPreferred | ( | const QString & | name, |
const QString & | adaptType = QString() |
||
) |
unsigned size | ( | ) | const |