21 #include <QGraphicsRectItem>
32 enum {Type = UserType + Rectangle
48 RectItem(
double x0 = 0,
double y0 = 0,
unsigned color = 0,
49 QGraphicsItem* parent = 0,
double width = 3,
double height = 2,
50 bool visible =
true, FillStyle fillStyle = NoBrush,
51 double relSize = 1,
double dir = 0);
63 RectItem(
const KConfigGroup* plo,
unsigned color = 0,
68 inline double dir()
const {
return m_dir; };
72 inline double height()
const {
return m_height; };
79 inline void setDir(
double dir) { m_dir = dir; };
89 inline void setHeight(
double height) { m_height = height; };
101 inline void setWidth(
double width) { m_width = width; };
103 virtual int type()
const {
return Type; };
107 inline double width()
const {
return m_width; };
112 void writePlo(KConfigGroup* plo)
const;
118 void setProperties();
119 FillStyle m_fillStyle;
120 double m_width, m_height, m_dir;
double width() const
Returns width in cm.
Definition: rectitem.h:107
virtual void mouseReleaseEvent(QGraphicsSceneMouseEvent *event)
FillStyle
Fill styles.
Definition: kplitem.h:47
void setHeight(double height)
Sets height.
Definition: rectitem.h:89
double height() const
Returns height in cm.
Definition: rectitem.h:72
void writePlo(KConfigGroup *plo, bool visible) const
Writes into plot file.
void update(const QRectF &rect)
Rectangle item class.
Definition: rectitem.h:28
virtual int type() const
Returns specific QGraphicsItem type number.
Definition: rectitem.h:103
void setFillStyle(FillStyle style)
Sets fill style.
Definition: rectitem.h:84
void setDir(double dir)
Sets rotation angle.
Definition: rectitem.h:79
void setWidth(double width)
Sets width.
Definition: rectitem.h:101
static QPixmap pixmap(Symbol symbol)
Returns black decoration pixmap of plot symbol for use in dialog GUI.
double dir() const
Returns rotation angle in deg.
Definition: rectitem.h:68
Decoration item class.
Definition: decoitem.h:36
FillStyle fillStyle() const
Returns fill style.
Definition: rectitem.h:70