28#include <QPainterPath>
74 sipType = sipType_QgsHighlight;
85 Q_PROPERTY( QColor color READ color WRITE setColor )
86 Q_PROPERTY( QColor fillColor READ fillColor WRITE setFillColor )
87 Q_PROPERTY(
int width READ width WRITE setWidth )
88 Q_PROPERTY(
int buffer READ buffer WRITE setBuffer )
112 QColor color()
const {
return mColor; }
118 void setColor(
const QColor &color );
131 void setFillColor(
const QColor &fillColor );
137 int width()
const {
return mWidth; }
144 void setWidth(
int width );
153 double buffer()
const {
return mBuffer; }
172 void updatePosition()
override;
179 void applyDefaultStyle();
182 void paint( QPainter *p )
override;
188 void updateTransformedGeometry();
201 std::unique_ptr<QgsFeatureRenderer> createRenderer(
QgsRenderContext &context,
const QColor &color,
const QColor &fillColor );
204 void paintPolygon( QPainter *p,
const QgsPolygonXY &polygon );
214 QPointer<QgsMapLayer> mLayer;
217 double mMinWidth = 0;
221 friend class QgsMapToolAddFeature;
222 friend class QgsUpdateGpsDetailsAction;
223 double mPointSizeRadiusMM = 1.5;
224 PointSymbol mPointSymbol = PointSymbol::Square;
RenderUnit
Rendering size units.
Abstract base class for all 2D vector feature renderers.
The feature class encapsulates a single feature including its unique ID, geometry and a list of field...
A geometry is the spatial representation of a feature.
Highlights features on the map.
QgsMapLayer * layer() const
Returns the layer for which this highlight has been created.
double buffer() const
Returns the line/stroke buffer size (in millimeters)
void setBuffer(double buffer)
Sets the line/stroke buffer size (in millimeters).
int width() const
Returns the stroke width.
QColor fillColor() const
Returns the fill color.
void setMinWidth(double width)
Sets the minimum line/stroke width (in millimeters).
An abstract class for items that can be placed on the map canvas.
Map canvas is a class for displaying all GIS data types on a canvas.
Base class for all map layer types.
Point geometry type, with support for z-dimension and m-values.
Contains information about the context of a rendering operation.
Abstract base class for all rendered symbols.
Represents a vector layer which manages a vector based dataset.
#define SIP_CONVERT_TO_SUBCLASS_CODE(code)
QVector< QgsPolylineXY > QgsPolygonXY
Polygon: first item of the list is outer ring, inner rings (if any) start from second item.
QVector< QgsPointXY > QgsPolylineXY
Polyline as represented as a vector of two-dimensional points.