31 #ifndef PT_GFX_PAINTER_H
32 #define PT_GFX_PAINTER_H
34 #include <Pt/Gfx/Api.h>
35 #include <Pt/Gfx/Size.h>
36 #include <Pt/Gfx/Point.h>
37 #include <Pt/Gfx/Rect.h>
38 #include <Pt/Gfx/Font.h>
39 #include <Pt/Gfx/FontMetrics.h>
40 #include <Pt/Gfx/Pen.h>
41 #include <Pt/Gfx/Brush.h>
42 #include <Pt/Gfx/Transform.h>
43 #include <Pt/String.h>
66 virtual void setCompositionMode(
const CompositionMode& mode) = 0;
70 virtual const CompositionMode& compositionMode()
const = 0;
74 virtual void setClip(
const RectF& clip) = 0;
78 virtual void setPen(
const Pen& pen) = 0;
82 virtual const Pen& pen()
const = 0;
86 virtual void setBrush(
const Brush& brush) = 0;
90 virtual const Brush& brush()
const = 0;
94 virtual void setFont(
const Font& font) = 0;
98 virtual const Font& font()
const = 0;
102 virtual FontMetrics fontMetrics(
const Pt::String& text)
const = 0;
106 virtual void drawLine(
const PointF& from,
const PointF& to) = 0;
110 virtual void drawPolyline(
const PointF* points,
const size_t pointCount) = 0;
114 virtual void fillPolygon(
const PointF* points,
const size_t pointCount) = 0;
122 virtual void drawRect(
const RectF& rect) = 0;
126 virtual void fillRect(
const RectF& rect) = 0;
132 drawEllipse(topLeft,
SizeF(diameter, diameter));
139 fillEllipse(topLeft,
SizeF(diameter, diameter));
144 virtual void drawEllipse(
const PointF& topLeft,
const SizeF& size) = 0;
148 virtual void fillEllipse(
const PointF& topLeft,
const SizeF& size) = 0;
152 virtual void drawImage(
const PointF& to,
const Image& im) = 0;
156 virtual void drawImage(
const PointF& to,
const Image& im,
const RectF& rect) = 0;
virtual ~Painter()
Destructor.
Definition: Painter.h:57
void drawCircle(const PointF &topLeft, std::size_t diameter)
Draws the outline of a circle.
Definition: Painter.h:130
Attributs for the drawing of outlines.
Definition: Pen.h:52
Unicode capable basic_string.
Definition: String.h:42
void fillCircle(const PointF &topLeft, std::size_t diameter)
Fills a circular area.
Definition: Painter.h:137
2D painter interface.
Definition: Painter.h:53
Generic image.
Definition: Image.h:43