dptext.h

00001 /***************************************************************************
00002  *   Copyright (C) 2003-2005 by David Saxton                               *
00003  *   david@bluehaze.org                                                    *
00004  *                                                                         *
00005  *   This program is free software; you can redistribute it and/or modify  *
00006  *   it under the terms of the GNU General Public License as published by  *
00007  *   the Free Software Foundation; either version 2 of the License, or     *
00008  *   (at your option) any later version.                                   *
00009  ***************************************************************************/
00010 
00011 #ifndef CANVASTEXT_H
00012 #define CANVASTEXT_H
00013 
00014 #include "drawpart.h"
00015 
00020 class DPText : public DrawPart
00021 {
00022 public:
00023         DPText( ItemDocument *itemDocument, bool newItem, const char *id = 0 );
00024         ~DPText();
00025 
00026         static Item* construct( ItemDocument *itemDocument, bool newItem, const char *id );
00027         static LibraryItem *libraryItem();
00028         static LibraryItem *libraryItemOld();
00029 
00030         virtual void setSelected( bool yes );
00031         
00032         virtual QSize minimumSize() const;
00033 
00034 protected:
00035         virtual void postResize();
00036         
00037 private:
00038         virtual void drawShape( QPainter &p );
00039         void dataChanged();
00040         QString m_caption;
00041         bool b_displayBackground;
00042         QColor m_textColor;
00043         QColor m_backgroundColor;
00044         QColor m_frameColor;
00045         RectangularOverlay *m_rectangularOverlay;
00046 };
00047 
00048 #endif

Generated on Tue May 8 17:05:29 2007 for KTechLab by  doxygen 1.5.1