canvascv::WidgetFactory Class Reference
The WidgetFactory class. More...
#include <widgetfactory.h>
Inheritance diagram for canvascv::WidgetFactory:
Static Public Member Functions | |
static std::shared_ptr< Widget > | newWidget (std::string type, Layout &layoutVal, const cv::Point &pos) |
newWidget More... | |
Detailed Description
Widget prototypes are added to this class with the help of the WidgetFactoryT class. You can create widgets with newWidget() of this class, but if you supply a wrong name you'll get back a null pointer.
- Examples:
- example_add_widget.cpp.
Member Function Documentation
|
static |
Use this to create widgets by name.
- Parameters
-
type is the name of the concrete Widget sub type. layoutVal is the parent layout pos is an intial location for the Widget on the Layout (if the layout supports specific positions).
- Returns
- a pointer to a newly allocated widget of type 'type' or nullptr if 'type' doesn't exist.
The documentation for this class was generated from the following file:
- CanvasCV-doxygen/src/canvascv/widgets/widgetfactory.h
Generated by 1.8.11