Developer Documentation
LightWidgetGenerator Class Reference
Inheritance diagram for LightWidgetGenerator:
ACG::QtWidgets::SceneGraphWidgetGenerator

Public Member Functions

virtual QWidget * getWidget (ACG::SceneGraph::BaseNode *_node)
 Get a widget for this Node. More...
 
virtual bool canHandle (std::string _className)
 returns if the widgets can handle the given class More...
 
virtual std::string handles ()
 return the type this generator handles More...
 
virtual QString contextMenuName ()
 Return a name for your widget in the context menu. More...
 

Additional Inherited Members

- Protected Attributes inherited from ACG::QtWidgets::SceneGraphWidgetGenerator
QMap< SceneGraph::BaseNode *, QWidget *> widgetMap_
 

Detailed Description

Definition at line 69 of file LightObject.cc.

Member Function Documentation

◆ canHandle()

virtual bool LightWidgetGenerator::canHandle ( std::string  _className)
inlinevirtual

returns if the widgets can handle the given class

This function has to check if the given classname is supported

Reimplemented from ACG::QtWidgets::SceneGraphWidgetGenerator.

Definition at line 93 of file LightObject.cc.

◆ contextMenuName()

virtual QString LightWidgetGenerator::contextMenuName ( )
inlinevirtual

Return a name for your widget in the context menu.

This name will be the same for all passed in nodes

Reimplemented from ACG::QtWidgets::SceneGraphWidgetGenerator.

Definition at line 101 of file LightObject.cc.

◆ getWidget()

virtual QWidget* LightWidgetGenerator::getWidget ( ACG::SceneGraph::BaseNode _node)
inlinevirtual

Get a widget for this Node.

Derive from this class to get a widget for the given node you have to overload this function. First check, if your widget can handle nodes of the given type (check for _node->className() ) Then generate your widget and handle the _node inside it. Return 0 if you can not handle it and check if the map already contains a widget for this node so that you generate one widget per node.

Reimplemented from ACG::QtWidgets::SceneGraphWidgetGenerator.

Definition at line 76 of file LightObject.cc.

◆ handles()

virtual std::string LightWidgetGenerator::handles ( )
inlinevirtual

return the type this generator handles

return the classname of the node this generator can handle

Reimplemented from ACG::QtWidgets::SceneGraphWidgetGenerator.

Definition at line 97 of file LightObject.cc.


The documentation for this class was generated from the following file: