QWT API (中文) 7.0.1
Qt绘图库 - 中文API文档
载入中...
搜索中...
未找到
| Public 类型 | Public 槽 | 信号 | Public 成员函数 | Protected 成员函数 | 属性 | 友元 | 所有成员列表
QwtPolarPlot类 参考

显示极坐标系的绘图控件 更多...

#include <qwt_polar_plot.h>

类 QwtPolarPlot 继承关系图:
QwtPolarItemDict

class  PrivateData
 

Public 类型

enum  LegendPosition {
  LeftLegend , RightLegend , BottomLegend , TopLegend ,
  ExternalLegend
}
 图例相对于画布的位置 更多...
 

Public 槽

virtual void replot ()
 Replot the plot
 
void autoRefresh ()
 Auto refresh the plot
 
void setAzimuthOrigin (double)
 Set the azimuth origin
 

信号

void itemAttached (QwtPolarItem *plotItem, bool on)
 A signal indicating, that an item has been attached/detached 表示绘图项已附加/分离的信号
 
void legendDataChanged (const QVariant &itemInfo, const QList< QwtLegendData > &data)
 A signal with the attributes how to update the legend entries for a plot item 包含如何更新绘图项图例条目属性的信号
 
void layoutChanged ()
 A signal that is emitted, whenever the layout of the plot has been recalculated 当绘图的布局重新计算时发出的信号
 

Public 成员函数

 QwtPolarPlot (QWidget *parent=nullptr)
 Constructor
 
 QwtPolarPlot (const QwtText &title, QWidget *parent=nullptr)
 Constructor with title
 
virtual ~QwtPolarPlot ()
 Destructor
 
void setTitle (const QString &)
 Set the title
 
void setTitle (const QwtText &)
 Set the title
 
QwtText title () const
 Get the title
 
QwtTextLabeltitleLabel ()
 Get the title label
 
const QwtTextLabeltitleLabel () const
 Get the title label (const version)
 
void setAutoReplot (bool tf=true)
 Set auto replot
 
bool autoReplot () const
 Get auto replot
 
void setAutoScale (int scaleId)
 Set auto scale for a scale
 
bool hasAutoScale (int scaleId) const
 Check if a scale has auto scale
 
void setScaleMaxMinor (int scaleId, int maxMinor)
 Set the maximum number of minor ticks for a scale
 
int scaleMaxMinor (int scaleId) const
 Get the maximum number of minor ticks for a scale
 
int scaleMaxMajor (int scaleId) const
 Get the maximum number of major ticks for a scale
 
void setScaleMaxMajor (int scaleId, int maxMajor)
 Set the maximum number of major ticks for a scale
 
QwtScaleEnginescaleEngine (int scaleId)
 Get the scale engine for a scale
 
const QwtScaleEnginescaleEngine (int scaleId) const
 Get the scale engine for a scale (const version)
 
void setScaleEngine (int scaleId, QwtScaleEngine *)
 Set the scale engine for a scale
 
void setScale (int scaleId, double min, double max, double step=0)
 Set the scale for a scale
 
void setScaleDiv (int scaleId, const QwtScaleDiv &)
 Set the scale division for a scale
 
const QwtScaleDivscaleDiv (int scaleId) const
 Get the scale division for a scale (const version)
 
QwtScaleDivscaleDiv (int scaleId)
 Get the scale division for a scale
 
QwtScaleMap scaleMap (int scaleId, double radius) const
 Get the scale map for a scale with radius
 
QwtScaleMap scaleMap (int scaleId) const
 Get the scale map for a scale
 
void updateScale (int scaleId)
 Update a scale
 
double azimuthOrigin () const
 Get the azimuth origin
 
void zoom (const QwtPointPolar &, double factor)
 Zoom to a position with a factor
 
void unzoom ()
 Unzoom the plot
 
QwtPointPolar zoomPos () const
 Get the zoom position
 
double zoomFactor () const
 Get the zoom factor
 
QwtPolarCanvascanvas ()
 Get the canvas
 
const QwtPolarCanvascanvas () const
 Get the canvas (const version)
 
void setPlotBackground (const QBrush &c)
 Set the plot background
 
const QBrush & plotBackground () const
 Get the plot background
 
virtual void drawCanvas (QPainter *, const QRectF &) const
 Draw the canvas
 
void insertLegend (QwtAbstractLegend *, LegendPosition=RightLegend, double ratio=-1.0)
 Insert a legend
 
