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

« back to all changes in this revision

Viewing changes to doc/html/qdesktopwidget.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:
2
2
<!DOCTYPE html
3
3
    PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "DTD/xhtml1-strict.dtd">
4
4
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
5
 
<!-- /fasttmp/mkdist-qt-4.5.2-1245473805/qt-x11-opensource-src-4.5.2/doc/src/qdesktopwidget.qdoc -->
 
5
<!-- qdesktopwidget.qdoc -->
6
6
<head>
7
 
  <title>Qt 4.5: QDesktopWidget Class Reference</title>
 
7
  <title>Qt 4.6: QDesktopWidget Class Reference</title>
8
8
  <link href="classic.css" rel="stylesheet" type="text/css" />
9
9
</head>
10
10
<body>
 
11
<a name="//apple_ref/cpp/cl//QDesktopWidget" />
11
12
<table border="0" cellpadding="0" cellspacing="0" width="100%">
12
13
<tr>
13
 
<td align="left" valign="top" width="32"><a href="http://qtsoftware.com/products/qt"><img src="images/qt-logo.png" align="left" border="0" /></a></td>
14
 
<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="namespaces.html"><font color="#004faf">All&nbsp;Namespaces</font></a>&nbsp;&middot; <a href="classes.html"><font color="#004faf">All&nbsp;Classes</font></a>&nbsp;&middot; <a href="mainclasses.html"><font color="#004faf">Main&nbsp;Classes</font></a>&nbsp;&middot; <a href="groups.html"><font color="#004faf">Grouped&nbsp;Classes</font></a>&nbsp;&middot; <a href="modules.html"><font color="#004faf">Modules</font></a>&nbsp;&middot; <a href="functions.html"><font color="#004faf">Functions</font></a></td>
15
 
<td align="right" valign="top" width="230"></td></tr></table><h1 class="title">QDesktopWidget Class Reference<br /><span class="small-subtitle">[<a href="qtgui.html">QtGui</a> module]</span>
 
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">QDesktopWidget Class Reference<br /><span class="small-subtitle">[<a href="qtgui.html">QtGui</a> module]</span>
16
17
</h1>
17
18
<p>The QDesktopWidget class provides access to screen information on multi-head systems. <a href="#details">More...</a></p>
18
19
<pre> #include &lt;QDesktopWidget&gt;</pre><p>Inherits <a href="qwidget.html">QWidget</a>.</p>
19
20
<ul>
20
21
<li><a href="qdesktopwidget-members.html">List of all members, including inherited members</a></li>
21
 
</ul>
 
22
<li><a href="qdesktopwidget-obsolete.html">Obsolete members</a></li>
 
23
</ul>
 
24
<hr />
 
25
<a name="properties"></a>
 
26
<h2>Properties</h2>
 
27
<ul>
 
28
<li><div class="fn"><b><a href="qdesktopwidget.html#primaryScreen-prop">primaryScreen</a></b> : const int</div></li>
 
29
<li><div class="fn"><b><a href="qdesktopwidget.html#screenCount-prop">screenCount</a></b> : const int</div></li>
 
30
<li><div class="fn"><b><a href="qdesktopwidget.html#virtualDesktop-prop">virtualDesktop</a></b> : const bool</div></li>
 
31
</ul>
 
32
<ul>
 
33
<li><div bar="2" class="fn"></div>58 properties inherited from <a href="qwidget.html#properties">QWidget</a></li>
 
34
<li><div bar="2" class="fn"></div>1 property inherited from <a href="qobject.html#properties">QObject</a></li>
 
35
</ul>
 
36
<hr />
22
37
<a name="public-functions"></a>
23
 
<h3>Public Functions</h3>
24
 
<ul>
25
 
<li><div class="fn"></div>const QRect <b><a href="qdesktopwidget.html#availableGeometry">availableGeometry</a></b> ( int <i>screen</i> = -1 ) const</li>
26
 
<li><div class="fn"></div>const QRect <b><a href="qdesktopwidget.html#availableGeometry-2">availableGeometry</a></b> ( const QWidget * <i>widget</i> ) const</li>
27
 
<li><div class="fn"></div>const QRect <b><a href="qdesktopwidget.html#availableGeometry-3">availableGeometry</a></b> ( const QPoint &amp; <i>p</i> ) const</li>
28
 
