Qwt User's Guide 6.1.2

- Main Page
- Related Pages
- Classes

All Classes Functions Variables Typedefs Enumerations Enumerator Pages
qwt_plot_svgitem.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_PLOT_SVGITEM_H
11 #define QWT_PLOT_SVGITEM_H
12
13 #include "qwt_global.h"
14 #include "qwt_plot_item.h"
15 #include <qstring.h>
16
17 class QSvgRenderer;
18 class QByteArray;
19
27 class QWT_EXPORT QwtPlotSvgItem: public QwtPlotItem
28 {
29 public:
30 explicit QwtPlotSvgItem( const QString& title = QString::null );
31 explicit QwtPlotSvgItem( const QwtText& title );
32 virtual ~QwtPlotSvgItem();
33
34 bool loadFile( const QRectF&, const QString &fileName );
35 bool loadData( const QRectF&, const QByteArray & );
36
37 virtual QRectF boundingRect() const;
38
39 virtual void draw( QPainter *p,
40 const QwtScaleMap &xMap, const QwtScaleMap &yMap,
41 const QRectF &rect ) const;
42
43 virtual int rtti() const;
44
45 protected:
46 const QSvgRenderer &renderer() const;
47 QSvgRenderer &renderer();
48
49 void render( QPainter *painter,
50 const QRectF &viewBox, const QRectF &rect ) const;
51
52 QRectF viewBox( const QRectF &area ) const;
53
54 private:
55 void init();
56
57 class PrivateData;
58 PrivateData *d_data;
59 };
60
61 #endif
QwtPlotSvgItem
A plot item, which displays data in Scalable Vector Graphics (SVG) format.
Definition: qwt_plot_svgitem.h:27
QwtPlotItem::draw
virtual void draw(QPainter *painter, const QwtScaleMap &xMap, const QwtScaleMap &yMap, const QRectF &canvasRect) const =0
Draw the item.
QwtPlotItem
Base class for items on the plot canvas.
Definition: qwt_plot_item.h:64
QwtText
A class representing a text.
Definition: qwt_text.h:51
QwtScaleMap
A scale map.
Definition: qwt_scale_map.h:30
QwtPlotItem::rtti
virtual int rtti() const
Definition: qwt_plot_item.cpp:120
QwtPlotItem::boundingRect
virtual QRectF boundingRect() const
Definition: qwt_plot_item.cpp:537