18 #ifndef QGSDXFPAINTENGINE_H 19 #define QGSDXFPAINTENGINE_H 23 #include "qgis_core.h" 24 #include <QPaintEngine> 43 bool begin( QPaintDevice *pdev )
override;
45 QPaintEngine::Type type()
const override;
46 void updateState(
const QPaintEngineState &state )
override;
48 void drawPixmap(
const QRectF &r,
const QPixmap &pm,
const QRectF &sr )
override;
50 void drawPolygon(
const QPointF *points,
int pointCount, PolygonDrawMode mode )
override;
51 void drawPath(
const QPainterPath &path )
override;
52 void drawLines(
const QLineF *lines,
int lineCount )
override;
54 void setLayer(
const QString &layer ) { mLayer = layer; }
55 QString
layer()
const {
return mLayer; }
57 void setShift( QPointF shift ) { mShift = shift; }
64 QTransform mTransform;
68 double mOpacity = 1.0;
72 QPolygonF mCurrentPolygon;
73 QList<QPointF> mCurrentCurve;
75 QgsPoint toDxfCoordinates( QPointF pt )
const;
76 double currentWidth()
const;
78 void moveTo(
double dx,
double dy );
79 void lineTo(
double dx,
double dy );
80 void curveTo(
double dx,
double dy );
84 void setRing(
QgsPointSequence &polyline,
const QPointF *points,
int pointCount );
87 static QPointF bezierPoint(
const QList<QPointF> &controlPolygon,
double t );
88 static double bernsteinPoly(
int n,
int i,
double t );
89 static int lower(
int n,
int i );
90 static double power(
double a,
int b );
94 QColor penColor()
const;
96 QColor brushColor()
const;
99 #endif // QGSDXFPAINTENGINE_H A paint device for drawing into dxf files.
void setShift(QPointF shift)
Point geometry type, with support for z-dimension and m-values.
QVector< QgsPoint > QgsPointSequence
QVector< QgsPointSequence > QgsRingSequence
int ANALYSIS_EXPORT lower(int n, int i)
Lower function.
void setLayer(const QString &layer)
int ANALYSIS_EXPORT faculty(int n)
Faculty function.