forked from liuzenan/MapGraphics
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathArrowObject.h
More file actions
36 lines (26 loc) · 814 Bytes
/
ArrowObject.h
File metadata and controls
36 lines (26 loc) · 814 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
#ifndef ARROWOBJECT_H
#define ARROWOBJECT_H
#include "MapGraphics_global.h"
#include "Position.h"
#include "MapGraphicsObject.h"
class MAPGRAPHICSSHARED_EXPORT ArrowObject : public MapGraphicsObject
{
Q_OBJECT
public:
explicit ArrowObject(qreal dx, qreal dy,
QColor color = QColor(0,0,0,0),
MapGraphicsObject *parent = nullptr);
virtual ~ArrowObject() override;
// pure-virtual from MapGraphicsObject
QRectF boundingRect() const override;
// pure-virtual from MapGraphicsObject
void paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget) override;
void setColor(const QColor& color);
signals:
public slots:
private slots:
private:
qreal _dx, _dy;
QColor _color;
};
#endif // ARROWOBJECT_H