~oif-team/ubuntu/natty/qt4-x11/xi2.1

« back to all changes in this revision

Viewing changes to doc/html/qdecorationdefault.html

  • Committer: Bazaar Package Importer
  • Author(s): Alessandro Ghersi
  • Date: 2009-11-02 18:30:08 UTC
  • mfrom: (1.2.2 upstream)
  • mto: (15.2.5 experimental)
  • mto: This revision was merged to the branch mainline in revision 88.
  • Revision ID: james.westby@ubuntu.com-20091102183008-b6a4gcs128mvfb3m
Tags: upstream-4.6.0~beta1
ImportĀ upstreamĀ versionĀ 4.6.0~beta1

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<?xml version="1.0" encoding="iso-8859-1"?>
 
2
<!DOCTYPE html
 
3
    PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "DTD/xhtml1-strict.dtd">
 
4
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
 
5
<!-- qdecorationdefault_qws.cpp -->
 
6
<head>
 
7
  <title>Qt 4.6: QDecorationDefault Class Reference</title>
 
8
  <link href="classic.css" rel="stylesheet" type="text/css" />
 
9
</head>
 
10
<body>
 
11
<a name="//apple_ref/cpp/cl//QDecorationDefault" />
 
12
<table border="0" cellpadding="0" cellspacing="0" width="100%">
 
13
<tr>
 
14
<td align="left" valign="top" width="32"><a href="http://qt.nokia.com/"><img src="images/qt-logo.png" align="left" border="0" /></a></td>
 
15
<td width="1">&nbsp;&nbsp;</td><td class="postheader" valign="center"><a href="index.html"><font color="#004faf">Home</font></a>&nbsp;&middot; <a href="classes.html"><font color="#004faf">All&nbsp;Classes</font></a>&nbsp;&middot; <a href="functions.html"><font color="#004faf">All&nbsp;Functions</font></a>&nbsp;&middot; <a href="overviews.html"><font color="#004faf">Overviews</font></a></td><td class="searchBar" align="right" valign="center"><form action="http://www.google.com/cse" id="cse-search-box"><div><input type="hidden" name="cx" value="000136343326384750312:dhbxnqlakyu" /><input type="hidden" name="ie" value="UTF-8" /><input type="text" name="q" size="31" /><input type="submit" name="sa" value="Search" /></div></form></td>
 
16
</tr></table><h1 class="title">QDecorationDefault Class Reference<br /><span class="small-subtitle">[<a href="qtgui.html">QtGui</a> module]</span>
 
17
</h1>
 
18
<p>The QDecorationDefault class is a base class providing default window decorations. <a href="#details">More...</a></p>
 
19
<pre> #include &lt;QDecorationDefault&gt;</pre><p>Inherits <a href="qdecoration.html">QDecoration</a>.</p>
 
20
<p>This class was introduced in Qt 4.4.</p>
 
21
<ul>
 
22
<li><a href="qdecorationdefault-members.html">List of all members, including inherited members</a></li>
 
23
</ul>
 
24
<hr />
 
25
<a name="public-functions"></a>
 
26
<h2>Public Functions</h2>
 
27
<table class="alignedsummary" border="0" cellpadding="0" cellspacing="0" width="100%">
 
28
<tr><td class="memItemLeft" align="right" valign="top"></td><td class="memItemRight" valign="bottom"><b><a href="qdecorationdefault.html#QDecorationDefault">QDecorationDefault</a></b> ()</td></tr>
 
29
<tr><td class="memItemLeft" align="right" valign="top">virtual </td><td class="memItemRight" valign="bottom"><b><a href="qdecorationdefault.html#dtor.QDecorationDefault">~QDecorationDefault</a></b> ()</td></tr>
 
30
</table>
 
31
<hr />
 
32
<a name="reimplemented-public-functions"></a>
 
33
<h2>Reimplemented Public Functions</h2>
 
34
<table class="alignedsummary" border="0" cellpadding="0" cellspacing="0" width="100%">
 
35
<tr><td class="memItemLeft" align="right" valign="top">virtual bool </td><td class="memItemRight" valign="bottom"><b><a href="qdecorationdefault.html#paint">paint</a></b> ( QPainter * <i>painter</i>, const QWidget * <i>widget</i>, int <i>decorationRegion</i> = All, DecorationState <i>state</i> = Normal )</td></tr>
 
36
<tr><td class="memItemLeft" align="right" valign="top">virtual QRegion </td><td class="memItemRight" valign="bottom"><b><a href="qdecorationdefault.html#region">region</a></b> ( const QWidget * <i>widget</i>, const QRect &amp; <i>rect</i>, int <i>decorationRegion</i> = All )</td></tr>
 
37
</table>
 
38
<ul>
 
39
<li><div bar="2" class="fn"></div>8 public functions inherited from <a href="qdecoration.html#public-functions">QDecoration</a></li>
 
40
</ul>
 
41
<hr />
 
42
<a name="protected-functions"></a>
 
43
<h2>Protected Functions</h2>
 
44
<table class="alignedsummary" border="0" cellpadding="0" cellspacing="0" width="100%">
 
