~ubuntu-branches/ubuntu/precise/python-qt4/precise-proposed

« back to all changes in this revision

Viewing changes to doc/html/qpaintdevice.html

  • Committer: Bazaar Package Importer
  • Author(s): Jonathan Riddell, Jonathan Riddell
  • Date: 2010-11-08 16:13:33 UTC
  • mfrom: (1.5.5 upstream)
  • Revision ID: james.westby@ubuntu.com-20101108161333-0nec4wu0nz3wpf9r
Tags: 4.8.1-0ubuntu1
[ Jonathan Riddell ]
* New upstream release
* Build against python-sip-dev 4.11.2
* Remove kubuntu_02_fix-scpk-and-flag-issue.diff merged upstream
* Install __init__.py into /usr/lib/python3.2/dist-packages/PyQt4,
  fixes Python 3 support
* Add QtDeclarative to python-qt4
* Add kubuntu_03_uiparser.diff from upstream

Show diffs side-by-side

added added

removed removed

Lines of Context:
6
6
td.postheader { font-family: sans-serif }
7
7
tr.address { font-family: sans-serif }
8
8
body { background: #ffffff; color: black; }
9
 
</style></head><body><table border="0" cellpadding="0" cellspacing="0" width="100%"><tr /><td align="left" valign="top" width="32"><img align="left" border="0" height="32" src="images/rb-logo.png" width="32" /></td><td width="1">&#160;&#160;</td><td class="postheader" valign="center"><a href="../pyqt4ref.html"><font color="#004faf">Home</font></a>&#160;&#183; <a href="classes.html"><font color="#004faf">All Classes</font></a>&#160;&#183; <a href="modules.html"><font color="#004faf">Modules</font></a></td></table><h1 align="center">QPaintDevice Class Reference<br /><sup><sup>[<a href="qtgui.html">QtGui</a> module]</sup></sup></h1><p>The QPaintDevice class is the base class of objects that can be painted. <a href="#details">More...</a></p>
10
 
<p>Inherited by <a href="qglframebufferobject.html">QGLFramebufferObject</a>, <a href="qglpixelbuffer.html">QGLPixelBuffer</a>, <a href="qimage.html">QImage</a>, <a href="qpicture.html">QPicture</a>, <a href="qpixmap.html">QPixmap</a>, <a href="qprinter.html">QPrinter</a>, <a href="qsvggenerator.html">QSvgGenerator</a> and <a href="qwidget.html">QWidget</a>.</p><h3>Types</h3><ul><li><div class="fn" />enum <b><a href="qpaintdevice.html#PaintDeviceMetric-enum">PaintDeviceMetric</a></b> { PdmWidth, PdmHeight, PdmWidthMM, PdmHeightMM, ..., PdmPhysicalDpiY }</li></ul><h3>Methods</h3><ul><li><div class="fn" /><b><a href="qpaintdevice.html#QPaintDevice">__init__</a></b> (<i>self</i>)</li><li><div class="fn" />int <b><a href="qpaintdevice.html#colorCount">colorCount</a></b> (<i>self</i>)</li><li><div class="fn" />int <b><a href="qpaintdevice.html#depth">depth</a></b> (<i>self</i>)</li><li><div class="fn" />int <b><a href="qpaintdevice.html#height">height</a></b> (<i>self</i>)</li><li><div class="fn" />int <b><a href="qpaintdevice.html#heightMM">heightMM</a></b> (<i>self</i>)</li><li><div class="fn" />int <b><a href="qpaintdevice.html#logicalDpiX">logicalDpiX</a></b> (<i>self</i>)</li><li><div class="fn" />int <b><a href="qpaintdevice.html#logicalDpiY">logicalDpiY</a></b> (<i>self</i>)</li><li><div class="fn" />int <b><a href="qpaintdevice.html#metric">metric</a></b> (<i>self</i>, PaintDeviceMetric)</li><li><div class="fn" />int <b><a href="qpaintdevice.html#numColors">numColors</a></b> (<i>self</i>)</li><li><div class="fn" />QPaintEngine <b><a href="qpaintdevice.html#paintEngine">paintEngine</a></b> (<i>self</i>)</li><li><div class="fn" />bool <b><a href="qpaintdevice.html#paintingActive">paintingActive</a></b> (<i>self</i>)</li><li><div class="fn" />int <b><a href="qpaintdevice.html#physicalDpiX">physicalDpiX</a></b> (<i>self</i>)</li><li><div class="fn" />int <b><a href="qpaintdevice.html#physicalDpiY">physicalDpiY</a></b> (<i>self</i>)</li><li><div class="fn" />int <b><a href="qpaintdevice.html#width">width</a></b> (<i>self</i>)</li><li><div class="fn" />int <b><a href="qpaintdevice.html#widthMM">widthMM</a></b> (<i>self</i>)</li></ul><a name="details" /><hr /><h2>Detailed Description</h2><p>The QPaintDevice class is the base class of objects that can be painted.</p>
11
 
<p>A paint device is an abstraction of a two-dimensional space that can be drawn using a <a href="qpainter.html">QPainter</a>. Its default coordinate system has its origin located at the top-left position. X increases to the right and Y increases downwards. The unit is one pixel.</p>
12
 
<p>The drawing capabilities of QPaintDevice are currently implemented by the <a href="qwidget.html">QWidget</a>, <a href="qimage.html">QImage</a>, <a href="qpixmap.html">QPixmap</a>, <a href="qglpixelbuffer.html">QGLPixelBuffer</a>, <a href="qpicture.html">QPicture</a>, and <a href="qprinter.html">QPrinter</a> subclasses.</p>
13
 
<p>To implement support for a new backend, you must derive from QPaintDevice and reimplement the virtual <a href="qpaintdevice.html#paintEngine">paintEngine</a>() function to tell <a href="qpainter.html">QPainter</a> which paint engine should be used to draw on this particular device. Note that you also must create a corresponding paint engine to be able to draw on the device, i.e derive from <a href="qpaintengine.html">QPaintEngine</a> and reimplement its virtual functions.</p>
14
 
<p><b>Warning:</b> Qt requires that a <a href="qapplication.html">QApplication</a> object exists before any paint devices can be created. Paint devices access window system resources, and these resources are not initialized before an application object is created.</p>
15
 
<p>The QPaintDevice class provides several functions returning the various device metrics: The <a href="qpaintdevice.html#depth">depth</a>() function returns its bit depth (number of bit planes). The <a href="qpaintdevice.html#height">height</a>() function returns its height in default coordinate system units (e.g. pixels for <a href="qpixmap.html">QPixmap</a> and <a href="qwidget.html">QWidget</a>) while <a href="qpaintdevice.html#heightMM">heightMM</a>() returns the height of the device in millimeters. Similiarily, the <a href="qpaintdevice.html#width">width</a>() and <a href="qpaintdevice.html#widthMM">widthMM</a>() functions return the width of the device in default coordinate system units and in millimeters, respectively. Alternatively, the protected <a href="qpaintdevice.html#metric">metric</a>() function can be used to retrieve the metric information by specifying the desired <a href="qpaintdevice.html#PaintDeviceMetric-enum">PaintDeviceMetric</a> as argument.</p>
16
 
<p>The <a href="qpaintdevice.html#logicalDpiX">logicalDpiX</a>() and <a href="qpaintdevice.html#logicalDpiY">logicalDpiY</a>() functions return the horizontal and vertical resolution of the device in dots per inch. The <a href="qpaintdevice.html#physicalDpiX">physicalDpiX</a>() and <a href="qpaintdevice.html#physicalDpiY">physicalDpiY</a>() functions also return the resolution of the device in dots per inch, but note that if the logical and physical resolution differ, the corresponding <a href="qpaintengine.html">QPaintEngine</a> must handle the mapping. Finally, the <a href="qpaintdevice.html#colorCount">colorCount</a>() function returns the number of different colors available for the paint device.</p>
17
 
<p>See also <a href="qpaintengine.html">QPaintEngine</a>, <a href="qpainter.html">QPainter</a>, <a href="coordsys.html">The Coordinate System</a>, and <a href="paintsystem.html">The Paint System</a>.</p>
 
9
</style></head><body><table border="0" cellpadding="0" cellspacing="0" width="100%"><tr /><td align="left" valign="top" width="32"><img align="left" border="0" height="32" src="images/rb-logo.png" width="32" /></td><td width="1">&#160;&#160;</td><td class="postheader" valign="center"><a href="../pyqt4ref.html"><font color="#004faf">Home</font></a>&#160;&#183; <a href="classes.html"><font color="#004faf">All Classes</font></a>&#160;&#183; <a href="modules.html"><font color="#004faf">Modules</font></a></td></table><h1 align="center">QPaintDevice Class Reference<br /><sup><sup>[<a href="qtgui.html">QtGui</a> module]</sup></sup></h1><p>The QPaintDevice class is the base class of objects that can be
 
10
painted. <a href="#details">More...</a></p>
 
11
 
 
12
<p>Inherited by <a href="qglframebufferobject.html">QGLFramebufferObject</a>, <a href="qglpixelbuffer.html">QGLPixelBuffer</a>, <a href="qimage.html">QImage</a>, <a href="qpicture.html">QPicture</a>, <a href="qpixmap.html">QPixmap</a>, <a href="qprinter.html">QPrinter</a>, <a href="qsvggenerator.html">QSvgGenerator</a> and <a href="qwidget.html">QWidget</a>.</p><h3>Types</h3><ul><li><div class="fn" />enum <b><a href="qpaintdevice.html#PaintDeviceMetric-enum">PaintDeviceMetric</a></b> { PdmWidth, PdmHeight, PdmWidthMM, PdmHeightMM, ..., PdmPhysicalDpiY }</li></ul><h3>Methods</h3><ul><li><div class="fn" /><b><a href="qpaintdevice.html#QPaintDevice">__init__</a></b> (<i>self</i>)</li><li><div class="fn" />int <b><a href="qpaintdevice.html#colorCount">colorCount</a></b> (<i>self</i>)</li><li><div class="fn" />int <b><a href="qpaintdevice.html#depth">depth</a></b> (<i>self</i>)</li><li><div class="fn" />int <b><a href="qpaintdevice.html#height">height</a></b> (<i>self</i>)</li><li><div class="fn" />int <b><a href="qpaintdevice.html#heightMM">heightMM</a></b> (<i>self</i>)</li><li><div class="fn" />int <b><a href="qpaintdevice.html#logicalDpiX">logicalDpiX</a></b> (<i>self</i>)</li><li><div class="fn" />int <b><a href="qpaintdevice.html#logicalDpiY">logicalDpiY</a></b> (<i>self</i>)</li><li><div class="fn" />int <b><a href="qpaintdevice.html#metric">metric</a></b> (<i>self</i>, PaintDeviceMetric)</li><li><div class="fn" />int <b><a href="qpaintdevice.html#numColors">numColors</a></b> (<i>self</i>)</li><li><div class="fn" />QPaintEngine <b><a href="qpaintdevice.html#paintEngine">paintEngine</a></b> (<i>self</i>)</li><li><div class="fn" />bool <b><a href="qpaintdevice.html#paintingActive">paintingActive</a></b> (<i>self</i>)</li><li><div class="fn" />int <b><a href="qpaintdevice.html#physicalDpiX">physicalDpiX</a></b> (<i>self</i>)</li><li><div class="fn" />int <b><a href="qpaintdevice.html#physicalDpiY">physicalDpiY</a></b> (<i>self</i>)</li><li><div class="fn" />int <b><a href="qpaintdevice.html#width">width</a></b> (<i>self</i>)</li><li><div class="fn" />int <b><a href="qpaintdevice.html#widthMM">widthMM</a></b> (<i>self</i>)</li></ul><a name="details" /><hr /><h2>Detailed Description</h2><p>The QPaintDevice class is the base class of objects that can be
 
13
painted.</p>
 
14
<p>A paint device is an abstraction of a two-dimensional space that
 
15
can be drawn using a <a href="qpainter.html">QPainter</a>. Its
 
16
default coordinate system has its origin located at the top-left
 
17
position. X increases to the right and Y increases downwards. The
 
18
unit is one pixel.</p>
 
19
<p>The drawing capabilities of QPaintDevice are currently
 
20
implemented by the <a href="qwidget.html">QWidget</a>, <a href="qimage.html">QImage</a>, <a href="qpixmap.html">QPixmap</a>,
 
21
<a href="qglpixelbuffer.html">QGLPixelBuffer</a>, <a href="qpicture.html">QPicture</a>, and <a href="qprinter.html">QPrinter</a> subclasses.</p>
 
22
<p>To implement support for a new backend, you must derive from
 
23
QPaintDevice and reimplement the virtual <a href="qpaintdevice.html#paintEngine">paintEngine</a>() function to tell
 
24
<a href="qpainter.html">QPainter</a> which paint engine should be
 
25
used to draw on this particular device. Note that you also must
 
26
create a corresponding paint engine to be able to draw on the
 
27
device, i.e derive from <a href="qpaintengine.html">QPaintEngine</a> and reimplement its virtual
 
28
functions.</p>
 
29
<p><b>Warning:</b> Qt requires that a <a href="qapplication.html">QApplication</a> object exists before any paint
 
30
devices can be created. Paint devices access window system
 
31
resources, and these resources are not initialized before an
 
32
application object is created.</p>
 
33
<p>The QPaintDevice class provides several functions returning the
 
34
various device metrics: The <a href="qpaintdevice.html#depth">depth</a>() function returns its bit
 
35
depth (number of bit planes). The <a href="qpaintdevice.html#height">height</a>() function returns its height
 
36
in default coordinate system units (e.g. pixels for <a href="qpixmap.html">QPixmap</a> and <a href="qwidget.html">QWidget</a>)
 
37
while <a href="qpaintdevice.html#heightMM">heightMM</a>() returns
 
38
the height of the device in millimeters. Similiarily, the <a href="qpaintdevice.html#width">width</a>() and <a href="qpaintdevice.html#widthMM">widthMM</a>() functions return the
 
39
width of the device in default coordinate system units and in
 
40
millimeters, respectively. Alternatively, the protected <a href="qpaintdevice.html#metric">metric</a>() function can be used to
 
41
retrieve the metric information by specifying the desired <a href="qpaintdevice.html#PaintDeviceMetric-enum">PaintDeviceMetric</a> as
 
42
argument.</p>
 
43
<p>The <a href="qpaintdevice.html#logicalDpiX">logicalDpiX</a>()
 
44
and <a href="qpaintdevice.html#logicalDpiY">logicalDpiY</a>()
 
45
functions return the horizontal and vertical resolution of the
 
46
device in dots per inch. The <a href="qpaintdevice.html#physicalDpiX">physicalDpiX</a>() and <a href="qpaintdevice.html#physicalDpiY">physicalDpiY</a>() functions also
 
47
return the resolution of the device in dots per inch, but note that
 
48
if the logical and physical resolution differ, the corresponding
 
49
<a href="qpaintengine.html">QPaintEngine</a> must handle the
 
50
mapping. Finally, the <a href="qpaintdevice.html#colorCount">colorCount</a>() function returns
 
51
the number of different colors available for the paint device.</p>
18
52
<hr /><h2>Type Documentation</h2><h3 class="fn"><a name="PaintDeviceMetric-enum" />QPaintDevice.PaintDeviceMetric</h3><p>Describes the various metrics of a paint device.</p>
19
 
<p><table border="1" cellpadding="2" cellspacing="1" class="valuelist" width="100%">
20
 
<tr><th width="25%">Constant</th><th width="15%">Value</th><th width="60%">Description</th></tr>
21
 
<tr><td valign="top"><tt>QPaintDevice.PdmWidth</tt></td><td align="center" valign="top"><tt>1</tt></td><td valign="top">The width of the paint device in default coordinate system units (e.g. pixels for <a href="qpixmap.html">QPixmap</a> and <a href="qwidget.html">QWidget</a>). See also <a href="qpaintdevice.html#width">width</a>().</td></tr>
22
 
<tr><td valign="top"><tt>QPaintDevice.PdmHeight</tt></td><td align="center" valign="top"><tt>2</tt></td><td valign="top">The height of the paint device in default coordinate system units (e.g. pixels for <a href="qpixmap.html">QPixmap</a> and <a href="qwidget.html">QWidget</a>). See also <a href="qpaintdevice.html#height">height</a>().</td></tr>
23
 
<tr><td valign="top"><tt>QPaintDevice.PdmWidthMM</tt></td><td align="center" valign="top"><tt>3</tt></td><td valign="top">The width of the paint device in millimeters. See also <a href="qpaintdevice.html#widthMM">widthMM</a>().</td></tr>
24
 
<tr><td valign="top"><tt>QPaintDevice.PdmHeightMM</tt></td><td align="center" valign="top"><tt>4</tt></td><td valign="top">The height of the paint device in millimeters. See also <a href="qpaintdevice.html#heightMM">heightMM</a>().</td></tr>
25
 
<tr><td valign="top"><tt>QPaintDevice.PdmNumColors</tt></td><td align="center" valign="top"><tt>5</tt></td><td valign="top">The number of different colors available for the paint device. See also <a href="qpaintdevice.html#colorCount">colorCount</a>().</td></tr>
26
 
<tr><td valign="top"><tt>QPaintDevice.PdmDepth</tt></td><td align="center" valign="top"><tt>6</tt></td><td valign="top">The bit depth (number of bit planes) of the paint device. See also <a href="qpaintdevice.html#depth">depth</a>().</td></tr>
27
 
<tr><td valign="top"><tt>QPaintDevice.PdmDpiX</tt></td><td align="center" valign="top"><tt>7</tt></td><td valign="top">The horizontal resolution of the device in dots per inch. See also <a href="qpaintdevice.html#logicalDpiX">logicalDpiX</a>().</td></tr>
28
 
<tr><td valign="top"><tt>QPaintDevice.PdmDpiY</tt></td><td align="center" valign="top"><tt>8</tt></td><td valign="top">The vertical resolution of the device in dots per inch. See also <a href="qpaintdevice.html#logicalDpiY">logicalDpiY</a>().</td></tr>
29
 
<tr><td valign="top"><tt>QPaintDevice.PdmPhysicalDpiX</tt></td><td align="center" valign="top"><tt>9</tt></td><td valign="top">The horizontal resolution of the device in dots per inch. See also <a href="qpaintdevice.html#physicalDpiX">physicalDpiX</a>().</td></tr>
30
 
<tr><td valign="top"><tt>QPaintDevice.PdmPhysicalDpiY</tt></td><td align="center" valign="top"><tt>10</tt></td><td valign="top">The vertical resolution of the device in dots per inch. See also <a href="qpaintdevice.html#physicalDpiY">physicalDpiY</a>().</td></tr>
31
 
</table></p>
 
53
<table class="valuelist">
 
54
<tr class="odd">
 
55
<td />
 
56
</tr>
 
57
<tr>
 
58
<th class="tblConst">Constant</th>
 
59
<th class="tblval">Value</th>
 
60
<th class="tbldscr">Description</th>
 
61
</tr>
 
62
<tr>
 
63
<td class="topAlign"><tt>QPaintDevice.PdmWidth</tt></td>
 
64
<td class=" topAlign"><tt>1</tt></td>
 
65
<td class="topAlign">The width of the paint device in default
 
66
coordinate system units (e.g. pixels for <a href="qpixmap.html">QPixmap</a> and <a href="qwidget.html">QWidget</a>).
 
67
See also <a href="qpaintdevice.html#width">width</a>().</td>
 
68
</tr>
 
69
<tr>
 
70
<td class="topAlign"><tt>QPaintDevice.PdmHeight</tt></td>
 
71
<td class=" topAlign"><tt>2</tt></td>
 
72
<td class="topAlign">The height of the paint device in default
 
73
coordinate system units (e.g. pixels for <a href="qpixmap.html">QPixmap</a> and <a href="qwidget.html">QWidget</a>).
 
74
See also <a href="qpaintdevice.html#height">height</a>().</td>
 
75
</tr>
 
76
<tr>
 
77
<td class="topAlign"><tt>QPaintDevice.PdmWidthMM</tt></td>
 
78
<td class=" topAlign"><tt>3</tt></td>
 
79
<td class="topAlign">The width of the paint device in millimeters.
 
80
See also <a href="qpaintdevice.html#widthMM">widthMM</a>().</td>
 
81
</tr>
 
82
<tr>
 
83
<td class="topAlign"><tt>QPaintDevice.PdmHeightMM</tt></td>
 
84
<td class=" topAlign"><tt>4</tt></td>
 
85
<td class="topAlign">The height of the paint device in millimeters.
 
86
See also <a href="qpaintdevice.html#heightMM">heightMM</a>().</td>
 
87
</tr>
 
88
<tr>
 
89
<td class="topAlign"><tt>QPaintDevice.PdmNumColors</tt></td>
 
90
<td class=" topAlign"><tt>5</tt></td>
 
91
<td class="topAlign">The number of different colors available for
 
92
the paint device. See also <a href="qpaintdevice.html#colorCount">colorCount</a>().</td>
 
93
</tr>
 
94
<tr>
 
95
<td class="topAlign"><tt>QPaintDevice.PdmDepth</tt></td>
 
96
<td class=" topAlign"><tt>6</tt></td>
 
97
<td class="topAlign">The bit depth (number of bit planes) of the
 
98
paint device. See also <a href="qpaintdevice.html#depth">depth</a>().</td>
 
99
</tr>
 
100
<tr>
 
101
<td class="topAlign"><tt>QPaintDevice.PdmDpiX</tt></td>
 
102
<td class=" topAlign"><tt>7</tt></td>
 
103
<td class="topAlign">The horizontal resolution of the device in
 
104
dots per inch. See also <a href="qpaintdevice.html#logicalDpiX">logicalDpiX</a>().</td>
 
105
</tr>
 
106
<tr>
 
107
<td class="topAlign"><tt>QPaintDevice.PdmDpiY</tt></td>
 
108
<td class=" topAlign"><tt>8</tt></td>
 
109
<td class="topAlign">The vertical resolution of the device in dots
 
110
per inch. See also <a href="qpaintdevice.html#logicalDpiY">logicalDpiY</a>().</td>
 
111
</tr>
 
112
<tr>
 
113
<td class="topAlign"><tt>QPaintDevice.PdmPhysicalDpiX</tt></td>
 
114
<td class=" topAlign"><tt>9</tt></td>
 
115
<td class="topAlign">The horizontal resolution of the device in
 
116
dots per inch. See also <a href="qpaintdevice.html#physicalDpiX">physicalDpiX</a>().</td>
 
117
</tr>
 
118
<tr>
 
119
<td class="topAlign"><tt>QPaintDevice.PdmPhysicalDpiY</tt></td>
 
120
<td class=" topAlign"><tt>10</tt></td>
 
121
<td class="topAlign">The vertical resolution of the device in dots
 
122
per inch. See also <a href="qpaintdevice.html#physicalDpiY">physicalDpiY</a>().</td>
 
123
</tr>
 
124
</table>
32
125
<p>See also <a href="qpaintdevice.html#metric">metric</a>().</p>
33
 
<hr /><h2>Method Documentation</h2><h3 class="fn"><a name="QPaintDevice" />QPaintDevice.__init__ (<i>self</i>)</h3><p>Constructs a paint device. This constructor can be invoked only from subclasses of <a href="qpaintdevice.html">QPaintDevice</a>.</p>
34
 
<a name="//apple_ref/cpp/instm/QPaintDevice/~QPaintDevice" />
35
 
<h3 class="fn"><a name="colorCount" />int QPaintDevice.colorCount (<i>self</i>)</h3><p>Returns the number of different colors available for the paint device. Since this value is an int, it will not be sufficient to represent the number of colors on 32 bit displays, in this case INT_MAX is returned instead.</p>
36
 
<a name="//apple_ref/cpp/instm/QPaintDevice/depth" />
37
 
<h3 class="fn"><a name="depth" />int QPaintDevice.depth (<i>self</i>)</h3><p>Returns the bit depth (number of bit planes) of the paint device.</p>
38
 
<a name="//apple_ref/cpp/instm/QPaintDevice/height" />
39
 
<h3 class="fn"><a name="height" />int QPaintDevice.height (<i>self</i>)</h3><p>Returns the height of the paint device in default coordinate system units (e.g. pixels for <a href="qpixmap.html">QPixmap</a> and <a href="qwidget.html">QWidget</a>).</p>
 
126
<hr /><h2>Method Documentation</h2><h3 class="fn"><a name="QPaintDevice" />QPaintDevice.__init__ (<i>self</i>)</h3><p>Constructs a paint device. This constructor can be invoked only
 
127
from subclasses of <a href="qpaintdevice.html">QPaintDevice</a>.</p>
 
128
 
 
129
 
 
130
<h3 class="fn"><a name="colorCount" />int QPaintDevice.colorCount (<i>self</i>)</h3><p>Returns the number of different colors available for the paint
 
131
device. Since this value is an int, it will not be sufficient to
 
132
represent the number of colors on 32 bit displays, in this case
 
133
INT_MAX is returned instead.</p>
 
134
 
 
135
 
 
136
<h3 class="fn"><a name="depth" />int QPaintDevice.depth (<i>self</i>)</h3><p>Returns the bit depth (number of bit planes) of the paint
 
137
device.</p>
 
138
 
 
139
 
 
140
<h3 class="fn"><a name="height" />int QPaintDevice.height (<i>self</i>)</h3><p>Returns the height of the paint device in default coordinate
 
141
system units (e.g. pixels for <a href="qpixmap.html">QPixmap</a>
 
142
and <a href="qwidget.html">QWidget</a>).</p>
40
143
<p>See also <a href="qpaintdevice.html#heightMM">heightMM</a>().</p>
41
 
<a name="//apple_ref/cpp/instm/QPaintDevice/heightMM" />
42
 
<h3 class="fn"><a name="heightMM" />int QPaintDevice.heightMM (<i>self</i>)</h3><p>Returns the height of the paint device in millimeters. Due to platform limitations it may not be possible to use this function to determine the actual physical size of a widget on the screen.</p>
 
144
 
 
145
 
 
146
<h3 class="fn"><a name="heightMM" />int QPaintDevice.heightMM (<i>self</i>)</h3><p>Returns the height of the paint device in millimeters. Due to
 
147
platform limitations it may not be possible to use this function to
 
148
determine the actual physical size of a widget on the screen.</p>
43
149
<p>See also <a href="qpaintdevice.html#height">height</a>().</p>
44
 
<a name="//apple_ref/cpp/instm/QPaintDevice/logicalDpiX" />
45
 
<h3 class="fn"><a name="logicalDpiX" />int QPaintDevice.logicalDpiX (<i>self</i>)</h3><p>Returns the horizontal resolution of the device in dots per inch, which is used when computing font sizes. For X11, this is usually the same as could be computed from <a href="qpaintdevice.html#widthMM">widthMM</a>().</p>
46
 
<p>Note that if the logicalDpiX() doesn't equal the <a href="qpaintdevice.html#physicalDpiX">physicalDpiX</a>(), the corresponding <a href="qpaintengine.html">QPaintEngine</a> must handle the resolution mapping.</p>
 
150
 
 
151
 
 
152
<h3 class="fn"><a name="logicalDpiX" />int QPaintDevice.logicalDpiX (<i>self</i>)</h3><p>Returns the horizontal resolution of the device in dots per
 
153
inch, which is used when computing font sizes. For X11, this is
 
154
usually the same as could be computed from <a href="qpaintdevice.html#widthMM">widthMM</a>().</p>
 
155
<p>Note that if the logicalDpiX() doesn't equal the <a href="qpaintdevice.html#physicalDpiX">physicalDpiX</a>(), the
 
156
corresponding <a href="qpaintengine.html">QPaintEngine</a> must
 
157
handle the resolution mapping.</p>
47
158
<p>See also <a href="qpaintdevice.html#logicalDpiY">logicalDpiY</a>() and <a href="qpaintdevice.html#physicalDpiX">physicalDpiX</a>().</p>
48
 
<a name="//apple_ref/cpp/instm/QPaintDevice/logicalDpiY" />
49
 
<h3 class="fn"><a name="logicalDpiY" />int QPaintDevice.logicalDpiY (<i>self</i>)</h3><p>Returns the vertical resolution of the device in dots per inch, which is used when computing font sizes. For X11, this is usually the same as could be computed from <a href="qpaintdevice.html#heightMM">heightMM</a>().</p>
50
 
<p>Note that if the logicalDpiY() doesn't equal the <a href="qpaintdevice.html#physicalDpiY">physicalDpiY</a>(), the corresponding <a href="qpaintengine.html">QPaintEngine</a> must handle the resolution mapping.</p>
 
159
 
 
160
 
 
161
<h3 class="fn"><a name="logicalDpiY" />int QPaintDevice.logicalDpiY (<i>self</i>)</h3><p>Returns the vertical resolution of the device in dots per inch,
 
162
which is used when computing font sizes. For X11, this is usually
 
163
the same as could be computed from <a href="qpaintdevice.html#heightMM">heightMM</a>().</p>
 
164
<p>Note that if the logicalDpiY() doesn't equal the <a href="qpaintdevice.html#physicalDpiY">physicalDpiY</a>(), the
 
165
corresponding <a href="qpaintengine.html">QPaintEngine</a> must
 
166
handle the resolution mapping.</p>
51
167
<p>See also <a href="qpaintdevice.html#logicalDpiX">logicalDpiX</a>() and <a href="qpaintdevice.html#physicalDpiY">physicalDpiY</a>().</p>
52
 
<a name="//apple_ref/cpp/instm/QPaintDevice/metric" />
53
 
<h3 class="fn"><a name="metric" />int QPaintDevice.metric (<i>self</i>, <a href="qpaintdevice.html#PaintDeviceMetric-enum">PaintDeviceMetric</a>)</h3><p>Returns the metric information for the given paint device <i>metric</i>.</p>
 
168
 
 
169
 
 
170
<h3 class="fn"><a name="metric" />int QPaintDevice.metric (<i>self</i>, <a href="qpaintdevice.html#PaintDeviceMetric-enum">PaintDeviceMetric</a>)</h3><p>Returns the metric information for the given paint device
 
171
<i>metric</i>.</p>
54
172
<p>See also <a href="qpaintdevice.html#PaintDeviceMetric-enum">PaintDeviceMetric</a>.</p>
55
 
<a name="//apple_ref/cpp/instm/QPaintDevice/numColors" />
 
173
 
 
174
 
56
175
<h3 class="fn"><a name="numColors" />int QPaintDevice.numColors (<i>self</i>)</h3><p>This function is deprecated.</p>
57
 
<p>Use <a href="qpaintdevice.html#colorCount">colorCount</a>() instead.</p>
58
 
<p>Returns the number of different colors available for the paint device. Since this value is an int, it will not be sufficient to represent the number of colors on 32 bit displays, in this case INT_MAX is returned instead.</p>
59
 
<a name="//apple_ref/cpp/instm/QPaintDevice/paintEngine" />
60
 
<h3 class="fn"><a name="paintEngine" /><a href="qpaintengine.html">QPaintEngine</a> QPaintDevice.paintEngine (<i>self</i>)</h3><p>This method is abstract and should be reimplemented in any sub-class.</p><p>Returns a pointer to the paint engine used for drawing on the device.</p>
61
 
<a name="//apple_ref/cpp/instm/QPaintDevice/paintingActive" />
62
 
<h3 class="fn"><a name="paintingActive" />bool QPaintDevice.paintingActive (<i>self</i>)</h3><p>Returns true if the device is currently being painted on, i.e. someone has called <a href="qpainter.html#begin">QPainter.begin</a>() but not yet called <a href="qpainter.html#end">QPainter.end</a>() for this device; otherwise returns false.</p>
 
176
<p>Use <a href="qpaintdevice.html#colorCount">colorCount</a>()
 
177
instead.</p>
 
178
<p>Returns the number of different colors available for the paint
 
179
device. Since this value is an int, it will not be sufficient to
 
180
represent the number of colors on 32 bit displays, in this case
 
181
INT_MAX is returned instead.</p>
 
182
 
 
183
 
 
184
<h3 class="fn"><a name="paintEngine" /><a href="qpaintengine.html">QPaintEngine</a> QPaintDevice.paintEngine (<i>self</i>)</h3><p>This method is abstract and should be reimplemented in any sub-class.</p><p>Returns a pointer to the paint engine used for drawing on the
 
185
device.</p>
 
186
 
 
187
 
 
188
<h3 class="fn"><a name="paintingActive" />bool QPaintDevice.paintingActive (<i>self</i>)</h3><p>Returns true if the device is currently being painted on, i.e.
 
189
someone has called <a href="qpainter.html#begin">QPainter.begin</a>() but not yet called
 
190
<a href="qpainter.html#end">QPainter.end</a>() for this device;
 
191
otherwise returns false.</p>
63
192
<p>See also <a href="qpainter.html#isActive">QPainter.isActive</a>().</p>
64
 
<a name="//apple_ref/cpp/instm/QPaintDevice/physicalDpiX" />
65
 
<h3 class="fn"><a name="physicalDpiX" />int QPaintDevice.physicalDpiX (<i>self</i>)</h3><p>Returns the horizontal resolution of the device in dots per inch. For example, when printing, this resolution refers to the physical printer's resolution. The logical DPI on the other hand, refers to the resolution used by the actual paint engine.</p>
66
 
<p>Note that if the physicalDpiX() doesn't equal the <a href="qpaintdevice.html#logicalDpiX">logicalDpiX</a>(), the corresponding <a href="qpaintengine.html">QPaintEngine</a> must handle the resolution mapping.</p>
 
193
 
 
194
 
 
195
<h3 class="fn"><a name="physicalDpiX" />int QPaintDevice.physicalDpiX (<i>self</i>)</h3><p>Returns the horizontal resolution of the device in dots per
 
196
inch. For example, when printing, this resolution refers to the
 
197
physical printer's resolution. The logical DPI on the other hand,
 
198
refers to the resolution used by the actual paint engine.</p>
 
199
<p>Note that if the physicalDpiX() doesn't equal the <a href="qpaintdevice.html#logicalDpiX">logicalDpiX</a>(), the
 
200
corresponding <a href="qpaintengine.html">QPaintEngine</a> must
 
201
handle the resolution mapping.</p>
67
202
<p>See also <a href="qpaintdevice.html#physicalDpiY">physicalDpiY</a>() and <a href="qpaintdevice.html#logicalDpiX">logicalDpiX</a>().</p>
68
 
<a name="//apple_ref/cpp/instm/QPaintDevice/physicalDpiY" />
69
 
<h3 class="fn"><a name="physicalDpiY" />int QPaintDevice.physicalDpiY (<i>self</i>)</h3><p>Returns the horizontal resolution of the device in dots per inch. For example, when printing, this resolution refers to the physical printer's resolution. The logical DPI on the other hand, refers to the resolution used by the actual paint engine.</p>
70
 
<p>Note that if the physicalDpiY() doesn't equal the <a href="qpaintdevice.html#logicalDpiY">logicalDpiY</a>(), the corresponding <a href="qpaintengine.html">QPaintEngine</a> must handle the resolution mapping.</p>
 
203
 
 
204
 
 
205
<h3 class="fn"><a name="physicalDpiY" />int QPaintDevice.physicalDpiY (<i>self</i>)</h3><p>Returns the horizontal resolution of the device in dots per
 
206
inch. For example, when printing, this resolution refers to the
 
207
physical printer's resolution. The logical DPI on the other hand,
 
208
refers to the resolution used by the actual paint engine.</p>
 
209
<p>Note that if the physicalDpiY() doesn't equal the <a href="qpaintdevice.html#logicalDpiY">logicalDpiY</a>(), the
 
210
corresponding <a href="qpaintengine.html">QPaintEngine</a> must
 
211
handle the resolution mapping.</p>
71
212
<p>See also <a href="qpaintdevice.html#physicalDpiX">physicalDpiX</a>() and <a href="qpaintdevice.html#logicalDpiY">logicalDpiY</a>().</p>
72
 
<a name="//apple_ref/cpp/instm/QPaintDevice/width" />
73
 
<h3 class="fn"><a name="width" />int QPaintDevice.width (<i>self</i>)</h3><p>Returns the width of the paint device in default coordinate system units (e.g. pixels for <a href="qpixmap.html">QPixmap</a> and <a href="qwidget.html">QWidget</a>).</p>
 
213
 
 
214
 
 
215
<h3 class="fn"><a name="width" />int QPaintDevice.width (<i>self</i>)</h3><p>Returns the width of the paint device in default coordinate
 
216
system units (e.g. pixels for <a href="qpixmap.html">QPixmap</a>
 
217
and <a href="qwidget.html">QWidget</a>).</p>
74
218
<p>See also <a href="qpaintdevice.html#widthMM">widthMM</a>().</p>
75
 
<a name="//apple_ref/cpp/instm/QPaintDevice/widthMM" />
76
 
<h3 class="fn"><a name="widthMM" />int QPaintDevice.widthMM (<i>self</i>)</h3><p>Returns the width of the paint device in millimeters. Due to platform limitations it may not be possible to use this function to determine the actual physical size of a widget on the screen.</p>
 
219
 
 
220
 
 
221
<h3 class="fn"><a name="widthMM" />int QPaintDevice.widthMM (<i>self</i>)</h3><p>Returns the width of the paint device in millimeters. Due to
 
222
platform limitations it may not be possible to use this function to
 
223
determine the actual physical size of a widget on the screen.</p>
77
224
<p>See also <a href="qpaintdevice.html#width">width</a>().</p>
78
 
<p /><address><hr /><div align="center"><table border="0" cellspacing="0" width="100%"><tr class="address"><td align="left" width="25%">PyQt&#160;4.7.7 for X11</td><td align="center" width="50%">Copyright &#169; <a href="http://www.riverbankcomputing.com">Riverbank&#160;Computing&#160;Ltd</a> and <a href="http://www.qtsoftware.com">Nokia</a> 2010</td><td align="right" width="25%">Qt&#160;4.6.3</td></tr></table></div></address></body></html>
 
 
b'\\ No newline at end of file'
 
225
<address><hr /><div align="center"><table border="0" cellspacing="0" width="100%"><tr class="address"><td align="left" width="25%">PyQt&#160;4.8.1 for X11</td><td align="center" width="50%">Copyright &#169; <a href="http://www.riverbankcomputing.com">Riverbank&#160;Computing&#160;Ltd</a> and <a href="http://www.qtsoftware.com">Nokia</a> 2010</td><td align="right" width="25%">Qt&#160;4.7.0</td></tr></table></div></address></body></html>
 
 
b'\\ No newline at end of file'