marble
AreaAnnotation.cpp
Go to the documentation of this file.
255 // The offset in pixels after which a mouse move event should not be considered actually a mouse
271 m_viewport->screenCoordinates( m_movedPointCoords.longitude(), m_movedPointCoords.latitude(), x, y );
void clear()
GeoDataCoordinates moveByBearing(qreal bearing, qreal distance) const
Returns the coordinates of the resulting point after moving this point according to the distance and ...
Definition: GeoDataCoordinates.cpp:1226
virtual const char * nodeType() const
Provides type information for downcasting a GeoData.
Definition: GeoDataGeometry.cpp:77
A LinearRing that allows to store a closed, contiguous set of line segments.
Definition: GeoDataLinearRing.h:68
const char * GeoDataPolygonType
Definition: GeoDataTypes.cpp:69
virtual bool contains(const GeoDataCoordinates &coordinates) const
Returns whether the given coordinates lie within the polygon.
Definition: GeoDataLinearRing.cpp:58
bool geoCoordinates(const int x, const int y, qreal &lon, qreal &lat, GeoDataCoordinates::Unit unit=GeoDataCoordinates::Degree) const
Get the earth coordinates corresponding to a pixel in the map.
Definition: ViewportParams.cpp:391
A painter that allows to draw geometric primitives on the map.
Definition: GeoPainter.h:98
virtual const char * graphicType() const
Provides information for downcasting a SceneGraphicsItem.
Definition: AreaAnnotation.cpp:378
QPair< int, int > & mergedNodes()
Getters for the nodes to be merged.
Definition: AreaAnnotation.cpp:373
virtual void paint(GeoPainter *painter, const ViewportParams *viewport)
Paints the item using the given GeoPainter.
Definition: AreaAnnotation.cpp:41
const T & at(int i) const
virtual bool mouseReleaseEvent(QMouseEvent *event)
Definition: AreaAnnotation.cpp:253
QList< int > & selectedNodes()
Returns the list of selected node indexes.
Definition: AreaAnnotation.cpp:320
void setRegions(const QList< QRegion > ®ions)
A setter for the m_regions private member.
Definition: SceneGraphicsItem.cpp:36
void save()
int rightClickedNode() const
Returns the node index on which the mouse press event (with the right button) has been caught...
Definition: AreaAnnotation.cpp:325
qreal distanceSphere(qreal lon1, qreal lat1, qreal lon2, qreal lat2)
This method calculates the shortest distance between two points on a sphere.
Definition: MarbleMath.h:52
qreal latitude(GeoDataCoordinates::Unit unit=GeoDataCoordinates::Radian) const
retrieves the latitude of the GeoDataCoordinates object use the unit parameter to switch between Radi...
Definition: GeoDataCoordinates.cpp:751
void drawEllipse(const GeoDataCoordinates ¢erPosition, qreal width, qreal height, bool isGeoProjected=false)
Draws an ellipse at the given position. The ellipse is placed with its center located at the given ce...
Definition: GeoPainter.cpp:289
QRegion regionFromEllipse(const GeoDataCoordinates ¢erPosition, qreal width, qreal height, bool isGeoProjected=false, qreal strokeWidth=3) const
Creates a region for an ellipse at a given position.
Definition: GeoPainter.cpp:356
int x() const
int y() const
int size() const
GeoDataGeometry * geometry()
The geometry of the GeoDataPlacemark is to be rendered to the marble map along with the icon at the c...
Definition: GeoDataPlacemark.cpp:152
AreaAnnotation(GeoDataPlacemark *placemark)
Definition: AreaAnnotation.cpp:31
void append(const T &value)
bool isInnerBoundsPoint(const QPoint &point, bool restrictive=false) const
Checks whether the point parameter is contained by one of its inner boundaries.
Definition: AreaAnnotation.cpp:330
Qt::MouseButton button() const
This is the base class for all scene graphics included within the annotate plugin.
Definition: SceneGraphicsItem.h:34
virtual bool mouseMoveEvent(QMouseEvent *event)
Definition: AreaAnnotation.cpp:153
int removeAll(const T &value)
qreal bearing(const GeoDataCoordinates &other, Unit unit=Radian, BearingType type=InitialBearing) const
Returns the bearing (true bearing, the angle between the line defined by this point and the other and...
Definition: GeoDataCoordinates.cpp:1213
void setBrush(const QBrush &brush)
bool screenCoordinates(const qreal lon, const qreal lat, qreal &x, qreal &y) const
Get the screen coordinates corresponding to geographical coordinates in the map.
Definition: ViewportParams.cpp:357
static void normalizeLonLat(qreal &lon, qreal &lat, GeoDataCoordinates::Unit=GeoDataCoordinates::Radian)
normalize both longitude and latitude at the same time This method normalizes both latitude and longi...
Definition: GeoDataCoordinates.cpp:845
void set(qreal lon, qreal lat, qreal alt=0, GeoDataCoordinates::Unit unit=GeoDataCoordinates::Radian)
(re)set the coordinates in a GeoDataCoordinates object
Definition: GeoDataCoordinates.cpp:657
void append(const GeoDataCoordinates &position)
Appends a given geodesic position as a new node to the LineString.
Definition: GeoDataLineString.cpp:225
GeoDataLinearRing & outerBoundary()
Returns the outer boundary that is represented as a LinearRing.
Definition: GeoDataPolygon.cpp:123
GeoDataCoordinates & at(int pos)
Returns a reference to the coordinates of a node at a given position. This method detaches the return...
Definition: GeoDataLineString.cpp:143
A public class that controls what is visible in the viewport of a Marble map.
Definition: ViewportParams.h:44
bool contains(const QPoint &p) const
qreal longitude(GeoDataCoordinates::Unit unit=GeoDataCoordinates::Radian) const
retrieves the longitude of the GeoDataCoordinates object use the unit parameter to switch between Rad...
Definition: GeoDataCoordinates.cpp:739
bool contains(const T &value) const
void setLatitude(qreal lat, GeoDataCoordinates::Unit unit=GeoDataCoordinates::Radian)
set the longitude in a GeoDataCoordinates object
Definition: GeoDataCoordinates.cpp:699
This file contains the headers for ViewportParams.
void restore()
void setLongitude(qreal lon, GeoDataCoordinates::Unit unit=GeoDataCoordinates::Radian)
set the longitude in a GeoDataCoordinates object
Definition: GeoDataCoordinates.cpp:679
const T & at(int i) const
QList< QRegion > regions() const
Returns the list of regions which form the scene graphic element.
Definition: SceneGraphicsItem.cpp:31
QRegion regionFromPolygon(const GeoDataLinearRing &linearRing, Qt::FillRule fillRule, qreal strokeWidth=3) const
Creates a region for a given linear ring (a "polygon without holes").
Definition: GeoPainter.cpp:585
const char * SceneGraphicAreaAnnotation
Definition: SceneGraphicsTypes.cpp:20
QVector< GeoDataLinearRing > & innerBoundaries()
Returns a set of inner boundaries which are represented as LinearRings.
Definition: GeoDataPolygon.cpp:139
const GeoDataPlacemark * placemark() const
SceneGraphicItem class, when called from one of its derived classes' constructors, takes as a parameter a pointer to the placemark of the graphic element.
Definition: SceneGraphicsItem.cpp:41
const QPoint & pos() const
void setMergedNodes(const QPair< int, int > &nodes)
Sets the nodes to be merged.
Definition: AreaAnnotation.cpp:368
bool isValidPolygon() const
Checks if the polygon has a valid shape; an invalid shape would be, for example, if one of its inner ...
Definition: AreaAnnotation.cpp:353
Definition: MarbleGlobal.h:32
int size() const
a class representing a point of interest on the map
Definition: GeoDataPlacemark.h:54
virtual bool mousePressEvent(QMouseEvent *event)
In the implementation of these virtual functions, the following convention has been followed: if the ...
Definition: AreaAnnotation.cpp:109
This file is part of the KDE documentation.
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:13:38 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
Documentation copyright © 1996-2020 The KDE developers.
Generated on Mon Jun 22 2020 13:13:38 by doxygen 1.8.7 written by Dimitri van Heesch, © 1997-2006
KDE's Doxygen guidelines are available online.