Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Class Members | File Members

iconlabel.h

Go to the documentation of this file.
00001 /***************************************************************************
00002  *   Copyright (C) 2003 by Bosselut Cyril                                   *
00003  *   bosselut@b1project.com                                                      *
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 #ifndef ICONLABEL_H
00011 #define ICONLABEL_H
00012 
00013 #include <qpixmap.h>
00014 #include <qimage.h>
00015 #include <qpainter.h>
00016 #include <qstring.h>
00017 #include <qstringlist.h>
00018 #include <qtimer.h>
00019 #include <qtooltip.h>
00020 
00021 #include <kiconloader.h>
00022 
00023 #include "karamba.h"
00024 #include "meter.h"
00025 
00026 class karamba;
00027 
00032 class IconLabel : public Meter
00033 {
00034 public:
00035   IconLabel( int ix,int iy,int iw,int ih );
00036   IconLabel();
00037   ~IconLabel();
00038   void setValue( QString imagePath );
00039 
00040   void setValue( int );
00041   void setSize( int s=0 );
00042   void setCenter( bool c, int w=0, int h=0 );
00043   void mUpdate( QPainter * );
00044 
00045   void rolloverImage(QMouseEvent *e);
00046   void parseImages( QString fn, int, int, int, int, int won=0 );
00047 
00048   void setKaramba(karamba*);
00049   void setTooltip(QString txt);
00050   QPixmap pixmap;
00051 
00052 private:
00053 
00054   int pixmapWidth;
00055   int pixmapHeight;
00056   int woff;
00057   int won;
00058   bool center;
00059   int witdh;
00060   int height;
00061   QString icon;
00062 
00063   QRect rect_off, rect_on;
00064 
00065   bool zoomed;
00066   bool rollover;
00067   QPixmap pixmap_off;
00068   QPixmap pixmap_on;
00069   int xoff,xon;
00070   int yoff,yon;
00071   karamba* myKaramba;
00072   KIconLoader* i;
00073 }
00074 ;
00075 #endif // ICONLABEL_H

Generated on Mon May 16 13:59:20 2005 for karamba by  doxygen 1.3.9.1