pass a component a StringIO.. possible?
"Alec Bennett" <[email protected]>
| Newsgroups | gmane.comp.python.pythoncard |
|---|---|
| Message-ID | <[email protected]> |
I'm trying to avoid saving a jpeg to a temp file before loading it into a Pythoncard gui component. Something like: import Image filename = "whatever.jpg" im = Image.open(filename) im2 = im.resize( [512, 384] ) self.viewerWindow.components.pic1.file = im2 The above errors out of course, because the component is expecting a filename. I'm wondering if anyone knows how to do this without having to save im2 to a temp file? I gather StringIO can do this, but I can't figure out how. Thanks for any help. ------------------------------------------------------------------------- Take Surveys. Earn Cash. Influence the Future of IT Join SourceForge.net's Techsay panel and you'll get the chance to share your opinions on IT & business topics through brief surveys-and earn cash http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV _______________________________________________ Pythoncard-users mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/pythoncard-users