⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 qwtsliderbase.3

📁 linux下qt的第三方的一个类
💻 3
📖 第 1 页 / 共 2 页
字号:
.TH "QwtSliderBase" 3 "16 Nov 2004" "Version 4.2.0" "Qwt User's Guide" \" -*- nroff -*-.ad l.nh.SH NAMEQwtSliderBase \- .SH SYNOPSIS.br.PPInherits \fBQwtDblRange\fP..PPInherited by \fBQwtDial\fP, \fBQwtKnob\fP, \fBQwtSlider\fP, and \fBQwtWheel\fP..PP.SH "Detailed Description".PP A Base class for sliders. QwtSliderBase is a base class for slider widgets. QwtSliderBase handles the mouse events and updates the slider's value accordingly. Derived classes only have to implement the \fBgetValue()\fP and \fBgetScrollMode()\fP members, and should react to a \fBvalueChange()\fP, which normally requires repainting. .PPDefinition at line 30 of file qwt_sldbase.h..SS "Public Types".in +1c.ti -1c.RI "enum \fBScrollMode\fP { \fBScrNone\fP, \fBScrMouse\fP, \fBScrTimer\fP, \fBScrDirect\fP, \fBScrPage\fP }".br.in -1c.SS "Public Slots".in +1c.ti -1c.RI "virtual void \fBsetValue\fP (double val)".br.ti -1c.RI "virtual void \fBfitValue\fP (double val)".br.ti -1c.RI "virtual void \fBincValue\fP (int steps)".br.ti -1c.RI "virtual void \fBsetReadOnly\fP (bool)".br.in -1c.SS "Signals".in +1c.ti -1c.RI "void \fBvalueChanged\fP (double value)".br.ti -1c.RI "void \fBsliderPressed\fP ()".br.ti -1c.RI "void \fBsliderReleased\fP ()".br.ti -1c.RI "void \fBsliderMoved\fP (double value)".br.in -1c.SS "Public Member Functions".in +1c.ti -1c.RI "\fBQwtSliderBase\fP (Qt::Orientation orientation, QWidget *parent=0, const char *name=0, Qt::WFlags flags=0)".br.ti -1c.RI "virtual \fB~QwtSliderBase\fP ()".br.ti -1c.RI "void \fBsetUpdateTime\fP (int t)".br.ti -1c.RI "void \fBstopMoving\fP ()".br.ti -1c.RI "void \fBsetTracking\fP (bool enable)".br.ti -1c.RI "virtual void \fBsetMass\fP (double val)".br.ti -1c.RI "virtual double \fBmass\fP () const".br.ti -1c.RI "virtual void \fBsetOrientation\fP (Orientation o)".br.ti -1c.RI "Orientation \fBorientation\fP () const".br.ti -1c.RI "bool \fBisReadOnly\fP () const".br.ti -1c.RI "bool \fBisValid\fP () const".br.ti -1c.RI "void \fBsetValid\fP (bool valid)".br.in -1c.SS "Protected Member Functions".in +1c.ti -1c.RI "void \fBsetPosition\fP (const QPoint &p)".br.ti -1c.RI "virtual void \fBvalueChange\fP ()".br.ti -1c.RI "virtual void \fBtimerEvent\fP (QTimerEvent *e)".br.ti -1c.RI "virtual void \fBmousePressEvent\fP (QMouseEvent *e)".br.ti -1c.RI "virtual void \fBmouseReleaseEvent\fP (QMouseEvent *e)".br.ti -1c.RI "virtual void \fBmouseMoveEvent\fP (QMouseEvent *e)".br.ti -1c.RI "virtual void \fBkeyPressEvent\fP (QKeyEvent *e)".br.ti -1c.RI "virtual void \fBwheelEvent\fP (QWheelEvent *e)".br.ti -1c.RI "virtual double \fBgetValue\fP (const QPoint &p)=0".br.ti -1c.RI "virtual void \fBgetScrollMode\fP (const QPoint &p, int &scrollMode, int &direction)=0".br.in -1c.SS "Protected Attributes".in +1c.ti -1c.RI "int \fBd_scrollMode\fP".br.ti -1c.RI "double \fBd_mouseOffset\fP".br.ti -1c.RI "int \fBd_direction\fP".br.ti -1c.RI "int \fBd_tracking\fP".br.in -1c.SH "Constructor & Destructor Documentation".PP .SS "QwtSliderBase::QwtSliderBase (Qt::Orientation orientation, QWidget * parent = \fC0\fP, const char * name = \fC0\fP, Qt::WFlags flags = \fC0\fP)".PPConstructor. .PPDefinition at line 19 of file qwt_sldbase.cpp..PPReferences QwtDblRange::setRange(), and setValue()..SS "QwtSliderBase::~\fBQwtSliderBase\fP ()\fC [virtual]\fP".PPDestructor. .PPDefinition at line 38 of file qwt_sldbase.cpp..SH "Member Function Documentation".PP .SS "void QwtSliderBase::fitValue (double val)\fC [virtual, slot]\fP".PPSet the slider's value to the nearest integer multiple of the step size. .PP\fBSee also:\fP.RS 4\fBQwtSliderBase::setValue()\fP .RE.PP.PPReimplemented from \fBQwtDblRange\fP..PPDefinition at line 519 of file qwt_sldbase.cpp..PPReferences QwtDblRange::fitValue(), and stopMoving()..SS "virtual void QwtSliderBase::getScrollMode (const QPoint & p, int & scrollMode, int & direction)\fC [protected, pure virtual]\fP".PPDetermine what to do when the user presses a mouse button. .PPThis function is abstract and has to be implemented by derived classes. It is called on a mousePress event. The derived class can determine what should happen next in dependence of the position where the mouse was pressed by returning scrolling mode and direction. QwtSliderBase knows the following modes:.IP "\fBQwtSliderBase::ScrNone \fP" 1cScrolling switched off. Don't change the value. .IP "\fBQwtSliderBase::ScrMouse \fP" 1cChange the value while the user keeps the button pressed and moves the mouse. .IP "\fBQwtSliderBase::ScrTimer \fP" 1cAutomatic scrolling. Increment the value in the specified direction as long as the user keeps the button pressed. .IP "\fBQwtSliderBase::ScrPage \fP" 1cAutomatic scrolling. Same as ScrTimer, but increment by page size..PP.PP\fBParameters:\fP.RS 4\fIp\fP point where the mouse was pressed .RE.PP\fBReturn values:\fP.RS 4\fIscrollMode\fP The scrolling mode .br\fIdirection\fP direction: 1, 0, or -1. .RE.PP.PPImplemented in \fBQwtDial\fP, \fBQwtSlider\fP, and \fBQwtWheel\fP..PPReferenced by mousePressEvent(), and wheelEvent()..SS "virtual double QwtSliderBase::getValue (const QPoint & p)\fC [protected, pure virtual]\fP".PPDetermine the value corresponding to a specified poind. .PPThis is an abstract virtual function which is called when the user presses or releases a mouse button or moves the mouse. It has to be implemented by the derived class. .PP\fBParameters:\fP.RS 4\fIp\fP point .RE.PP.PPImplemented in \fBQwtDial\fP, \fBQwtSlider\fP, and \fBQwtWheel\fP..PPReferenced by mousePressEvent(), and setPosition()..SS "void QwtSliderBase::incValue (int steps)\fC [virtual, slot]\fP".PPIncrement the value by a specified number of steps. .PP\fBParameters:\fP.RS 4\fIsteps\fP number of steps .RE.PP.PPReimplemented from \fBQwtDblRange\fP..PPDefinition at line 531 of file qwt_sldbase.cpp..PPReferences QwtDblRange::incValue(), and stopMoving()..SS "bool QwtSliderBase::isReadOnly () const".PPIn read only mode the slider can磘 be controlled by mouse or keyboard..PP\fBReturns:\fP.RS 4TRUE if read only .RE.PP\fBSee also:\fP.RS 4\fBsetReadOnly\fP .RE.PPDefinition at line 66 of file qwt_sldbase.cpp..PPReferenced by QwtDial::drawFocusIndicator(), keyPressEvent(), QwtDial::keyPressEvent(), QwtCompass::keyPressEvent(), mouseMoveEvent(), mousePressEvent(), mouseReleaseEvent(), and wheelEvent()..SS "bool QwtSliderBase::isValid () const".PP\fBSee also:\fP.RS 4\fBQwtDblRange::isValid\fP .RE.PP.PPReimplemented from \fBQwtDblRange\fP..PPDefinition at line 66 of file qwt_sldbase.h..PPReferences QwtDblRange::isValid()..PPReferenced by QwtDial::drawContents(), QwtKnob::drawKnob(), QwtAnalogClock::drawNeedle(), QwtCompass::drawScaleContents(), QwtSlider::drawSlider(), keyPressEvent(), QwtDial::keyPressEvent(), mouseMoveEvent(), mousePressEvent(), mouseReleaseEvent(), and wheelEvent()..SS "void QwtSliderBase::keyPressEvent (QKeyEvent * e)\fC [protected, virtual]\fP".PPHandles key events.PP.IP "\(bu" 2Key_Down, KeyLeft.br Decrement by 1.IP "\(bu" 2Key_Up, Key_Right.br

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -