00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00020
00021 #ifndef QTS_LABEL_H
00022 #define QTS_LABEL_H
00023
00024 #include "rs_line.h"
00025 #include "rs_vector.h"
00026
00032 class QTS_Label : public RS_Line {
00033 public:
00034 QTS_Label(RS_EntityContainer* parent);
00035 QTS_Label(RS_EntityContainer* parent,
00036 const RS_Vector& p1,
00037 const RS_Vector& p2,
00038 const RS_String& text);
00039
00040 virtual RS_Entity* clone();
00041
00042 virtual ~QTS_Label();
00043
00045 virtual RS::EntityType rtti() const {
00046 return RS::EntityUnknown;
00047 }
00048
00049 RS_String getText() const {
00050 return text;
00051 }
00052
00053 virtual void move(RS_Vector offset);
00054 virtual void rotate(RS_Vector center, double angle);
00055 virtual void scale(RS_Vector center, RS_Vector factor);
00056
00057 friend std::ostream& operator << (std::ostream& os, const QTS_Label& l);
00058
00059 protected:
00060 virtual void calculateBorders();
00061
00062 protected:
00063 RS_String text;
00064 };
00065
00066 #endif