<li><div class="fn"></div>bool <b><a href="qdesktopwidget.html#isVirtualDesktop">isVirtualDesktop</a></b> () const</li>
29
 
<li><div class="fn"></div>int <b><a href="qdesktopwidget.html#numScreens">numScreens</a></b> () const</li>
30
 
<li><div class="fn"></div>int <b><a href="qdesktopwidget.html#primaryScreen">primaryScreen</a></b> () const</li>
31
 
<li><div class="fn"></div>QWidget * <b><a href="qdesktopwidget.html#screen">screen</a></b> ( int <i>screen</i> = -1 )</li>
32
 
<li><div class="fn"></div>const QRect <b><a href="qdesktopwidget.html#screenGeometry">screenGeometry</a></b> ( int <i>screen</i> = -1 ) const</li>
33
 
<li><div class="fn"></div>const QRect <b><a href="qdesktopwidget.html#screenGeometry-2">screenGeometry</a></b> ( const QWidget * <i>widget</i> ) const</li>
34
 
<li><div class="fn"></div>const QRect <b><a href="qdesktopwidget.html#screenGeometry-3">screenGeometry</a></b> ( const QPoint &amp; <i>p</i> ) const</li>
35
 
<li><div class="fn"></div>int <b><a href="qdesktopwidget.html#screenNumber">screenNumber</a></b> ( const QWidget * <i>widget</i> = 0 ) const</li>
36
 
<li><div class="fn"></div>int <b><a href="qdesktopwidget.html#screenNumber-2">screenNumber</a></b> ( const QPoint &amp; <i>point</i> ) const</li>
37
 
</ul>
38
 
<ul>
39
 
<li><div class="fn"></div>207 public functions inherited from <a href="qwidget.html#public-functions">QWidget</a></li>
40
 
<li><div class="fn"></div>29 public functions inherited from <a href="qobject.html#public-functions">QObject</a></li>
41
 
<li><div class="fn"></div>12 public functions inherited from <a href="qpaintdevice.html#public-functions">QPaintDevice</a></li>
42
 
</ul>
 
38
<h2>Public Functions</h2>
 
39
<table class="alignedsummary" border="0" cellpadding="0" cellspacing="0" width="100%">
 
40
<tr><td class="memItemLeft" align="right" valign="top">const QRect </td><td class="memItemRight" valign="bottom"><b><a href="qdesktopwidget.html#availableGeometry">availableGeometry</a></b> ( int <i>screen</i> = -1 ) const</td></tr>
 
41
<tr><td class="memItemLeft" align="right" valign="top">const QRect </td><td class="memItemRight" valign="bottom"><b><a href="qdesktopwidget.html#availableGeometry-2">availableGeometry</a></b> ( const QWidget * <i>widget</i> ) const</td></tr>
 
42
<tr><td class="memItemLeft" align="right" valign="top">const QRect </td><td class="memItemRight" valign="bottom"><b><a href="qdesktopwidget.html#availableGeometry-3">availableGeometry</a></b> ( const QPoint &amp; <i>p</i> ) const</td></tr>
 
43
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><b><a href="qdesktopwidget.html#virtualDesktop-prop">isVirtualDesktop</a></b> () const</td></tr>
 
44
<tr><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><b><a href="qdesktopwidget.html#primaryScreen-prop">primaryScreen</a></b> () const</td></tr>
 
45
<tr><td class="memItemLeft" align="right" valign="top">QWidget * </td><td class="memItemRight" valign="bottom"><b><a href="qdesktopwidget.html#screen">screen</a></b> ( int <i>screen</i> = -1 )</td></tr>
 
46
<tr><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><b><a href="qdesktopwidget.html#screenCount-prop">screenCount</a></b> () const</td></tr>
 
47
<tr><td class="memItemLeft" align="right" valign="top">const QRect </td><td class="memItemRight" valign="bottom"><b><a href="qdesktopwidget.html#screenGeometry">screenGeometry</a></b> ( int <i>screen</i> = -1 ) const</td></tr>
 
48
<tr><td class="memItemLeft" align="right" valign="top">const QRect </td><td class="memItemRight" valign="bottom"><b><a href="qdesktopwidget.html#screenGeometry-2">screenGeometry</a></b> ( const QWidget * <i>widget</i> ) const</td></tr>
 
