Main Page   Class Hierarchy   Compound List   File List   Compound Members   File Members  

Txq2dLabel.h

Go to the documentation of this file.
00001 //---------------------------------------------------------------------------
00002 //
00003 // File:    Txq2dLabel.h
00004 //
00005 // Purpose:  A class for drawing text on the Txq2dCanvas.
00006 //
00007 // Version: $Id: Txq2dLabel.h,v 1.6 2002/01/17 19:29:21 kgl Exp $
00008 //
00009 // Author: Kelly G. Luetkemeyer
00010 //
00011 //---------------------------------------------------------------------------
00012 
00013 #ifndef TXQ2D_LABEL_H
00014 #define TXQ2D_LABEL_H
00015 
00016 // Txq includes
00017 #include "Txq2dDrawable.h"
00018 #include "TxqDoublePoint.h"
00019 
00024 class Txq2dLabel: public Txq2dDrawable 
00025 {
00026 
00027 public:
00031   Txq2dLabel();
00032 
00040   Txq2dLabel(QString thisLabel, double sx, double sy);
00041 
00045   virtual ~Txq2dLabel();
00046 
00051   void setLabel(QString label);
00052 
00057   QString getLabel();
00058 
00063   void setLocation(TxqDoublePoint p);
00064 
00070   void setLocation(double x, double y);
00071 
00077   void setLocation(int x, int y);
00078 
00083   void setLocation(QPoint p);
00084 
00089   TxqDoublePoint getLocation(); 
00090 
00095  void setFont(QFont f);
00096 
00101  QFont getFont();
00102 
00107   void paint(QPainter* g );
00108 
00109 protected:
00110 
00116   void dump(QTextStream *ts);
00117 
00121   TxqDoublePoint point;
00122 
00126   QFont font;
00127 
00131  QString label;
00132 
00133 };
00134 #endif
Copyright Tech-X Corporation, all rights reserved.