A map view implemented as a QWidget component. More...
| Header | #include <Map |
| Since | Esri |
| Inherits | Esri |
Public Functions
| Map | |
| Map | |
| virtual | ~ |
Signals
| void | analysis |
| void | attribution |
| void | attribution |
| void | draw |
| void | error |
| void | geo |
| void | hover |
| void | hover |
| void | hover |
| void | key |
| void | key |
| void | layer |
| void | map |
| void | map |
| void | map |
| void | mouse |
| void | mouse |
| void | mouse |
| void | mouse |
| void | mouse |
| void | mouse |
| void | mouse |
| void | navigating |
| void | rect |
| void | spatial |
| void | touched(QTouch |
| void | use |
| void | viewpoint |
Detailed Description
MapViewWidget is a QWidget-based view that renders a map and forwards user input (mouse, keyboard, touch) to the underlying view implementation. It emits signals for common GeoView events (for example, viewpointChanged, drawStatusChanged and input events).
Use MapViewWidget when building QWidget-based user interfaces that require an embedded map. For QML/QtQuick-based UIs use MapQuickView.
See also MapGraphicsView, MapQuickView, MapView, and GeoView.
Member Function Documentation
[explicit] MapViewWidget::MapViewWidget (QWidget *parent = nullptr)
Constructs a MapViewWidget with an optional parent.
[explicit] MapViewWidget::MapViewWidget (Esri::ArcGISRuntime::Map *map, QWidget *parent = nullptr)
Constructs a MapViewWidget with a map and an optional parent.
[override virtual noexcept] MapViewWidget::~MapViewWidget ()
Destroys the MapViewWidget.
[signal] void MapViewWidget::analysisViewStateChanged (Esri::ArcGISRuntime::Analysis *analysis, const Esri::ArcGISRuntime::AnalysisViewState &analysisViewState )
Signal emitted when the AnalysisViewState changes.
- analysis - The analysis that had a state change.
- analysisViewState - The AnalysisViewState with the new state information.
The returned Analysis object has the MapViewWidget as its parent.
See also Returned QObjects Parenting.
[signal] void MapViewWidget::attributionRectChanged ()
Emitted when the attribution bounding rectangle changes.
[signal] void MapViewWidget::attributionTextChanged ()
Emitted when the attribution text changes.
[signal] void MapViewWidget::drawStatusChanged (Esri::ArcGISRuntime::DrawStatus status)
Signal emitted when the DrawStatus changes.
- status - The new DrawStatus.
[signal] void MapViewWidget::errorOccurred (const Esri::ArcGISRuntime::Error &error)
Signal emitted when an error occurs.
- error - Details about the error.
[signal] void MapViewWidget::geoModelErrorChanged (const Esri::ArcGISRuntime::Error &error)
Signal emitted when the geo model error changes.
This error is used to indicate that the geo model assigned to the view had an issue loading or did not meet the requirements after loading, resulting in nothing rendering on screen.
This signal can be emitted multiple times but only one error can be active at a time. It is emitted when there is an error and when that error gets cleared. When the error is cleared, the error is represented as empty.
- error - The geo model error associated with the view.
[signal] void MapViewWidget::hoverEntered (QHoverEvent &hoverEvent )
Emitted when the cursor enters.
- hoverEvent - The hover event.
[signal] void MapViewWidget::hoverLeft (QHoverEvent &hoverEvent )
Emitted when the cursor leaves.
- hoverEvent - The hover event.
[signal] void MapViewWidget::hoverMoved (QHoverEvent &hoverEvent )
Emitted when the cursor moves.
- hoverEvent - The hover event.
[signal] void MapViewWidget::keyPressed (QKeyEvent &keyEvent )
Emitted when a key press is detected.
- keyEvent - The key event.
[signal] void MapViewWidget::keyReleased (QKeyEvent &keyEvent )
Emitted when a key release is detected.
- keyEvent - The key event.
[signal] void MapViewWidget::layerViewStateChanged (Esri::ArcGISRuntime::Layer *layer, const Esri::ArcGISRuntime::LayerViewState &layerViewState )
Signal emitted when the LayerViewState changes.
- layer - The layer that had a state change.
- layerViewState - The LayerViewState with the new state information.
The returned Layer object has the MapViewWidget as its parent.
See also Returned QObjects Parenting.
[signal] void MapViewWidget::mapChanged ()
Emitted when the map changes.
[signal] void MapViewWidget::mapRotationChanged ()
Signal emitted when the mapRotation changes.
[signal] void MapViewWidget::mapScaleChanged ()
Signal emitted when the mapScale changes.
[signal] void MapViewWidget::mouseClicked (QMouseEvent &mouseEvent )
Emitted when mouse is pressed and released over the same location.
- mouseEvent - The mouse event.
[signal] void MapViewWidget::mouseDoubleClicked (QMouseEvent &mouseEvent )
Emitted when a double click event is detected.
- mouseEvent - The mouse event.
[signal] void MapViewWidget::mouseMoved (QMouseEvent &mouseEvent )
Emitted when mouse is moved.
- mouseEvent - The mouse event.
[signal] void MapViewWidget::mousePressed (QMouseEvent &mouseEvent )
Emitted when mouse is pressed.
- mouseEvent - The mouse event.
[signal] void MapViewWidget::mousePressedAndHeld (QMouseEvent &mouseEvent )
Emitted when there is a long press and hold (currently 800ms) on the same point.
- mouseEvent - The mouse event.
[signal] void MapViewWidget::mouseReleased (QMouseEvent &mouseEvent )
Emitted when mouse is released.
- mouseEvent - The mouse event.
[signal] void MapViewWidget::mouseWheelChanged (QWheelEvent &wheelEvent )
Emitted when mouse wheel movement is detected.
- wheelEvent - The wheel event.
[signal] void MapViewWidget::navigatingChanged ()
Signal emitted when the view has started or completed navigating.
[signal] void MapViewWidget::rectChanged (const QRectF &rect)
Emitted when the visible area changes.
- rect - The new rect representing the visible area.
[signal] void MapViewWidget::spatialReferenceChanged ()
Signal emitted when the SpatialReference changed.
[signal] void MapViewWidget::touched(QTouchEvent &event)
Emitted when a touch event is detected.
- event - The touch event.
[signal] void MapViewWidget::useSystemTextScaleChanged ()
Emitted when the useSystemTextScale property changes.
[signal] void MapViewWidget::viewpointChanged ()
Emitted when the viewpoint changes.