Path: csiph.com!usenet.pasdenom.info!weretis.net!feeder4.news.weretis.net!rt.uk.eu.org!newsfeed.xs4all.nl!newsfeed3.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail Return-Path: X-Original-To: python-list@python.org Delivered-To: python-list@mail.python.org X-Spam-Status: OK 0.000 X-Spam-Evidence: '*H*': 1.00; '*S*': 0.00; 'messages.': 0.05; 'tkinter': 0.07; '__init__': 0.09; 'pavel': 0.09; 'pil': 0.09; 'received:80.91': 0.09; 'received:80.91.229': 0.09; 'received:gmane.org': 0.09; 'received:list': 0.09; 'jan': 0.12; 'windows': 0.15; 'effect.': 0.16; 'png': 0.16; 'received:80.91.229.3': 0.16; 'received:plane.gmane.org': 0.16; 'reedy': 0.16; 'subject:PIL': 0.16; 'subject:fails': 0.16; 'subject:image': 0.16; 'fix': 0.17; 'wrote:': 0.18; 'code.': 0.18; 'library': 0.18; 'trying': 0.19; 'load': 0.23; 'this?': 0.23; 'header:User-Agent:1': 0.23; 'error': 0.23; 'skip:i 40': 0.24; 'fine': 0.24; 'file.': 0.24; 'mention': 0.26; 'skip:" 30': 0.26; 'header:X-Complaints-To:1': 0.27; 'header:In-Reply-To:1': 0.27; 'installed': 0.27; 'subject:) ': 0.29; 'getting': 0.31; "skip:' 10": 0.31; 'file': 0.32; 'text': 0.33; 'linux': 0.33; 'running': 0.33; 'could': 0.34; 'subject:with': 0.35; 'display': 0.35; 'but': 0.35; 'skip:" 50': 0.36; 'hi,': 0.36; 'should': 0.36; 'button': 0.38; 'question,': 0.38; 'to:addr:python-list': 0.38; 'pm,': 0.38; 'to:addr:python.org': 0.39; 'received:org': 0.40; 'how': 0.40; 'received:173': 0.61; 'here': 0.66; 'received:fios.verizon.net': 0.84 X-Injected-Via-Gmane: http://gmane.org/ To: python-list@python.org From: Terry Reedy Subject: Re: PIL(Pillow) fails with PNG image Date: Thu, 05 Dec 2013 20:14:25 -0500 References: <52A0E163.5030702@gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit X-Gmane-NNTP-Posting-Host: pool-173-75-254-207.phlapa.fios.verizon.net User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:24.0) Gecko/20100101 Thunderbird/24.1.1 In-Reply-To: <52A0E163.5030702@gmail.com> X-BeenThere: python-list@python.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: General discussion list for the Python programming language List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Newsgroups: comp.lang.python Message-ID: Lines: 34 NNTP-Posting-Host: 2001:888:2000:d::a6 X-Trace: 1386292478 news.xs4all.nl 2874 [2001:888:2000:d::a6]:48944 X-Complaints-To: abuse@xs4all.nl Xref: csiph.com comp.lang.python:61108 I cannot answer your question, but wanted to mention that you should send text only and not include an html copy of messages. On 12/5/2013 3:26 PM, tastyminerals wrote: > Hi, I am getting an error when trying to use Pillow library to display > image PNG on a Tkinter Button widget. Here is my code. > > |image= Image.open(os.path.join('icons','bulb.png')) # using PIL for png images > self.correctGuessImage= ImageTk.PhotoImage(image) > > |>>> > |File "/home/user/Documents/temp.py", line222, in drawButtons > self.correctGuessImage= ImageTk.PhotoImage(image) > File "/usr/lib/python2.7/dist-packages/PIL/ImageTk.py", line121, in __init__ > self.paste(image) > File "/usr/lib/python2.7/dist-packages/PIL/ImageTk.py", line171, in paste > im.load() > File "/usr/lib/python2.7/dist-packages/PIL/ImageFile.py", line192, in load > d= Image._getdecoder(self.mode, d, a, self.decoderconfig) > AttributeError: 'module' object has no attribute'_getdecoder'||| > > While working fine under windows 7x64 it fails to work on Linux Mint > x64. I am getting this error running the same file. I installed > everything I could find with 'python','png' and 'tk' from the reps but > no effect. Any ideas why is this happening and how to fix this? > > Pavel > > -- Terry Jan Reedy