45
<tr><td class="memItemLeft" align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><b><a href="qdecorationdefault.html#paintButton">paintButton</a></b> ( QPainter * <i>painter</i>, const QWidget * <i>widget</i>, int <i>buttonRegion</i>, DecorationState <i>state</i>, const QPalette &amp; <i>palette</i> )</td></tr>
 
46
<tr><td class="memItemLeft" align="right" valign="top">virtual QPixmap </td><td class="memItemRight" valign="bottom"><b><a href="qdecorationdefault.html#pixmapFor">pixmapFor</a></b> ( const QWidget * <i>widget</i>, int <i>decorationRegion</i>, int &amp; <i>xoff</i>, int &amp; <i>yoff</i> )</td></tr>
 
47
<tr><td class="memItemLeft" align="right" valign="top">virtual int </td><td class="memItemRight" valign="bottom"><b><a href="qdecorationdefault.html#titleBarHeight">titleBarHeight</a></b> ( const QWidget * <i>widget</i> )</td></tr>
 
48
<tr><td class="memItemLeft" align="right" valign="top">virtual const char ** </td><td class="memItemRight" valign="bottom"><b><a href="qdecorationdefault.html#xpmForRegion">xpmForRegion</a></b> ( int <i>region</i> )</td></tr>
 
49
</table>
 
50
<h3>Additional Inherited Members</h3>
 
51
<ul>
 
52
<li><div class="fn"></div>2 static public members inherited from <a href="qdecoration.html#static-public-members">QDecoration</a></li>
 
53
</ul>
 
54
<a name="details"></a>
 
55
<hr />
 
56
<h2>Detailed Description</h2>
 
57
<p>The QDecorationDefault class is a base class providing default window decorations.</p>
 
58
<p>See the documentation for class <a href="qdecoration.html">QDecoration</a> for a detailed description. This subclass of <a href="qdecoration.html">QDecoration</a> provides standard icons for the decoration regions.</p>
 
59
<p>Note that this class is non-portable and only available in <a href="qt-embedded-linux.html">Qt for Embedded Linux</a>.</p>
 
60
<hr />
 
61
<h2>Member Function Documentation</h2>
 
62
<a name="//apple_ref/cpp/instm/QDecorationDefault/QDecorationDefault" />
 
63
<h3 class="fn"><a name="QDecorationDefault"></a>QDecorationDefault::QDecorationDefault ()</h3>
 
64
<p>Default constructor.</p>
 
65
<a name="//apple_ref/cpp/instm/QDecorationDefault/~QDecorationDefault" />
 
66
<h3 class="fn"><a name="dtor.QDecorationDefault"></a>QDecorationDefault::~QDecorationDefault ()&nbsp;&nbsp;<tt> [virtual]</tt></h3>
 
67
<p>The constructor deletes the static pixmaps.</p>
 
68
<a name="//apple_ref/cpp/instm/QDecorationDefault/paint" />
 
69
<h3 class="fn"><a name="paint"></a>bool QDecorationDefault::paint ( <a href="qpainter.html">QPainter</a> * <i>painter</i>, const <a href="qwidget.html">QWidget</a> * <i>widget</i>, int <i>decorationRegion</i> = All, <a href="qdecoration.html#DecorationState-enum">DecorationState</a> <i>state</i> = Normal )&nbsp;&nbsp;<tt> [virtual]</tt></h3>
 
70
<p>Reimplemented from <a href="qdecoration.html#paint">QDecoration::paint</a>().</p>
 
71
<p>Paints the border and title decoration for the top-level <i>widget</i> using the <i>painter</i> provided and the decoration <i>state</i>. The value of <i>decorationRegion</i> is a combination of the bitmask values of enum <a href="qdecoration.html#DecorationRegion-enum">DecorationRegion</a>.</p>
 
72
<p>Note that Qt for Embedded Linux expects this function to return true if any of the widget's decorations are repainted; otherwise it returns false.</p>
 
73
<a name="//apple_ref/cpp/instm/QDecorationDefault/paintButton" />
 
74
<h3 class="fn"><a name="paintButton"></a>void QDecorationDefault::paintButton ( <a href="qpainter.html">QPainter</a> * <i>painter</i>, const <a href="qwidget.html">QWidget</a> * <i>widget</i>, int <i>buttonRegion</i>, <a href="qdecoration.html#DecorationState-enum">DecorationState</a> <i>state</i>, const <a href="qpalette.html">QPalette</a> &amp; <i>palette</i> )&nbsp;&nbsp;<tt> [virtual protected]</tt></h3>
 
75
<p>Paints a region of the top-level <i>widget</i>. The region is painted in the specified decoration <i>state</i> using the <i>painter</i> and <i>palette</i> provided. The region to be painted is specified by <i>buttonRegion</i>, which is a combination of the bitmask values of <a href="qdecoration.html#DecorationRegion-enum">DecorationRegion</a>. If the value of <i>buttonRegion</i> is one of <i>Help</i>, <i>Menu</i>, <i>Close</i>, <i>Minimize</i>, <i>Maximize</i>, and <i>Normalize</i>, the button pixmap for that region is painted.</p>
 
