QTimeSeries Homepage

Main Page   Alphabetical List   Compound List   File List   Compound Members  

qts_label.h

00001 /*****************************************************************************
00002 **  $Id: qts_label.h,v 1.1 2002/10/07 22:47:17 andrew23 Exp $
00003 **
00004 **  This is part of the qcad library
00005 **  Copyright (C) 2001 Andrew Mustun
00006 **
00007 **  This program is free software; you can redistribute it and/or modify
00008 **  it under the terms of the GNU General Public License (version 2) as
00009 **  published by the Free Software Foundation.
00010 **
00011 **  This program is distributed in the hope that it will be useful,
00012 **  but WITHOUT ANY WARRANTY; without even the implied warranty of
00013 **  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
00014 **  GNU General Public License for more details.
00015 **
00016 **  You should have received a copy of the GNU General Public License
00017 **  along with this program; if not, write to the Free Software
00018 **  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
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

Copyright © 2002, Andrew Mustun <andrew@mustun.com>. All rights reserved.
System documentation was generated using doxygen.