|
QWT API (中文) 7.0.1
Qt绘图库 - 中文API文档
|
带刻度的滑块控件的抽象基类 更多...
#include <qwt_abstract_slider.h>
类 | |
| class | PrivateData |
Public 槽 | |
| void | setValue (double value) |
| Set the slider value (English only) | |
信号 | |
| void | valueChanged (double value) |
| 通知值变化 | |
| void | sliderPressed () |
| 当用户按下滑块的可移动部分时发出的信号 | |
| void | sliderReleased () |
| 当用户释放滑块的可移动部分时发出的信号 | |
| void | sliderMoved (double value) |
| 当用户用鼠标移动滑块时发出的信号 | |
Public 成员函数 | |
| QwtAbstractSlider (QWidget *parent=nullptr) | |
| Constructor for QwtAbstractSlider (English only) | |
| virtual | ~QwtAbstractSlider () |
| Destructor for QwtAbstractSlider (English only) | |
| void | setValid (bool) |
| Set whether the slider is valid (English only) | |
| bool | isValid () const |
| Return whether the slider is valid (English only) | |
| double | value () const |
| Return the current value (English only) | |
| void | setWrapping (bool) |
| Set whether wrapping is enabled (English only) | |
| bool | wrapping () const |
| Return whether wrapping is enabled (English only) | |
| void | setTotalSteps (uint) |
| Set the total number of steps (English only) | |
| uint | totalSteps () const |
| Return the total number of steps (English only) | |
| void | setSingleSteps (uint) |
| Set the number of single steps (English only) | |
| uint | singleSteps () const |
| Return the number of single steps (English only) | |
| void | setPageSteps (uint) |
| Set the number of page steps (English only) | |
| uint | pageSteps () const |
| Return the number of page steps (English only) | |
| void | setStepAlignment (bool) |
| Set whether step alignment is enabled (English only) | |
| bool | stepAlignment () const |
| Return whether step alignment is enabled (English only) | |
| void | setTracking (bool) |
| Set whether tracking is enabled (English only) | |
| bool | isTracking () const |
| Return whether tracking is enabled (English only) | |
| void | setReadOnly (bool) |
| Set whether the slider is read-only (English only) | |
| bool | isReadOnly () const |
| Return whether the slider is read-only (English only) | |
| void | setInvertedControls (bool) |
| Set whether controls are inverted (English only) | |
| bool | invertedControls () const |
| Return whether controls are inverted (English only) | |
Public 成员函数 继承自 QwtAbstractScale | |
| QwtAbstractScale (QWidget *parent=nullptr) | |
| QwtAbstractScale 构造函数 | |
| virtual | ~QwtAbstractScale () |
| QwtAbstractScale 析构函数 | |
| void | setScale (double lowerBound, double upperBound) |
| 通过区间边界指定刻度 | |
| void | setScale (const QwtInterval &) |
| 通过区间对象指定刻度 | |
| void | setScale (const QwtScaleDiv &) |
| 通过刻度划分指定刻度 | |
| const QwtScaleDiv & | scaleDiv () const |
| 返回刻度划分 | |
| void | setLowerBound (double value) |
| 设置刻度的下界 | |
| double | lowerBound () const |
| 返回刻度的下界 | |
| void | setUpperBound (double value) |
| 设置刻度的上界 | |
| double | upperBound () const |
| 返回刻度的上界 | |
| void | setScaleStepSize (double stepSize) |
| 设置用于计算刻度划分的步长 | |
| double | scaleStepSize () const |
| 返回步长提示值 | |
| void | setScaleMaxMajor (int ticks) |
| 设置主刻度间隔的最大数量 | |
| int | scaleMaxMinor () const |
| 返回次刻度间隔的最大数量 | |
| void | setScaleMaxMinor (int ticks) |
| 设置次刻度间隔的最大数量 | |
| int | scaleMaxMajor () const |
| 返回主刻度间隔的最大数量 | |
| void | setScaleEngine (QwtScaleEngine *) |
| 设置刻度引擎 | |
| const QwtScaleEngine * | scaleEngine () const |
| 返回刻度引擎(常量版本) | |
| QwtScaleEngine * | scaleEngine () |
| 返回刻度引擎(非常量版本) | |
| int | transform (double) const |
| 将刻度值转换为控件坐标 | |
| double | invTransform (int) const |
| 将控件坐标转换为刻度值 | |
| bool | isInverted () const |
| 检查刻度是否反向 | |
| double | minimum () const |
| 返回最小边界 | |
| double | maximum () const |
| 返回最大边界 | |
| const QwtScaleMap & | scaleMap () const |
| 返回刻度映射 | |
Protected 成员函数 | |
| virtual void | mousePressEvent (QMouseEvent *) override |
| Handle mouse press events (English only) | |
| virtual void | mouseReleaseEvent (QMouseEvent *) override |
| Handle mouse release events (English only) | |
| virtual void | mouseMoveEvent (QMouseEvent *) override |
| Handle mouse move events (English only) | |
| virtual void | keyPressEvent (QKeyEvent *) override |
| Handle key press events (English only) | |
| virtual void | wheelEvent (QWheelEvent *) override |
| Handle wheel events (English only) | |
| virtual bool | isScrollPosition (const QPoint &pos) const =0 |
| 确定当用户按下鼠标按钮时该做什么 | |
| virtual double | scrolledTo (const QPoint &pos) const =0 |
| 确定滑块可移动部分新位置的值 | |
| void | incrementValue (int stepCount) |
| Increment the value by a number of steps (English only) | |
| virtual void | scaleChange () override |
| Handle scale changes (English only) | |
| virtual void | sliderChange () |
| Handle slider changes (English only) | |
| double | incrementedValue (double value, int stepCount) const |
| Calculate incremented value (English only) | |
Protected 成员函数 继承自 QwtAbstractScale | |
| virtual void | changeEvent (QEvent *) override |
| Handle change events (English only) | |
| void | rescale (double lowerBound, double upperBound, double stepSize) |
| Recalculate scale and update scale draw (English only) | |
| void | setAbstractScaleDraw (QwtAbstractScaleDraw *) |
| Set the scale draw object (English only) | |
| const QwtAbstractScaleDraw * | abstractScaleDraw () const |
| Return the scale draw (const version) (English only) | |
| QwtAbstractScaleDraw * | abstractScaleDraw () |
| Return the scale draw (non-const version) (English only) | |
| void | updateScaleDraw () |
| Update the scale draw (English only) | |
属性 | |
| double | value |
| uint | totalSteps |
| uint | singleSteps |
| uint | pageSteps |
| bool | stepAlignment |
| bool | readOnly |
| bool | tracking |
| bool | wrapping |
| bool | invertedControls |
属性 继承自 QwtAbstractScale | |
| double | lowerBound |
| double | upperBound |
| int | scaleMaxMajor |
| int | scaleMaxMinor |
| double | scaleStepSize |
带刻度的滑块控件的抽象基类
|
explicit |
Constructor for QwtAbstractSlider (English only)
QwtAbstractSlider 构造函数
|
virtual |
Destructor for QwtAbstractSlider (English only)
QwtAbstractSlider 析构函数
|
protected |
Calculate incremented value (English only)
增量一个值
|
protected |
Increment the value by a number of steps (English only)
增量滑块
| bool QwtAbstractSlider::invertedControls | ( | ) | const |
Return whether controls are inverted (English only)
检查控制是否被反转
| bool QwtAbstractSlider::isReadOnly | ( | ) | const |
Return whether the slider is read-only (English only)
检查是否启用了只读模式
|
protectedpure virtual |
| bool QwtAbstractSlider::isTracking | ( | ) | const |
Return whether tracking is enabled (English only)
检查是否启用了跟踪
| bool QwtAbstractSlider::isValid | ( | ) | const |
Return whether the slider is valid (English only)
检查值是否有效
|
overrideprotectedvirtual |
|
overrideprotectedvirtual |
Handle mouse move events (English only)
处理鼠标移动事件
|
overrideprotectedvirtual |
|
overrideprotectedvirtual |
| uint QwtAbstractSlider::pageSteps | ( | ) | const |
Return the number of page steps (English only)
返回页步数
|
overrideprotectedvirtual |
|
protectedpure virtual |
| void QwtAbstractSlider::setInvertedControls | ( | bool | on | ) |
Set whether controls are inverted (English only)
反转滚轮和键盘事件
| void QwtAbstractSlider::setPageSteps | ( | uint | stepCount | ) |
Set the number of page steps (English only)
设置页步数
| void QwtAbstractSlider::setReadOnly | ( | bool | on | ) |
Set whether the slider is read-only (English only)
启用或禁用只读模式
| void QwtAbstractSlider::setSingleSteps | ( | uint | stepCount | ) |
Set the number of single steps (English only)
设置单步增量步数
| void QwtAbstractSlider::setStepAlignment | ( | bool | on | ) |
Set whether step alignment is enabled (English only)
启用步对齐
| void QwtAbstractSlider::setTotalSteps | ( | uint | stepCount | ) |
Set the total number of steps (English only)
设置步数
| void QwtAbstractSlider::setTracking | ( | bool | on | ) |
Set whether tracking is enabled (English only)
启用或禁用跟踪
| void QwtAbstractSlider::setValid | ( | bool | on | ) |
Set whether the slider is valid (English only)
设置值为有效或无效
|
slot |
Set the slider value (English only)
将滑块设置为指定值
| void QwtAbstractSlider::setWrapping | ( | bool | on | ) |
Set whether wrapping is enabled (English only)
启用或禁用环绕
| uint QwtAbstractSlider::singleSteps | ( | ) | const |
Return the number of single steps (English only)
返回单步数
|
protectedvirtual |
|
signal |
当用户用鼠标移动滑块时发出的信号
|
signal |
当用户按下滑块的可移动部分时发出的信号
|
signal |
当用户释放滑块的可移动部分时发出的信号
| bool QwtAbstractSlider::stepAlignment | ( | ) | const |
Return whether step alignment is enabled (English only)
检查是否启用了步对齐
| uint QwtAbstractSlider::totalSteps | ( | ) | const |
Return the total number of steps (English only)
返回步数
| double QwtAbstractSlider::value | ( | ) | const |
Return the current value (English only)
返回当前值
|
signal |
通知值变化
|
overrideprotectedvirtual |
| bool QwtAbstractSlider::wrapping | ( | ) | const |
Return whether wrapping is enabled (English only)
检查是否启用了环绕