QWT API (中文) 7.3.0
Qt绘图库 - 中文API文档
载入中...
搜索中...
未找到
Public 成员函数 | Protected 成员函数 | 所有成员列表
QwtLogScaleEngine类 参考

A scale engine for logarithmic scales 更多...

#include <qwt_scale_engine.h>

类 QwtLogScaleEngine 继承关系图:
QwtScaleEngine

Public 成员函数

 QwtLogScaleEngine (uint base=10)
 Constructor
 
 ~QwtLogScaleEngine () override
 Destructor
 
virtual void autoScale (int maxNumSteps, double &x1, double &x2, double &stepSize) const override
 Align and divide an interval
 
virtual QwtScaleDiv divideScale (double x1, double x2, int maxMajorSteps, int maxMinorSteps, double stepSize=0.0) const override
 Calculate a scale division for an interval
 
- Public 成员函数 继承自 QwtScaleEngine
 QwtScaleEngine (uint base=10)
 Constructor
 
void setBase (uint base)
 Set the base
 
uint base () const
 Return base of the scale engine
 
void setAttribute (Attribute, bool on=true)
 Set an attribute
 
bool testAttribute (Attribute) const
 Test if an attribute is enabled
 
void setAttributes (Attributes)
 Set attributes
 
Attributes attributes () const
 Return scale attributes
 
void setReference (double)
 Set the reference value
 
double reference () const
 Return the reference value
 
void setMargins (double lower, double upper)
 Set the margins
 
double lowerMargin () const
 Return the margin at the lower end of the scale
 
double upperMargin () const
 Return the margin at the upper end of the scale
 
void setTransformation (QwtTransform *)
 Set the transformation
 
QwtTransformtransformation () const
 Create and return a clone of the transformation of the engine
 

Protected 成员函数

QwtInterval align (const QwtInterval &, double stepSize) const
 Align an interval to a step size
 
void buildTicks (const QwtInterval &, double stepSize, int maxMinorSteps, QList< double > ticks[QwtScaleDiv::NTickTypes]) const
 Calculate ticks for an interval
 
QList< double > buildMajorTicks (const QwtInterval &interval, double stepSize) const
 Calculate major ticks for an interval
 
void buildMinorTicks (const QList< double > &majorTicks, int maxMinorSteps, double stepSize, QList< double > &minorTicks, QList< double > &mediumTicks) const
 Calculate minor/medium ticks for major ticks
 
- Protected 成员函数 继承自 QwtScaleEngine
bool contains (const QwtInterval &, double value) const
 Check if an interval contains a value
 
QList< double > strip (const QList< double > &, const QwtInterval &) const
 Strip values outside an interval
 
double divideInterval (double intervalSize, int numSteps) const
 Divide an interval
 
QwtInterval buildInterval (double value) const
 Build an interval around a value
 

额外继承的成员函数

- Public 类型 继承自 QwtScaleEngine
enum  Attribute {
  NoAttribute = 0x00 , IncludeReference = 0x01 , Symmetric = 0x02 , Floating = 0x04 ,
  Inverted = 0x08
}
 Layout attributes 更多...
 

详细描述

A scale engine for logarithmic scales

The step size is measured in decades and the major step size will be adjusted to fit the pattern $\left\{ 1,2,3,5\right\} \cdot 10^{n}$, where n is a natural number including zero.

警告
The step size as well as the margins are measured in decades.

构造及析构函数说明

◆ QwtLogScaleEngine()

QwtLogScaleEngine::QwtLogScaleEngine ( uint  base = 10)
explicit

Constructor

参数
baseBase of the scale engine
参见
setBase()

成员函数说明

◆ align()

QwtInterval QwtLogScaleEngine::align ( const QwtInterval interval,
double  stepSize 
) const
protected

Align an interval to a step size

参数
intervalInterval
stepSizeStep size
返回
Aligned interval

◆ autoScale()

void QwtLogScaleEngine::autoScale ( int  maxNumSteps,
double &  x1,
double &  x2,
double &  stepSize 
) const
overridevirtual

Align and divide an interval

参数
maxNumStepsMax. number of steps
x1First limit of the interval (In/Out)
x2Second limit of the interval (In/Out)
stepSizeStep size (Out)
参见
QwtScaleEngine::setAttribute()

实现了 QwtScaleEngine.

◆ buildMajorTicks()

QList< double > QwtLogScaleEngine::buildMajorTicks ( const QwtInterval interval,
double  stepSize 
) const
protected

Calculate major ticks for an interval

参数
intervalInterval
stepSizeStep size
返回
Calculated ticks

◆ buildMinorTicks()

void QwtLogScaleEngine::buildMinorTicks ( const QList< double > &  majorTicks,
int  maxMinorSteps,
double  stepSize,
QList< double > &  minorTicks,
QList< double > &  mediumTicks 
) const
protected

Calculate minor/medium ticks for major ticks

参数
majorTicksMajor ticks
maxMinorStepsMaximum number of minor steps
stepSizeStep size
minorTicksArray to be filled with the calculated minor ticks
mediumTicksArray to be filled with the calculated medium ticks

◆ buildTicks()

void QwtLogScaleEngine::buildTicks ( const QwtInterval interval,
double  stepSize,
int  maxMinorSteps,
QList< double >  ticks[QwtScaleDiv::NTickTypes] 
) const
protected

Calculate ticks for an interval

参数
intervalInterval
stepSizeStep size
maxMinorStepsMaximum number of minor steps
ticksArrays to be filled with the calculated ticks
参见
buildMajorTicks(), buildMinorTicks()

◆ divideScale()

QwtScaleDiv QwtLogScaleEngine::divideScale ( double  x1,
double  x2,
int  maxMajorSteps,
int  maxMinorSteps,
double  stepSize = 0.0 
) const
overridevirtual

Calculate a scale division for an interval

参数
x1First interval limit
x2Second interval limit
maxMajorStepsMaximum for the number of major steps
maxMinorStepsMaximum number of minor steps
stepSizeStep size. If stepSize == 0, the engine calculates one.
返回
Calculated scale division

实现了 QwtScaleEngine.


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