superkaramba
bar.h
00001
00002
00003
00004
00005
00006
00007
00008
00009
00010 #ifndef BAR_H
00011 #define BAR_H
00012
00013 #include "meter.h"
00014 #include <tqpixmap.h>
00015 #include <tqstring.h>
00016 #include <tqpainter.h>
00017
00018 class Bar : public Meter
00019 {
00020 Q_OBJECT
00021 public:
00022 Bar(karamba* k,int ix,int iy,int iw,int ih );
00023 ~Bar();
00024
00025 void mUpdate( TQPainter * );
00026
00027 virtual void setMax( long m );
00028 virtual void setMin( long m );
00029
00030 public slots:
00031 bool setImage( TQString imagePath );
00032 TQString getImage() { return imagePath; };
00033
00034 void setValue( long );
00035 long getValue() { return barValue; };
00036 void setValue( TQString );
00037 void recalculateValue() {setValue(barValue); };
00038
00039 void setVertical( bool );
00040 int getVertical() { return vertical; };
00041
00042 private:
00043 long barValue;
00044 long value;
00045
00046 int pixmapWidth;
00047 int pixmapHeight;
00048
00049 bool vertical;
00050
00051 TQString imagePath;
00052 TQPixmap pixmap;
00053 }
00054 ;
00055 #endif // BAR_H