49
<tr><td class="memItemLeft" align="right" valign="top">const QRect </td><td class="memItemRight" valign="bottom"><b><a href="qdesktopwidget.html#screenGeometry-3">screenGeometry</a></b> ( const QPoint &amp; <i>p</i> ) const</td></tr>
 
50
<tr><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><b><a href="qdesktopwidget.html#screenNumber">screenNumber</a></b> ( const QWidget * <i>widget</i> = 0 ) const</td></tr>
 
51
<tr><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><b><a href="qdesktopwidget.html#screenNumber-2">screenNumber</a></b> ( const QPoint &amp; <i>point</i> ) const</td></tr>
 
52
</table>
 
53
<ul>
 
54
<li><div bar="2" class="fn"></div>215 public functions inherited from <a href="qwidget.html#public-functions">QWidget</a></li>
 
55
<li><div bar="2" class="fn"></div>29 public functions inherited from <a href="qobject.html#public-functions">QObject</a></li>
 
56
<li><div bar="2" class="fn"></div>12 public functions inherited from <a href="qpaintdevice.html#public-functions">QPaintDevice</a></li>
 
57
</ul>
 
58
<hr />
43
59
<a name="signals"></a>
44
 
<h3>Signals</h3>
 
60
<h2>Signals</h2>
 
61
<table class="alignedsummary" border="0" cellpadding="0" cellspacing="0" width="100%">
 
62
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><b><a href="qdesktopwidget.html#resized">resized</a></b> ( int <i>screen</i> )</td></tr>
 
63
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><b><a href="qdesktopwidget.html#screenCountChanged">screenCountChanged</a></b> ( int <i>newCount</i> )</td></tr>
 
64
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><b><a href="qdesktopwidget.html#workAreaResized">workAreaResized</a></b> ( int <i>screen</i> )</td></tr>
 
65
</table>
45
66
<ul>
46
 
<li><div class="fn"></div>void <b><a href="qdesktopwidget.html#resized">resized</a></b> ( int <i>screen</i> )</li>
47
 
<li><div class="fn"></div>void <b><a href="qdesktopwidget.html#workAreaResized">workAreaResized</a></b> ( int <i>screen</i> )</li>
 
67
<li><div bar="2" class="fn"></div>1 signal inherited from <a href="qwidget.html#signals">QWidget</a></li>
 
68
<li><div bar="2" class="fn"></div>1 signal inherited from <a href="qobject.html#signals">QObject</a></li>
48
69
</ul>
 
70
<hr />
 
71
<a name="reimplemented-protected-functions"></a>
 
72
<h2>Reimplemented Protected Functions</h2>
 
73
<table class="alignedsummary" border="0" cellpadding="0" cellspacing="0" width="100%">
 
74
<tr><td class="memItemLeft" align="right" valign="top">virtual void </td><td class="memItemRight" valign="bottom"><b><a href="qdesktopwidget.html#resizeEvent">resizeEvent</a></b> ( QResizeEvent * <i>event</i> )</td></tr>
 
75
</table>
49
76
<ul>
50
 
<li><div class="fn"></div>1 signal inherited from <a href="qwidget.html#signals">QWidget</a></li>
51
 
<li><div class="fn"></div>1 signal inherited from <a href="qobject.html#signals">QObject</a></li>
 
77
<li><div bar="2" class="fn"></div>37 protected functions inherited from <a href="qwidget.html#protected-functions">QWidget</a></li>
 
78
<li><div bar="2" class="fn"></div>7 protected functions inherited from <a href="qobject.html#protected-functions">QObject</a></li>
 
79
<li><div bar="2" class="fn"></div>1 protected function inherited from <a href="qpaintdevice.html#protected-functions">QPaintDevice</a></li>
52
80
</ul>
53
81
<h3>Additional Inherited Members</h3>
54
82
<ul>
55
 
<li><div class="fn"></div>57 properties inherited from <a href="qwidget.html#properties">QWidget</a></li>
56
 
