~asdfghjkl-deactivatedaccount1/python-imaging/gif-fix

« back to all changes in this revision

Viewing changes to Docs/pythondoc-PIL.ImageWin.html

  • Committer: effbot
  • Date: 2006-07-05 20:36:11 UTC
  • Revision ID: svn-v4:be285980-f00d-0410-a9fe-d4747b46ecd0:pil:348
Load Imaging-1.1.6b1 into pil.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
<!DOCTYPE html PUBLIC '-//W3C//DTD XHTML 1.0 Strict//EN' 'http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd'>
2
 
<html>
3
 
<head>
4
 
<meta http-equiv='Content-Type' content='text/html; charset=us-ascii' />
5
 
<title>The PIL.ImageWin Module</title>
6
 
<link rel='stylesheet' href='effbot.css' type='text/css' />
7
 
</head>
8
 
<body>
9
 
<h1>The PIL.ImageWin Module</h1>
10
 
<dl>
11
 
<dt><b>Dib(image, size=None)</b> (class) [<a href='#PIL.ImageWin.Dib-class'>#</a>]</dt>
12
 
<dd>
13
 
<p>Create a Windows bitmap with the given mode and size.</p>
14
 
<p>For more information about this class, see <a href='#PIL.ImageWin.Dib-class'><i>The Dib Class</i></a>.</p>
15
 
</dd>
16
 
<dt><b>HDC(dc)</b> (class) [<a href='#PIL.ImageWin.HDC-class'>#</a>]</dt>
17
 
<dd>
18
 
<p>The ImageWin module contains support to create and display
19
 
images under Windows 95/98, NT, 2000 and later.</p>
20
 
<p>For more information about this class, see <a href='#PIL.ImageWin.HDC-class'><i>The HDC Class</i></a>.</p>
21
 
</dd>
22
 
<dt><b>ImageWindow(image, title=&quot;PIL&quot;)</b> (class) [<a href='#PIL.ImageWin.ImageWindow-class'>#</a>]</dt>
23
 
<dd>
24
 
<p>Create an image window which displays the given image.</p>
25
 
<p>For more information about this class, see <a href='#PIL.ImageWin.ImageWindow-class'><i>The ImageWindow Class</i></a>.</p>
26
 
</dd>
27
 
<dt><b>Window(title=&quot;PIL&quot;, width=None, height=None)</b> (class) [<a href='#PIL.ImageWin.Window-class'>#</a>]</dt>
28
 
<dd>
29
 
<p>Create a Window with the given title size.</p>
30
 
<p>For more information about this class, see <a href='#PIL.ImageWin.Window-class'><i>The Window Class</i></a>.</p>
31
 
</dd>
32
 
</dl>
33
 
<h2><a id='PIL.ImageWin.Dib-class' name='PIL.ImageWin.Dib-class'>The Dib Class</a></h2>
34
 
<dl>
35
 
<dt><b>Dib(image, size=None)</b> (class) [<a href='#PIL.ImageWin.Dib-class'>#</a>]</dt>
36
 
<dd>
37
 
<p>Create a Windows bitmap with the given mode and size.  The mode can
38
 
be one of "1", "L", "P", or "RGB".
39
 
 
40
 
If the display requires a palette, this constructor creates a
41
 
suitable palette and associates it with the image. For an "L" image,
42
 
128 greylevels are allocated. For an "RGB" image, a 6x6x6 colour
43
 
cube is used, together with 20 greylevels.
44
 
 
45
 
To make sure that palettes work properly under Windows, you must
46
 
call the <b>palette</b> method upon certain events from Windows.
47
 
</p></dd>
48
 
<dt><a id='PIL.ImageWin.Dib.__init__-method' name='PIL.ImageWin.Dib.__init__-method'><b>__init__(image, size=None)</b></a> [<a href='#PIL.ImageWin.Dib.__init__-method'>#</a>]</dt>
49
 
<dd>
50
 
<p>Create Windows bitmap.</p>
51
 
<dl>
52
 
<dt><i>image</i></dt>
53
 
<dd>
54
 
Either a PIL image, or a mode string.  If a
55
 
   mode string is used, a size must also be given.  The
56
 
   mode can be one of &quot;1&quot;, &quot;L&quot;, &quot;P&quot;, or &quot;RGB&quot;.</dd>
57
 
<dt><i>size</i></dt>
58
 
<dd>
59
 
If the first argument is a mode string, this
60
 
   defines the size of the image.</dd>
61
 
</dl><br />
62
 
</dd>
63
 
<dt><a id='PIL.ImageWin.Dib.expose-method' name='PIL.ImageWin.Dib.expose-method'><b>expose(handle)</b></a> [<a href='#PIL.ImageWin.Dib.expose-method'>#</a>]</dt>
64
 
<dd>
65
 
<p>Copy the bitmap contents to a device context.</p>
66
 
<dl>
67
 
<dt><i>handle</i></dt>
68
 
<dd>
69
 
Device context (HDC), cast to a Python integer,
70
 
   or a HDC or HWND instance.  In PythonWin, you can use the
71
 
   <b>GetHandleAttrib</b> method of the <b>CDC</b> class to get
72
 
   a suitable handle.
73
 
</dd>
74
 
</dl><br />
75
 
</dd>
76
 
<dt><a id='PIL.ImageWin.Dib.fromstring-method' name='PIL.ImageWin.Dib.fromstring-method'><b>fromstring(buffer)</b></a> [<a href='#PIL.ImageWin.Dib.fromstring-method'>#</a>]</dt>
77
 
<dd>
78
 
<p>Load display memory contents from string buffer.</p>
79
 
<dl>
80
 
<dt><i>buffer</i></dt>
81
 
<dd>
82
 
A string buffer containing display data (usually
83
 
    data returned from <b>tostring</b>)
84
 
</dd>
85
 
</dl><br />
86
 
</dd>
87
 
<dt><a id='PIL.ImageWin.Dib.paste-method' name='PIL.ImageWin.Dib.paste-method'><b>paste(im, box=None)</b></a> [<a href='#PIL.ImageWin.Dib.paste-method'>#</a>]</dt>
88
 
<dd>
89
 
<p>Paste a PIL image into the bitmap image.</p>
90
 
<dl>
91
 
<dt><i>im</i></dt>
92
 
<dd>
93
 
A PIL image.  The size must match the target region.
94
 
   If the mode does not match, the image is converted to the
95
 
   mode of the bitmap image.</dd>
96
 
<dt><i>box</i></dt>
97
 
<dd>
98
 
A 4-tuple defining the left, upper, right, and
99
 
   lower pixel coordinate.  If None is given instead of a
100
 
   tuple, all of the image is assumed.</dd>
101
 
</dl><br />
102
 
</dd>
103
 
<dt><a id='PIL.ImageWin.Dib.query_palette-method' name='PIL.ImageWin.Dib.query_palette-method'><b>query_palette(dc)</b></a> [<a href='#PIL.ImageWin.Dib.query_palette-method'>#</a>]</dt>
104
 
<dd>
105
 
<p>Installs the palette associated with the image in the
106
 
given device context.
107
 
</p><p>
108
 
This method should be called upon <b>QUERYNEWPALETTE</b>
109
 
and <b>PALETTECHANGED</b> events from Windows. If this
110
 
method returns a non-zero value, one or more display
111
 
palette entries were changed, and the image should be
112
 
redrawn.
113
 
 
114
 
</p><dl>
115
 
<dt><i>dc</i></dt>
116
 
<dd>
117
 
Device context (HDC), cast to a Python integer,
118
 
    or an HDC or HWND instance.</dd>
119
 
<dt>Returns:</dt>
120
 
<dd>
121
 
A true value if one or more entries were changed
122
 
   (this indicates that the image should be redrawn).</dd>
123
 
</dl><br />
124
 
</dd>
125
 
<dt><a id='PIL.ImageWin.Dib.tostring-method' name='PIL.ImageWin.Dib.tostring-method'><b>tostring()</b></a> [<a href='#PIL.ImageWin.Dib.tostring-method'>#</a>]</dt>
126
 
<dd>
127
 
<p>Copy display memory contents to string buffer.</p>
128
 
<dl>
129
 
<dt>Returns:</dt>
130
 
<dd>
131
 
A string buffer containing display data.</dd>
132
 
</dl><br />
133
 
</dd>
134
 
</dl>
135
 
<h2><a id='PIL.ImageWin.HDC-class' name='PIL.ImageWin.HDC-class'>The HDC Class</a></h2>
136
 
<dl>
137
 
<dt><b>HDC(dc)</b> (class) [<a href='#PIL.ImageWin.HDC-class'>#</a>]</dt>
138
 
<dd>
139
 
<p>The <b>ImageWin</b> module contains support to create and display
140
 
images under Windows 95/98, NT, 2000 and later.
141
 
</p></dd>
142
 
</dl>
143
 
<h2><a id='PIL.ImageWin.ImageWindow-class' name='PIL.ImageWin.ImageWindow-class'>The ImageWindow Class</a></h2>
144
 
<dl>
145
 
<dt><b>ImageWindow(image, title=&quot;PIL&quot;)</b> (class) [<a href='#PIL.ImageWin.ImageWindow-class'>#</a>]</dt>
146
 
<dd>
147
 
<p>Create an image window which displays the given image.</p>
148
 
</dd>
149
 
</dl>
150
 
<h2><a id='PIL.ImageWin.Window-class' name='PIL.ImageWin.Window-class'>The Window Class</a></h2>
151
 
<dl>
152
 
<dt><b>Window(title=&quot;PIL&quot;, width=None, height=None)</b> (class) [<a href='#PIL.ImageWin.Window-class'>#</a>]</dt>
153
 
<dd>
154
 
<p>Create a Window with the given title size.</p>
155
 
</dd>
156
 
</dl>
157
 
</body></html>
 
1
<!DOCTYPE html PUBLIC '-//W3C//DTD XHTML 1.0 Strict//EN' 'http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd'>
 
2
<html>
 
3
<head>
 
4
<meta http-equiv='Content-Type' content='text/html; charset=us-ascii' />
 
5
<title>The PIL.ImageWin Module</title>
 
6
<link rel='stylesheet' href='effbot.css' type='text/css' />
 
7
</head>
 
8
<body>
 
9
<h1>The PIL.ImageWin Module</h1>
 
10
<dl>
 
11
<dt><b>Dib(image, size=None)</b> (class) [<a href='#PIL.ImageWin.Dib-class'>#</a>]</dt>
 
12
<dd>
 
13
<p>Create a Windows bitmap with the given mode and size.</p>
 
14
<p>For more information about this class, see <a href='#PIL.ImageWin.Dib-class'><i>The Dib Class</i></a>.</p>
 
15
</dd>
 
16
<dt><b>HDC(dc)</b> (class) [<a href='#PIL.ImageWin.HDC-class'>#</a>]</dt>
 
17
<dd>
 
18
<p>The ImageWin module contains support to create and display
 
19
images under Windows 95/98, NT, 2000 and later.</p>
 
20
<p>For more information about this class, see <a href='#PIL.ImageWin.HDC-class'><i>The HDC Class</i></a>.</p>
 
21
</dd>
 
22
<dt><b>ImageWindow(image, title=&quot;PIL&quot;)</b> (class) [<a href='#PIL.ImageWin.ImageWindow-class'>#</a>]</dt>
 
23
<dd>
 
24
<p>Create an image window which displays the given image.</p>
 
25
<p>For more information about this class, see <a href='#PIL.ImageWin.ImageWindow-class'><i>The ImageWindow Class</i></a>.</p>
 
26
</dd>
 
27
<dt><b>Window(title=&quot;PIL&quot;, width=None, height=None)</b> (class) [<a href='#PIL.ImageWin.Window-class'>#</a>]</dt>
 
28
<dd>
 
29
<p>Create a Window with the given title size.</p>
 
30
<p>For more information about this class, see <a href='#PIL.ImageWin.Window-class'><i>The Window Class</i></a>.</p>
 
31
</dd>
 
32
</dl>
 
33
<h2><a id='PIL.ImageWin.Dib-class' name='PIL.ImageWin.Dib-class'>The Dib Class</a></h2>
 
34
<dl>
 
35
<dt><b>Dib(image, size=None)</b> (class) [<a href='#PIL.ImageWin.Dib-class'>#</a>]</dt>
 
36
<dd>
 
37
<p>Create a Windows bitmap with the given mode and size.  The mode can
 
38
be one of "1", "L", "P", or "RGB".
 
39
 
 
40
If the display requires a palette, this constructor creates a
 
41
suitable palette and associates it with the image. For an "L" image,
 
42
128 greylevels are allocated. For an "RGB" image, a 6x6x6 colour
 
43
cube is used, together with 20 greylevels.
 
44
 
 
45
To make sure that palettes work properly under Windows, you must
 
46
call the <b>palette</b> method upon certain events from Windows.
 
47
</p></dd>
 
48
<dt><a id='PIL.ImageWin.Dib.__init__-method' name='PIL.ImageWin.Dib.__init__-method'><b>__init__(image, size=None)</b></a> [<a href='#PIL.ImageWin.Dib.__init__-method'>#</a>]</dt>
 
49
<dd>
 
50
<dl>
 
51
<dt><i>image</i></dt>
 
52
<dd>
 
53
</dd>
 
54
<dt><i>size</i></dt>
 
55
<dd>
 
56
</dd>
 
57
</dl><br />
 
58
</dd>
 
59
<dt><a id='PIL.ImageWin.Dib.expose-method' name='PIL.ImageWin.Dib.expose-method'><b>expose(handle)</b></a> [<a href='#PIL.ImageWin.Dib.expose-method'>#</a>]</dt>
 
60
<dd>
 
61
<dl>
 
62
<dt><i>handle</i></dt>
 
63
<dd>
 
64
Device context (HDC), cast to a Python integer,
 
65
   or a HDC or HWND instance.  In PythonWin, you can use the
 
66
   <b>GetHandleAttrib</b> method of the <b>CDC</b> class to get
 
67
   a suitable handle.
 
68
</dd>
 
69
</dl><br />
 
70
</dd>
 
71
<dt><a id='PIL.ImageWin.Dib.fromstring-method' name='PIL.ImageWin.Dib.fromstring-method'><b>fromstring(buffer)</b></a> [<a href='#PIL.ImageWin.Dib.fromstring-method'>#</a>]</dt>
 
72
<dd>
 
73
<dl>
 
74
<dt><i>buffer</i></dt>
 
75
<dd>
 
76
A string buffer containing display data (usually
 
77
    data returned from <b>tostring</b>)
 
78
</dd>
 
79
</dl><br />
 
80
</dd>
 
81
<dt><a id='PIL.ImageWin.Dib.paste-method' name='PIL.ImageWin.Dib.paste-method'><b>paste(im, box=None)</b></a> [<a href='#PIL.ImageWin.Dib.paste-method'>#</a>]</dt>
 
82
<dd>
 
83
<dl>
 
84
<dt><i>im</i></dt>
 
85
<dd>
 
86
</dd>
 
87
<dt><i>box</i></dt>
 
88
<dd>
 
89
</dd>
 
90
</dl><br />
 
91
</dd>
 
92
<dt><a id='PIL.ImageWin.Dib.query_palette-method' name='PIL.ImageWin.Dib.query_palette-method'><b>query_palette(handle)</b></a> [<a href='#PIL.ImageWin.Dib.query_palette-method'>#</a>]</dt>
 
93
<dd>
 
94
<p>Installs the palette associated with the image in the
 
95
given device context.
 
96
</p><p>
 
97
This method should be called upon <b>QUERYNEWPALETTE</b>
 
98
and <b>PALETTECHANGED</b> events from Windows. If this
 
99
method returns a non-zero value, one or more display
 
100
palette entries were changed, and the image should be
 
101
redrawn.
 
102
 
 
103
</p><dl>
 
104
<dt><i>handle</i></dt>
 
105
<dd>
 
106
</dd>
 
107
<dt>Returns:</dt>
 
108
<dd>
 
109
</dd>
 
110
</dl><br />
 
111
</dd>
 
112
<dt><a id='PIL.ImageWin.Dib.tostring-method' name='PIL.ImageWin.Dib.tostring-method'><b>tostring()</b></a> [<a href='#PIL.ImageWin.Dib.tostring-method'>#</a>]</dt>
 
113
<dd>
 
114
<dl>
 
115
<dt>Returns:</dt>
 
116
<dd>
 
117
</dd>
 
118
</dl><br />
 
119
</dd>
 
120
</dl>
 
121
<h2><a id='PIL.ImageWin.HDC-class' name='PIL.ImageWin.HDC-class'>The HDC Class</a></h2>
 
122
<dl>
 
123
<dt><b>HDC(dc)</b> (class) [<a href='#PIL.ImageWin.HDC-class'>#</a>]</dt>
 
124
<dd>
 
125
<p>The <b>ImageWin</b> module contains support to create and display
 
126
images under Windows 95/98, NT, 2000 and later.
 
127
</p></dd>
 
128
</dl>
 
129
<h2><a id='PIL.ImageWin.ImageWindow-class' name='PIL.ImageWin.ImageWindow-class'>The ImageWindow Class</a></h2>
 
130
<dl>
 
131
<dt><b>ImageWindow(image, title=&quot;PIL&quot;)</b> (class) [<a href='#PIL.ImageWin.ImageWindow-class'>#</a>]</dt>
 
132
<dd>
 
133
</dd>
 
134
</dl>
 
135
<h2><a id='PIL.ImageWin.Window-class' name='PIL.ImageWin.Window-class'>The Window Class</a></h2>
 
136
<dl>
 
137
<dt><b>Window(title=&quot;PIL&quot;, width=None, height=None)</b> (class) [<a href='#PIL.ImageWin.Window-class'>#</a>]</dt>
 
138
<dd>
 
139
</dd>
 
140
</dl>
 
141
</body></html>