![]() |
VR-Forces 4.0.4 Class Documentation
|
This handler creates entities. More...

Public Slots | |
| virtual void | create (QVector< DtPoint > &points, QString name, QString label, QColor color, int forceType, int appearance, bool publish, QString attachTo, DtArchivableObject *userData, bool createDone=true) |
| If createDone is false, dialog will not be removed and the create process can continue. | |
| virtual void | completeEdit (QString name, QString label, QColor color, int forceType, int appearance, bool publish, DtArchivableObject *userData) |
| virtual void | cancel () |
| Handle the cancelling of this object creation. | |
| virtual bool | mouseEvent (DtTMMapArea *area, QMouseEvent *evnt, const DtPoint &pnt) |
| virtual void | updateTempSymbol () |
| virtual void | redrawSymbol () |
| virtual void | clearHideSymbol () |
| virtual void | done () |
| Called when finished creating or editing (either by OK or cancel) | |
Signals | |
| void | selectedPoint (const DtPoint &p) |
| void | userComplete (bool finish) |
| Emitted when the user never wants to show the dialog, will tell the dialog that is hidden that the user has complete the operation. | |
Public Member Functions | |
| DtCreateControlObjectHandler () | |
| Default Constructor. | |
| virtual | ~DtCreateControlObjectHandler () |
| Destructor. | |
| virtual QWidget * | createDialog (QWidget *parent) |
| Creates the dialog associated with this handler (if there is one) | |
| virtual void | setCreationObject (DtEntityMapperKey obj, int frc) |
| Set the object you are creating. | |
| virtual void | setVertices (const QVector< DtPoint > &pnt) |
| Sets the vertices used for creation. | |
| virtual void | setName (const QString &name) |
Static Public Member Functions | |
| static bool | addDialogCreator (const DtEntityMapperKey &key, DtDialogCreator fcn) |
| Adds a dialog creator function to the list of dialogs that can be created (by entity key). | |
| static void | cleanupDialogCreators () |
| Call to cleanup memory owned by myDialogCreators member. | |
| static void | setDefaultNameLabel (const QString &) |
| static QString | defaultNameLabel () |
Protected Member Functions | |
| virtual QWidget * | createWidgetFor (const DtEntityMapperKey &key, QWidget *parent) |
| Dialog creation routines. Creates the dialog from internally added dialog creators. | |
| virtual void | setWorkingName ()=0 |
| Sets the working name of the temp symbol. | |
| virtual void | additionalTempSymbolModifications (QPolygon &pts) |
| Additional modifications to be made to the temp symbol by subclasses. | |
| virtual void | initDialog (QWidget *w) |
| Initializes dialog with default values. | |
| virtual void | initDialogConnections () |
| Uses myEventDlg pointer to init connections. | |
| virtual void | initCreateConnections () |
| Connections that are initialized when in create mode. | |
| virtual void | initEditConnections () |
| Connections that are are made when editing. | |
| virtual void | pointSelected (const DtPoint &p) |
| virtual void | activate () |
| Called when this event handler first becomes active. | |
| virtual void | deactivate () |
| Called when we are decativated, acts as a cancel on the current event. | |
| virtual void | stop (const DtPoint &pnt) |
| virtual DtSymbol * | createTempSymbol (DtTMMapArea *area) |
| Creates the temp symbol and sets the working name. | |
| virtual DtSymbol * | createSymbol (DtTMMapArea *area) |
| Subclasses need to create temp symbol. | |
| virtual void | getVertices (QVector< DtPoint > &modelPoints) const |
| virtual bool | canPublish () const |
| virtual bool | isPublished () const |
| virtual void | setCaption (QWidget *w) |
| Sets the caption for the dialog based on mode and type. | |
| virtual QString | defaultName () const |
| Default name of any item of a particular type. | |
| virtual void | sendUserComplete (bool finish=false) |
| Sends user complete message if show dialog type is Never. | |
| virtual bool | userDefinedAction (DtUserDefinedType iAction, void *usr) |
| virtual bool | complete () const |
| Returns true if the item is complete by the number of points. | |
| virtual bool | finishOnCreate () const |
| Return true if want to finish on create by default. Default is false. | |
| virtual void | disconnectDialogConnections () |
| virtual void | disconnectEditConnections () |
| virtual void | disconnectCreateConnections () |
| virtual int | publishedEditTimeout () const |
| 250 ms default, then, calls done to hide copied symbol | |
| virtual const char * | eventSignalName () |
| virtual QPixmap | createCursor () |
| Creates/restores the override cusror to display that the handler is in creation mode. | |
| virtual void | dialogDestroyedEvent () |
| Called when dialog is destroyed. | |
Protected Attributes | |
| QVector< DtPoint > | myPointList |
| QString | myObjectName |
| QString | myLabelName |
| bool | myFinalPointSelected |
| DtSymbol * | myHideSymbol |
| DtOverlaySymbolDescriptor * | myDescription |
| bool | myDeleteDescription |
| bool | myFirstClick |
| DtArchivableObject * | myUserData |
| Set by the dialogs, this will be passed to create and edit routines for modification. | |
Static Protected Attributes | |
| static QList < DtDialogCreatorInfo * > | myDialogCreators |
| Dialog creators. | |
| static QString | theDefaultNameLabel |
This handler creates entities.
Default Constructor.
| virtual DtCreateControlObjectHandler::~DtCreateControlObjectHandler | ( | ) | [virtual] |
Destructor.
| virtual QWidget* DtCreateControlObjectHandler::createDialog | ( | QWidget * | w | ) | [virtual] |
Creates the dialog associated with this handler (if there is one)
Reimplemented from DtEventHandler.
| static bool DtCreateControlObjectHandler::addDialogCreator | ( | const DtEntityMapperKey & | key, |
| DtDialogCreator | fcn | ||
| ) | [static] |
Adds a dialog creator function to the list of dialogs that can be created (by entity key).
If one exists with the key, replaces
| static void DtCreateControlObjectHandler::cleanupDialogCreators | ( | ) | [static] |
Call to cleanup memory owned by myDialogCreators member.
Current called as part of application cleanup
| virtual void DtCreateControlObjectHandler::setCreationObject | ( | DtEntityMapperKey | obj, |
| int | frc | ||
| ) | [virtual] |
Set the object you are creating.
Reimplemented from DtCreationHandler.
| virtual void DtCreateControlObjectHandler::setVertices | ( | const QVector< DtPoint > & | pnt | ) | [virtual] |
Sets the vertices used for creation.
This is used if no model data. Note the vertices are copied into the myPointsList
| virtual void DtCreateControlObjectHandler::setName | ( | const QString & | name | ) | [virtual] |
| static void DtCreateControlObjectHandler::setDefaultNameLabel | ( | const QString & | ) | [static] |
| static QString DtCreateControlObjectHandler::defaultNameLabel | ( | ) | [static] |
| virtual void DtCreateControlObjectHandler::create | ( | QVector< DtPoint > & | points, |
| QString | name, | ||
| QString | label, | ||
| QColor | color, | ||
| int | forceType, | ||
| int | appearance, | ||
| bool | publish, | ||
| QString | attachTo, | ||
| DtArchivableObject * | userData, | ||
| bool | createDone = true |
||
| ) | [virtual, slot] |
If createDone is false, dialog will not be removed and the create process can continue.
| virtual void DtCreateControlObjectHandler::completeEdit | ( | QString | name, |
| QString | label, | ||
| QColor | color, | ||
| int | forceType, | ||
| int | appearance, | ||
| bool | publish, | ||
| DtArchivableObject * | userData | ||
| ) | [virtual, slot] |
| virtual void DtCreateControlObjectHandler::cancel | ( | ) | [virtual, slot] |
Handle the cancelling of this object creation.
Implements DtCreationHandler.
| virtual bool DtCreateControlObjectHandler::mouseEvent | ( | DtTMMapArea * | area, |
| QMouseEvent * | evnt, | ||
| const DtPoint & | pnt | ||
| ) | [virtual, slot] |
Reimplemented from DtCreationHandler.
Reimplemented in DtCreateLineHandler.
| virtual void DtCreateControlObjectHandler::updateTempSymbol | ( | ) | [virtual, slot] |
Implements DtCreationHandler.
| virtual void DtCreateControlObjectHandler::redrawSymbol | ( | ) | [virtual, slot] |
| virtual void DtCreateControlObjectHandler::clearHideSymbol | ( | ) | [virtual, slot] |
| virtual void DtCreateControlObjectHandler::done | ( | ) | [virtual, slot] |
Called when finished creating or editing (either by OK or cancel)
Reimplemented in DtTerrainCreateLineHandler.
| void DtCreateControlObjectHandler::selectedPoint | ( | const DtPoint & | p | ) | [signal] |
| void DtCreateControlObjectHandler::userComplete | ( | bool | finish | ) | [signal] |
Emitted when the user never wants to show the dialog, will tell the dialog that is hidden that the user has complete the operation.
If the operation is a success, it will create the object. If not, the dialog should display itself
| virtual QWidget* DtCreateControlObjectHandler::createWidgetFor | ( | const DtEntityMapperKey & | key, |
| QWidget * | parent | ||
| ) | [protected, virtual] |
Dialog creation routines. Creates the dialog from internally added dialog creators.
Reimplemented in DtTerrainCreateLineHandler.
| virtual void DtCreateControlObjectHandler::setWorkingName | ( | ) | [protected, pure virtual] |
Sets the working name of the temp symbol.
Implemented in DtCreateAreaHandler, DtCreateLineHandler, and DtCreatePointHandler.
| virtual void DtCreateControlObjectHandler::additionalTempSymbolModifications | ( | QPolygon & | pts | ) | [protected, virtual] |
Additional modifications to be made to the temp symbol by subclasses.
The array is the screen point location of all points in the object
| virtual void DtCreateControlObjectHandler::initDialog | ( | QWidget * | w | ) | [protected, virtual] |
Initializes dialog with default values.
Reimplemented in DtTerrainCreateLineHandler, DtCreateLineHandler, and DtCreatePointHandler.
| virtual void DtCreateControlObjectHandler::initDialogConnections | ( | ) | [protected, virtual] |
Uses myEventDlg pointer to init connections.
Set as function of calling createWidgetForCategory from createDialog. Common connections plus call to edit or create connections depending on mode
Reimplemented in DtCreateLineHandler, and DtCreatePointHandler.
| virtual void DtCreateControlObjectHandler::initCreateConnections | ( | ) | [protected, virtual] |
Connections that are initialized when in create mode.
| virtual void DtCreateControlObjectHandler::initEditConnections | ( | ) | [protected, virtual] |
Connections that are are made when editing.
| virtual void DtCreateControlObjectHandler::pointSelected | ( | const DtPoint & | p | ) | [protected, virtual] |
Implements DtCreationHandler.
Reimplemented in DtCreatePointHandler.
| virtual void DtCreateControlObjectHandler::activate | ( | ) | [protected, virtual] |
Called when this event handler first becomes active.
Reimplemented from DtCreationHandler.
Reimplemented in DtTerrainCreatePointHandler.
| virtual void DtCreateControlObjectHandler::deactivate | ( | ) | [protected, virtual] |
Called when we are decativated, acts as a cancel on the current event.
Reimplemented from DtCreationHandler.
| virtual void DtCreateControlObjectHandler::stop | ( | const DtPoint & | pnt | ) | [protected, virtual] |
Reimplemented from DtCreationHandler.
| virtual DtSymbol* DtCreateControlObjectHandler::createTempSymbol | ( | DtTMMapArea * | area | ) | [protected, virtual] |
Creates the temp symbol and sets the working name.
If in edit mode, hide the original symbol
Reimplemented from DtCreationHandler.
Reimplemented in DtTerrainCreateLineHandler.
| virtual DtSymbol* DtCreateControlObjectHandler::createSymbol | ( | DtTMMapArea * | area | ) | [protected, virtual] |
Subclasses need to create temp symbol.
Implements DtCreationHandler.
Reimplemented in DtCreateLineHandler, and DtCreatePointHandler.
| virtual void DtCreateControlObjectHandler::getVertices | ( | QVector< DtPoint > & | modelPoints | ) | const [protected, virtual] |
| virtual bool DtCreateControlObjectHandler::canPublish | ( | ) | const [protected, virtual] |
| virtual bool DtCreateControlObjectHandler::isPublished | ( | ) | const [protected, virtual] |
| virtual void DtCreateControlObjectHandler::setCaption | ( | QWidget * | w | ) | [protected, virtual] |
Sets the caption for the dialog based on mode and type.
| virtual QString DtCreateControlObjectHandler::defaultName | ( | ) | const [protected, virtual] |
Default name of any item of a particular type.
| virtual void DtCreateControlObjectHandler::sendUserComplete | ( | bool | finish = false | ) | [protected, virtual] |
Sends user complete message if show dialog type is Never.
Reimplemented in DtCreatePointHandler.
| virtual bool DtCreateControlObjectHandler::userDefinedAction | ( | DtUserDefinedType | iAction, |
| void * | usr | ||
| ) | [protected, virtual] |
Reimplemented from DtEventHandler.
| virtual bool DtCreateControlObjectHandler::complete | ( | ) | const [protected, virtual] |
Returns true if the item is complete by the number of points.
Called on first click if dialog is displayed on first click
| virtual bool DtCreateControlObjectHandler::finishOnCreate | ( | ) | const [protected, virtual] |
Return true if want to finish on create by default. Default is false.
Reimplemented in DtCreateLineHandler.
| virtual void DtCreateControlObjectHandler::disconnectDialogConnections | ( | ) | [protected, virtual] |
| virtual void DtCreateControlObjectHandler::disconnectEditConnections | ( | ) | [protected, virtual] |
| virtual void DtCreateControlObjectHandler::disconnectCreateConnections | ( | ) | [protected, virtual] |
| virtual int DtCreateControlObjectHandler::publishedEditTimeout | ( | ) | const [protected, virtual] |
250 ms default, then, calls done to hide copied symbol
| virtual const char* DtCreateControlObjectHandler::eventSignalName | ( | ) | [inline, protected, virtual] |
Reimplemented in DtCreateLineHandler, DtCreatePointHandler, and DtCreateAreaHandler.
References DtCreateControlObjectWidgetEvent.
| virtual QPixmap DtCreateControlObjectHandler::createCursor | ( | ) | [protected, virtual] |
Creates/restores the override cusror to display that the handler is in creation mode.
Reimplemented from DtCreationHandler.
| virtual void DtCreateControlObjectHandler::dialogDestroyedEvent | ( | ) | [protected, virtual] |
Called when dialog is destroyed.
Reimplemented from DtEventHandler.
QVector<DtPoint> DtCreateControlObjectHandler::myPointList [protected] |
QString DtCreateControlObjectHandler::myObjectName [protected] |
QString DtCreateControlObjectHandler::myLabelName [protected] |
DtSymbol* DtCreateControlObjectHandler::myHideSymbol [protected] |
bool DtCreateControlObjectHandler::myFirstClick [protected] |
Set by the dialogs, this will be passed to create and edit routines for modification.
QList<DtDialogCreatorInfo*> DtCreateControlObjectHandler::myDialogCreators [static, protected] |
Dialog creators.
QString DtCreateControlObjectHandler::theDefaultNameLabel [static, protected] |