<li><div class="fn"></div>1 property inherited from <a href="qobject.html#properties">QObject</a></li>
57
83
<li><div class="fn"></div>19 public slots inherited from <a href="qwidget.html#public-slots">QWidget</a></li>
58
84
<li><div class="fn"></div>1 public slot inherited from <a href="qobject.html#public-slots">QObject</a></li>
59
85
<li><div class="fn"></div>4 static public members inherited from <a href="qwidget.html#static-public-members">QWidget</a></li>
67
93
<hr />
68
94
<h2>Detailed Description</h2>
69
95
<p>The QDesktopWidget class provides access to screen information on multi-head systems.</p>
70
 
<p><a href="qapplication.html#desktop">QApplication::desktop</a>() function should be used to get an instance of the QDesktopWidget.</p>
71
 
<p>Systems with more than one graphics card and monitor can manage the physical screen space available either as multiple desktops, or as a large virtual desktop, which usually has the size of the bounding rectangle of all the screens (see <a href="qdesktopwidget.html#isVirtualDesktop">isVirtualDesktop</a>()). For an application, one of the available screens is the primary screen, i.e&#x2e; the screen where the main widget resides (see <a href="qdesktopwidget.html#primaryScreen">primaryScreen</a>()). All windows opened in the context of the application should be constrained to the boundaries of the primary screen; for example, it would be inconvenient if a dialog box popped up on a different screen, or split over two screens.</p>
72
 
<p>The QDesktopWidget provides information about the geometry of the available screens with <a href="qdesktopwidget.html#screenGeometry">screenGeometry</a>(). The number of screens available is returned by <a href="qdesktopwidget.html#numScreens">numScreens</a>(). The screen number that a particular point or widget is located in is returned by <a href="qdesktopwidget.html#screenNumber">screenNumber</a>().</p>
73
 
<p>Widgets provided by Qt use this class, for example, to place tooltips, menus and dialog boxes according to the parent or application widget.</p>
74
 
<p>Applications can use this class to save window positions, or to place child widgets on one screen.</p>
 
96
<p>Systems with more than one graphics card and monitor can manage the physical screen space available either as multiple desktops, or as a large virtual desktop.</p>
 
97
<p>This class provides information about the user's desktop, such as its total size, number of screens, the geometry of each screen, and whether they are configured as separate desktops or a single virtual desktop.</p>
 
98
<p>Widgets provided by Qt use this class to place tooltips, menus and dialog boxes on the correct screen for their parent or application widgets. Applications can use this class to obtain information that can be used to save window positions, or to place child widgets and dialogs on one particular screen.</p>
 
99
<a name="obtaining-a-desktop-widget"></a>
 
100
<h3>Obtaining a Desktop Widget</h3>
 
101
<p>The <a href="qapplication.html#desktop">QApplication::desktop</a>() function is used to get an instance of QDesktopWidget.</p>
 
102
<p>The widget's <a href="qdesktopwidget.html#screenGeometry">screenGeometry</a>() function provides information about the geometry of the available screens with. The number of screens available is returned by <a href="qdesktopwidget.html#screenCount-prop">screenCount</a>, and the <a href="qdesktopwidget.html#screenCountChanged">screenCountChanged</a>() signal is emitted when screens are added or removed. The screen number that a particular point or widget is located in is returned by <a href="qdesktopwidget.html#screenNumber">screenNumber</a>().</p>
 
103
<a name="screen-geometry"></a>
 
104
<h3>Screen Geometry</h3>
 
105
<p>To obtain the dimensions of a particular screen, call the <a href="qdesktopwidget.html#screenGeometry">screenGeometry</a>() function. On some desktop environments, not all of the screen is available for applications to use; for example, an application dock or menu bar may take up some space. Use the <a href="qdesktopwidget.html#availableGeometry">availableGeometry</a>() function to obtain the available area for applications.</p>
 
106
<p>QDesktopWidget also inherits the <a href="qwidget.html">QWidget</a> properties, <a href="qwidget.html#width-prop">width</a>() and <a href="qwidget.html#height-prop">height</a>(), which specify the size of the desktop. However, for desktops with multiple screens, the size of the desktop is the union of all the screen sizes, so <a href="qwidget.html#width-prop">width</a>() and <a href="qwidget.html#height-prop">height</a>() should <i>not</i> be used for computing the size of a widget to be placed on one of the screens.</p>
 
107
<p>On systems that are configured to use the available screens as a single, large virtual desktop, the <a href="qdesktopwidget.html#virtualDesktop-prop">virtualDesktop</a> property will be set to true. In this case, the widget's size is usually the size of the bounding rectangle of all the screens.</p>
 
