mirror of
https://github.com/python-pillow/Pillow.git
synced 2025-08-27 07:34:46 +03:00
Merge d7d7e63e01
into 3d8035bf31
This commit is contained in:
commit
4f80a9105e
|
@ -122,6 +122,17 @@ class PILDriver(object):
|
||||||
color = int(self.do_pop())
|
color = int(self.do_pop())
|
||||||
self.push(Image.new("L", (xsize, ysize), color))
|
self.push(Image.new("L", (xsize, ysize), color))
|
||||||
|
|
||||||
|
def do_new2(self):
|
||||||
|
"""usage: new2 <string:mode> <int:xsize> <int:ysize> <int:color>:
|
||||||
|
|
||||||
|
Create and push a image of given mode, size and color.
|
||||||
|
"""
|
||||||
|
mode = int(self.do_pop())
|
||||||
|
xsize = int(self.do_pop())
|
||||||
|
ysize = int(self.do_pop())
|
||||||
|
color = int(self.do_pop())
|
||||||
|
self.push(Image.new(mode, (xsize, ysize), color))
|
||||||
|
|
||||||
def do_open(self):
|
def do_open(self):
|
||||||
"""usage: open <string:filename>
|
"""usage: open <string:filename>
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue
Block a user