|
QWT API (中文) 7.0.1
Qt绘图库 - 中文API文档
|
极坐标绘图项的基类 更多...
#include <qwt_polar_item.h>
类 | |
| class | PrivateData |
Public 类型 | |
| enum | RttiValues { Rtti_PolarItem = 0 , Rtti_PolarGrid , Rtti_PolarMarker , Rtti_PolarCurve , Rtti_PolarSpectrogram , Rtti_PolarUserItem = 1000 } |
| enum | ItemAttribute { Legend = 0x01 , AutoScale = 0x02 } |
| enum | RenderHint { RenderAntialiased = 0x01 } |
Public 成员函数 | |
| QwtPolarItem (const QwtText &title=QwtText()) | |
| Constructor | |
| virtual | ~QwtPolarItem () |
| Destructor | |
| void | attach (QwtPolarPlot *plot) |
| Attach the item to a plot | |
| void | detach () |
| Detach the item from its plot | |
| QwtPolarPlot * | plot () const |
| Get the attached plot | |
| void | setTitle (const QString &title) |
| Set the title from a QString | |
| void | setTitle (const QwtText &title) |
| Set the title from a QwtText | |
| const QwtText & | title () const |
| Get the title | |
| virtual int | rtti () const |
| Get the runtime type information | |
| void | setItemAttribute (ItemAttribute, bool on=true) |
| Set an item attribute | |
| bool | testItemAttribute (ItemAttribute) const |
| Test an item attribute | |
| void | setRenderHint (RenderHint, bool on=true) |
| Set a render hint | |
| bool | testRenderHint (RenderHint) const |
| Test a render hint | |
| void | setRenderThreadCount (uint numThreads) |
| Set the number of render threads | |
| uint | renderThreadCount () const |
| Get the number of render threads | |
| double | z () const |
| Get the z value | |
| void | setZ (double z) |
| Set the z value | |
| void | show () |
| Show the item | |
| void | hide () |
| Hide the item | |
| virtual void | setVisible (bool) |
| Set the visibility | |
| bool | isVisible () const |
| Get the visibility | |
| virtual void | itemChanged () |
| Update the item and trigger autoRefresh | |
| virtual void | legendChanged () |
| Update the legend | |
| virtual void | draw (QPainter *painter, const QwtScaleMap &azimuthMap, const QwtScaleMap &radialMap, const QPointF &pole, double radius, const QRectF &canvasRect) const =0 |
| virtual QwtInterval | boundingInterval (int scaleId) const |
| Get the bounding interval for a scale | |
| virtual void | updateScaleDiv (const QwtScaleDiv &, const QwtScaleDiv &, const QwtInterval &) |
| Update the scale division | |
| virtual int | marginHint () const |
| Get the margin hint | |
| void | setLegendIconSize (const QSize &) |
| Set the legend icon size | |
| QSize | legendIconSize () const |
| Get the legend icon size | |
| virtual QList< QwtLegendData > | legendData () const |
| Get the legend data | |
| virtual QwtGraphic | legendIcon (int index, const QSizeF &) const |
| Get the legend icon | |
极坐标绘图项的基类
运行时类型信息
RttiValues 用于转换绘图项,而无需启用编译器的运行时类型信息。
| 枚举值 | |
|---|---|
| Rtti_PolarItem | Unspecific value, that can be used, when it doesn't matter |
| Rtti_PolarGrid | For QwtPolarGrid |
| Rtti_PolarMarker | For QwtPolarMarker |
| Rtti_PolarCurve | For QwtPolarCurve |
| Rtti_PolarSpectrogram | |
| Rtti_PolarUserItem | Values >= Rtti_PolarUserItem are reserved for plot items not implemented in the QwtPolar library. |
|
virtual |
Destructor
析构函数
| void QwtPolarItem::attach | ( | QwtPolarPlot * | plot | ) |
Attach the item to a plot
将项附加到绘图
|
virtual |
Get the bounding interval for a scale
获取刻度的边界区间
被 QwtPolarCurve, QwtPolarMarker , 以及 QwtPolarSpectrogram 重载.
| void QwtPolarItem::detach | ( | ) |
Detach the item from its plot
从关联的绘图分离项
|
pure virtual |
绘制项
| [in] | painter | 画师 |
| [in] | azimuthMap | 将方位角值映射到与 0.0, M_2PI 相关的值 |
| [in] | radialMap | 将半径值映射到画师坐标 |
| [in] | pole | 画师坐标中极点的位置 |
| [in] | radius | 画师坐标中完整绘图区域的半径 |
| [in] | canvasRect | 画师坐标中画布的内容矩形 |
在 QwtPolarCurve, QwtPolarGrid, QwtPolarMarker , 以及 QwtPolarSpectrogram 内被实现.
| void QwtPolarItem::hide | ( | ) |
Hide the item
隐藏项
| bool QwtPolarItem::isVisible | ( | ) | const |
Get the visibility
检查项是否可见
|
virtual |
Update the item and trigger autoRefresh
更新图例并调用父绘图的 QwtPolarPlot::autoRefresh
|
virtual |
Update the legend
更新父绘图的图例
|
virtual |
Get the legend data
返回在图例上表示项所需的所有信息
|
virtual |
| QSize QwtPolarItem::legendIconSize | ( | ) | const |
Get the legend icon size
获取图例图标大小
|
virtual |
| QwtPolarPlot * QwtPolarItem::plot | ( | ) | const |
Get the attached plot
获取附加的绘图
| uint QwtPolarItem::renderThreadCount | ( | ) | const |
Get the number of render threads
获取渲染线程数
|
virtual |
Get the runtime type information
获取所表示的特定类的运行时类型信息
被 QwtPolarCurve, QwtPolarGrid, QwtPolarMarker , 以及 QwtPolarSpectrogram 重载.
| void QwtPolarItem::setItemAttribute | ( | ItemAttribute | attribute, |
| bool | on = true |
||
| ) |
Set an item attribute
切换项属性
| void QwtPolarItem::setLegendIconSize | ( | const QSize & | size | ) |
Set the legend icon size
设置图例图标的大小
| void QwtPolarItem::setRenderHint | ( | RenderHint | hint, |
| bool | on = true |
||
| ) |
Set a render hint
切换渲染提示
| void QwtPolarItem::setRenderThreadCount | ( | uint | numThreads | ) |
Set the number of render threads
设置渲染线程数
| void QwtPolarItem::setTitle | ( | const QString & | title | ) |
Set the title from a QString
设置新标题
|
virtual |
Set the visibility
显示/隐藏项
| void QwtPolarItem::setZ | ( | double | z | ) |
Set the z value
设置 z 值
| void QwtPolarItem::show | ( | ) |
Show the item
显示项
| bool QwtPolarItem::testItemAttribute | ( | ItemAttribute | attribute | ) | const |
Test an item attribute
测试项属性
| bool QwtPolarItem::testRenderHint | ( | RenderHint | hint | ) | const |
Test a render hint
测试渲染提示
| const QwtText & QwtPolarItem::title | ( | ) | const |
Get the title
获取项的标题
|
virtual |
| double QwtPolarItem::z | ( | ) | const |
Get the z value
获取 z 值