108
<a name="use-of-the-primary-screen"></a>
 
109
<h3>Use of the Primary Screen</h3>
 
110
<p>For an application, the screen where the main widget resides is the primary screen. This is stored in the <a href="qdesktopwidget.html#primaryScreen-prop">primaryScreen</a> property. All windows opened in the context of the application should be constrained to the boundaries of the primary screen; for example, it would be inconvenient if a dialog box popped up on a different screen, or split over two screens.</p>
75
111
<p align="center"><img src="images/qdesktopwidget.png" alt="Managing Multiple Screens" /></p><p>In the illustration above, Application One's primary screen is screen 0, and App Two's primary screen is screen 1.</p>
76
 
<a name="multiple-screens-note"></a><p><b>Note:</b> QDesktopWidget inherits the <a href="qwidget.html">QWidget</a> properties, <a href="qwidget.html#width-prop">width</a>() and <a href="qwidget.html#height-prop">height</a>(), which specify the size of the desktop. However, for desktops with multiple screens, the size of the desktop is the union of all the screen sizes, so <a href="qwidget.html#width-prop">width</a>() and <a href="qwidget.html#height-prop">height</a>() should <i>not</i> be used for computing the size of a widget to be placed on one of the screens. The correct width and height values are obtained using <a href="qdesktopwidget.html#availableGeometry">availableGeometry</a>() or <a href="qdesktopwidget.html#screenGeometry">screenGeometry</a>() for a particular screen.</p>
77
112
<p>See also <a href="qapplication.html">QApplication</a>, <a href="qapplication.html#desktop">QApplication::desktop</a>(), and <a href="qx11info.html#appRootWindow">QX11Info::appRootWindow</a>().</p>
78
113
<hr />
 
114
<h2>Property Documentation</h2>
 
115
<a name="//apple_ref/cpp/instm/QDesktopWidget/primaryScreen" />
 
116
<h3 class="fn"><a name="primaryScreen-prop"></a>primaryScreen : const int</h3>
 
117
<p>This property holds the index of the screen that is configured to be the primary screen on the system.</p>
 
118
<p><b>Access functions:</b></p>
 
119
<table class="alignedsummary" border="0" cellpadding="0" cellspacing="0" width="100%">
 
120
<tr><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><b>primaryScreen</b> () const</td></tr>
 
121
</table>
 
122
<a name="//apple_ref/cpp/instm/QDesktopWidget/screenCount" />
 
123
<a name="//apple_ref/cpp/instm/QDesktopWidget/screenCountChanged" />
 
124
<h3 class="fn"><a name="screenCount-prop"></a>screenCount : const int</h3>
 
125
<p>This property holds the number of screens currently available on the system.</p>
 
126
<p>This property was introduced in Qt 4.6.</p>
 
127
<p><b>Access functions:</b></p>
 
128
<table class="alignedsummary" border="0" cellpadding="0" cellspacing="0" width="100%">
 
129
<tr><td class="memItemLeft" align="right" valign="top">int </td><td class="memItemRight" valign="bottom"><b>screenCount</b> () const</td></tr>
 
130
</table>
 
131
<p><b>Notifier signal:</b></p>
 
132
<table class="alignedsummary" border="0" cellpadding="0" cellspacing="0" width="100%">
 
133
<tr><td class="memItemLeft" align="right" valign="top">void </td><td class="memItemRight" valign="bottom"><b><a href="qdesktopwidget.html#screenCountChanged">screenCountChanged</a></b> ( int <i>newCount</i> )</td></tr>
 
134
</table>
 
135
<p>See also <a href="qdesktopwidget.html#screenCountChanged">screenCountChanged</a>().</p>
 
136
<a name="//apple_ref/cpp/instm/QDesktopWidget/isVirtualDesktop" />
 
137
<h3 class="fn"><a name="virtualDesktop-prop"></a>virtualDesktop : const bool</h3>
 
138
<p>This property holds if the system manages the available screens in a virtual desktop.</p>
 
139
<p>For virtual desktops, <a href="qdesktopwidget.html#screen">screen</a>() will always return the same widget. The size of the virtual desktop is the size of this desktop widget.</p>
 
140
<p><b>Access functions:</b></p>
 
