<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> <title>Qwt User's Guide: QwtDoubleRange Class Reference</title> <link href="tabs.css" rel="stylesheet" type="text/css"/> <link href="doxygen.css" rel="stylesheet" type="text/css"/> </head> <body> <!-- Generated by Doxygen 1.7.3 --> <div id="top"> <div id="titlearea"> <table cellspacing="0" cellpadding="0"> <tbody> <tr style="height: 56px;"> <td style="padding-left: 0.5em;"> <div id="projectname">Qwt User's Guide <span id="projectnumber">6.0.1</span></div> </td> </tr> </tbody> </table> </div> <div id="navrow1" class="tabs"> <ul class="tablist"> <li><a href="index.html"><span>Main Page</span></a></li> <li><a href="pages.html"><span>Related Pages</span></a></li> <li class="current"><a href="annotated.html"><span>Classes</span></a></li> <li><a href="files.html"><span>Files</span></a></li> </ul> </div> <div id="navrow2" class="tabs2"> <ul class="tablist"> <li><a href="annotated.html"><span>Class List</span></a></li> <li><a href="classes.html"><span>Class Index</span></a></li> <li><a href="inherits.html"><span>Class Hierarchy</span></a></li> <li><a href="functions.html"><span>Class Members</span></a></li> </ul> </div> </div> <div class="header"> <div class="summary"> <a href="#pub-methods">Public Member Functions</a> | <a href="#pro-methods">Protected Member Functions</a> </div> <div class="headertitle"> <h1>QwtDoubleRange Class Reference</h1> </div> </div> <div class="contents"> <!-- doxytag: class="QwtDoubleRange" --> <p>A class which controls a value within an interval. <a href="#_details">More...</a></p> <p><code>#include <<a class="el" href="qwt__double__range_8h_source.html">qwt_double_range.h</a>></code></p> <div class="dynheader"> Inheritance diagram for QwtDoubleRange:</div> <div class="dyncontent"> <div class="center"><img src="class_qwt_double_range__inherit__graph.png" border="0" usemap="#_qwt_double_range_inherit__map" alt="Inheritance graph"/></div> <map name="_qwt_double_range_inherit__map" id="_qwt_double_range_inherit__map"> <area shape="rect" id="node3" href="class_qwt_abstract_slider.html" title="An abstract base class for slider widgets." alt="" coords="211,83,336,112"/><area shape="rect" id="node17" href="class_qwt_counter.html" title="The Counter Widget." alt="" coords="360,83,451,112"/><area shape="rect" id="node5" href="class_qwt_dial.html" title="QwtDial class provides a rounded range control." alt="" coords="96,160,163,189"/><area shape="rect" id="node11" href="class_qwt_knob.html" title="The Knob Widget." alt="" coords="187,160,261,189"/><area shape="rect" id="node13" href="class_qwt_slider.html" title="The Slider Widget." alt="" coords="285,160,363,189"/><area shape="rect" id="node15" href="class_qwt_wheel.html" title="The Wheel Widget." alt="" coords="387,160,469,189"/><area shape="rect" id="node7" href="class_qwt_analog_clock.html" title="An analog clock." alt="" coords="5,237,123,267"/><area shape="rect" id="node9" href="class_qwt_compass.html" title="A Compass Widget." alt="" coords="147,237,245,267"/></map> <center><span class="legend">[<a href="graph_legend.html">legend</a>]</span></center></div> <p><a href="class_qwt_double_range-members.html">List of all members.</a></p> <table class="memberdecls"> <tr><td colspan="2"><h2><a name="pub-methods"></a> Public Member Functions</h2></td></tr> <tr><td class="memItemLeft" align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_double_range.html#a63bc8ea5e7ecd776b7d32d21db1ea668">fitValue</a> (double)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_double_range.html#a19b85337d4ab0b5f0579b02e4fb29a8f">incPages</a> (int)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_double_range.html#a299c35c72e9b69f5a0e3dcd2b7da775b">incValue</a> (int)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_double_range.html#afc4921deb3f68a64cc08b0654a040bc6">isValid</a> () const </td></tr> <tr><td class="memItemLeft" align="right" valign="top">double </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_double_range.html#a215275a1a8b4218a424ee8444c7fe409">maxValue</a> () const </td></tr> <tr><td class="memItemLeft" align="right" valign="top">double </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_double_range.html#a8b8650a6f8a96144d3af21207ee71637">minValue</a> () const </td></tr> <tr><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_double_range.html#ac12a5c43dc5839913379982ec40a39d8">pageSize</a> () const </td></tr> <tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_double_range.html#ad1efbcbf29dbc74f3f378292b76b007b">periodic</a> () const </td></tr> <tr><td class="memItemLeft" align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_double_range.html#a86f9f76df03d7917d88a95d1667f2d72">QwtDoubleRange</a> ()</td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_double_range.html#a95fa6a4e44fc47726d939155bb6f6f1f">setPeriodic</a> (bool tf)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_double_range.html#a43891011664b74b8e5454763a3f5ff21">setRange</a> (double vmin, double vmax, double vstep=0.0, int pagesize=1)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_double_range.html#a29ed5fc66439def424a8ad773eea285d">setStep</a> (double)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_double_range.html#a50a9c386663e170016a74cf8ee28ab8f">setValid</a> (bool)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_double_range.html#af6a3aa74c970a2bef29f0c1af99720e8">setValue</a> (double)</td></tr> <tr><td class="memItemLeft" align="right" valign="top">double </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_double_range.html#a0cb8cc60548c10cb1d98e54387961967">step</a> () const </td></tr> <tr><td class="memItemLeft" align="right" valign="top">double </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_double_range.html#a7777cf257c812579c4891512f1b6cad0">value</a> () const </td></tr> <tr><td class="memItemLeft" align="right" valign="top">virtual </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_double_range.html#abdcecda4b14ba81cfdaf063e2b98a22d">~QwtDoubleRange</a> ()</td></tr> <tr><td colspan="2"><h2><a name="pro-methods"></a> Protected Member Functions</h2></td></tr> <tr><td class="memItemLeft" align="right" valign="top">double </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_double_range.html#a595c04ed863eb7f0adaf94440087fe0a">exactPrevValue</a> () const </td></tr> <tr><td class="memItemLeft" align="right" valign="top">double </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_double_range.html#a705b76d28882d37bc5313d6c38c9a720">exactValue</a> () const </td></tr> <tr><td class="memItemLeft" align="right" valign="top">double </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_double_range.html#a38768187bef94dd5e5a2c8664746b365">prevValue</a> () const </td></tr> <tr><td class="memItemLeft" align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_double_range.html#a3583134a1ac32706aa4742088bb9d4dc">rangeChange</a> ()</td></tr> <tr><td class="memItemLeft" align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_double_range.html#a86641f8755ed172ca4cf72d36df539ca">stepChange</a> ()</td></tr> <tr><td class="memItemLeft" align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_double_range.html#a1d50398342d6aa1d9cd86650ee29aff8">valueChange</a> ()</td></tr> </table> <hr/><a name="_details"></a><h2>Detailed Description</h2> <div class="textblock"><p>A class which controls a value within an interval. </p> <p>This class is useful as a base class or a member for sliders. It represents an interval of type double within which a value can be moved. The value can be either an arbitrary point inside the interval (see <a class="el" href="class_qwt_double_range.html#af6a3aa74c970a2bef29f0c1af99720e8" title="Set a new value without adjusting to the step raster.">QwtDoubleRange::setValue</a>), or it can be fitted into a step raster (see <a class="el" href="class_qwt_double_range.html#a63bc8ea5e7ecd776b7d32d21db1ea668" title="Adjust the value to the closest point in the step raster.">QwtDoubleRange::fitValue</a> and <a class="el" href="class_qwt_double_range.html#a299c35c72e9b69f5a0e3dcd2b7da775b" title="Increment the value by a specified number of steps.">QwtDoubleRange::incValue</a>).</p> <p>As a special case, a <a class="el" href="class_qwt_double_range.html" title="A class which controls a value within an interval.">QwtDoubleRange</a> can be periodic, which means that a value outside the interval will be mapped to a value inside the interval when <a class="el" href="class_qwt_double_range.html#af6a3aa74c970a2bef29f0c1af99720e8" title="Set a new value without adjusting to the step raster.">QwtDoubleRange::setValue()</a>, <a class="el" href="class_qwt_double_range.html#a63bc8ea5e7ecd776b7d32d21db1ea668" title="Adjust the value to the closest point in the step raster.">QwtDoubleRange::fitValue()</a>, <a class="el" href="class_qwt_double_range.html#a299c35c72e9b69f5a0e3dcd2b7da775b" title="Increment the value by a specified number of steps.">QwtDoubleRange::incValue()</a> or <a class="el" href="class_qwt_double_range.html#a19b85337d4ab0b5f0579b02e4fb29a8f" title="Increment the value by a specified number of pages.">QwtDoubleRange::incPages()</a> are called. </p> </div><hr/><h2>Constructor & Destructor Documentation</h2> <a class="anchor" id="a86f9f76df03d7917d88a95d1667f2d72"></a><!-- doxytag: member="QwtDoubleRange::QwtDoubleRange" ref="a86f9f76df03d7917d88a95d1667f2d72" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">QwtDoubleRange::QwtDoubleRange </td> <td>(</td> <td class="paramname"></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>The range is initialized to [0.0, 100.0], the step size to 1.0, and the value to 0.0. </p> </div> </div> <a class="anchor" id="abdcecda4b14ba81cfdaf063e2b98a22d"></a><!-- doxytag: member="QwtDoubleRange::~QwtDoubleRange" ref="abdcecda4b14ba81cfdaf063e2b98a22d" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">QwtDoubleRange::~QwtDoubleRange </td> <td>(</td> <td class="paramname"></td><td>)</td> <td><code> [virtual]</code></td> </tr> </table> </div> <div class="memdoc"> <p>Destroys the <a class="el" href="class_qwt_double_range.html" title="A class which controls a value within an interval.">QwtDoubleRange</a>. </p> </div> </div> <hr/><h2>Member Function Documentation</h2> <a class="anchor" id="a595c04ed863eb7f0adaf94440087fe0a"></a><!-- doxytag: member="QwtDoubleRange::exactPrevValue" ref="a595c04ed863eb7f0adaf94440087fe0a" args="() const " --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">double QwtDoubleRange::exactPrevValue </td> <td>(</td> <td class="paramname"></td><td>)</td> <td> const<code> [protected]</code></td> </tr> </table> </div> <div class="memdoc"> <p>Returns the exact previous value. </p> </div> </div> <a class="anchor" id="a705b76d28882d37bc5313d6c38c9a720"></a><!-- doxytag: member="QwtDoubleRange::exactValue" ref="a705b76d28882d37bc5313d6c38c9a720" args="() const " --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">double QwtDoubleRange::exactValue </td> <td>(</td> <td class="paramname"></td><td>)</td> <td> const<code> [protected]</code></td> </tr> </table> </div> <div class="memdoc"> <p>Returns the exact value. </p> <p>The exact value is the value which <a class="el" href="class_qwt_double_range.html#a7777cf257c812579c4891512f1b6cad0" title="Returns the current value.">QwtDoubleRange::value</a> would return if the value were not adjusted to the step raster. It differs from the current value only if <a class="el" href="class_qwt_double_range.html#a63bc8ea5e7ecd776b7d32d21db1ea668" title="Adjust the value to the closest point in the step raster.">fitValue()</a> or <a class="el" href="class_qwt_double_range.html#a299c35c72e9b69f5a0e3dcd2b7da775b" title="Increment the value by a specified number of steps.">incValue()</a> have been used before. This function is intended for internal use in derived classes. </p> </div> </div> <a class="anchor" id="a63bc8ea5e7ecd776b7d32d21db1ea668"></a><!-- doxytag: member="QwtDoubleRange::fitValue" ref="a63bc8ea5e7ecd776b7d32d21db1ea668" args="(double)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void QwtDoubleRange::fitValue </td> <td>(</td> <td class="paramtype">double </td> <td class="paramname"><em>x</em></td><td>)</td> <td><code> [virtual]</code></td> </tr> </table> </div> <div class="memdoc"> <p>Adjust the value to the closest point in the step raster. </p> <dl><dt><b>Parameters:</b></dt><dd> <table class="params"> <tr><td class="paramname">x</td><td>value </td></tr> </table> </dd> </dl> <dl class="warning"><dt><b>Warning:</b></dt><dd>The value is clipped when it lies outside the range. When the range is <a class="el" href="class_qwt_double_range.html#ad1efbcbf29dbc74f3f378292b76b007b" title="Returns true if the range is periodic.">QwtDoubleRange::periodic</a>, it will be mapped to a point in the interval such that <div class="fragment"><pre class="fragment">new value := x + n * (max. value - min. value)</pre></div> with an integer number n. </dd></dl> <p>Reimplemented in <a class="el" href="class_qwt_abstract_slider.html#a50ed1e265beaa1c8adbe718caa023e50">QwtAbstractSlider</a>.</p> </div> </div> <a class="anchor" id="a19b85337d4ab0b5f0579b02e4fb29a8f"></a><!-- doxytag: member="QwtDoubleRange::incPages" ref="a19b85337d4ab0b5f0579b02e4fb29a8f" args="(int)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void QwtDoubleRange::incPages </td> <td>(</td> <td class="paramtype">int </td> <td class="paramname"><em>nPages</em></td><td>)</td> <td><code> [virtual]</code></td> </tr> </table> </div> <div class="memdoc"> <p>Increment the value by a specified number of pages. </p> <dl><dt><b>Parameters:</b></dt><dd> <table class="params"> <tr><td class="paramname">nPages</td><td>Number of pages to increment. A negative number decrements the value. </td></tr> </table> </dd> </dl> <dl class="warning"><dt><b>Warning:</b></dt><dd>The Page size is specified in the constructor. </dd></dl> </div> </div> <a class="anchor" id="a299c35c72e9b69f5a0e3dcd2b7da775b"></a><!-- doxytag: member="QwtDoubleRange::incValue" ref="a299c35c72e9b69f5a0e3dcd2b7da775b" args="(int)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void QwtDoubleRange::incValue </td> <td>(</td> <td class="paramtype">int </td> <td class="paramname"><em>nSteps</em></td><td>)</td> <td><code> [virtual]</code></td> </tr> </table> </div> <div class="memdoc"> <p>Increment the value by a specified number of steps. </p> <dl><dt><b>Parameters:</b></dt><dd> <table class="params"> <tr><td class="paramname">nSteps</td><td>Number of steps to increment </td></tr> </table> </dd> </dl> <dl class="warning"><dt><b>Warning:</b></dt><dd>As a result of this operation, the new value will always be adjusted to the step raster. </dd></dl> <p>Reimplemented in <a class="el" href="class_qwt_abstract_slider.html#a5fccdb2ca370bba9ed4d29864fd80788">QwtAbstractSlider</a>.</p> </div> </div> <a class="anchor" id="afc4921deb3f68a64cc08b0654a040bc6"></a><!-- doxytag: member="QwtDoubleRange::isValid" ref="afc4921deb3f68a64cc08b0654a040bc6" args="() const " --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">bool QwtDoubleRange::isValid </td> <td>(</td> <td class="paramname"></td><td>)</td> <td> const</td> </tr> </table> </div> <div class="memdoc"> <p>Indicates if the value is valid. </p> <p>Reimplemented in <a class="el" href="class_qwt_abstract_slider.html#a87c750f098cb5f70306a7908339cb88e">QwtAbstractSlider</a>.</p> </div> </div> <a class="anchor" id="a215275a1a8b4218a424ee8444c7fe409"></a><!-- doxytag: member="QwtDoubleRange::maxValue" ref="a215275a1a8b4218a424ee8444c7fe409" args="() const " --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">double QwtDoubleRange::maxValue </td> <td>(</td> <td class="paramname"></td><td>)</td> <td> const</td> </tr> </table> </div> <div class="memdoc"> <p>Returns the value of the second border of the range. </p> <p>maxValue returns the value which has been specified as the second parameter in <a class="el" href="class_qwt_double_range.html#a43891011664b74b8e5454763a3f5ff21" title="Specify range and step size.">QwtDoubleRange::setRange</a>.</p> <dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="class_qwt_double_range.html#a43891011664b74b8e5454763a3f5ff21" title="Specify range and step size.">setRange()</a> </dd></dl> <p>Reimplemented in <a class="el" href="class_qwt_counter.html#a1db7484bea02c18681f9d628cd88695f">QwtCounter</a>.</p> </div> </div> <a class="anchor" id="a8b8650a6f8a96144d3af21207ee71637"></a><!-- doxytag: member="QwtDoubleRange::minValue" ref="a8b8650a6f8a96144d3af21207ee71637" args="() const " --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">double QwtDoubleRange::minValue </td> <td>(</td> <td class="paramname"></td><td>)</td> <td> const</td> </tr> </table> </div> <div class="memdoc"> <p>Returns the value at the first border of the range. </p> <p>minValue returns the value which has been specified as the first parameter in <a class="el" href="class_qwt_double_range.html#a43891011664b74b8e5454763a3f5ff21" title="Specify range and step size.">setRange()</a>.</p> <dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="class_qwt_double_range.html#a43891011664b74b8e5454763a3f5ff21" title="Specify range and step size.">setRange()</a> </dd></dl> <p>Reimplemented in <a class="el" href="class_qwt_counter.html#aa8ccc5f0626ae1ad4f542b0fdb51cc08">QwtCounter</a>.</p> </div> </div> <a class="anchor" id="ac12a5c43dc5839913379982ec40a39d8"></a><!-- doxytag: member="QwtDoubleRange::pageSize" ref="ac12a5c43dc5839913379982ec40a39d8" args="() const " --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">int QwtDoubleRange::pageSize </td> <td>(</td> <td class="paramname"></td><td>)</td> <td> const</td> </tr> </table> </div> <div class="memdoc"> <p>Returns the page size in steps. </p> </div> </div> <a class="anchor" id="ad1efbcbf29dbc74f3f378292b76b007b"></a><!-- doxytag: member="QwtDoubleRange::periodic" ref="ad1efbcbf29dbc74f3f378292b76b007b" args="() const " --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">bool QwtDoubleRange::periodic </td> <td>(</td> <td class="paramname"></td><td>)</td> <td> const</td> </tr> </table> </div> <div class="memdoc"> <p>Returns true if the range is periodic. </p> <dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="class_qwt_double_range.html#a95fa6a4e44fc47726d939155bb6f6f1f" title="Make the range periodic.">setPeriodic()</a> </dd></dl> </div> </div> <a class="anchor" id="a38768187bef94dd5e5a2c8664746b365"></a><!-- doxytag: member="QwtDoubleRange::prevValue" ref="a38768187bef94dd5e5a2c8664746b365" args="() const " --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">double QwtDoubleRange::prevValue </td> <td>(</td> <td class="paramname"></td><td>)</td> <td> const<code> [protected]</code></td> </tr> </table> </div> <div class="memdoc"> <p>Returns the previous value. </p> </div> </div> <a class="anchor" id="a3583134a1ac32706aa4742088bb9d4dc"></a><!-- doxytag: member="QwtDoubleRange::rangeChange" ref="a3583134a1ac32706aa4742088bb9d4dc" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void QwtDoubleRange::rangeChange </td> <td>(</td> <td class="paramname"></td><td>)</td> <td><code> [protected, virtual]</code></td> </tr> </table> </div> <div class="memdoc"> <p>Notify a change of the range. </p> <p>This virtual function is called whenever the range changes. The default implementation does nothing. </p> <p>Reimplemented in <a class="el" href="class_qwt_counter.html#a4fd4e750b1f5a852250e57778a3e4159">QwtCounter</a>, <a class="el" href="class_qwt_dial.html#a81b21a9954c5561af549214ee153573c">QwtDial</a>, and <a class="el" href="class_qwt_slider.html#ae8eff3a30ef4086cac42d244cef81ac0">QwtSlider</a>.</p> </div> </div> <a class="anchor" id="a95fa6a4e44fc47726d939155bb6f6f1f"></a><!-- doxytag: member="QwtDoubleRange::setPeriodic" ref="a95fa6a4e44fc47726d939155bb6f6f1f" args="(bool tf)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void QwtDoubleRange::setPeriodic </td> <td>(</td> <td class="paramtype">bool </td> <td class="paramname"><em>tf</em></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Make the range periodic. </p> <p>When the range is periodic, the value will be set to a point inside the interval such that</p> <div class="fragment"><pre class="fragment">point = value + n * width </pre></div><p>if the user tries to set a new value which is outside the range. If the range is nonperiodic (the default), values outside the range will be clipped.</p> <dl><dt><b>Parameters:</b></dt><dd> <table class="params"> <tr><td class="paramname">tf</td><td>true for a periodic range </td></tr> </table> </dd> </dl> </div> </div> <a class="anchor" id="a43891011664b74b8e5454763a3f5ff21"></a><!-- doxytag: member="QwtDoubleRange::setRange" ref="a43891011664b74b8e5454763a3f5ff21" args="(double vmin, double vmax, double vstep=0.0, int pagesize=1)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void QwtDoubleRange::setRange </td> <td>(</td> <td class="paramtype">double </td> <td class="paramname"><em>vmin</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">double </td> <td class="paramname"><em>vmax</em>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">double </td> <td class="paramname"><em>vstep</em> = <code>0.0</code>, </td> </tr> <tr> <td class="paramkey"></td> <td></td> <td class="paramtype">int </td> <td class="paramname"><em>pageSize</em> = <code>1</code> </td> </tr> <tr> <td></td> <td>)</td> <td></td><td></td> </tr> </table> </div> <div class="memdoc"> <p>Specify range and step size. </p> <dl><dt><b>Parameters:</b></dt><dd> <table class="params"> <tr><td class="paramname">vmin</td><td>lower boundary of the interval </td></tr> <tr><td class="paramname">vmax</td><td>higher boundary of the interval </td></tr> <tr><td class="paramname">vstep</td><td>step width </td></tr> <tr><td class="paramname">pageSize</td><td>page size in steps </td></tr> </table> </dd> </dl> <dl class="warning"><dt><b>Warning:</b></dt><dd><ul> <li>A change of the range changes the value if it lies outside the new range. The current value will *not* be adjusted to the new step raster. </li> <li>vmax < vmin is allowed. </li> <li>If the step size is left out or set to zero, it will be set to 1/100 of the interval length. </li> <li>If the step size has an absurd value, it will be corrected to a better one. </li> </ul> </dd></dl> </div> </div> <a class="anchor" id="a29ed5fc66439def424a8ad773eea285d"></a><!-- doxytag: member="QwtDoubleRange::setStep" ref="a29ed5fc66439def424a8ad773eea285d" args="(double)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void QwtDoubleRange::setStep </td> <td>(</td> <td class="paramtype">double </td> <td class="paramname"><em>vstep</em></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Change the step raster. </p> <dl><dt><b>Parameters:</b></dt><dd> <table class="params"> <tr><td class="paramname">vstep</td><td>new step width </td></tr> </table> </dd> </dl> <dl class="warning"><dt><b>Warning:</b></dt><dd>The value will <em>not</em> be adjusted to the new step raster. </dd></dl> <p>Reimplemented in <a class="el" href="class_qwt_counter.html#ab885e97d0071877dfefb73feb0adc0cd">QwtCounter</a>.</p> </div> </div> <a class="anchor" id="a50a9c386663e170016a74cf8ee28ab8f"></a><!-- doxytag: member="QwtDoubleRange::setValid" ref="a50a9c386663e170016a74cf8ee28ab8f" args="(bool)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void QwtDoubleRange::setValid </td> <td>(</td> <td class="paramtype">bool </td> <td class="paramname"><em>isValid</em></td><td>)</td> <td></td> </tr> </table> </div> <div class="memdoc"> <p>Set the value to be valid/invalid. </p> <p>Reimplemented in <a class="el" href="class_qwt_abstract_slider.html#a79d99f14ebd47dfede8135845c90cedb">QwtAbstractSlider</a>.</p> </div> </div> <a class="anchor" id="af6a3aa74c970a2bef29f0c1af99720e8"></a><!-- doxytag: member="QwtDoubleRange::setValue" ref="af6a3aa74c970a2bef29f0c1af99720e8" args="(double)" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void QwtDoubleRange::setValue </td> <td>(</td> <td class="paramtype">double </td> <td class="paramname"><em>x</em></td><td>)</td> <td><code> [virtual]</code></td> </tr> </table> </div> <div class="memdoc"> <p>Set a new value without adjusting to the step raster. </p> <dl><dt><b>Parameters:</b></dt><dd> <table class="params"> <tr><td class="paramname">x</td><td>new value </td></tr> </table> </dd> </dl> <dl class="warning"><dt><b>Warning:</b></dt><dd>The value is clipped when it lies outside the range. When the range is <a class="el" href="class_qwt_double_range.html#ad1efbcbf29dbc74f3f378292b76b007b" title="Returns true if the range is periodic.">QwtDoubleRange::periodic</a>, it will be mapped to a point in the interval such that <div class="fragment"><pre class="fragment">new value := x + n * (max. value - min. value)</pre></div> with an integer number n. </dd></dl> <p>Reimplemented in <a class="el" href="class_qwt_abstract_slider.html#ac3713f8989b647cb79f0a5894991e36a">QwtAbstractSlider</a>, and <a class="el" href="class_qwt_counter.html#a429a2e986aa46c1231643df5d4c78970">QwtCounter</a>.</p> </div> </div> <a class="anchor" id="a0cb8cc60548c10cb1d98e54387961967"></a><!-- doxytag: member="QwtDoubleRange::step" ref="a0cb8cc60548c10cb1d98e54387961967" args="() const " --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">double QwtDoubleRange::step </td> <td>(</td> <td class="paramname"></td><td>)</td> <td> const</td> </tr> </table> </div> <div class="memdoc"> <dl class="return"><dt><b>Returns:</b></dt><dd>the step size </dd></dl> <dl class="see"><dt><b>See also:</b></dt><dd><a class="el" href="class_qwt_double_range.html#a29ed5fc66439def424a8ad773eea285d" title="Change the step raster.">setStep()</a>, <a class="el" href="class_qwt_double_range.html#a43891011664b74b8e5454763a3f5ff21" title="Specify range and step size.">setRange()</a> </dd></dl> <p>Reimplemented in <a class="el" href="class_qwt_counter.html#ab3496bdd6bdb093462bca588880d8c1b">QwtCounter</a>.</p> </div> </div> <a class="anchor" id="a86641f8755ed172ca4cf72d36df539ca"></a><!-- doxytag: member="QwtDoubleRange::stepChange" ref="a86641f8755ed172ca4cf72d36df539ca" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void QwtDoubleRange::stepChange </td> <td>(</td> <td class="paramname"></td><td>)</td> <td><code> [protected, virtual]</code></td> </tr> </table> </div> <div class="memdoc"> <p>Notify a change of the step size. </p> <p>This virtual function is called whenever the step size changes. The default implementation does nothing. </p> </div> </div> <a class="anchor" id="a7777cf257c812579c4891512f1b6cad0"></a><!-- doxytag: member="QwtDoubleRange::value" ref="a7777cf257c812579c4891512f1b6cad0" args="() const " --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">double QwtDoubleRange::value </td> <td>(</td> <td class="paramname"></td><td>)</td> <td> const</td> </tr> </table> </div> <div class="memdoc"> <p>Returns the current value. </p> <p>Reimplemented in <a class="el" href="class_qwt_counter.html#a121194fadd8cea929c1ac9509f27fe58">QwtCounter</a>.</p> </div> </div> <a class="anchor" id="a1d50398342d6aa1d9cd86650ee29aff8"></a><!-- doxytag: member="QwtDoubleRange::valueChange" ref="a1d50398342d6aa1d9cd86650ee29aff8" args="()" --> <div class="memitem"> <div class="memproto"> <table class="memname"> <tr> <td class="memname">void QwtDoubleRange::valueChange </td> <td>(</td> <td class="paramname"></td><td>)</td> <td><code> [protected, virtual]</code></td> </tr> </table> </div> <div class="memdoc"> <p>Notify a change of value. </p> <p>This virtual function is called whenever the value changes. The default implementation does nothing. </p> <p>Reimplemented in <a class="el" href="class_qwt_abstract_slider.html#a2f04dc51e4402b51fef3250bcc99dc7f">QwtAbstractSlider</a>, <a class="el" href="class_qwt_dial.html#ad8803d79d9fbefdae55907728bb01894">QwtDial</a>, <a class="el" href="class_qwt_slider.html#a62380259b0831ad98a1b0ad011f32bea">QwtSlider</a>, and <a class="el" href="class_qwt_wheel.html#a0fa3d4f4189f7bb6ee0944cd30060eb5">QwtWheel</a>.</p> </div> </div> </div> <hr class="footer"/><address class="footer"><small>Generated by  <a href="http://www.doxygen.org/index.html"> <img class="footer" src="doxygen.png" alt="doxygen"/></a> 1.7.3 </small></address> </body> </html>