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

📄 qgroupbox.html

📁 QT3的教程
💻 HTML
📖 第 1 页 / 共 2 页
字号:
</h3><p>返回组合框标题的对齐方式。详细情况请参考<a href="qgroupbox.html#alignment-prop">“alignment”</a>属性。<h3 class=fn>int <a name="columns"></a>QGroupBox::columns () const</h3><p>返回组合框中的列数或者行数(依赖<a href="#orientation-prop">orientation</a>)。详细情况请参考<a href="qgroupbox.html#columns-prop">“columns”</a>属性。<h3 class=fn>int <a name="insideMargin"></a>QGroupBox::insideMargin () const</h3>返回组合框中的项和框架之间的空白的宽度。<p> 仅仅适用于组合框有一个定义的方向。<p> 默认大约为11。<p> <p>也可以参考<a href="#setInsideMargin">setInsideMargin</a>()和<a href="#orientation-prop">orientation</a>。<h3 class=fn>int <a name="insideSpacing"></a>QGroupBox::insideSpacing () const</h3>返回组合框中各项之间的空白的宽度。<p> 仅仅适用于组合框有一个定义的方向。<p> 默认大约为5。<p> <p>也可以参考<a href="#setInsideSpacing">setInsideSpacing</a>()和<a href="#orientation-prop">orientation</a>。<h3 class=fn><a href="qt.html#Orientation-enum">Orientation</a> <a name="orientation"></a>QGroupBox::orientation () const</h3><p>返回组合框的当前方向。详细情况请参考<a href="qgroupbox.html#orientation-prop">“orientation”</a>属性。<h3 class=fn>void <a name="setAlignment"></a>QGroupBox::setAlignment ( int )<tt> [虚]</tt></h3><p>设置组合框标题的对齐方式。详细情况请参考<a href="qgroupbox.html#alignment-prop">“alignment”</a>属性。<h3 class=fn>void <a name="setColumnLayout"></a>QGroupBox::setColumnLayout ( int&nbsp;strips, <a href="qt.html#Orientation-enum">Orientation</a>&nbsp;direction )<tt> [虚]</tt></h3>改变组合框的布局。这个函数只有和没有使用任何布局信息的默认构造函数联合使用才有用。这个函数会把所有已经存在的子对象放入新的布局中。在已经插入子对象之后再调用这个函数不是很好的Qt编程风格。<p> <p>也可以参考<a href="#orientation-prop">orientation</a>和<a href="#columns-prop">columns</a>。<p>实例:<a href="tutorial2-09.html#x2546">chart/optionsform.cpp</a>。<h3 class=fn>void <a name="setColumns"></a>QGroupBox::setColumns ( int )</h3><p>设置组合框中的列数或者行数(依赖<a href="#orientation-prop">orientation</a>)。详细情况请参考<a href="qgroupbox.html#columns-prop">“columns”</a>属性。<h3 class=fn>void <a name="setInsideMargin"></a>QGroupBox::setInsideMargin ( int&nbsp;m )</h3>设置组合框中的项和框架之间的空白的宽度为<em>m</em>象素。<p> <p>也可以参考<a href="#insideSpacing">insideSpacing</a>()。<h3 class=fn>void <a name="setInsideSpacing"></a>QGroupBox::setInsideSpacing ( int&nbsp;s )</h3>设置组合框中各项之间的空白的宽度为<em>m</em>象素。<h3 class=fn>void <a name="setOrientation"></a>QGroupBox::setOrientation ( <a href="qt.html#Orientation-enum">Orientation</a> )</h3><p>设置组合框的当前方向。详细情况请参考<a href="qgroupbox.html#orientation-prop">“orientation”</a>属性。<h3 class=fn>void <a name="setTitle"></a>QGroupBox::setTitle ( const&nbsp;<a href="qstring.html">QString</a>&nbsp;&amp; )<tt> [虚]</tt></h3><p>设置组合框的标题文本。详细情况请参考<a href="qgroupbox.html#title-prop">“title”</a>属性。<h3 class=fn><a href="qstring.html">QString</a> <a name="title"></a>QGroupBox::title () const</h3><p>返回组合框的标题文本。详细情况请参考<a href="qgroupbox.html#title-prop">“title”</a>属性。<hr><h2>属性文档</h2><h3 class=fn>Alignment <a name="alignment-prop"></a>alignment</h3><p>这个属性保存的是组合框标题的对齐方式。<p>标题总是被放在框架上面的那行中,可是,水平对齐方式可以由这个对齐参数指定。<p> 对齐方式是下述标记之一:<ul><li> <a href="qt.html#AlignmentFlags-enum">AlignAuto</a>根据语言对齐标题,通常为左。<li> <a href="qt.html#AlignmentFlags-enum">AlignLeft</a>左对齐标题。<li> <a href="qt.html#AlignmentFlags-enum">AlignRight</a>右对齐标题。<li> <a href="qt.html#AlignmentFlags-enum">AlignHCenter</a>中间对齐标题。</ul><p> 默认的对齐方式是<a href="qt.html#AlignmentFlags-enum">AlignAuto</a>。<p> <p>也可以参考<a href="qt.html#AlignmentFlags-enum">Qt::AlignmentFlags</a>。<p>通过<a href="#setAlignment">setAlignment</a>()设置属性值并且通过<a href="#alignment">alignment</a>()来获得属性值。<h3 class=fn>int <a name="columns-prop"></a>columns</h3><p>这个属性保存的是组合框中的列数或者行数(依赖<a href="#orientation-prop">orientation</a>)。<p>通常设置这个属性不是一个好主意,因为这会使它变慢(它是一个完全的布局)。最好在构造函数中直接设置列数或者行数。<p>通过<a href="#setColumns">setColumns</a>()设置属性值并且通过<a href="#columns">columns</a>()来获得属性值。<h3 class=fn><a href="qt.html#Orientation-enum">Orientation</a> <a name="orientation-prop"></a>orientation</h3><p>这个属性保存的是组合框的当前方向。<p>水平组合框把它的子对象按列排列,而垂直组合框会按行排列它们。因此只有一列的水平组合框会把它的子对象垂直地排列在这列中。<p>通常设置这个属性不是一个好主意,因为这会使它变慢(它是一个完全的布局)。最好在构造函数中直接设置方向。<p>通过<a href="#setOrientation">setOrientation</a>()设置属性值并且通过<a href="#orientation">orientation</a>()来获得属性值。<h3 class=fn><a href="qstring.html">QString</a> <a name="title-prop"></a>title</h3><p>这个属性保存的是组合框的标题文本。<p>如果这个标题包含一个&amp;,后面还有一个字母,这个组合框标题文本将会又一个焦点改变键盘快捷键。<p> <pre>      g-&gt;setTitle( "&amp;User information" );  </pre>这将会产生“User information”并且U下面有下划线。Alt+U会移动<a href="focus.html#keyboard-focus">键盘焦点</a>到这个组合框。<p> 没有默认标题文本。<p>通过<a href="#setTitle">setTitle</a>()设置属性值并且通过<a href="#title">title</a>()来获得属性值。<!-- eof --><hr><p>这个文件是<a href="index.html">Qt工具包</a>一部分。版权所有 &copy; 1995-2002<a href="http://www.trolltech.com/">Trolltech</a>。保留所有权利。<p><address><hr><div align=center><table width=100% cellspacing=0 border=0><tr><td>Copyright &copy; 2002 <a href="http://www.trolltech.com">Trolltech</a><td><a href="http://www.trolltech.com/trademarks.html">Trademarks</a><td><a href="zh_CN.html">译者:Cavendish</a><td align=right><div align=right>Qt 3.0.5版</div></table></div></address></body></html>

⌨️ 快捷键说明

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