![]() |
VR-Forces 4.1.1 Class Documentation
|
DtTMMapArea is a class used for drawing and navigation of terrain. More...

Public Slots | |
| virtual void | zoomIn () |
| Zooms in tdb view, emits tdbViewChanged, and updates. | |
| virtual void | zoomOut () |
| Zooms out tdb view, emits tdbViewChanged, and updates. | |
| virtual void | drawRubberBands (QPainter *p) |
| virtual void | clearSelection (bool signal=true) |
| virtual void | changeSelection (const QVector< DtModelKey > &d) |
| virtual bool | addSelection (const QVector< DtModelKey > &d) |
| Adds these keys to the selection list if they are not there already. | |
| virtual bool | removeSelection (const QVector< DtModelKey > &d) |
| Removes these keys from the selection list if they are in it. | |
| virtual void | setRightClickMaintainSelection (bool b) |
| virtual bool | rightClickMaintainSelection () |
| virtual void | forcePersistentSymbol (DtSymbol *s) |
| virtual void | stopForcePersistentSymbol (DtSymbol *s) |
| virtual void | catchViewportChange (const DtTMViewportExtents *v) |
| virtual bool | dragStart () |
| Called when a drag/drop operation is about to start. | |
| virtual void | dragComplete () |
| Called when a drag/drop operation is complete, regardless of the success of the operation. | |
| virtual void | setFreezeSelection (bool) |
| Sets whether or not to freeze current selection regardless of any type of change made. | |
| bool | freezeSelection () const |
Public Slots inherited from DtTMArea | |
| virtual void | loadDatabaseFile (const QString &) |
| virtual bool | updateAllSymbols () |
| Go through the list of symbols that we have marked for update and update them. | |
| virtual void | updateBackground () |
| virtual void | resizeMapArea () |
| virtual DtSymbol * | addSymbol (const DtModelData &data, bool force=false) |
| virtual void | removeSymbol (const DtModelKey &data, bool force=false) |
| virtual void | setDrawOrderSymbols (bool b) |
| Set to true to draw order symbols on the next tick. | |
| virtual void | signalDrawOrderSymbols () |
| Signals to draw order the symbols on the next tick. | |
| virtual void | drawOrderSymbols () |
| Draw order symbols if at least one first/last draw by having lens area draw order symbols. | |
Signals | |
| void | leftDoubleClick () |
| void | symbolsSelected (DtSymbolList *) |
| void | selectionChanged (const QVector< DtModelKey > &) |
| void | selectionUpdated (const QVector< DtModelKey > &) |
| void | databasePointSelected (const DtPoint &) |
| void | nullSelected () |
| void | rightMouseContext (DtSymbolList *, QPoint) |
| void | middleMouseContext (DtSymbolList *, QPoint) |
| void | mouseSignal (QMouseEvent *, const DtPoint &) |
| Sent whenever a mouse event happens. | |
| void | keyboardSignal (QKeyEvent *) |
| Sent whenever a key event happens. | |
| void | focusEventSignal (QEvent *) |
| Sent whenever a you leave the focus area. | |
| void | enterEventSignal (QEvent *) |
| void | leaveEventSignal (QEvent *) |
| void | activateMap (DtTMMapArea *) |
| void | dropEventSignal (QDropEvent *) |
| void | dragEnterEventSignal (QDragEnterEvent *) |
| void | dragLeaveEventSignal (QDragLeaveEvent *) |
| void | dragMoveEventSignal (QDragMoveEvent *) |
| void | selectionInProgress (DtSymbolSelector &symbolSelector) |
| Sent whenever a selection is in process (i.e. before mouse is released) | |
| void | selectedModelDataUpdated () |
| Sent whenever the selected model data is updated. | |
| void | aboutToDraw (QPainter *map) |
| Sent when the lens area is about to draw. | |
| void | selectionModeChanged (int iNewMode) |
| Sent when the selection mode has changed. | |
| void | frozenChanged (bool) |
| Emitted when frozen selection changes. | |
Signals inherited from DtTMArea | |
| void | viewportExtentsSet (const DtTMViewportExtents *v) |
| Called after setTdbView. | |
| void | viewportExtentsChanged (const DtTMViewportExtents *v) |
| Called after internally changing tdb view. | |
| void | newDatabaseFile (const QString &) |
| void | removingSymbol (const DtModelKey &data) |
| Called when removing, adding or modifying a symbol. | |
| void | addingSymbol (const DtModelKey &data) |
| void | modifyingSymbol (const DtModelKey &data) |
| void | resized () |
| Sent when this area has resized. | |
| void | modelDataMarkedForUpdated (const DtModelData &d) |
| void | modelDataRemovedFromUpdate (const DtModelData &) |
Public Member Functions | |
| DtTMMapArea (QWidget *parent=0, const Qt::WindowFlags &flags=0) | |
| virtual | ~DtTMMapArea () |
| virtual bool | init (const DtTMFactory *f) |
| Initializer. MUST BE CALLED. | |
| virtual void | setSelectorType (DtSymbolSelector::DtSelectorType type) |
| virtual DtSymbolSelector & | symbolSelector () |
| virtual DtSymbolList & | selectedSymbols () |
| virtual const QVector < DtModelKey > & | selectedModelKeys () const |
| Returns mySelectedModelKeys. | |
| virtual QVector< DtModelKey > & | selectedModelKeys () |
| virtual bool | leftButtonClicked () |
| virtual double | getDatabaseHeight (double x, double y) const |
| virtual bool | tick () |
| Check to see if need to draw order. | |
| virtual void | setActivateMap () |
| Activate the map. | |
| virtual void | updateSelectedModelData () |
| virtual void | setResetLabelPositions (bool b) |
| Signal to tell the symbol updater to reset label positions (or not) on next tick. | |
| virtual void | clear () |
| Clears out selected symbols and drawn symbols. | |
| virtual void | removeFromPersistentData (const QString &key) |
| virtual void | applyOptions (DtSymbol *s) |
| This routine will ask the symbol updater to apply the options for the supplied symbol. | |
| DtObjectSelector * | objectSelector () |
| virtual bool | startNullSelectionMode (bool showHandCursor=false) |
| Routines that will allow certain valid selections on the map area Start null selection mode. | |
| virtual bool | startNormalSelectionMode () |
| Start normal selection mode. | |
| virtual bool | startSymbolPointSelectionMode (int selectionMode, bool showHandCursor=false, bool reset=false, bool backup=true, bool force=false) |
| virtual bool | startSymbolRectangleSelectionMode (int selectionMode, bool showHandCursor=false, bool reset=false, bool backup=true, bool force=false) |
| virtual bool | startSelectionMode (int selectionMode, DtSymbolSelector::DtSelectorType type, bool showHandCursor=false, bool reset=false, bool backup=true, bool force=false) |
| General selection function. | |
| virtual void | swapModelKeys (QVector< DtModelKey > &orig, QVector< DtModelKey > &save, QVector< DtModelKey > &display) |
| virtual int | symbolSelectionMode () const |
| const DtPoint & | lastSelectedPoint () const |
| virtual void | removeSymbol (const DtModelData &data, bool force) |
| Removes the symbol from the map area and from any internal selected lists. | |
| virtual DtSymbolSelector * | setCurrentSelector (DtSymbolSelector *s) |
| Returns the current symbol selector after setting to new selector. | |
| virtual DtSymbolSelector * | currentSelector () |
| virtual void | setObjectSelectionMode (const DtFilter *f=NULL, bool swapKeys=false) |
| Selection modes. | |
| virtual bool | inObjectSelectionMode () const |
| Returns true if this area is in object selection mode. | |
| virtual DtSymbol * | symbolAtLocation (const DtPoint &pnt) const |
| Asks the object selector (if it exists) to return the symbol at the specified database location. | |
| virtual bool | event (QEvent *) |
| Only exposed for public access. | |
Public Member Functions inherited from DtTMArea | |
| DtTMArea (QWidget *parent=0, const Qt::WindowFlags &flags=0) | |
| virtual | ~DtTMArea () |
| virtual void | setSymbolMapper (DtBaseSymbolMapper *mapper) |
| virtual DtBaseSymbolMapper * | getSymbolMapper () |
| virtual DtTMSymbolUpdater * | symbolUpdater () |
| virtual DtTMViewportExtents * | viewportExtents () const |
| Gets the current viewport extents. | |
| virtual DtViewDriver * | viewDriver () const |
| Gets the current view driver. | |
| virtual void | setViewDriver (DtViewDriver *v) |
| Sets the current view driver. | |
| virtual DtTMBackground * | background () const |
| Gets the current background. | |
| virtual void | setBackground (DtTMBackground *v) |
| Sets the current background. | |
| virtual void | setSymbolLensArea (DtSymbolLensArea *area) |
| virtual DtSymbolLensArea * | symbolLensArea () |
| virtual bool | isInitialized () |
| virtual DtModelDataDict & | ModelDataDict () |
| Returns the local list of Symbol Datas. | |
| virtual DtModelDataIter * | ModelDataIter () const |
| Returns the local list of Symbol Datas. | |
| virtual DtModelDataIter * | CombinedModelDataIter () const |
| Returns the combined list of global application and local model data. | |
| virtual void | setUpdateOnTick (bool b) |
| Set the fact that this area will also refresh its display on a tick. | |
| virtual void | markForUpdate (const QVector< DtModelKey > &, bool emitSignal=true) |
| Copy the model data from the supplied list to our internal update list that will be updated on the next call to updateAllSymbols. | |
| virtual void | markForUpdate (DtModelDataIter *iter, bool emitSignal=true) |
| virtual void | markForUpdate (const DtModelData &data, bool emitSignal=true) |
| virtual void | removeFromUpdate (DtModelDataIter *iter) |
| Call these to remove model datas for update. | |
| virtual void | removeFromUpdate (const DtModelData &data) |
| virtual void | removeDictionaryEntry (const DtModelKey &key) |
| Removes this entry from the local dictionary. | |
| virtual void | setUpdateBackgroundOnTick (bool b) |
| Set to true to call updateBackground on next tick. | |
| void | setNextTickIsRepaint (bool b) |
| Set to have the next update (if the area is updated in a tick) to be a repaint rather than an update. | |
| bool | nextTickIsRepaint () const |
| virtual bool | needsTick () const |
| Return true if this area needs to be ticked. | |
| virtual bool | needsUpdate () const |
| Return true if this area needs update because myUpdateData.count() is not zero. | |
| virtual DtSymbol * | addSymbol (const DtModelData &data, DtSymbol *symbol) |
| Adds a new symbol with the associated model data to the map area. | |
| virtual void | read (QTextStream &ts) |
| Archival operators. | |
| virtual void | write (QTextStream &ts) |
| virtual void | clearSymbols () |
| virtual void | setForceTickOnViewportChange (bool b) |
| Set this to true to force a tick when the viewport has changed (to speed drawing on map areas). | |
| virtual bool | forceTickOnViewportChange () const |
| virtual void | paint (QPainter *painter, bool paintBackground=true) |
| Draw to the supplied device. Draws the background (if specified) and the lens area. | |
| virtual void | redrawBackground () |
| virtual DtSymbol * | getSymbol (const DtModelKey &) const |
| Returns a symbol from the view driver for the given model key (if exists) | |
| void | setAlwaysResizeToGlobalView (bool) |
| If true, when map area is resized, always go back to global view. | |
| bool | alwaysResizeToGlobalView () const |
| virtual bool | terrainLoaded () const |
| void | setWindow (DtBaseWindow *) |
| DtBaseWindow * | window () const |
| virtual bool | needsDrawOrder () const |
| Return true/false depending on whether or not the area cares about draw ordering symbols. | |
| virtual void | insertIntoDrawOrder (DtSymbol *) |
| Insert symbol into lens area draw order. | |
Static Public Member Functions | |
| static DtTMMapArea * | create (QWidget *parent, const Qt::WindowFlags &flags) |
| Returns a newly created instance of a DtTMMapArea. | |
Protected Member Functions | |
| virtual void | setViewportExtents (const DtTMViewportExtents *v) |
| virtual void | modifySymbol (const DtModelData &data) |
| virtual bool | initViewDriver (const DtTMFactory *f) |
| virtual bool | initObjectSelector (const DtTMFactory *f) |
| virtual void | updateSymbolSelection (Qt::KeyboardModifiers keyState, Qt::MouseButtons mouseState, bool updateInternalSelection=true) |
| virtual void | updateSelectedSymbols (const QVector< DtModelKey > &selectedKeys) |
| virtual void | updatePersistentModelData () |
| virtual void | highlightNoSymbols () |
| virtual void | highlightSymbols (QVector< DtModelKey > *display=NULL) |
| virtual void | mousePressEvent (QMouseEvent *e) |
| Event overloads. | |
| virtual void | mouseReleaseEvent (QMouseEvent *e) |
| virtual void | mouseMoveEvent (QMouseEvent *e) |
| virtual void | mouseDoubleClickEvent (QMouseEvent *e) |
| virtual void | keyPressEvent (QKeyEvent *e) |
| virtual void | keyReleaseEvent (QKeyEvent *e) |
| virtual void | wheelEvent (QWheelEvent *e) |
| virtual void | focusOutEvent (QFocusEvent *e) |
| virtual void | leaveEvent (QEvent *e) |
| virtual void | enterEvent (QEvent *e) |
| virtual void | mouseSelect (QMouseEvent *e) |
| virtual void | mousePressSelect (QMouseEvent *e) |
| virtual void | dragEnterEvent (QDragEnterEvent *e) |
| Drag/Drop code. | |
| virtual void | dragLeaveEvent (QDragLeaveEvent *e) |
| virtual void | dragMoveEvent (QDragMoveEvent *e) |
| virtual void | dropEvent (QDropEvent *e) |
Protected Member Functions inherited from DtTMArea | |
| DtTMArea (const DtTMArea &orig) | |
| Not implemented. | |
| DtTMArea & | operator= (const DtTMArea &rhs) |
| Not implemented. | |
| virtual bool | initViewportExtents (const DtTMFactory *f) |
| virtual bool | initLensArea (const DtTMFactory *f, bool useGL=false) |
| virtual bool | initBackground (const DtTMFactory *f) |
| virtual void | resizeEvent (QResizeEvent *e) |
| Resize event. | |
| virtual void | showEvent (QShowEvent *e) |
Private Member Functions | |
| DtTMMapArea (const DtTMMapArea &orig) | |
| Not implemented. | |
| DtTMMapArea & | operator= (const DtTMMapArea &rhs) |
| Not implemented. | |
Additional Inherited Members | |
Protected Slots inherited from DtTMArea | |
| virtual void | catchViewportChange (const DtTMViewportExtents *v) |
| virtual void | symbolAdded (const DtModelKey &data) |
| Called when the view driver adds or removes a symbol. | |
| virtual void | symbolAdded (const DtSymbol *) |
| virtual void | symbolRemoved (const DtModelKey &data) |
| virtual void | symbolRemoved (const DtSymbol *) |
DtTMMapArea is a class used for drawing and navigation of terrain.
Slots are provided for navigation calls, and all of them currently result in a redraw of the terrain. This class must be initialized with the proper drawers. DtPixmapTerrain provides the drawing functionality, while DtTdbView provides the navigation.
| DtTMMapArea::DtTMMapArea | ( | QWidget * | parent = 0, |
| const Qt::WindowFlags & | flags = 0 |
||
| ) |
|
virtual |
|
private |
Not implemented.
|
virtual |
|
virtual |
|
virtual |
|
virtual |
|
virtual |
Returns mySelectedModelKeys.
To see what is currently selected in the system selector, get the symbol selector via symbolSelector() and check the symbol selectors selected symbols
|
virtual |
|
virtual |
|
virtual |
Reimplemented in DtTerrainMapArea.
|
virtual |
Check to see if need to draw order.
Reimplemented from DtTMArea.
|
virtual |
Activate the map.
|
virtual |
|
virtual |
Signal to tell the symbol updater to reset label positions (or not) on next tick.
|
virtual |
Clears out selected symbols and drawn symbols.
Reimplemented from DtTMArea.
|
virtual |
|
virtual |
This routine will ask the symbol updater to apply the options for the supplied symbol.
|
inline |
References myObjectSelector.
|
static |
Returns a newly created instance of a DtTMMapArea.
Reimplemented in DtTerrainMapArea.
Routines that will allow certain valid selections on the map area Start null selection mode.
if showHandCursor is true, will display the hand cursor on screen
|
virtual |
Start normal selection mode.
|
virtual |
|
virtual |
|
virtual |
General selection function.
use this if you need a selection mode not defined by any of the above functions.
|
virtual |
|
virtual |
| const DtPoint& DtTMMapArea::lastSelectedPoint | ( | ) | const |
|
virtual |
Removes the symbol from the map area and from any internal selected lists.
Reimplemented from DtTMArea.
|
virtual |
Returns the current symbol selector after setting to new selector.
|
virtual |
|
virtual |
Selection modes.
If Filter is NULL, selects all objects. If swapKeys is true, moves current selection to the temporary backup before revalidating due to filter. To restore the selection, setNormalSelectionMode()
|
virtual |
Returns true if this area is in object selection mode.
Asks the object selector (if it exists) to return the symbol at the specified database location.
|
virtual |
Only exposed for public access.
|
signal |
|
signal |
|
signal |
|
signal |
|
signal |
|
signal |
|
signal |
|
signal |
|
signal |
Sent whenever a mouse event happens.
This is useful for event handling The Point is the mouse location in DATABASE coordinates
|
signal |
Sent whenever a key event happens.
This is useful for event handling
|
signal |
Sent whenever a you leave the focus area.
this allows us to reset some things if necessary
|
signal |
|
signal |
|
signal |
|
signal |
|
signal |
|
signal |
|
signal |
|
signal |
Sent whenever a selection is in process (i.e. before mouse is released)
|
signal |
Sent whenever the selected model data is updated.
|
signal |
Sent when the lens area is about to draw.
|
signal |
Sent when the selection mode has changed.
|
signal |
Emitted when frozen selection changes.
|
virtualslot |
Zooms in tdb view, emits tdbViewChanged, and updates.
|
virtualslot |
Zooms out tdb view, emits tdbViewChanged, and updates.
|
virtualslot |
|
virtualslot |
|
virtualslot |
|
virtualslot |
Adds these keys to the selection list if they are not there already.
Returns true if any changes were made.
|
virtualslot |
Removes these keys from the selection list if they are in it.
Returns true if any changes were made.
|
virtualslot |
|
virtualslot |
|
virtualslot |
|
virtualslot |
|
virtualslot |
|
virtualslot |
Called when a drag/drop operation is about to start.
Return false to abort the drag/drop operation
|
virtualslot |
Called when a drag/drop operation is complete, regardless of the success of the operation.
|
virtualslot |
Sets whether or not to freeze current selection regardless of any type of change made.
Note that the selection will be unfrozen when starting normal selection mode. If the selection is frozen, even if there are items selected, the current database point will be emitted
|
inlineslot |
References myFreezeSelection.
|
protectedvirtual |
Reimplemented from DtTMArea.
|
protectedvirtual |
Reimplemented from DtTMArea.
|
private |
Not implemented.
|
protectedvirtual |
Reimplemented from DtTMArea.
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
Event overloads.
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
|
protectedvirtual |
Drag/Drop code.
Reimplemented in DtFormationEditor.
|
protectedvirtual |
Reimplemented in DtFormationEditor.
|
protectedvirtual |
Reimplemented in DtFormationEditor.
|
protectedvirtual |
Reimplemented in DtFormationEditor.
|
protected |
Referenced by objectSelector().
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
Referenced by freezeSelection().
|
protected |