QwtAbstractLegendlegend ()
 Get the legend
 
const QwtAbstractLegendlegend () const
 Get the legend (const version)
 
void updateLegend ()
 Update the legend
 
void updateLegend (const QwtPolarItem *)
 Update the legend for an item
 
QwtPolarLayoutplotLayout ()
 Get the plot layout
 
const QwtPolarLayoutplotLayout () const
 Get the plot layout (const version)
 
QwtInterval visibleInterval () const
 Get the visible interval
 
QRectF plotRect () const
 Get the plot rectangle
 
QRectF plotRect (const QRectF &) const
 Get the plot rectangle for a given rectangle
 
int plotMarginHint () const
 Get the plot margin hint
 
virtual QVariant itemToInfo (QwtPolarItem *) const
 Convert an item to info
 
virtual QwtPolarIteminfoToItem (const QVariant &) const
 Convert info to an item
 
- Public 成员函数 继承自 QwtPolarItemDict
 QwtPolarItemDict ()
 Constructor
 
 ~QwtPolarItemDict ()
 Destructor
 
void setAutoDelete (bool)
 Set auto delete
 
bool autoDelete () const
 Get auto delete
 
const QwtPolarItemListitemList () const
 Get the item list
 
void detachItems (int rtti=QwtPolarItem::Rtti_PolarItem, bool autoDelete=true)
 Detach items
 

Protected 成员函数

virtual bool event (QEvent *) override
 Handle events
 
virtual void resizeEvent (QResizeEvent *) override
 Handle resize events
 
virtual void updateLayout ()
 Update the layout
 
virtual void drawItems (QPainter *painter, const QwtScaleMap &radialMap, const QwtScaleMap &azimuthMap, const QPointF &pole, double radius, const QRectF &canvasRect) const
 Draw items
 
- Protected 成员函数 继承自 QwtPolarItemDict
void insertItem (QwtPolarItem *)
 Insert an item
 
void removeItem (QwtPolarItem *)
 Remove an item
 

属性

QBrush plotBackground
 
double azimuthOrigin
 

友元

class QwtPolarItem
 

详细描述

显示极坐标系的绘图控件

成员枚举类型说明

◆ LegendPosition

图例相对于画布的位置

枚举值
LeftLegend 

The legend will be left from the canvas

RightLegend 

The legend will be right from the canvas

BottomLegend 

The legend will be below the canvas

TopLegend 

The legend will be between canvas and title

ExternalLegend 

外部意味着只有图例的内容由 QwtPlot 处理,而不是其几何形状。 如果应用程序希望在外部窗口(或在画布上)放置图例,这可能很有用。

注解
图例不由 QwtPolarRenderer 绘制

构造及析构函数说明

◆ QwtPolarPlot() [1/2]

QwtPolarPlot::QwtPolarPlot ( QWidget *  parent = nullptr)
explicit

Constructor

构造函数

◆ QwtPolarPlot() [2/2]

QwtPolarPlot::QwtPolarPlot ( const QwtText title,
QWidget *  parent = nullptr 
)

Constructor with title

带标题的构造函数

◆ ~QwtPolarPlot()

QwtPolarPlot::~QwtPolarPlot ( )
virtual

Destructor

析构函数

成员函数说明

◆ autoRefresh

void QwtPolarPlot::autoRefresh ( )
slot

Auto refresh the plot

如果 autoReplot()true 则重新绘制绘图

◆ autoReplot()

bool QwtPolarPlot::autoReplot ( ) const

Get auto replot

检查是否设置了自动重绘选项

◆ azimuthOrigin()

double QwtPolarPlot::azimuthOrigin ( ) const

Get the azimuth origin

获取方位角刻度的原点

◆ canvas() [1/2]

QwtPolarCanvas * QwtPolarPlot::canvas ( )

Get the canvas

获取绘图的画布

◆ canvas() [2/2]

const QwtPolarCanvas * QwtPolarPlot::canvas ( ) const

Get the canvas (const version)

获取绘图的画布(常量版本)

◆ drawCanvas()

void QwtPolarPlot::drawCanvas ( QPainter *  painter,
const QRectF &  canvasRect 
) const
virtual

Draw the canvas

重绘画布

◆ drawItems()

void QwtPolarPlot::drawItems ( QPainter *  painter,
const QwtScaleMap azimuthMap,
const QwtScaleMap radialMap,
const QPointF &  pole,
double  radius,
const QRectF &  canvasRect 
) const
protectedvirtual

Draw items

