00001
00002
00003
00004
00005
00006
00007
00008
00009
00010 #ifndef QWT_INTERVAL_SYMBOL_H
00011 #define QWT_INTERVAL_SYMBOL_H
00012
00013 #include "qwt_global.h"
00014 #include <qpen.h>
00015 #include <qsize.h>
00016
00017 class QPainter;
00018 class QRect;
00019 class QPointF;
00020
00026 class QWT_EXPORT QwtIntervalSymbol
00027 {
00028 public:
00049 enum Style
00050 {
00051 NoSymbol = -1,
00052
00053 Bar,
00054 Box,
00055
00056 UserSymbol = 1000
00057 };
00058
00059 public:
00060 QwtIntervalSymbol( Style = NoSymbol );
00061 QwtIntervalSymbol( const QwtIntervalSymbol & );
00062 virtual ~QwtIntervalSymbol();
00063
00064 QwtIntervalSymbol &operator=( const QwtIntervalSymbol & );
00065 bool operator==( const QwtIntervalSymbol & ) const;
00066 bool operator!=( const QwtIntervalSymbol & ) const;
00067
00068 void setWidth( int );
00069 int width() const;
00070
00071 void setBrush( const QBrush& b );
00072 const QBrush& brush() const;
00073
00074 void setPen( const QPen & );
00075 const QPen& pen() const;
00076
00077 void setStyle( Style );
00078 Style style() const;
00079
00080 virtual void draw( QPainter *, Qt::Orientation,
00081 const QPointF& from, const QPointF& to ) const;
00082
00083 private:
00084
00085 class PrivateData;
00086 PrivateData* d_data;
00087 };
00088
00089 #endif