76
<p>See also <a href="qdecorationdefault.html#pixmapFor">pixmapFor</a>().</p>
 
77
<a name="//apple_ref/cpp/instm/QDecorationDefault/pixmapFor" />
 
78
<h3 class="fn"><a name="pixmapFor"></a><a href="qpixmap.html">QPixmap</a> QDecorationDefault::pixmapFor ( const <a href="qwidget.html">QWidget</a> * <i>widget</i>, int <i>decorationRegion</i>, int &amp; <i>xoff</i>, int &amp; <i>yoff</i> )&nbsp;&nbsp;<tt> [virtual protected]</tt></h3>
 
79
<p>Returns a pointer to the <a href="qpixmap.html">QPixmap</a> for the widget specified by <i>widget</i> and <i>decorationRegion</i>. The returned <a href="qpixmap.html">QPixmap</a> is constructed from the default X pixmap obtained from <a href="qdecorationdefault.html#xpmForRegion">xpmForRegion</a>().</p>
 
80
<p><i>xoff</i> and <i>yoff</i> specify the offset for the pixmap.</p>
 
81
<p>The value of <i>decorationRegion</i> must be one of a subset of the values of enum <a href="qdecoration.html#DecorationRegion-enum">DecorationRegion</a>. The supported values are <i>Help</i>, <i>Menu</i>, <i>Close</i>, <i>Minimize</i>, <i>Maximize</i>, and <i>Normalize</i>. Other values of <i>decorationRegion</i> return 0.</p>
 
82
<p>See also <a href="qdecoration.html#DecorationRegion-enum">QDecoration::DecorationRegion</a>.</p>
 
83
<a name="//apple_ref/cpp/instm/QDecorationDefault/region" />
 
84
<h3 class="fn"><a name="region"></a><a href="qregion.html">QRegion</a> QDecorationDefault::region ( const <a href="qwidget.html">QWidget</a> * <i>widget</i>, const <a href="qrect.html">QRect</a> &amp; <i>rect</i>, int <i>decorationRegion</i> = All )&nbsp;&nbsp;<tt> [virtual]</tt></h3>
 
85
<p>Reimplemented from <a href="qdecoration.html#region">QDecoration::region</a>().</p>
 
86
<p>Returns the region specified by <i>decorationRegion</i> for the top-level <i>widget</i>. <i>rect</i> specifies the rectangle the decoration wraps. The value of <i>decorationRegion</i> is a combination of the bitmask values of enum <a href="qdecoration.html#DecorationRegion-enum">DecorationRegion</a>.</p>
 
87
<a name="//apple_ref/cpp/instm/QDecorationDefault/titleBarHeight" />
 
88
<h3 class="fn"><a name="titleBarHeight"></a>int QDecorationDefault::titleBarHeight ( const <a href="qwidget.html">QWidget</a> * <i>widget</i> )&nbsp;&nbsp;<tt> [virtual protected]</tt></h3>
 
89
<p>Returns the title bar height in pixels for the given <i>widget</i>. It is the greater of 20, or the sum of the application font's line spacing value plus a border width fudge factor.</p>
 
90
<a name="//apple_ref/cpp/instm/QDecorationDefault/xpmForRegion" />
 
91
<h3 class="fn"><a name="xpmForRegion"></a>const char ** QDecorationDefault::xpmForRegion ( int <i>region</i> )&nbsp;&nbsp;<tt> [virtual protected]</tt></h3>
 
92
<p>Returns a pointer to the X pixmap for the icon specified by <i>region</i>. An X pixmap is an ASCII-text-based image. The value of <i>region</i> must be one of a subset of the values of enum <a href="qdecoration.html#DecorationRegion-enum">DecorationRegion</a>. The supported values are <i>Help</i>, <i>Menu</i>, <i>Close</i>, <i>Minimize</i>, <i>Maximize</i>, and <i>Normalize</i>. Other values of <i>region</i> cause zero to be returned.</p>
 
93
<p>See also <a href="qdecoration.html#DecorationRegion-enum">QDecoration::DecorationRegion</a>.</p>
 
94
<p /><address><hr /><div align="center">
 
95
<table width="100%" cellspacing="0" border="0"><tr class="address">
 
96
<td width="40%" align="left">Copyright &copy; 2009 Nokia Corporation and/or its subsidiary(-ies)</td>
 
97
<td width="20%" align="center"><a href="trademarks.html">Trademarks</a></td>
 
98
<td width="40%" align="right"><div align="right">Qt 4.6.0</div></td>
 
99
<script type="text/javascript" src="http://www.google.com/jsapi"></script><script type="text/javascript">google.load("elements", "1", {packages: "transliteration"});</script><script type="text/javascript" src="http://www.google.com/coop/cse/t13n?form=cse-search-box&t13n_langs=en"></script><script type="text/javascript" src="http://www.google.com/coop/cse/brand?form=cse-search-box&lang=en"></script></tr></table></div></address></body>
 
100
</html>