source: trunk/doc/html/qpaintdevice.html@ 208

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

reference documentation added

File size: 24.6 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/kernel/qpaintdevice_x11.cpp:47 -->
3<html>
4<head>
5<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
6<title>QPaintDevice 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>QPaintDevice Class Reference</h1>
33
34<p>The QPaintDevice class is the base class of objects that
35can be painted.
36<a href="#details">More...</a>
37<p><tt>#include &lt;<a href="qpaintdevice-h.html">qpaintdevice.h</a>&gt;</tt>
38<p>Inherited by <a href="qwidget.html">QWidget</a>, <a href="qpixmap.html">QPixmap</a>, <a href="qpicture.html">QPicture</a>, and <a href="qprinter.html">QPrinter</a>.
39<p><a href="qpaintdevice-members.html">List of all member functions.</a>
40<h2>Public Members</h2>
41<ul>
42<li class=fn>virtual <a href="#~QPaintDevice"><b>~QPaintDevice</b></a> ()</li>
43<li class=fn>bool <a href="#isExtDev"><b>isExtDev</b></a> () const</li>
44<li class=fn>bool <a href="#paintingActive"><b>paintingActive</b></a> () const</li>
45<li class=fn>virtual HDC <b>handle</b> () const</li>
46<li class=fn>virtual Qt::HANDLE <a href="#handle"><b>handle</b></a> () const</li>
47<li class=fn>Display * <a href="#x11Display"><b>x11Display</b></a> () const</li>
48<li class=fn>int <a href="#x11Screen"><b>x11Screen</b></a> () const</li>
49<li class=fn>int <a href="#x11Depth"><b>x11Depth</b></a> () const</li>
50<li class=fn>int <a href="#x11Cells"><b>x11Cells</b></a> () const</li>
51<li class=fn>Qt::HANDLE <a href="#x11Colormap"><b>x11Colormap</b></a> () const</li>
52<li class=fn>bool <a href="#x11DefaultColormap"><b>x11DefaultColormap</b></a> () const</li>
53<li class=fn>void * <a href="#x11Visual"><b>x11Visual</b></a> () const</li>
54<li class=fn>bool <a href="#x11DefaultVisual"><b>x11DefaultVisual</b></a> () const</li>
55</ul>
56<h2>Static Public Members</h2>
57<ul>
58<li class=fn>Display * <a href="#x11AppDisplay"><b>x11AppDisplay</b></a> ()</li>
59<li class=fn>int <a href="#x11AppScreen"><b>x11AppScreen</b></a> ()</li>
60<li class=fn>int <a href="#x11AppDpiX-2"><b>x11AppDpiX</b></a> ()</li>
61<li class=fn>int <a href="#x11AppDpiY-2"><b>x11AppDpiY</b></a> ()</li>
62<li class=fn>void <a href="#x11SetAppDpiX-2"><b>x11SetAppDpiX</b></a> ( int&nbsp;dpi )</li>
63<li class=fn>void <a href="#x11SetAppDpiY-2"><b>x11SetAppDpiY</b></a> ( int&nbsp;dpi )</li>
64<li class=fn>int <a href="#x11AppDepth-2"><b>x11AppDepth</b></a> ()</li>
65<li class=fn>int <a href="#x11AppCells"><b>x11AppCells</b></a> ()</li>
66<li class=fn>Qt::HANDLE <a href="#x11AppRootWindow"><b>x11AppRootWindow</b></a> ()</li>
67<li class=fn>Qt::HANDLE <a href="#x11AppColormap"><b>x11AppColormap</b></a> ()</li>
68<li class=fn>bool <a href="#x11AppDefaultColormap"><b>x11AppDefaultColormap</b></a> ()</li>
69<li class=fn>void * <a href="#x11AppVisual"><b>x11AppVisual</b></a> ()</li>
70<li class=fn>bool <a href="#x11AppDefaultVisual"><b>x11AppDefaultVisual</b></a> ()</li>
71<li class=fn>int <a href="#x11AppDepth"><b>x11AppDepth</b></a> ( int&nbsp;screen )</li>
72<li class=fn>int <a href="#x11AppCells-2"><b>x11AppCells</b></a> ( int&nbsp;screen )</li>
73<li class=fn>Qt::HANDLE <a href="#x11AppRootWindow-2"><b>x11AppRootWindow</b></a> ( int&nbsp;screen )</li>
74<li class=fn>Qt::HANDLE <a href="#x11AppColormap-2"><b>x11AppColormap</b></a> ( int&nbsp;screen )</li>
75<li class=fn>void * <a href="#x11AppVisual-2"><b>x11AppVisual</b></a> ( int&nbsp;screen )</li>
76<li class=fn>bool <a href="#x11AppDefaultColormap-2"><b>x11AppDefaultColormap</b></a> ( int&nbsp;screen )</li>
77<li class=fn>bool <a href="#x11AppDefaultVisual-2"><b>x11AppDefaultVisual</b></a> ( int&nbsp;screen )</li>
78<li class=fn>int <a href="#x11AppDpiX"><b>x11AppDpiX</b></a> ( int&nbsp;screen )</li>
79<li class=fn>int <a href="#x11AppDpiY"><b>x11AppDpiY</b></a> ( int&nbsp;screen )</li>
80<li class=fn>void <a href="#x11SetAppDpiX"><b>x11SetAppDpiX</b></a> ( int&nbsp;dpi, int&nbsp;screen )</li>
81<li class=fn>void <a href="#x11SetAppDpiY"><b>x11SetAppDpiY</b></a> ( int&nbsp;dpi, int&nbsp;screen )</li>
82</ul>
83<h2>Protected Members</h2>
84<ul>
85<li class=fn><a href="#QPaintDevice"><b>QPaintDevice</b></a> ( uint&nbsp;devflags )</li>
86<li class=fn>virtual bool <a href="#cmd"><b>cmd</b></a> ( int, QPainter *, QPDevCmdParam * )</li>
87</ul>
88<h2>Related Functions</h2>
89<ul>
90<li class=fn>void <a href="#bitBlt"><b>bitBlt</b></a> ( QPaintDevice&nbsp;*&nbsp;dst, int&nbsp;dx, int&nbsp;dy, const&nbsp;QPaintDevice&nbsp;*&nbsp;src, int&nbsp;sx, int&nbsp;sy, int&nbsp;sw, int&nbsp;sh, Qt::RasterOp&nbsp;rop, bool&nbsp;ignoreMask )</li>
91<li class=fn>void <a href="#bitBlt-2"><b>bitBlt</b></a> ( QPaintDevice&nbsp;*&nbsp;dst, const&nbsp;QPoint&nbsp;&amp;&nbsp;dp, const&nbsp;QPaintDevice&nbsp;*&nbsp;src, const&nbsp;QRect&nbsp;&amp;&nbsp;sr, RasterOp&nbsp;rop )</li>
92</ul>
93<hr><a name="details"></a><h2>Detailed Description</h2>
94
95
96The QPaintDevice class is the base class of objects that
97can be painted.
98<p>
99
100<p> A paint device is an abstraction of a two-dimensional space that
101can be drawn using a <a href="qpainter.html">QPainter</a>. The drawing capabilities are
102implemented by the subclasses <a href="qwidget.html">QWidget</a>, <a href="qpixmap.html">QPixmap</a>, <a href="qpicture.html">QPicture</a> and
103<a href="qprinter.html">QPrinter</a>.
104<p> The default coordinate system of a paint device has its origin
105located at the top-left position. X increases to the right and Y
106increases downward. The unit is one pixel. There are several ways
107to set up a user-defined coordinate system using the painter, for
108example, using <a href="qpainter.html#setWorldMatrix">QPainter::setWorldMatrix</a>().
109<p> Example (draw on a paint device):
110<pre>
111 void MyWidget::paintEvent( <a href="qpaintevent.html">QPaintEvent</a> * )
112 {
113 <a href="qpainter.html">QPainter</a> p; // our painter
114 p.<a href="qpainter.html#begin">begin</a>( this ); // start painting the widget
115 p.<a href="qpainter.html#setPen">setPen</a>( red ); // red outline
116 p.<a href="qpainter.html#setBrush">setBrush</a>( yellow ); // yellow fill
117 p.<a href="qpainter.html#drawEllipse">drawEllipse</a>( 10, 20, 100,100 ); // 100x100 ellipse at position (10, 20)
118 p.<a href="qpainter.html#end">end</a>(); // painting done
119 }
120 </pre>
121
122<p> The bit block transfer is an extremely useful operation for
123copying pixels from one paint device to another (or to itself). It
124is implemented as the global function <a href="#bitBlt">bitBlt</a>().
125<p> Example (scroll widget contents 10 pixels to the right):
126<pre>
127 <a href="#bitBlt">bitBlt</a>( myWidget, 10, 0, myWidget );
128 </pre>
129
130<p> <b>Warning:</b> Qt requires that a <a href="qapplication.html">QApplication</a> object exists before
131any paint devices can be created. Paint devices access window
132system resources, and these resources are not initialized before
133an application object is created.
134<p>See also <a href="graphics.html">Graphics Classes</a> and <a href="images.html">Image Processing Classes</a>.
135
136<hr><h2>Member Function Documentation</h2>
137<h3 class=fn><a name="QPaintDevice"></a>QPaintDevice::QPaintDevice ( uint&nbsp;devflags )<tt> [protected]</tt>
138</h3>
139Constructs a paint device with internal flags <em>devflags</em>. This
140constructor can be invoked only from QPaintDevice subclasses.
141
142<h3 class=fn><a name="~QPaintDevice"></a>QPaintDevice::~QPaintDevice ()<tt> [virtual]</tt>
143</h3>
144Destroys the paint device and frees window system resources.
145
146<h3 class=fn>bool <a name="cmd"></a>QPaintDevice::cmd ( int, <a href="qpainter.html">QPainter</a>&nbsp;*, QPDevCmdParam * )<tt> [virtual protected]</tt>
147</h3>
148Internal virtual function that interprets drawing commands from
149the painter.
150<p> Implemented by subclasses that have no direct support for drawing
151graphics (external paint devices, for example, <a href="qpicture.html">QPicture</a>).
152
153<h3 class=fn>Qt::HANDLE <a name="handle"></a>QPaintDevice::handle () const<tt> [virtual]</tt>
154</h3>
155Returns the window system handle of the paint device, for
156low-level access. Using this function is not portable.
157<p> The HANDLE type varies with platform; see <a href="qpaintdevice-h.html">qpaintdevice.h</a> and
158<a href="qwindowdefs-h.html">qwindowdefs.h</a> for details.
159<p> <p>See also <a href="#x11Display">x11Display</a>().
160
161<h3 class=fn>bool <a name="isExtDev"></a>QPaintDevice::isExtDev () const
162</h3>
163
164<p> Returns TRUE if the device is an external paint device; otherwise
165returns FALSE.
166<p> External paint devices cannot be <a href="#bitBlt">bitBlt</a>()'ed from. <a href="qpicture.html">QPicture</a> and
167<a href="qprinter.html">QPrinter</a> are external paint devices.
168
169<h3 class=fn>bool <a name="paintingActive"></a>QPaintDevice::paintingActive () const
170</h3>
171
172<p> Returns TRUE if the device is being painted, i.e. someone has
173called <a href="qpainter.html#begin">QPainter::begin</a>() but not yet called <a href="qpainter.html#end">QPainter::end</a>() for
174this device; otherwise returns FALSE.
175<p> <p>See also <a href="qpainter.html#isActive">QPainter::isActive</a>().
176
177<h3 class=fn>int <a name="x11AppCells"></a>QPaintDevice::x11AppCells ()<tt> [static]</tt>
178</h3>
179
180<p> Returns the number of entries in the colormap for the default
181screen of the X display global to the application (X11
182only). Using this function is not portable.
183<p> <p>See also <a href="#x11Colormap">x11Colormap</a>().
184
185<h3 class=fn>int <a name="x11AppCells-2"></a>QPaintDevice::x11AppCells ( int&nbsp;screen )<tt> [static]</tt>
186</h3>
187This is an overloaded member function, provided for convenience. It behaves essentially like the above function.
188<p>
189<p> Returns the number of entries in the colormap for screen <em>screen</em>
190of the X display global to the application (X11 only). Using this
191function is not portable.
192<p> <p>See also <a href="#x11Colormap">x11Colormap</a>().
193
194<h3 class=fn>Qt::HANDLE <a name="x11AppColormap"></a>QPaintDevice::x11AppColormap ()<tt> [static]</tt>
195</h3>
196
197<p> Returns the colormap for the default screen of the X display
198global to the application (X11 only). Using this function is not
199portable.
200<p> <p>See also <a href="#x11Cells">x11Cells</a>().
201
202<h3 class=fn>Qt::HANDLE <a name="x11AppColormap-2"></a>QPaintDevice::x11AppColormap ( int&nbsp;screen )<tt> [static]</tt>
203</h3>
204This is an overloaded member function, provided for convenience. It behaves essentially like the above function.
205<p>
206<p> Returns the colormap for screen <em>screen</em> of the X display global
207to the application (X11 only). Using this function is not
208portable.
209<p> <p>See also <a href="#x11Cells">x11Cells</a>().
210
211<h3 class=fn>bool <a name="x11AppDefaultColormap"></a>QPaintDevice::x11AppDefaultColormap ()<tt> [static]</tt>
212</h3>
213
214<p> Returns the default colormap for the default screen of the X
215display global to the application (X11 only). Using this function
216is not portable.
217<p> <p>See also <a href="#x11Cells">x11Cells</a>().
218
219<h3 class=fn>bool <a name="x11AppDefaultColormap-2"></a>QPaintDevice::x11AppDefaultColormap ( int&nbsp;screen )<tt> [static]</tt>
220</h3>
221This is an overloaded member function, provided for convenience. It behaves essentially like the above function.
222<p>
223<p> Returns the default colormap for screen <em>screen</em> of the X display
224global to the application (X11 only). Using this function is not
225portable.
226<p> <p>See also <a href="#x11Cells">x11Cells</a>().
227
228<h3 class=fn>bool <a name="x11AppDefaultVisual"></a>QPaintDevice::x11AppDefaultVisual ()<tt> [static]</tt>
229</h3>
230
231<p> Returns TRUE if the Visual used is the default for the default
232screen of the X display global to the application (X11 only);
233otherwise returns FALSE. Using this function is not portable.
234
235<h3 class=fn>bool <a name="x11AppDefaultVisual-2"></a>QPaintDevice::x11AppDefaultVisual ( int&nbsp;screen )<tt> [static]</tt>
236</h3>
237This is an overloaded member function, provided for convenience. It behaves essentially like the above function.
238<p>
239<p> Returns TRUE if the Visual used is the default for screen
240<em>screen</em> of the X display global to the application (X11 only);
241otherwise returns FALSE. Using this function is not portable.
242
243<h3 class=fn>int <a name="x11AppDepth"></a>QPaintDevice::x11AppDepth ( int&nbsp;screen )<tt> [static]</tt>
244</h3>
245
246<p> Returns the depth for screen <em>screen</em> of the X display global to
247the application (X11 only). Using this function is not portable.
248<p> <p>See also <a href="qpixmap.html#defaultDepth">QPixmap::defaultDepth</a>().
249
250<h3 class=fn>int <a name="x11AppDepth-2"></a>QPaintDevice::x11AppDepth ()<tt> [static]</tt>
251</h3>
252This is an overloaded member function, provided for convenience. It behaves essentially like the above function.
253<p>
254<p> Returns the depth for the default screen of the X display global
255to the application (X11 only). Using this function is not
256portable.
257<p> <p>See also <a href="qpixmap.html#defaultDepth">QPixmap::defaultDepth</a>().
258
259<h3 class=fn>Display * <a name="x11AppDisplay"></a>QPaintDevice::x11AppDisplay ()<tt> [static]</tt>
260</h3>
261
262<p> Returns a pointer to the X display global to the application (X11
263only). Using this function is not portable.
264<p> <p>See also <a href="#handle">handle</a>().
265
266<h3 class=fn>int <a name="x11AppDpiX"></a>QPaintDevice::x11AppDpiX ( int&nbsp;screen )<tt> [static]</tt>
267</h3>
268Returns the horizontal DPI of the X display (X11 only) for screen
269<em>screen</em>. Using this function is not portable. See
270<a href="qpaintdevicemetrics.html">QPaintDeviceMetrics</a> for portable access to related information.
271Using this function is not portable.
272<p> <p>See also <a href="#x11AppDpiY">x11AppDpiY</a>(), <a href="#x11SetAppDpiX">x11SetAppDpiX</a>(), and <a href="qpaintdevicemetrics.html#logicalDpiX">QPaintDeviceMetrics::logicalDpiX</a>().
273
274<h3 class=fn>int <a name="x11AppDpiX-2"></a>QPaintDevice::x11AppDpiX ()<tt> [static]</tt>
275</h3>
276This is an overloaded member function, provided for convenience. It behaves essentially like the above function.
277<p> Returns the horizontal DPI of the X display (X11 only) for the
278default screen. Using this function is not portable. See
279<a href="qpaintdevicemetrics.html">QPaintDeviceMetrics</a> for portable access to related information.
280Using this function is not portable.
281
282<h3 class=fn>int <a name="x11AppDpiY"></a>QPaintDevice::x11AppDpiY ( int&nbsp;screen )<tt> [static]</tt>
283</h3>
284Returns the vertical DPI of the X11 display (X11 only) for screen
285<em>screen</em>. Using this function is not portable. See
286<a href="qpaintdevicemetrics.html">QPaintDeviceMetrics</a> for portable access to related information.
287Using this function is not portable.
288<p> <p>See also <a href="#x11AppDpiX">x11AppDpiX</a>(), <a href="#x11SetAppDpiY">x11SetAppDpiY</a>(), and <a href="qpaintdevicemetrics.html#logicalDpiY">QPaintDeviceMetrics::logicalDpiY</a>().
289
290<h3 class=fn>int <a name="x11AppDpiY-2"></a>QPaintDevice::x11AppDpiY ()<tt> [static]</tt>
291</h3>
292This is an overloaded member function, provided for convenience. It behaves essentially like the above function.
293<p> Returns the vertical DPI of the X11 display (X11 only) for the
294default screen. Using this function is not portable. See
295<a href="qpaintdevicemetrics.html">QPaintDeviceMetrics</a> for portable access to related information.
296Using this function is not portable.
297<p> <p>See also <a href="#x11AppDpiX">x11AppDpiX</a>(), <a href="#x11SetAppDpiY">x11SetAppDpiY</a>(), and <a href="qpaintdevicemetrics.html#logicalDpiY">QPaintDeviceMetrics::logicalDpiY</a>().
298
299<h3 class=fn>Qt::HANDLE <a name="x11AppRootWindow"></a>QPaintDevice::x11AppRootWindow ()<tt> [static]</tt>
300</h3>
301
302<p> Returns the root window for the default screen of the X display
303global to the applicatoin (X11 only). Using this function is not
304portable.
305
306<h3 class=fn>Qt::HANDLE <a name="x11AppRootWindow-2"></a>QPaintDevice::x11AppRootWindow ( int&nbsp;screen )<tt> [static]</tt>
307</h3>
308This is an overloaded member function, provided for convenience. It behaves essentially like the above function.
309<p>
310<p> Returns the root window for screen <em>screen</em> of the X display
311global to the applicatoin (X11 only). Using this function is not
312portable.
313
314<h3 class=fn>int <a name="x11AppScreen"></a>QPaintDevice::x11AppScreen ()<tt> [static]</tt>
315</h3>
316
317<p> Returns the screen number on the X display global to the
318application (X11 only). Using this function is not portable.
319
320<h3 class=fn>void * <a name="x11AppVisual"></a>QPaintDevice::x11AppVisual ()<tt> [static]</tt>
321</h3>
322
323<p> Returns the Visual for the default screen of the X display global
324to the application (X11 only). Using this function is not
325portable.
326
327<h3 class=fn>void * <a name="x11AppVisual-2"></a>QPaintDevice::x11AppVisual ( int&nbsp;screen )<tt> [static]</tt>
328</h3>
329This is an overloaded member function, provided for convenience. It behaves essentially like the above function.
330<p>
331<p> Returns the Visual for screen <em>screen</em> of the X display global to
332the application (X11 only). Using this function is not portable.
333
334<h3 class=fn>int <a name="x11Cells"></a>QPaintDevice::x11Cells () const
335</h3>
336
337<p> Returns the number of entries in the colormap of the X display for
338the paint device (X11 only). Using this function is not portable.
339<p> <p>See also <a href="#x11Colormap">x11Colormap</a>().
340
341<h3 class=fn>Qt::HANDLE <a name="x11Colormap"></a>QPaintDevice::x11Colormap () const
342</h3>
343
344<p> Returns the colormap of the X display for the paint device (X11
345only). Using this function is not portable.
346<p> <p>See also <a href="#x11Cells">x11Cells</a>().
347
348<h3 class=fn>bool <a name="x11DefaultColormap"></a>QPaintDevice::x11DefaultColormap () const
349</h3>
350
351<p> Returns the default colormap of the X display for the paint device
352(X11 only). Using this function is not portable.
353<p> <p>See also <a href="#x11Cells">x11Cells</a>().
354
355<h3 class=fn>bool <a name="x11DefaultVisual"></a>QPaintDevice::x11DefaultVisual () const
356</h3>
357
358<p> Returns the default Visual of the X display for the paint device
359(X11 only). Using this function is not portable.
360
361<h3 class=fn>int <a name="x11Depth"></a>QPaintDevice::x11Depth () const
362</h3>
363
364<p> Returns the depth of the X display for the paint device (X11
365only). Using this function is not portable.
366<p> <p>See also <a href="qpixmap.html#defaultDepth">QPixmap::defaultDepth</a>().
367
368<h3 class=fn>Display * <a name="x11Display"></a>QPaintDevice::x11Display () const
369</h3>
370
371<p> Returns a pointer to the X display for the paint device (X11
372only). Using this function is not portable.
373<p> <p>See also <a href="#handle">handle</a>().
374
375<h3 class=fn>int <a name="x11Screen"></a>QPaintDevice::x11Screen () const
376</h3>
377
378<p> Returns the screen number on the X display for the paint device
379(X11 only). Using this function is not portable.
380
381<h3 class=fn>void <a name="x11SetAppDpiX"></a>QPaintDevice::x11SetAppDpiX ( int&nbsp;dpi, int&nbsp;screen )<tt> [static]</tt>
382</h3>
383Sets the value returned by <a href="#x11AppDpiX">x11AppDpiX</a>() to <em>dpi</em> for screen
384<em>screen</em>. The default is determined by the display configuration.
385Changing this value will alter the scaling of fonts and many other
386metrics and is not recommended. Using this function is not
387portable.
388<p> <p>See also <a href="#x11SetAppDpiY">x11SetAppDpiY</a>().
389
390<h3 class=fn>void <a name="x11SetAppDpiX-2"></a>QPaintDevice::x11SetAppDpiX ( int&nbsp;dpi )<tt> [static]</tt>
391</h3>
392This is an overloaded member function, provided for convenience. It behaves essentially like the above function.
393<p> Sets the value returned by <a href="#x11AppDpiX">x11AppDpiX</a>() to <em>dpi</em> for the default
394screen. The default is determined by the display configuration.
395Changing this value will alter the scaling of fonts and many other
396metrics and is not recommended. Using this function is not
397portable.
398<p>
399<h3 class=fn>void <a name="x11SetAppDpiY"></a>QPaintDevice::x11SetAppDpiY ( int&nbsp;dpi, int&nbsp;screen )<tt> [static]</tt>
400</h3>
401Sets the value returned by <a href="#x11AppDpiY">x11AppDpiY</a>() to <em>dpi</em> for screen
402<em>screen</em>. The default is determined by the display configuration.
403Changing this value will alter the scaling of fonts and many other
404metrics and is not recommended. Using this function is not
405portable.
406<p> <p>See also <a href="#x11SetAppDpiX">x11SetAppDpiX</a>().
407
408<h3 class=fn>void <a name="x11SetAppDpiY-2"></a>QPaintDevice::x11SetAppDpiY ( int&nbsp;dpi )<tt> [static]</tt>
409</h3>
410This is an overloaded member function, provided for convenience. It behaves essentially like the above function.
411<p> Sets the value returned by <a href="#x11AppDpiY">x11AppDpiY</a>() to <em>dpi</em> for the default
412screen. The default is determined by the display configuration.
413Changing this value will alter the scaling of fonts and many other
414metrics and is not recommended. Using this function is not
415portable.
416
417<h3 class=fn>void * <a name="x11Visual"></a>QPaintDevice::x11Visual () const
418</h3>
419
420<p> Returns the Visual of the X display for the paint device (X11
421only). Using this function is not portable.
422
423<hr><h2>Related Functions</h2>
424<h3 class=fn>void <a name="bitBlt"></a>bitBlt ( <a href="qpaintdevice.html">QPaintDevice</a>&nbsp;*&nbsp;dst, int&nbsp;dx, int&nbsp;dy, const&nbsp;<a href="qpaintdevice.html">QPaintDevice</a>&nbsp;*&nbsp;src, int&nbsp;sx, int&nbsp;sy, int&nbsp;sw, int&nbsp;sh, <a href="qt.html#RasterOp-enum">Qt::RasterOp</a>&nbsp;rop, bool&nbsp;ignoreMask )
425</h3>
426
427<p> Copies a block of pixels from <em>src</em> to <em>dst</em>, perhaps merging
428each pixel according to the <a href="qt.html#RasterOp-enum">raster operation</a>
429<em>rop</em>. <em>sx</em>, <em>sy</em>
430is the top-left pixel in <em>src</em> (0, 0) by default, <em>dx</em>, <em>dy</em> is
431the top-left position in <em>dst</em> and <em>sw</em>, <em>sh</em> is the size of
432the copied block (all of <em>src</em> by default).
433<p> The most common values for <em>rop</em> are CopyROP and XorROP; the <a href="qt.html#RasterOp-enum">Qt::RasterOp</a> documentation defines all the possible values.
434<p> If <em>ignoreMask</em> is FALSE (the default) and <em>src</em> is a
435masked <a href="qpixmap.html">QPixmap</a>, the entire blit is masked by <em>src</em>->mask().
436<p> If <em>src</em>, <em>dst</em>, <em>sw</em> or <em>sh</em> is 0, <a href="#bitBlt">bitBlt</a>() does nothing. If
437<em>sw</em> or <em>sh</em> is negative bitBlt() copies starting at <em>sx</em> (and
438respectively, <em>sy</em>) and ending at the right end (respectively,
439bottom) of <em>src</em>.
440<p> <em>src</em> must be a <a href="qwidget.html">QWidget</a> or QPixmap. You cannot blit from a
441<a href="qprinter.html">QPrinter</a>, for example. bitBlt() does nothing if you attempt to
442blit from an unsupported device.
443<p> bitBlt() does nothing if <em>src</em> has a greater depth than <em>dst</em>.
444If you need to for example, draw a 24-bit pixmap on an 8-bit
445widget, you must use drawPixmap().
446
447<h3 class=fn>void <a name="bitBlt-2"></a>bitBlt ( <a href="qpaintdevice.html">QPaintDevice</a>&nbsp;*&nbsp;dst, const&nbsp;<a href="qpoint.html">QPoint</a>&nbsp;&amp;&nbsp;dp, const&nbsp;<a href="qpaintdevice.html">QPaintDevice</a>&nbsp;*&nbsp;src, const&nbsp;<a href="qrect.html">QRect</a>&nbsp;&amp;&nbsp;sr, RasterOp&nbsp;rop )
448</h3>
449
450<p> This is an overloaded member function, provided for convenience. It behaves essentially like the above function.
451<p> Overloaded <a href="#bitBlt">bitBlt</a>() with the destination point <em>dp</em> and source
452rectangle <em>sr</em>.
453
454<!-- eof -->
455<hr><p>
456This file is part of the <a href="index.html">Qt toolkit</a>.
457Copyright &copy; 1995-2007
458<a href="http://www.trolltech.com/">Trolltech</a>. All Rights Reserved.<p><address><hr><div align=center>
459<table width=100% cellspacing=0 border=0><tr>
460<td>Copyright &copy; 2007
461<a href="troll.html">Trolltech</a><td align=center><a href="trademarks.html">Trademarks</a>
462<td align=right><div align=right>Qt 3.3.8</div>
463</table></div></address></body>
464</html>
Note: See TracBrowser for help on using the repository browser.