141
<table class="alignedsummary" border="0" cellpadding="0" cellspacing="0" width="100%">
 
142
<tr><td class="memItemLeft" align="right" valign="top">bool </td><td class="memItemRight" valign="bottom"><b>isVirtualDesktop</b> () const</td></tr>
 
143
</table>
 
144
<hr />
79
145
<h2>Member Function Documentation</h2>
 
146
<a name="//apple_ref/cpp/instm/QDesktopWidget/availableGeometry" />
80
147
<h3 class="fn"><a name="availableGeometry"></a>const <a href="qrect.html">QRect</a> QDesktopWidget::availableGeometry ( int <i>screen</i> = -1 ) const</h3>
81
148
<p>Returns the available geometry of the screen with index <i>screen</i>. What is available will be subrect of <a href="qdesktopwidget.html#screenGeometry">screenGeometry</a>() based on what the platform decides is available (for example excludes the dock and menu bar on Mac OS X, or the task bar on Windows). The default screen is used if <i>screen</i> is -1.</p>
82
149
<p>See also <a href="qdesktopwidget.html#screenNumber">screenNumber</a>() and <a href="qdesktopwidget.html#screenGeometry">screenGeometry</a>().</p>
88
155
<p>This is an overloaded function.</p>
89
156
<p>Returns the available geometry of the screen which contains <i>p</i>.</p>
90
157
<p>See also <a href="qdesktopwidget.html#screenGeometry">screenGeometry</a>().</p>
91
 
<h3 class="fn"><a name="isVirtualDesktop"></a>bool QDesktopWidget::isVirtualDesktop () const</h3>
92
 
<p>Returns true if the system manages the available screens in a virtual desktop; otherwise returns false.</p>
93
 
<p>For virtual desktops, <a href="qdesktopwidget.html#screen">screen</a>() will always return the same widget. The size of the virtual desktop is the size of this desktop widget.</p>
94
 
<h3 class="fn"><a name="numScreens"></a>int QDesktopWidget::numScreens () const</h3>
95
 
<p>Returns the number of available screens.</p>
96
 
<p>See also <a href="qdesktopwidget.html#primaryScreen">primaryScreen</a>().</p>
97
 
<h3 class="fn"><a name="primaryScreen"></a>int QDesktopWidget::primaryScreen () const</h3>
98
 
<p>Returns the index of the primary screen.</p>
99
 
<p>See also <a href="qdesktopwidget.html#numScreens">numScreens</a>().</p>
 
158
<a name="//apple_ref/cpp/instm/QDesktopWidget/resizeEvent" />
 
159
<h3 class="fn"><a name="resizeEvent"></a>void QDesktopWidget::resizeEvent ( <a href="qresizeevent.html">QResizeEvent</a> * <i>event</i> )&nbsp;&nbsp;<tt> [virtual protected]</tt></h3>
 
160
<p>Reimplemented from <a href="qwidget.html#resizeEvent">QWidget::resizeEvent</a>().</p>
 
161
<a name="//apple_ref/cpp/instm/QDesktopWidget/resized" />
100
162
<h3 class="fn"><a name="resized"></a>void QDesktopWidget::resized ( int <i>screen</i> )&nbsp;&nbsp;<tt> [signal]</tt></h3>
101
163
<p>This signal is emitted when the size of <i>screen</i> changes.</p>
 
164
<a name="//apple_ref/cpp/instm/QDesktopWidget/screen" />
102
165
<h3 class="fn"><a name="screen"></a><a href="qwidget.html">QWidget</a> * QDesktopWidget::screen ( int <i>screen</i> = -1 )</h3>
103
166
<p>Returns a widget that represents the screen with index <i>screen</i> (a value of -1 means the default screen).</p>
104
167
<p>If the system uses a virtual desktop, the returned widget will have the geometry of the entire virtual desktop; i.e&#x2e;, bounding every <i>screen</i>.</p>
105
 
<p>See also <a href="qdesktopwidget.html#primaryScreen">primaryScreen</a>(), <a href="qdesktopwidget.html#numScreens">numScreens</a>(), and <a href="qdesktopwidget.html#isVirtualDesktop">isVirtualDesktop</a>().</p>
 
