944,060 Members | Top Members by Rank

Ad:
  • Python Discussion Thread
  • Marked Solved
  • Views: 1385
  • Python RSS
Nov 28th, 2006
0

GIFs in a Dict

Expand Post »
Is it possible to use files such as GIF files as a value in a Python Dict; that is, is it possible to use GIF files in a Dict and access them directly, rendering them to the screen via Tkinter.

I have a group of GIF files I plan to use in a GUI-based Python program. I will need to access these GIFs based on the results of a RNG. At this point, using a dict seems the most promising considering the use of the "key", but I am not sure.

What is the best way in Python to group image files into a group, an array of images to possibly use within a program?

Regards, and TY in advance.

sharky_machine
Similar Threads
Featured Poster
Reputation Points: 105
Solved Threads: 1
Posting Maven
mattyd is offline Offline
2,582 posts
since Oct 2006
Nov 28th, 2006
0

Re: GIFs in a Dict

Take a look at:
http://www.daniweb.com/techtalkforum...257347-78.html
that Tkinter cardgame example uses a card_name:image_object dictionary.
Moderator
Reputation Points: 1333
Solved Threads: 1403
DaniWeb's Hypocrite
vegaseat is offline Offline
5,792 posts
since Oct 2004

This thread is solved

Either the thread starter or a moderator has marked this thread as solved. You can most likely trust the responses and answers given. There is most likely no reason for any further responses to be posted here. If you have a related question, please start a new thread in this forum instead.

This thread is more than three months old

No one has posted to this discussion for at least three months. Please let old threads die and do not reply to them unless you feel you have something new and valuable to contribute that absolutely must be added to make the discussion complete. Otherwise, please start a new thread in this forum instead.
Message:
Previous Thread in Python Forum Timeline: Best GUI toolkit?
Next Thread in Python Forum Timeline: help with converting a python programto java in eclipsed IDE





About Us | Contact Us | Advertise | Acceptable Use Policy
Forum Index | Build Custom RSS Feed


Follow us on Twitter


© 2011 DaniWeb® LLC