📄 class_qwt_plot_layout.html
字号:
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"><html><head><meta http-equiv="Content-Type" content="text/html;charset=iso-8859-1"><title>Qwt User's Guide: QwtPlotLayout Class Reference</title><link href="doxygen.css" rel="stylesheet" type="text/css"><link href="tabs.css" rel="stylesheet" type="text/css"></head><body><!-- Generated by Doxygen 1.4.6 --><div class="tabs"> <ul> <li><a href="index.html"><span>Main Page</span></a></li> <li id="current"><a href="classes.html"><span>Classes</span></a></li> <li><a href="files.html"><span>Files</span></a></li> <li><a href="pages.html"><span>Related Pages</span></a></li> </ul></div><div class="tabs"> <ul> <li><a href="classes.html"><span>Alphabetical List</span></a></li> <li><a href="annotated.html"><span>Class List</span></a></li> <li><a href="hierarchy.html"><span>Class Hierarchy</span></a></li> <li><a href="functions.html"><span>Class Members</span></a></li> </ul></div><h1>QwtPlotLayout Class Reference</h1><!-- doxytag: class="QwtPlotLayout" --><a href="class_qwt_plot_layout-members.html">List of all members.</a><hr><a name="_details"></a><h2>Detailed Description</h2>Layout class for <a class="el" href="class_qwt_plot.html">QwtPlot</a>. <p>Organizes the geometry for the different <a class="el" href="class_qwt_plot.html">QwtPlot</a> components. <p><p>Definition at line <a class="el" href="qwt__plot__layout_8h-source.html#l00022">22</a> of file <a class="el" href="qwt__plot__layout_8h-source.html">qwt_plot_layout.h</a>.<table border="0" cellpadding="0" cellspacing="0"><tr><td></td></tr><tr><td colspan="2"><br><h2>Public Types</h2></td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">enum </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_plot_layout.html#646296ab0befcaf043ba14b6eb83114d">Options</a> { <br> <b>AlignScales</b> = 1, <br> <b>IgnoreScrollbars</b> = 2, <br> <b>IgnoreFrames</b> = 4, <br> <b>IgnoreMargin</b> = 8, <br> <b>IgnoreLegend</b> = 16<br> }</td></tr><tr><td colspan="2"><br><h2>Public Member Functions</h2></td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top"> </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_plot_layout.html#c89596fb2a3d3a92901f124821045a47">QwtPlotLayout</a> ()</td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">virtual </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_plot_layout.html#39653485c638535bc11f50d2e5ef936d">~QwtPlotLayout</a> ()</td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_plot_layout.html#67fc75a6f4c4d368d629841df1c5e6a5">setMargin</a> (int)</td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_plot_layout.html#358367bf229c02a7a062f9890a1b3507">margin</a> () const </td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_plot_layout.html#11667dad6675a7a58cc60ab1597b1203">setCanvasMargin</a> (int margin, int axis=-1)</td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_plot_layout.html#acf659495ecc45367eacf5f4b2aeca7d">canvasMargin</a> (int axis) const </td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_plot_layout.html#147fcf4c59b34779b5a7dc7361a3b6c3">setAlignCanvasToScales</a> (bool)</td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_plot_layout.html#b0200ba639cfd0f31b798d6aa9b6bba7">alignCanvasToScales</a> () const </td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_plot_layout.html#6508553ec1d66bede49e7767526c3d03">setSpacing</a> (int)</td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_plot_layout.html#e93650a8f3208578f87348334b77a282">spacing</a> () const </td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_plot_layout.html#11c9695a68f95135841cb23212589f18">setLegendPosition</a> (<a class="el" href="class_qwt_plot.html#31aacb65b5c049dde8c34a0d8482661b">QwtPlot::LegendPosition</a> pos, double ratio)</td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_plot_layout.html#001f1eca91803d0eaa9548efc50879eb">setLegendPosition</a> (<a class="el" href="class_qwt_plot.html#31aacb65b5c049dde8c34a0d8482661b">QwtPlot::LegendPosition</a> pos)</td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top"><a class="el" href="class_qwt_plot.html#31aacb65b5c049dde8c34a0d8482661b">QwtPlot::LegendPosition</a> </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_plot_layout.html#6351a18b76e22d9e83d682d203599afc">legendPosition</a> () const </td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_plot_layout.html#abe9f952046139667e055c661bee4dbb">setLegendRatio</a> (double ratio)</td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">double </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_plot_layout.html#6d5d4e568ad74010742e1fdcfc1c7672">legendRatio</a> () const </td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">virtual QSize </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_plot_layout.html#068a12c510998760c727a095f5b055fe">minimumSizeHint</a> (const <a class="el" href="class_qwt_plot.html">QwtPlot</a> *) const </td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_plot_layout.html#4ccba7e8e8a857cd1e16d2a68f9bcbcb">activate</a> (const <a class="el" href="class_qwt_plot.html">QwtPlot</a> *, const QRect &rect, int options=0)</td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_plot_layout.html#44ce72879951571ffe4daa95be0ec242">invalidate</a> ()</td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">const QRect & </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_plot_layout.html#f6f48a4705eb7aa7616a9e1da98e2d14">titleRect</a> () const </td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">const QRect & </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_plot_layout.html#f3f630625686721b521a8cd3c015bcbf">legendRect</a> () const </td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">const QRect & </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_plot_layout.html#87154a8c0f12698113bf8990a7d579f6">scaleRect</a> (int axis) const </td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">const QRect & </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_plot_layout.html#244d79c1d635630b5d160053b62ae9f3">canvasRect</a> () const </td></tr><tr><td colspan="2"><br><h2>Protected Member Functions</h2></td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">QRect </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_plot_layout.html#3ac077f6dd97a28a81e2e443597d378c">layoutLegend</a> (int options, const QRect &) const </td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">QRect </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_plot_layout.html#51893ccc912ef62d0e86d91dc8eaf357">alignLegend</a> (const QRect &canvasRect, const QRect &legendRect) const </td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_plot_layout.html#036716f40c899fb5e82d2866e8758c81">expandLineBreaks</a> (int options, const QRect &rect, int &dimTitle, int dimAxes[QwtPlot::axisCnt]) const </td></tr><tr><td class="memItemLeft" nowrap align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><a class="el" href="class_qwt_plot_layout.html#a1ea394fce72c1c06f2aaf6fcd90db2a">alignScales</a> (int options, QRect &canvasRect, QRect scaleRect[QwtPlot::axisCnt]) const </td></tr></table><hr><h2>Constructor & Destructor Documentation</h2><a class="anchor" name="c89596fb2a3d3a92901f124821045a47"></a><!-- doxytag: member="QwtPlotLayout::QwtPlotLayout" ref="c89596fb2a3d3a92901f124821045a47" args="()" --><p><table class="mdTable" cellpadding="2" cellspacing="0"> <tr> <td class="mdRow"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top">QwtPlotLayout::QwtPlotLayout </td> <td class="md" valign="top">( </td> <td class="mdname1" valign="top" nowrap> </td> <td class="md" valign="top"> ) </td> <td class="md" nowrap><code> [explicit]</code></td> </tr> </table> </td> </tr></table><table cellspacing="5" cellpadding="0" border="0"> <tr> <td> </td> <td><p>Constructor. <p><p>Definition at line <a class="el" href="qwt__plot__layout_8cpp-source.html#l00183">183</a> of file <a class="el" href="qwt__plot__layout_8cpp-source.html">qwt_plot_layout.cpp</a>.<p>References <a class="el" href="qwt__plot__layout_8cpp-source.html#l00452">invalidate()</a>, <a class="el" href="qwt__plot__layout_8cpp-source.html#l00236">setCanvasMargin()</a>, and <a class="el" href="qwt__plot__layout_8cpp-source.html#l00327">setLegendPosition()</a>. </td> </tr></table><a class="anchor" name="39653485c638535bc11f50d2e5ef936d"></a><!-- doxytag: member="QwtPlotLayout::~QwtPlotLayout" ref="39653485c638535bc11f50d2e5ef936d" args="()" --><p><table class="mdTable" cellpadding="2" cellspacing="0"> <tr> <td class="mdRow"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top">QwtPlotLayout::~QwtPlotLayout </td> <td class="md" valign="top">( </td> <td class="mdname1" valign="top" nowrap> </td> <td class="md" valign="top"> ) </td> <td class="md" nowrap><code> [virtual]</code></td> </tr> </table> </td> </tr></table><table cellspacing="5" cellpadding="0" border="0"> <tr> <td> </td> <td><p>Destructor. <p><p>Definition at line <a class="el" href="qwt__plot__layout_8cpp-source.html#l00194">194</a> of file <a class="el" href="qwt__plot__layout_8cpp-source.html">qwt_plot_layout.cpp</a>. </td> </tr></table><hr><h2>Member Function Documentation</h2><a class="anchor" name="4ccba7e8e8a857cd1e16d2a68f9bcbcb"></a><!-- doxytag: member="QwtPlotLayout::activate" ref="4ccba7e8e8a857cd1e16d2a68f9bcbcb" args="(const QwtPlot *, const QRect &rect, int options=0)" --><p><table class="mdTable" cellpadding="2" cellspacing="0"> <tr> <td class="mdRow"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top">void QwtPlotLayout::activate </td> <td class="md" valign="top">( </td> <td class="md" nowrap valign="top">const <a class="el" href="class_qwt_plot.html">QwtPlot</a> * </td> <td class="mdname" nowrap> <em>plot</em>, </td> </tr> <tr> <td class="md" nowrap align="right"></td> <td class="md"></td> <td class="md" nowrap>const QRect & </td> <td class="mdname" nowrap> <em>plotRect</em>, </td> </tr> <tr> <td class="md" nowrap align="right"></td> <td class="md"></td> <td class="md" nowrap>int </td> <td class="mdname" nowrap> <em>options</em> = <code>0</code></td> </tr> <tr> <td class="md"></td> <td class="md">) </td> <td class="md" colspan="2"><code> [virtual]</code></td> </tr> </table> </td> </tr></table><table cellspacing="5" cellpadding="0" border="0"> <tr> <td> </td> <td><p>Recalculate the geometry of all components. <p><dl compact><dt><b>Parameters:</b></dt><dd> <table border="0" cellspacing="2" cellpadding="0"> <tr><td valign="top"></td><td valign="top"><em>plot</em> </td><td>Plot to be layout </td></tr> <tr><td valign="top"></td><td valign="top"><em>plotRect</em> </td><td>Rect where to place the components </td></tr> <tr><td valign="top"></td><td valign="top"><em>options</em> </td><td>Options</td></tr> </table></dl><dl compact><dt><b>See also:</b></dt><dd><a class="el" href="class_qwt_plot_layout.html#44ce72879951571ffe4daa95be0ec242">invalidate()</a>, <a class="el" href="class_qwt_plot_layout.html#f6f48a4705eb7aa7616a9e1da98e2d14">titleRect()</a>, <a class="el" href="class_qwt_plot_layout.html#f3f630625686721b521a8cd3c015bcbf">legendRect()</a>, <a class="el" href="class_qwt_plot_layout.html#87154a8c0f12698113bf8990a7d579f6">scaleRect()</a>, <a class="el" href="class_qwt_plot_layout.html#244d79c1d635630b5d160053b62ae9f3">canvasRect()</a> </dd></dl><p>Definition at line <a class="el" href="qwt__plot__layout_8cpp-source.html#l01017">1017</a> of file <a class="el" href="qwt__plot__layout_8cpp-source.html">qwt_plot_layout.cpp</a>.<p>References <a class="el" href="qwt__plot__layout_8cpp-source.html#l00452">invalidate()</a>, <a class="el" href="qwt__legend_8cpp-source.html#l00617">QwtLegend::isEmpty()</a>, <a class="el" href="qwt__plot__layout_8cpp-source.html#l00648">layoutLegend()</a>, and <a class="el" href="qwt__plot_8cpp-source.html#l00271">QwtPlot::legend()</a>. </td> </tr></table><a class="anchor" name="b0200ba639cfd0f31b798d6aa9b6bba7"></a><!-- doxytag: member="QwtPlotLayout::alignCanvasToScales" ref="b0200ba639cfd0f31b798d6aa9b6bba7" args="() const " --><p><table class="mdTable" cellpadding="2" cellspacing="0"> <tr> <td class="mdRow"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top">bool QwtPlotLayout::alignCanvasToScales </td> <td class="md" valign="top">( </td> <td class="mdname1" valign="top" nowrap> </td> <td class="md" valign="top"> ) </td> <td class="md" nowrap> const</td> </tr> </table> </td> </tr></table><table cellspacing="5" cellpadding="0" border="0"> <tr> <td> </td> <td><p>Return the align-canvas-to-axis-scales setting. The canvas may:<ul><li>extend beyond the axis scale ends to maximize its size</li><li>align with the axis scale ends to control its size.</li></ul><p><dl compact><dt><b>Returns:</b></dt><dd>align-canvas-to-axis-scales setting </dd></dl><dl compact><dt><b>See also:</b></dt><dd><a class="el" href="class_qwt_plot_layout.html#147fcf4c59b34779b5a7dc7361a3b6c3">setAlignCanvasToScales</a>, <a class="el" href="class_qwt_plot_layout.html#11667dad6675a7a58cc60ab1597b1203">setCanvasMargin()</a> </dd></dl><dl compact><dt><b>Note:</b></dt><dd>In this context the term 'scale' means the backbone of a scale. </dd></dl><p>Definition at line <a class="el" href="qwt__plot__layout_8cpp-source.html#l00288">288</a> of file <a class="el" href="qwt__plot__layout_8cpp-source.html">qwt_plot_layout.cpp</a>. </td> </tr></table><a class="anchor" name="51893ccc912ef62d0e86d91dc8eaf357"></a><!-- doxytag: member="QwtPlotLayout::alignLegend" ref="51893ccc912ef62d0e86d91dc8eaf357" args="(const QRect &canvasRect, const QRect &legendRect) const " --><p><table class="mdTable" cellpadding="2" cellspacing="0"> <tr> <td class="mdRow"> <table cellpadding="0" cellspacing="0" border="0"> <tr> <td class="md" nowrap valign="top">QRect QwtPlotLayout::alignLegend </td> <td class="md" valign="top">( </td> <td class="md" nowrap valign="top">const QRect & </td> <td class="mdname" nowrap> <em>canvasRect</em>, </td> </tr> <tr> <td class="md" nowrap align="right"></td> <td class="md"></td> <td class="md" nowrap>const QRect & </td> <td class="mdname" nowrap> <em>legendRect</em></td> </tr> <tr> <td class="md"></td> <td class="md">) </td> <td class="md" colspan="2"> const<code> [protected]</code></td>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -