|
QWT 7.0.1
|
An item, that represents a series of points. More...
#include <qwt_polar_curve.h>
Classes | |
| class | PrivateData |
Public Types | |
| enum | CurveStyle { NoCurve , Lines , UserCurve = 100 } |
| Curve styles. More... | |
| enum | LegendAttribute { LegendShowLine = 0x01 , LegendShowSymbol = 0x02 } |
| Attributes how to represent the curve on the legend. More... | |
Public Types inherited from QwtPolarItem | |
| enum | RttiValues { Rtti_PolarItem = 0 , Rtti_PolarGrid , Rtti_PolarMarker , Rtti_PolarCurve , Rtti_PolarSpectrogram , Rtti_PolarUserItem = 1000 } |
| Runtime type information. More... | |
| enum | ItemAttribute { Legend = 0x01 , AutoScale = 0x02 } |
| Plot Item Attributes. More... | |
| enum | RenderHint { RenderAntialiased = 0x01 } |
| Render hints. More... | |
Public Member Functions | |
| QwtPolarCurve () | |
| Constructor. | |
| QwtPolarCurve (const QwtText &title) | |
| Constructor. | |
| QwtPolarCurve (const QString &title) | |
| Constructor. | |
| virtual | ~QwtPolarCurve () |
| Destructor. | |
| virtual int | rtti () const QWT_OVERRIDE |
| void | setLegendAttribute (LegendAttribute, bool on=true) |
| Specify an attribute how to draw the legend identifier. | |
| bool | testLegendAttribute (LegendAttribute) const |
| Test if a legend attribute is enabled. | |
| void | setData (QwtSeriesData< QwtPointPolar > *data) |
| Initialize data with a pointer to QwtSeriesData<QwtPointPolar>. | |
| const QwtSeriesData< QwtPointPolar > * | data () const |
| size_t | dataSize () const |
| QwtPointPolar | sample (int i) const |
| void | setPen (const QPen &) |
| Assign a pen. | |
| const QPen & | pen () const |
| void | setStyle (CurveStyle style) |
| Set the curve's drawing style. | |
| CurveStyle | style () const |
| void | setSymbol (QwtSymbol *) |
| Assign a symbol. | |
| const QwtSymbol * | symbol () const |
| void | setCurveFitter (QwtCurveFitter *) |
| Insert a curve fitter. | |
| QwtCurveFitter * | curveFitter () const |
| virtual void | draw (QPainter *p, const QwtScaleMap &azimuthMap, const QwtScaleMap &radialMap, const QPointF &pole, double radius, const QRectF &canvasRect) const QWT_OVERRIDE |
| Draw the curve. | |
| virtual void | draw (QPainter *p, const QwtScaleMap &azimuthMap, const QwtScaleMap &radialMap, const QPointF &pole, int from, int to) const |
| Draw an interval of the curve. | |
| virtual QwtInterval | boundingInterval (int scaleId) const QWT_OVERRIDE |
| Interval, that is necessary to display the item This interval can be useful for operations like clipping or autoscaling. | |
| virtual QwtGraphic | legendIcon (int index, const QSizeF &) const QWT_OVERRIDE |
Public Member Functions inherited from QwtPolarItem | |
| QwtPolarItem (const QwtText &title=QwtText()) | |
| Constructor. | |
| virtual | ~QwtPolarItem () |
| Destroy the QwtPolarItem. | |
| void | attach (QwtPolarPlot *plot) |
| Attach the item to a plot. | |
| void | detach () |
| This method detaches a QwtPolarItem from the QwtPolarPlot it has been associated with. | |
| QwtPolarPlot * | plot () const |
| void | setTitle (const QString &title) |
| Set a new title. | |
| void | setTitle (const QwtText &title) |
| Set a new title. | |
| const QwtText & | title () const |
| void | setItemAttribute (ItemAttribute, bool on=true) |
| Toggle an item attribute. | |
| bool | testItemAttribute (ItemAttribute) const |
| Test an item attribute. | |
| void | setRenderHint (RenderHint, bool on=true) |
| Toggle an render hint. | |
| bool | testRenderHint (RenderHint) const |
| Test a render hint. | |
| void | setRenderThreadCount (uint numThreads) |
| On multi core systems rendering of certain plot item ( f.e QwtPolarSpectrogram ) can be done in parallel in several threads. | |
| uint | renderThreadCount () const |
| double | z () const |
| Plot items are painted in increasing z-order. | |
| void | setZ (double z) |
| Set the z value. | |
| void | show () |
| Show the item. | |
| void | hide () |
| Hide the item. | |
| virtual void | setVisible (bool) |
| Show/Hide the item. | |
| bool | isVisible () const |
| virtual void | itemChanged () |
| Update the legend and call QwtPolarPlot::autoRefresh for the parent plot. | |
| virtual void | legendChanged () |
| Update the legend of the parent plot. | |
| virtual void | updateScaleDiv (const QwtScaleDiv &, const QwtScaleDiv &, const QwtInterval &) |
| Update the item to changes of the axes scale division. | |
| virtual int | marginHint () const |
| Some items like to display something (f.e. | |
| void | setLegendIconSize (const QSize &) |
| Set the size of the legend icon. | |
| QSize | legendIconSize () const |
| virtual QList< QwtLegendData > | legendData () const |
| Return all information, that is needed to represent the item on the legend. | |
Protected Member Functions | |
| void | init () |
| Initialize data members. | |
| virtual void | drawCurve (QPainter *, int style, const QwtScaleMap &azimuthMap, const QwtScaleMap &radialMap, const QPointF &pole, int from, int to) const |
| Draw the line part (without symbols) of a curve interval. | |
| virtual void | drawSymbols (QPainter *, const QwtSymbol &, const QwtScaleMap &azimuthMap, const QwtScaleMap &radialMap, const QPointF &pole, int from, int to) const |
| Draw symbols. | |
| void | drawLines (QPainter *, const QwtScaleMap &azimuthMap, const QwtScaleMap &radialMap, const QPointF &pole, int from, int to) const |
| Draw lines. | |
An item, that represents a series of points.
A curve is the representation of a series of points in polar coordinates. The points are connected to the curve using the abstract QwtData interface.
Curve styles.
| Enumerator | |
|---|---|
| NoCurve | Don't draw a curve. Note: This doesn't affect the symbols. |
| Lines | Connect the points with straight lines. The lines might be interpolated depending on the 'Fitted' attribute. Curve fitting can be configured using setCurveFitter(). |
| UserCurve | Values > 100 are reserved for user specific curve styles. |
Attributes how to represent the curve on the legend.
If none of the flags is activated QwtPlotCurve tries to find a color representing the curve and paints a rectangle with it. In the default setting all attributes are off.
| Enumerator | |
|---|---|
| LegendShowLine | If the curveStyle() is not NoCurve a line is painted with the curvePen(). |
| LegendShowSymbol | If the curve has a valid symbol it is painted. |
|
explicit |
Constructor.
| title | title of the curve |
|
explicit |
Constructor.
| title | title of the curve |
|
virtual |
Interval, that is necessary to display the item This interval can be useful for operations like clipping or autoscaling.
| scaleId | Scale index |
Reimplemented from QwtPolarItem.
| QwtCurveFitter * QwtPolarCurve::curveFitter | ( | ) | const |
|
inline |
| size_t QwtPolarCurve::dataSize | ( | ) | const |
|
virtual |
Draw the curve.
| painter | Painter |
| azimuthMap | Maps azimuth values to values related to 0.0, M_2PI |
| radialMap | Maps radius values into painter coordinates. |
| pole | Position of the pole in painter coordinates |
| radius | Radius of the complete plot area in painter coordinates |
| canvasRect | Contents rect of the canvas in painter coordinates |
Implements QwtPolarItem.
|
virtual |
Draw an interval of the curve.
| painter | Painter |
| azimuthMap | Maps azimuth values to values related to 0.0, M_2PI |
| radialMap | Maps radius values into painter coordinates. |
| pole | Position of the pole in painter coordinates |
| from | index of the first point to be painted |
| to | index of the last point to be painted. If to < 0 the curve will be painted to its last point. |
|
protectedvirtual |
Draw the line part (without symbols) of a curve interval.
| painter | Painter |
| style | Curve style, see QwtPolarCurve::CurveStyle |
| azimuthMap | Maps azimuth values to values related to 0.0, M_2PI |
| radialMap | Maps radius values into painter coordinates. |
| pole | Position of the pole in painter coordinates |
| from | index of the first point to be painted |
| to | index of the last point to be painted. |
|
protected |
Draw lines.
| painter | Painter |
| azimuthMap | Maps azimuth values to values related to 0.0, M_2PI |
| radialMap | Maps radius values into painter coordinates. |
| pole | Position of the pole in painter coordinates |
| from | index of the first point to be painted |
| to | index of the last point to be painted. |
|
protectedvirtual |
Draw symbols.
| painter | Painter |
| symbol | Curve symbol |
| azimuthMap | Maps azimuth values to values related to 0.0, M_2PI |
| radialMap | Maps radius values into painter coordinates. |
| pole | Position of the pole in painter coordinates |
| from | index of the first point to be painted |
| to | index of the last point to be painted. |
|
virtual |
| index | Index of the legend entry ( ignored as there is only one ) |
| size | Icon size |
Reimplemented from QwtPolarItem.
| const QPen & QwtPolarCurve::pen | ( | ) | const |
|
virtual |
Reimplemented from QwtPolarItem.
|
inline |
| i | index |
| void QwtPolarCurve::setCurveFitter | ( | QwtCurveFitter * | curveFitter | ) |
Insert a curve fitter.
| curveFitter | Curve fitter |
A curve fitter interpolates the curve points. F.e QwtPolarFitter adds equidistant points so that the connection gets rounded instead of having straight lines. If curveFitter is NULL fitting is disabled.
| void QwtPolarCurve::setData | ( | QwtSeriesData< QwtPointPolar > * | data | ) |
Initialize data with a pointer to QwtSeriesData<QwtPointPolar>.
The x-values of the data object represent the azimuth, the y-value represents the radius.
| data | Data |
| void QwtPolarCurve::setLegendAttribute | ( | LegendAttribute | attribute, |
| bool | on = true |
||
| ) |
Specify an attribute how to draw the legend identifier.
| attribute | Attribute |
| on | On/Off /sa LegendAttribute, testLegendAttribute() |
| void QwtPolarCurve::setPen | ( | const QPen & | pen | ) |
| void QwtPolarCurve::setStyle | ( | CurveStyle | style | ) |
| void QwtPolarCurve::setSymbol | ( | QwtSymbol * | symbol | ) |
| QwtPolarCurve::CurveStyle QwtPolarCurve::style | ( | ) | const |
| const QwtSymbol * QwtPolarCurve::symbol | ( | ) | const |
| bool QwtPolarCurve::testLegendAttribute | ( | LegendAttribute | attribute | ) | const |
Test if a legend attribute is enabled.
| attribute | Legend attribute |