Qwt User's Guide 6.1.1

- Main Page
- Related Pages
- Classes

All Classes Functions Variables Typedefs Enumerations Enumerator Pages
qwt_round_scale_draw.h
1 /* -*- mode: C++ ; c-file-style: "stroustrup" -*- *****************************
2 * Qwt Widget Library
3 * Copyright (C) 1997 Josef Wilgen
4 * Copyright (C) 2002 Uwe Rathmann
5 *
6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the Qwt License, Version 1.0
8 *****************************************************************************/
9
10 #ifndef QWT_ROUND_SCALE_DRAW_H
11 #define QWT_ROUND_SCALE_DRAW_H
12
13 #include "qwt_global.h"
14 #include "qwt_abstract_scale_draw.h"
15 #include <qpoint.h>
16
30 class QWT_EXPORT QwtRoundScaleDraw: public QwtAbstractScaleDraw
31 {
32 public:
33 QwtRoundScaleDraw();
34 virtual ~QwtRoundScaleDraw();
35
36 void setRadius( double radius );
37 double radius() const;
38
39 void moveCenter( double x, double y );
40 void moveCenter( const QPointF & );
41 QPointF center() const;
42
43 void setAngleRange( double angle1, double angle2 );
44
45 virtual double extent( const QFont & ) const;
46
47 protected:
48 virtual void drawTick( QPainter *, double val, double len ) const;
49 virtual void drawBackbone( QPainter * ) const;
50 virtual void drawLabel( QPainter *, double val ) const;
51
52 private:
53 QwtRoundScaleDraw( const QwtRoundScaleDraw & );
54 QwtRoundScaleDraw &operator=( const QwtRoundScaleDraw &other );
55
56 class PrivateData;
57 PrivateData *d_data;
58 };
59
61 inline void QwtRoundScaleDraw::moveCenter( double x, double y )
62 {
63 moveCenter( QPointF( x, y ) );
64 }
65
66 #endif
QwtAbstractScaleDraw
A abstract base class for drawing scales.
Definition: qwt_abstract_scale_draw.h:31
QwtAbstractScaleDraw::extent
virtual double extent(const QFont &font) const =0
QwtRoundScaleDraw
A class for drawing round scales.
Definition: qwt_round_scale_draw.h:30
QwtAbstractScaleDraw::drawTick
virtual void drawTick(QPainter *painter, double value, double len) const =0
QwtAbstractScaleDraw::drawBackbone
virtual void drawBackbone(QPainter *painter) const =0
QwtAbstractScaleDraw::drawLabel
virtual void drawLabel(QPainter *painter, double value) const =0
QwtRoundScaleDraw::moveCenter
void moveCenter(double x, double y)
Move the center of the scale draw, leaving the radius unchanged.
Definition: qwt_round_scale_draw.h:61