source: trunk/doc/html/qframe.html@ 190

Last change on this file since 190 was 190, checked in by rudi, 14 years ago

reference documentation added

File size: 25.1 KB
Line 
1<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
2<!-- /home/espenr/tmp/qt-3.3.8-espenr-2499/qt-x11-free-3.3.8/src/widgets/qframe.cpp:46 -->
3<html>
4<head>
5<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
6<title>QFrame Class</title>
7<style type="text/css"><!--
8fn { margin-left: 1cm; text-indent: -1cm; }
9a:link { color: #004faf; text-decoration: none }
10a:visited { color: #672967; text-decoration: none }
11body { background: #ffffff; color: black; }
12--></style>
13</head>
14<body>
15
16<table border="0" cellpadding="0" cellspacing="0" width="100%">
17<tr bgcolor="#E5E5E5">
18<td valign=center>
19 <a href="index.html">
20<font color="#004faf">Home</font></a>
21 | <a href="classes.html">
22<font color="#004faf">All&nbsp;Classes</font></a>
23 | <a href="mainclasses.html">
24<font color="#004faf">Main&nbsp;Classes</font></a>
25 | <a href="annotated.html">
26<font color="#004faf">Annotated</font></a>
27 | <a href="groups.html">
28<font color="#004faf">Grouped&nbsp;Classes</font></a>
29 | <a href="functions.html">
30<font color="#004faf">Functions</font></a>
31</td>
32<td align="right" valign="center"><img src="logo32.png" align="right" width="64" height="32" border="0"></td></tr></table><h1 align=center>QFrame Class Reference</h1>
33
34<p>The QFrame class is the base class of widgets that can have a frame.
35<a href="#details">More...</a>
36<p><tt>#include &lt;<a href="qframe-h.html">qframe.h</a>&gt;</tt>
37<p>Inherits <a href="qwidget.html">QWidget</a>.
38<p>Inherited by <a href="qgroupbox.html">QGroupBox</a>, <a href="qscrollview.html">QScrollView</a>, <a href="qdockwindow.html">QDockWindow</a>, <a href="qgrid.html">QGrid</a>, <a href="qhbox.html">QHBox</a>, <a href="qlabel.html">QLabel</a>, <a href="qlcdnumber.html">QLCDNumber</a>, <a href="qlineedit.html">QLineEdit</a>, <a href="qmenubar.html">QMenuBar</a>, <a href="qpopupmenu.html">QPopupMenu</a>, <a href="qprogressbar.html">QProgressBar</a>, <a href="qsplitter.html">QSplitter</a>, <a href="qtoolbox.html">QToolBox</a>, and <a href="qwidgetstack.html">QWidgetStack</a>.
39<p><a href="qframe-members.html">List of all member functions.</a>
40<h2>Public Members</h2>
41<ul>
42<li class=fn><a href="#QFrame"><b>QFrame</b></a> ( QWidget&nbsp;*&nbsp;parent = 0, const&nbsp;char&nbsp;*&nbsp;name = 0, WFlags&nbsp;f = 0 )</li>
43<li class=fn>int <a href="#frameStyle"><b>frameStyle</b></a> () const</li>
44<li class=fn>virtual void <a href="#setFrameStyle"><b>setFrameStyle</b></a> ( int&nbsp;style )</li>
45<li class=fn>int <a href="#frameWidth"><b>frameWidth</b></a> () const</li>
46<li class=fn>QRect <a href="#contentsRect"><b>contentsRect</b></a> () const</li>
47<li class=fn>enum <a href="#Shape-enum"><b>Shape</b></a> { NoFrame = 0, Box = 0x0001, Panel = 0x0002, WinPanel = 0x0003, HLine = 0x0004, VLine = 0x0005, StyledPanel = 0x0006, PopupPanel = 0x0007, MenuBarPanel = 0x0008, ToolBarPanel = 0x0009, LineEditPanel = 0x000a, TabWidgetPanel = 0x000b, GroupBoxPanel = 0x000c, MShape = 0x000f }</li>
48<li class=fn>enum <a href="#Shadow-enum"><b>Shadow</b></a> { Plain = 0x0010, Raised = 0x0020, Sunken = 0x0030, MShadow = 0x00f0 }</li>
49<li class=fn>Shape <a href="#frameShape"><b>frameShape</b></a> () const</li>
50<li class=fn>void <a href="#setFrameShape"><b>setFrameShape</b></a> ( Shape )</li>
51<li class=fn>Shadow <a href="#frameShadow"><b>frameShadow</b></a> () const</li>
52<li class=fn>void <a href="#setFrameShadow"><b>setFrameShadow</b></a> ( Shadow )</li>
53<li class=fn>int <a href="#lineWidth"><b>lineWidth</b></a> () const</li>
54<li class=fn>virtual void <a href="#setLineWidth"><b>setLineWidth</b></a> ( int )</li>
55<li class=fn>int <a href="#margin"><b>margin</b></a> () const</li>
56<li class=fn>virtual void <a href="#setMargin"><b>setMargin</b></a> ( int )</li>
57<li class=fn>int <a href="#midLineWidth"><b>midLineWidth</b></a> () const</li>
58<li class=fn>virtual void <a href="#setMidLineWidth"><b>setMidLineWidth</b></a> ( int )</li>
59<li class=fn>QRect <a href="#frameRect"><b>frameRect</b></a> () const</li>
60<li class=fn>virtual void <a href="#setFrameRect"><b>setFrameRect</b></a> ( const QRect &amp; )</li>
61</ul>
62<h2>Properties</h2>
63<ul>
64<li class=fn>QRect <a href="#contentsRect-prop"><b>contentsRect</b></a>&nbsp;- the rectangle inside the frame &nbsp;<em>(read only)</em></li>
65<li class=fn>QRect <a href="#frameRect-prop"><b>frameRect</b></a>&nbsp;- the frame rectangle</li>
66<li class=fn>Shadow <a href="#frameShadow-prop"><b>frameShadow</b></a>&nbsp;- the frame shadow value from the frame style</li>
67<li class=fn>Shape <a href="#frameShape-prop"><b>frameShape</b></a>&nbsp;- the frame shape value from the frame style</li>
68<li class=fn>int <a href="#frameWidth-prop"><b>frameWidth</b></a>&nbsp;- the width of the frame that is drawn &nbsp;<em>(read only)</em></li>
69<li class=fn>int <a href="#lineWidth-prop"><b>lineWidth</b></a>&nbsp;- the line width</li>
70<li class=fn>int <a href="#margin-prop"><b>margin</b></a>&nbsp;- the width of the margin</li>
71<li class=fn>int <a href="#midLineWidth-prop"><b>midLineWidth</b></a>&nbsp;- the width of the mid-line</li>
72</ul>
73<h2>Protected Members</h2>
74<ul>
75<li class=fn>virtual void <a href="#paintEvent"><b>paintEvent</b></a> ( QPaintEvent&nbsp;*&nbsp;event )</li>
76<li class=fn>virtual void <a href="#resizeEvent"><b>resizeEvent</b></a> ( QResizeEvent&nbsp;*&nbsp;e )</li>
77<li class=fn>virtual void <a href="#drawFrame"><b>drawFrame</b></a> ( QPainter&nbsp;*&nbsp;p )</li>
78<li class=fn>virtual void <a href="#drawContents"><b>drawContents</b></a> ( QPainter * )</li>
79<li class=fn>virtual void <a href="#frameChanged"><b>frameChanged</b></a> ()</li>
80</ul>
81<hr><a name="details"></a><h2>Detailed Description</h2>
82
83
84The QFrame class is the base class of widgets that can have a frame.
85<p>
86<p> It draws a frame and calls a virtual function, <a href="#drawContents">drawContents</a>(), to
87fill in the frame. This function is reimplemented by subclasses.
88There are also two other less useful functions: <a href="#drawFrame">drawFrame</a>() and
89<a href="#frameChanged">frameChanged</a>().
90<p> <a href="qpopupmenu.html">QPopupMenu</a> uses this to "raise" the menu above the surrounding
91screen. <a href="qprogressbar.html">QProgressBar</a> has a "sunken" look. <a href="qlabel.html">QLabel</a> has a flat look.
92The frames of widgets like these can be changed.
93<p> <pre>
94 <a href="qlabel.html">QLabel</a> label(...);
95 label.<a href="#setFrameStyle">setFrameStyle</a>( QFrame::<a href="#Shape-enum">Panel</a> | QFrame::<a href="#Shadow-enum">Raised</a> );
96 label.<a href="#setLineWidth">setLineWidth</a>( 2 );
97
98 <a href="qprogressbar.html">QProgressBar</a> pbar(...);
99 label.<a href="#setFrameStyle">setFrameStyle</a>( QFrame::<a href="#Shape-enum">NoFrame</a> );
100 </pre>
101
102<p> The QFrame class can also be used directly for creating simple
103frames without any contents, although usually you would use a
104<a href="qhbox.html">QHBox</a> or <a href="qvbox.html">QVBox</a> because they automatically lay out the widgets you
105put inside the frame.
106<p> A frame widget has four attributes: <a href="#frameStyle">frameStyle</a>(), <a href="#lineWidth">lineWidth</a>(),
107<a href="#midLineWidth">midLineWidth</a>(), and <a href="#margin">margin</a>().
108<p> The frame style is specified by a <a href="#Shape-enum">frame
109 shape</a> and a <a href="#Shadow-enum">shadow style</a>. The
110frame shapes are <a href="#Shape-enum">NoFrame</a>, <a href="#Shape-enum">Box</a>, <a href="#Shape-enum">Panel</a>, <a href="#Shape-enum">StyledPanel</a>, <a href="#Shape-enum">PopupPanel</a>, <a href="#Shape-enum">WinPanel</a>, <a href="#Shape-enum">ToolBarPanel</a>, <a href="#Shape-enum">MenuBarPanel</a>, <a href="#Shape-enum">HLine</a> and <a href="#Shape-enum">VLine</a>; the shadow styles are <a href="#Shadow-enum">Plain</a>, <a href="#Shadow-enum">Raised</a> and
111<a href="#Shadow-enum">Sunken</a>.
112<p> The line width is the width of the frame border.
113<p> The mid-line width specifies the width of an extra line in the
114middle of the frame, which uses a third color to obtain a special
1153D effect. Notice that a mid-line is only drawn for <a href="#Shape-enum">Box</a>, <a href="#Shape-enum">HLine</a> and <a href="#Shape-enum">VLine</a> frames that are raised or sunken.
116<p> The margin is the gap between the frame and the contents of the
117frame.
118<p> <a name="picture"></a>
119This table shows the most useful combinations of styles and widths
120(and some rather useless ones):
121<p> <center><img src="frames.png" alt="Table of frame styles"></center> <p>See also <a href="abstractwidgets.html">Abstract Widget Classes</a>.
122
123<hr><h2>Member Type Documentation</h2>
124<h3 class=fn><a name="Shadow-enum"></a>QFrame::Shadow</h3>
125
126<p> This enum type defines the 3D effect used for QFrame's frame.
127<ul>
128<li><tt>QFrame::Plain</tt> - the frame and contents appear level with the
129surroundings; draws using the palette foreground color (without
130any 3D effect)
131<li><tt>QFrame::Raised</tt> - the frame and contents appear raised; draws a 3D
132raised line using the light and dark colors of the current color
133group
134<li><tt>QFrame::Sunken</tt> - the frame and contents appear sunken; draws a 3D
135sunken line using the light and dark colors of the current color
136group
137<li><tt>QFrame::MShadow</tt> - internal; mask for the shadow
138</ul><p> Shadow interacts with QFrame::Shape, the <a href="#lineWidth">lineWidth</a>() and the
139<a href="#midLineWidth">midLineWidth</a>(). See the <a href="#picture">picture of the frames</a>
140in the class description.
141<p> <p>See also <a href="#Shape-enum">QFrame::Shape</a>, <a href="#lineWidth-prop">lineWidth</a>, and <a href="#midLineWidth-prop">midLineWidth</a>.
142
143<h3 class=fn><a name="Shape-enum"></a>QFrame::Shape</h3>
144
145<p> This enum type defines the shapes of a QFrame's frame.
146<ul>
147<li><tt>QFrame::NoFrame</tt> - QFrame draws nothing
148<li><tt>QFrame::Box</tt> - QFrame draws a box around its contents
149<li><tt>QFrame::Panel</tt> - QFrame draws a panel to make the contents appear
150raised or sunken
151<li><tt>QFrame::StyledPanel</tt> - draws a rectangular panel with a look that
152depends on the current GUI style. It can be raised or sunken.
153<li><tt>QFrame::HLine</tt> - QFrame draws a horizontal line that frames nothing
154(useful as separator)
155<li><tt>QFrame::VLine</tt> - QFrame draws a vertical line that frames nothing
156(useful as separator)
157<li><tt>QFrame::GroupBoxPanel</tt> - draws a rectangular panel
158<li><tt>QFrame::WinPanel</tt> - draws a rectangular panel that can be raised or
159sunken like those in Windows 95. Specifying this shape sets
160the line width to 2 pixels. WinPanel is provided for compatibility.
161For GUI style independence we recommend using StyledPanel instead.
162<li><tt>QFrame::ToolBarPanel</tt>
163<li><tt>QFrame::MenuBarPanel</tt>
164<li><tt>QFrame::PopupPanel</tt>
165<li><tt>QFrame::LineEditPanel</tt> - is used to draw a frame suitable for line edits. The
166look depends upon the current GUI style.
167<li><tt>QFrame::TabWidgetPanel</tt> - is used to draw a frame suitable for tab widgets. The
168look depends upon the current GUI style.
169<li><tt>QFrame::MShape</tt> - internal mask
170</ul><p> When it does not call <a href="qstyle.html">QStyle</a>, Shape interacts with QFrame::Shadow,
171the <a href="#lineWidth">lineWidth</a>() and the <a href="#midLineWidth">midLineWidth</a>() to create the total result.
172See the <a href="#picture">picture of the frames</a> in the class
173description.
174<p> <p>See also <a href="#Shadow-enum">QFrame::Shadow</a>, <a href="qwidget.html#style">QFrame::style</a>(), and <a href="qstyle.html#drawPrimitive">QStyle::drawPrimitive</a>().
175
176<hr><h2>Member Function Documentation</h2>
177<h3 class=fn><a name="QFrame"></a>QFrame::QFrame ( <a href="qwidget.html">QWidget</a>&nbsp;*&nbsp;parent = 0, const&nbsp;char&nbsp;*&nbsp;name = 0, WFlags&nbsp;f = 0 )
178</h3>
179Constructs a frame widget with frame style <a href="#Shape-enum">NoFrame</a> and a
1801-pixel frame width.
181<p> The <em>parent</em>, <em>name</em> and <em>f</em> arguments are passed to the
182<a href="qwidget.html">QWidget</a> constructor.
183
184<h3 class=fn><a href="qrect.html">QRect</a> <a name="contentsRect"></a>QFrame::contentsRect () const
185</h3><p>Returns the rectangle inside the frame.
186See the <a href="qframe.html#contentsRect-prop">"contentsRect"</a> property for details.
187<h3 class=fn>void <a name="drawContents"></a>QFrame::drawContents ( <a href="qpainter.html">QPainter</a>&nbsp;* )<tt> [virtual protected]</tt>
188</h3>
189Virtual function that draws the contents of the frame.
190<p> The <a href="qpainter.html">QPainter</a> is already open when you get it, and you must leave
191it open. Painter <a href="qpainter.html#setWorldMatrix">transformations</a> are switched off on entry. If you
192transform the painter, remember to take the frame into account and
193<a href="qpainter.html#resetXForm">reset transformation</a> before
194returning.
195<p> This function is reimplemented by subclasses that draw something
196inside the frame. It should only draw inside <a href="#contentsRect">contentsRect</a>(). The
197default function does nothing.
198<p> <p>See also <a href="#contentsRect-prop">contentsRect</a> and <a href="qpainter.html#setClipRect">QPainter::setClipRect</a>().
199
200<p>Reimplemented in <a href="qlabel.html#drawContents">QLabel</a>, <a href="qlcdnumber.html#drawContents">QLCDNumber</a>, <a href="qmenubar.html#drawContents">QMenuBar</a>, and <a href="qpopupmenu.html#drawContents">QPopupMenu</a>.
201<h3 class=fn>void <a name="drawFrame"></a>QFrame::drawFrame ( <a href="qpainter.html">QPainter</a>&nbsp;*&nbsp;p )<tt> [virtual protected]</tt>
202</h3>
203Draws the frame using the painter <em>p</em> and the current frame
204attributes and color group. The rectangle inside the frame is not
205affected.
206<p> This function is virtual, but in general you do not need to
207reimplement it. If you do, note that the <a href="qpainter.html">QPainter</a> is already open
208and must remain open.
209<p> <p>See also <a href="#frameRect-prop">frameRect</a>, <a href="#contentsRect-prop">contentsRect</a>, <a href="#drawContents">drawContents</a>(), <a href="#frameStyle">frameStyle</a>(), and <a href="qwidget.html#palette-prop">palette</a>.
210
211<h3 class=fn>void <a name="frameChanged"></a>QFrame::frameChanged ()<tt> [virtual protected]</tt>
212</h3>
213Virtual function that is called when the frame style, line width
214or mid-line width changes.
215<p> This function can be reimplemented by subclasses that need to know
216when the frame attributes change.
217<p> The default implementation calls <a href="qwidget.html#update">update</a>().
218
219<h3 class=fn><a href="qrect.html">QRect</a> <a name="frameRect"></a>QFrame::frameRect () const
220</h3><p>Returns the frame rectangle.
221See the <a href="qframe.html#frameRect-prop">"frameRect"</a> property for details.
222<h3 class=fn><a href="qframe.html#Shadow-enum">Shadow</a> <a name="frameShadow"></a>QFrame::frameShadow () const
223</h3><p>Returns the frame shadow value from the frame style.
224See the <a href="qframe.html#frameShadow-prop">"frameShadow"</a> property for details.
225<h3 class=fn><a href="qframe.html#Shape-enum">Shape</a> <a name="frameShape"></a>QFrame::frameShape () const
226</h3><p>Returns the frame shape value from the frame style.
227See the <a href="qframe.html#frameShape-prop">"frameShape"</a> property for details.
228<h3 class=fn>int <a name="frameStyle"></a>QFrame::frameStyle () const
229</h3>
230
231<p> Returns the frame style.
232<p> The default value is QFrame::NoFrame.
233<p> <p>See also <a href="#setFrameStyle">setFrameStyle</a>(), <a href="#frameShape-prop">frameShape</a>, and <a href="#frameShadow-prop">frameShadow</a>.
234
235<p>Example: <a href="scrollview-example.html#x622">scrollview/scrollview.cpp</a>.
236<h3 class=fn>int <a name="frameWidth"></a>QFrame::frameWidth () const
237</h3><p>Returns the width of the frame that is drawn.
238See the <a href="qframe.html#frameWidth-prop">"frameWidth"</a> property for details.
239<h3 class=fn>int <a name="lineWidth"></a>QFrame::lineWidth () const
240</h3><p>Returns the line width.
241See the <a href="qframe.html#lineWidth-prop">"lineWidth"</a> property for details.
242<h3 class=fn>int <a name="margin"></a>QFrame::margin () const
243</h3><p>Returns the width of the margin.
244See the <a href="qframe.html#margin-prop">"margin"</a> property for details.
245<h3 class=fn>int <a name="midLineWidth"></a>QFrame::midLineWidth () const
246</h3><p>Returns the width of the mid-line.
247See the <a href="qframe.html#midLineWidth-prop">"midLineWidth"</a> property for details.
248<h3 class=fn>void <a name="paintEvent"></a>QFrame::paintEvent ( <a href="qpaintevent.html">QPaintEvent</a>&nbsp;*&nbsp;event )<tt> [virtual protected]</tt>
249</h3>
250Processes the paint event <em>event</em>.
251<p> Paints the frame and the contents.
252<p> Opens the painter on the frame and calls <a href="#drawFrame">drawFrame</a>(), then
253<a href="#drawContents">drawContents</a>().
254
255<p>Examples: <a href="life-example.html#x1888">life/life.cpp</a> and <a href="qfd-example.html#x1995">qfd/fontdisplayer.cpp</a>.
256<p>Reimplemented from <a href="qwidget.html#paintEvent">QWidget</a>.
257<h3 class=fn>void <a name="resizeEvent"></a>QFrame::resizeEvent ( <a href="qresizeevent.html">QResizeEvent</a>&nbsp;*&nbsp;e )<tt> [virtual protected]</tt>
258</h3>
259Processes the resize event <em>e</em>.
260<p> Adjusts the frame rectangle for the resized widget. The frame
261rectangle is elastic, and the surrounding area is static.
262<p> The resulting frame rectangle may be null or invalid. You can use
263<a href="qwidget.html#setMinimumSize">setMinimumSize</a>() to avoid those possibilities.
264<p> Nothing is done if the frame rectangle is a <a href="qrect.html#isNull">null rectangle</a> already.
265
266<p>Example: <a href="life-example.html#x1889">life/life.cpp</a>.
267<p>Reimplemented from <a href="qwidget.html#resizeEvent">QWidget</a>.
268<h3 class=fn>void <a name="setFrameRect"></a>QFrame::setFrameRect ( const&nbsp;<a href="qrect.html">QRect</a>&nbsp;&amp; )<tt> [virtual]</tt>
269</h3><p>Sets the frame rectangle.
270See the <a href="qframe.html#frameRect-prop">"frameRect"</a> property for details.
271<h3 class=fn>void <a name="setFrameShadow"></a>QFrame::setFrameShadow ( <a href="qframe.html#Shadow-enum">Shadow</a> )
272</h3><p>Sets the frame shadow value from the frame style.
273See the <a href="qframe.html#frameShadow-prop">"frameShadow"</a> property for details.
274<h3 class=fn>void <a name="setFrameShape"></a>QFrame::setFrameShape ( <a href="qframe.html#Shape-enum">Shape</a> )
275</h3><p>Sets the frame shape value from the frame style.
276See the <a href="qframe.html#frameShape-prop">"frameShape"</a> property for details.
277<h3 class=fn>void <a name="setFrameStyle"></a>QFrame::setFrameStyle ( int&nbsp;style )<tt> [virtual]</tt>
278</h3>
279Sets the frame style to <em>style</em>.
280<p> The <em>style</em> is the bitwise OR between a frame shape and a frame
281shadow style. See the <a href="#picture">illustration</a> in the
282class documentation.
283<p> The frame shapes are given in <a href="#Shape-enum">QFrame::Shape</a> and the shadow
284styles in <a href="#Shadow-enum">QFrame::Shadow</a>.
285<p> If a mid-line width greater than 0 is specified, an additional
286line is drawn for <a href="#Shadow-enum">Raised</a> or <a href="#Shadow-enum">Sunken</a> <a href="#Shape-enum">Box</a>, <a href="#Shape-enum">HLine</a>, and <a href="#Shape-enum">VLine</a> frames. The mid-color of the current color group is used for
287drawing middle lines.
288<p> <p>See also <a href="#picture">Illustration</a>, <a href="#frameStyle">frameStyle</a>(), <a href="qwidget.html#colorGroup-prop">colorGroup</a>, and <a href="qcolorgroup.html">QColorGroup</a>.
289
290<p>Examples: <a href="cursor-example.html#x1114">cursor/cursor.cpp</a>, <a href="layout-example.html#x531">layout/layout.cpp</a>, <a href="listboxcombo-example.html#x1401">listboxcombo/listboxcombo.cpp</a>, <a href="rangecontrols-example.html#x1381">rangecontrols/rangecontrols.cpp</a>, <a href="scrollview-example.html#x626">scrollview/scrollview.cpp</a>, <a href="tabdialog-example.html#x52">tabdialog/tabdialog.cpp</a>, and <a href="tictac-example.html#x24">tictac/tictac.cpp</a>.
291<h3 class=fn>void <a name="setLineWidth"></a>QFrame::setLineWidth ( int )<tt> [virtual]</tt>
292</h3><p>Sets the line width.
293See the <a href="qframe.html#lineWidth-prop">"lineWidth"</a> property for details.
294<h3 class=fn>void <a name="setMargin"></a>QFrame::setMargin ( int )<tt> [virtual]</tt>
295</h3><p>Sets the width of the margin.
296See the <a href="qframe.html#margin-prop">"margin"</a> property for details.
297<h3 class=fn>void <a name="setMidLineWidth"></a>QFrame::setMidLineWidth ( int )<tt> [virtual]</tt>
298</h3><p>Sets the width of the mid-line.
299See the <a href="qframe.html#midLineWidth-prop">"midLineWidth"</a> property for details.
300<hr><h2>Property Documentation</h2>
301<h3 class=fn><a href="qrect.html">QRect</a> <a name="contentsRect-prop"></a>contentsRect</h3>
302<p>This property holds the rectangle inside the frame.
303<p>Get this property's value with <a href="#contentsRect">contentsRect</a>().
304<p><p>See also <a href="#frameRect-prop">frameRect</a> and <a href="#drawContents">drawContents</a>().
305
306<h3 class=fn><a href="qrect.html">QRect</a> <a name="frameRect-prop"></a>frameRect</h3>
307<p>This property holds the frame rectangle.
308<p>The frame rectangle is the rectangle the frame is drawn in. By
309default, this is the entire widget. Setting this property does <em>not</em> cause a widget update.
310<p> If this property is set to a null rectangle (for example
311<tt>QRect(0, 0, 0, 0)</tt>), then the frame rectangle is equivalent to
312the <a href="qwidget.html#rect">widget rectangle</a>.
313<p> <p>See also <a href="#contentsRect-prop">contentsRect</a>.
314
315<p>Set this property's value with <a href="#setFrameRect">setFrameRect</a>() and get this property's value with <a href="#frameRect">frameRect</a>().
316<h3 class=fn><a href="qframe.html#Shadow-enum">Shadow</a> <a name="frameShadow-prop"></a>frameShadow</h3>
317<p>This property holds the frame shadow value from the frame style.
318<p>Set this property's value with <a href="#setFrameShadow">setFrameShadow</a>() and get this property's value with <a href="#frameShadow">frameShadow</a>().
319<p><p>See also <a href="#frameStyle">frameStyle</a>() and <a href="#frameShape-prop">frameShape</a>.
320
321<h3 class=fn><a href="qframe.html#Shape-enum">Shape</a> <a name="frameShape-prop"></a>frameShape</h3>
322<p>This property holds the frame shape value from the frame style.
323<p>Set this property's value with <a href="#setFrameShape">setFrameShape</a>() and get this property's value with <a href="#frameShape">frameShape</a>().
324<p><p>See also <a href="#frameStyle">frameStyle</a>() and <a href="#frameShadow-prop">frameShadow</a>.
325
326<h3 class=fn>int <a name="frameWidth-prop"></a>frameWidth</h3>
327<p>This property holds the width of the frame that is drawn.
328<p>Note that the frame width depends on the <a href="#setFrameStyle">frame style</a>, not only the line
329width and the mid-line width. For example, the style <a href="#Shape-enum">NoFrame</a>
330always has a frame width of 0, whereas the style <a href="#Shape-enum">Panel</a> has a
331frame width equivalent to the line width. The frame width also
332includes the margin.
333<p> <p>See also <a href="#lineWidth-prop">lineWidth</a>, <a href="#midLineWidth-prop">midLineWidth</a>, <a href="#frameStyle">frameStyle</a>(), and <a href="#margin-prop">margin</a>.
334
335<p>Get this property's value with <a href="#frameWidth">frameWidth</a>().
336<h3 class=fn>int <a name="lineWidth-prop"></a>lineWidth</h3>
337<p>This property holds the line width.
338<p>Note that the <em>total</em> line width for <a href="#Shape-enum">HLine</a> and <a href="#Shape-enum">VLine</a> is
339given by <a href="#frameWidth">frameWidth</a>(), not <a href="#lineWidth">lineWidth</a>().
340<p> The default value is 1.
341<p> <p>See also <a href="#midLineWidth-prop">midLineWidth</a> and <a href="#frameWidth-prop">frameWidth</a>.
342
343<p>Set this property's value with <a href="#setLineWidth">setLineWidth</a>() and get this property's value with <a href="#lineWidth">lineWidth</a>().
344<h3 class=fn>int <a name="margin-prop"></a>margin</h3>
345<p>This property holds the width of the margin.
346<p>The margin is the distance between the innermost pixel of the
347frame and the outermost pixel of <a href="#contentsRect">contentsRect</a>(). It is included in
348<a href="#frameWidth">frameWidth</a>().
349<p> The margin is filled according to <a href="qwidget.html#backgroundMode">backgroundMode</a>().
350<p> The default value is 0.
351<p> <p>See also <a href="#margin-prop">margin</a>, <a href="#lineWidth-prop">lineWidth</a>, and <a href="#frameWidth-prop">frameWidth</a>.
352
353<p>Set this property's value with <a href="#setMargin">setMargin</a>() and get this property's value with <a href="#margin">margin</a>().
354<h3 class=fn>int <a name="midLineWidth-prop"></a>midLineWidth</h3>
355<p>This property holds the width of the mid-line.
356<p>The default value is 0.
357<p> <p>See also <a href="#lineWidth-prop">lineWidth</a> and <a href="#frameWidth-prop">frameWidth</a>.
358
359<p>Set this property's value with <a href="#setMidLineWidth">setMidLineWidth</a>() and get this property's value with <a href="#midLineWidth">midLineWidth</a>().
360<!-- eof -->
361<hr><p>
362This file is part of the <a href="index.html">Qt toolkit</a>.
363Copyright &copy; 1995-2007
364<a href="http://www.trolltech.com/">Trolltech</a>. All Rights Reserved.<p><address><hr><div align=center>
365<table width=100% cellspacing=0 border=0><tr>
366<td>Copyright &copy; 2007
367<a href="troll.html">Trolltech</a><td align=center><a href="trademarks.html">Trademarks</a>
368<td align=right><div align=right>Qt 3.3.8</div>
369</table></div></address></body>
370</html>
Note: See TracBrowser for help on using the repository browser.