168
<p>See also <a href="qdesktopwidget.html#primaryScreen-prop">primaryScreen</a>, <a href="qdesktopwidget.html#screenCount-prop">screenCount</a>, and <a href="qdesktopwidget.html#virtualDesktop-prop">virtualDesktop</a>.</p>
 
169
<a name="//apple_ref/cpp/instm/QDesktopWidget/screenCountChanged" />
 
170
<h3 class="fn"><a name="screenCountChanged"></a>void QDesktopWidget::screenCountChanged ( int <i>newCount</i> )&nbsp;&nbsp;<tt> [signal]</tt></h3>
 
171
<p>This signal is emitted when the number of screens changes to <i>newCount</i>.</p>
 
172
<p>This function was introduced in Qt 4.6.</p>
 
173
<p>See also <a href="qdesktopwidget.html#screenCount-prop">screenCount</a>.</p>
 
174
<a name="//apple_ref/cpp/instm/QDesktopWidget/screenGeometry" />
106
175
<h3 class="fn"><a name="screenGeometry"></a>const <a href="qrect.html">QRect</a> QDesktopWidget::screenGeometry ( int <i>screen</i> = -1 ) const</h3>
107
176
<p>Returns the geometry of the screen with index <i>screen</i>. The default screen is used if <i>screen</i> is -1.</p>
108
177
<p>See also <a href="qdesktopwidget.html#screenNumber">screenNumber</a>().</p>
112
181
<h3 class="fn"><a name="screenGeometry-3"></a>const <a href="qrect.html">QRect</a> QDesktopWidget::screenGeometry ( const <a href="qpoint.html">QPoint</a> &amp; <i>p</i> ) const</h3>
113
182
<p>This is an overloaded function.</p>
114
183
<p>Returns the geometry of the screen which contains <i>p</i>.</p>
 
184
<a name="//apple_ref/cpp/instm/QDesktopWidget/screenNumber" />
115
185
<h3 class="fn"><a name="screenNumber"></a>int QDesktopWidget::screenNumber ( const <a href="qwidget.html">QWidget</a> * <i>widget</i> = 0 ) const</h3>
116
186
<p>Returns the index of the screen that contains the largest part of <i>widget</i>, or -1 if the widget not on a screen.</p>
117
 
<p>See also <a href="qdesktopwidget.html#primaryScreen">primaryScreen</a>().</p>
 
187
<p>See also <a href="qdesktopwidget.html#primaryScreen-prop">primaryScreen</a>.</p>
118
188
<h3 class="fn"><a name="screenNumber-2"></a>int QDesktopWidget::screenNumber ( const <a href="qpoint.html">QPoint</a> &amp; <i>point</i> ) const</h3>
119
189
<p>This is an overloaded function.</p>
120
190
<p>Returns the index of the screen that contains the <i>point</i>, or the screen which is the shortest distance from the <i>point</i>.</p>
121
 
<p>See also <a href="qdesktopwidget.html#primaryScreen">primaryScreen</a>().</p>
 
191
<p>See also <a href="qdesktopwidget.html#primaryScreen-prop">primaryScreen</a>.</p>
 
192
<a name="//apple_ref/cpp/instm/QDesktopWidget/workAreaResized" />
122
193
<h3 class="fn"><a name="workAreaResized"></a>void QDesktopWidget::workAreaResized ( int <i>screen</i> )&nbsp;&nbsp;<tt> [signal]</tt></h3>
123
194
<p>This signal is emitted when the work area available on <i>screen</i> changes.</p>
124
195
<p /><address><hr /><div align="center">
125
196
<table width="100%" cellspacing="0" border="0"><tr class="address">
126
 
<td width="30%" align="left">Copyright &copy; 2009 Nokia Corporation and/or its subsidiary(-ies)</td>
127
 
<td width="40%" align="center"><a href="trademarks.html">Trademarks</a></td>
128
 
<td width="30%" align="right"><div align="right">Qt 4.5.2</div></td>
129
 
</tr></table></div></address></body>
 
197
<td width="40%" align="left">Copyright &copy; 2009 Nokia Corporation and/or its subsidiary(-ies)</td>
 
198
<td width="20%" align="center"><a href="trademarks.html">Trademarks</a></td>
 
199
<td width="40%" align="right"><div align="right">Qt 4.6.0</div></td>
 
200
<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>
130
201
</html>