MAK Data Logger API Documentation for HLA
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
vectorButton.h
Go to the documentation of this file.
1 /******************************************************************************
2 ** Copyright (c) 1992-2010 VT MAK
3 ** All rights reserved.
4 ******************************************************************************/
5 
9 
10 
11 #ifndef vectorButton_H_
12 #define vectorButton_H_
13 
14 #include <lgrGui/lgrGui.h>
15 
16 #include <QAbstractButton>
17 
18 class QWidget;
19 class QPolygon;
20 class QPalette;
21 
22 
23 namespace MAKLogger
24 {
25 
26  class DtVectorButton;
27 
30  {
31  bool hasFocus;
33  bool isDown;
34  bool isEnabled;
35  };
36 
37  typedef void (*DtDrawButtonFunction)(QPainter& painter,const QPalette& pal,
38  DtDrawButtonState& state);
39 
42  {
43  Q_OBJECT
44 
45  public:
46 
47  DtVectorButton(QWidget* parent);
48 
49  DtDrawButtonFunction drawFunction() const;
50  void setDrawFunction(DtDrawButtonFunction function);
51 
52  protected:
53 
54  virtual void enterEvent(QEvent*);
55  virtual void leaveEvent(QEvent*);
56  virtual void paintEvent( QPaintEvent* );
57 
59  };
60 
63  {
64  public:
65 
66  static void hideButton(QPainter& painter,const QPalette& pal,DtDrawButtonState& state);
67 
68  static void drawButton(QPainter& painter,QPolygonF& points,
69  QColor light,QColor mid,QColor dark,QColor fill);
70 
71  static void leftBoundButton(QPainter& painter,const QPalette& pal,DtDrawButtonState& state,QRectF rect);
72  static void leftArrowButton(QPainter& painter,const QPalette& pal,DtDrawButtonState& state);
73  static void upArrowButton(QPainter& painter, const QPalette& pal, DtDrawButtonState& state);
74  static void downArrowButton(QPainter& painter, const QPalette& pal, DtDrawButtonState& state);
75  static void leftCircleButton(QPainter& painter, const QPalette& pal,DtDrawButtonState& state,QRectF rect);
76 
77  static void rightBoundButton(QPainter& painter,const QPalette& pal,DtDrawButtonState& state,QRectF rect);
78  static void rightArrowButton(QPainter& painter,const QPalette& pal,DtDrawButtonState& state);
79  static void rightCircleButton(QPainter& painter, const QPalette& pal,DtDrawButtonState& state,QRectF rect);
80 
81  static void fillArc( QPainter &painter, const QBrush& brush,const QPen& pen, QRectF top,int,int );
82 
83  };
84 
85 }
86 
87 #endif

Document ID: Generated on Tue Aug 1 09:00:26 EDT 2017 from SVN revision 179128
Copyright © 2017 VT MÄK. All Rights Reserved (www.mak.com)