Main Page | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members | Related Pages

qwt_arrbtn.h

00001 /* -*- mode: C++ ; c-file-style: "stroustrup" -*- *****************************
00002  * Qwt Widget Library
00003  * Copyright (C) 1997   Josef Wilgen
00004  * Copyright (C) 2002   Uwe Rathmann
00005  * 
00006  * This library is free software; you can redistribute it and/or
00007  * modify it under the terms of the Qwt License, Version 1.0
00008  *****************************************************************************/
00009 
00010 #ifndef QWT_ARRBTN_H
00011 #define QWT_ARRBTN_H
00012 
00013 #include <qpushbutton.h>
00014 #include "qwt_global.h"
00015 
00023 class QWT_EXPORT QwtArrowButton : public QPushButton
00024 {
00025 public:
00026     QwtArrowButton (int num, Qt::ArrowType, QWidget *parent,
00027           const char *name = 0);
00028 
00029     Qt::ArrowType arrowType() const;
00030     int num() const;
00031 
00032     virtual QSize sizeHint() const;
00033     virtual QSize minimumSizeHint() const;
00034     virtual QSizePolicy sizePolicy() const;
00035 
00036 protected:
00037     virtual void drawButtonLabel(QPainter *p);
00038     virtual void drawArrow(QPainter *, 
00039         const QRect &, Qt::ArrowType) const;
00040     virtual QRect labelRect() const;
00041     virtual QSize arrowSize(Qt::ArrowType,
00042         const QSize &boundingSize) const;
00043 
00044     virtual void keyPressEvent(QKeyEvent *);
00045 
00046 private:
00047 
00048     const int d_num;
00049     const Qt::ArrowType d_arrowType;
00050 };
00051 
00052 #endif

Generated on Sun Nov 21 11:12:42 2004 for Qwt User's Guide by doxygen 1.3.5