重绘画布项

◆ event()

bool QwtPolarPlot::event ( QEvent *  e)
overrideprotectedvirtual

Handle events

Qt 事件处理器

◆ hasAutoScale()

bool QwtPolarPlot::hasAutoScale ( int  scaleId) const

Check if a scale has auto scale

检查是否启用了自动缩放

◆ infoToItem()

QwtPolarItem * QwtPolarPlot::infoToItem ( const QVariant &  itemInfo) const
virtual

Convert info to an item

根据项信息对象标识绘图项

◆ insertLegend()

void QwtPolarPlot::insertLegend ( QwtAbstractLegend legend,
QwtPolarPlot::LegendPosition  pos = RightLegend,
double  ratio = -1.0 
)

Insert a legend

插入图例

◆ itemAttached

void QwtPolarPlot::itemAttached ( QwtPolarItem plotItem,
bool  on 
)
signal

A signal indicating, that an item has been attached/detached 表示绘图项已附加/分离的信号

参数
plotItemPlot item / 绘图项
onAttached/Detached / 附加/分离

◆ itemToInfo()

QVariant QwtPolarPlot::itemToInfo ( QwtPolarItem plotItem) const
virtual

Convert an item to info

构建信息对象以在图例上标识绘图项

◆ legend() [1/2]

QwtAbstractLegend * QwtPolarPlot::legend ( )

Get the legend

获取绘图的图例

◆ legend() [2/2]

const QwtAbstractLegend * QwtPolarPlot::legend ( ) const

Get the legend (const version)

获取绘图的图例(常量版本)

◆ legendDataChanged

void QwtPolarPlot::legendDataChanged ( const QVariant &  itemInfo,
const QList< QwtLegendData > &  data 
)
signal

A signal with the attributes how to update the legend entries for a plot item 包含如何更新绘图项图例条目属性的信号

参数
itemInfoInfo about a plot, build from itemToInfo() / 关于绘图的信息,由 itemToInfo() 构建
dataAttributes of the entries ( usually <= 1 ) for the plot item / 绘图项的条目属性(通常 <= 1)
参见
itemToInfo(), infoToItem(), QwtAbstractLegend::updateLegend()

◆ plotBackground()

const QBrush & QwtPolarPlot::plotBackground ( ) const

Get the plot background

获取绘图背景画刷

◆ plotLayout() [1/2]

QwtPolarLayout * QwtPolarPlot::plotLayout ( )

Get the plot layout

获取负责绘图组件几何形状的布局

◆ plotLayout() [2/2]

const QwtPolarLayout * QwtPolarPlot::plotLayout ( ) const

Get the plot layout (const version)

获取负责绘图组件几何形状的布局(常量版本)

◆ plotMarginHint()

int QwtPolarPlot::plotMarginHint ( ) const

Get the plot margin hint

获取所有项边距提示的最大值

◆ plotRect() [1/2]

QRectF QwtPolarPlot::plotRect ( ) const

Get the plot rectangle

获取绘图区域的边界矩形

◆ plotRect() [2/2]

QRectF QwtPolarPlot::plotRect ( const QRectF &  canvasRect) const

Get the plot rectangle for a given rectangle

计算绘图区域的边界矩形

◆ replot

void QwtPolarPlot::replot ( )
virtualslot

Replot the plot

重绘绘图

◆ resizeEvent()

void QwtPolarPlot::resizeEvent ( QResizeEvent *  e)
overrideprotectedvirtual

Handle resize events

调整大小并更新内部布局

◆ scaleDiv() [1/2]

QwtScaleDiv * QwtPolarPlot::scaleDiv ( int  scaleId)

Get the scale division for a scale

返回指定刻度的刻度划分

◆ scaleDiv() [2/2]

const QwtScaleDiv * QwtPolarPlot::scaleDiv ( int  scaleId) const

Get the scale division for a scale (const version)

返回指定刻度的刻度划分

◆ scaleEngine() [1/2]

QwtScaleEngine * QwtPolarPlot::scaleEngine ( int  scaleId)

Get the scale engine for a scale

获取特定刻度的刻度引擎

◆ scaleEngine() [2/2]

const QwtScaleEngine * QwtPolarPlot::scaleEngine ( int  scaleId) const

Get the scale engine for a scale (const version)

获取特定刻度的刻度引擎(常量版本)

◆ scaleMap() [1/2]

QwtScaleMap QwtPolarPlot::scaleMap ( int  scaleId) const

Get the scale map for a scale

构建刻度映射

◆ scaleMap() [2/2]

QwtScaleMap QwtPolarPlot::scaleMap ( int  scaleId,
double  radius 
) const

Get the scale map for a scale with radius

构建带有指定半径的刻度映射

◆ scaleMaxMajor()

int QwtPolarPlot::scaleMaxMajor ( int  scaleId) const

Get the maximum number of major ticks for a scale

获取指定轴的最大主要刻度数

◆ scaleMaxMinor()

int QwtPolarPlot::scaleMaxMinor ( int  scaleId) const

Get the maximum number of minor ticks for a scale

获取指定轴的最大次要刻度数

◆ setAutoReplot()

void QwtPolarPlot::setAutoReplot ( bool  enable = true)

Set auto replot

设置或重置自动重绘选项

◆ setAutoScale()

void QwtPolarPlot::setAutoScale ( int  scaleId)

Set auto scale for a scale

启用自动缩放

◆ setAzimuthOrigin

void QwtPolarPlot::setAzimuthOrigin ( double  origin)
slot

Set the azimuth origin

更改方位角刻度的原点

◆ setPlotBackground()

void QwtPolarPlot::setPlotBackground ( const QBrush &  brush)

Set the plot background

设置绘图区域的背景

◆ setScale()

void QwtPolarPlot::setScale ( int  scaleId,
double  min,
double  max,
double  stepSize = 0 
)

Set the scale for a scale

禁用自动缩放并指定选定刻度的固定刻度

◆ setScaleDiv()

void QwtPolarPlot::setScaleDiv ( int  scaleId,
const QwtScaleDiv scaleDiv 
)

Set the scale division for a scale

禁用自动缩放并指定选定刻度的固定刻度

◆ setScaleEngine()

void QwtPolarPlot::setScaleEngine ( int  scaleId,
QwtScaleEngine scaleEngine 
)

Set the scale engine for a scale

更改轴的刻度引擎

◆ setScaleMaxMajor()

void QwtPolarPlot::setScaleMaxMajor ( int  scaleId,
int  maxMajor 
)

Set the maximum number of major ticks for a scale

设置指定刻度的最大主要刻度间隔数

◆ setScaleMaxMinor()

void QwtPolarPlot::setScaleMaxMinor ( int  scaleId,
int  maxMinor 
)

Set the maximum number of minor ticks for a scale

设置指定刻度的最大次要刻度间隔数

◆ setTitle() [1/2]

void QwtPolarPlot::setTitle ( const QString &  title)

Set the title

更改绘图的标题

◆ setTitle() [2/2]

void QwtPolarPlot::setTitle ( const QwtText title)

Set the title

更改绘图的标题

◆ title()

QwtText QwtPolarPlot::title ( ) const

Get the title

获取绘图的标题

◆ titleLabel() [1/2]

QwtTextLabel * QwtPolarPlot::titleLabel ( )

Get the title label

获取标题标签控件

◆ titleLabel() [2/2]

const QwtTextLabel * QwtPolarPlot::titleLabel ( ) const

Get the title label (const version)

获取标题标签控件(常量版本)

◆ unzoom()

void QwtPolarPlot::unzoom ( )

Unzoom the plot

取消绘图的缩放

◆ updateLayout()

void QwtPolarPlot::updateLayout ( )
protectedvirtual

Update the layout

重建布局

◆ updateLegend() [1/2]

void QwtPolarPlot::updateLegend ( )

Update the legend

为所有绘图项发出 legendDataChanged() 信号

◆ updateLegend() [2/2]

void QwtPolarPlot::updateLegend ( const QwtPolarItem plotItem)

Update the legend for an item

为绘图项发出 legendDataChanged() 信号

◆ updateScale()

void QwtPolarPlot::updateScale ( int  scaleId)

Update a scale

重建刻度

◆ visibleInterval()

QwtInterval QwtPolarPlot::visibleInterval ( ) const

Get the visible interval

获取画布上可见的径向刻度的边界区间

◆ zoom()

void QwtPolarPlot::zoom ( const QwtPointPolar zoomPos,
double  zoomFactor 
)

Zoom to a position with a factor

平移和增/减缩放因子

◆ zoomFactor()

double QwtPolarPlot::zoomFactor ( ) const

Get the zoom factor

获取缩放因子

◆ zoomPos()

QwtPointPolar QwtPolarPlot::zoomPos ( ) const

Get the zoom position

获取缩放位置


该类的文档由以下文件生成: