[Tutor] Installing graphics module on python 2.7

2012-05-17 Thread Emeka
Hello All, I would like to install graphics. So that I can do this: import graphics Please help me. I tried "pip install graphics" nothing came out of it. Regards, \Janus -- *Satajanus Nig. Ltd * ___ Tutor maillist - Tutor@python.org To unsubsc

[Tutor] Help with update_wrapper

2011-12-09 Thread Emeka
Hello All, Could someone explain " functools.update_wrapper" with simple examples? Regards, Janus -- *Satajanus Nig. Ltd * ___ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: http://mail.python.org/mailman/listinf

Re: [Tutor] Please review my code

2011-09-16 Thread Emeka
Hello Alan, My bad, I have added the missing folder. To all, please make out time and review my code. I would like to have your comments. https://github.com/janus/Text-Twist Regards, emeka On Fri, Sep 16, 2011 at 1:20 PM, R. Alan Monroe wrote: > > > It was only tested on a Windows B

Re: [Tutor] Strange zip syntax

2011-09-16 Thread Emeka
iBrett, iter On Fri, Sep 16, 2011 at 3:35 AM, Brett Ritter wrote: > I ran into this article ( > http://blog.adku.com/2011/09/hodgepodge-of-python.html ) and found > myself temporarily stymied by one line it in: > > zip(*[iter(a)]*2) > > Used like this: > > >>> a = ['a','1','b','2','c','3'] > >>

[Tutor] Please review my code

2011-09-15 Thread Emeka
https://github.com/janus/Text-Twist I need you comments. -- *Regards, Emeka * ___ Tutor maillist - Tutor@python.org To unsubscribe or change subscription options: http://mail.python.org/mailman/listinfo/tutor

Re: [Tutor] Using type

2011-08-12 Thread Emeka
Chris, I was just fooling around and I wanted to do something for myself before going to bed the other night. func myflatten will turn say [ 34 [90] [12] 1] into [34 90 12 1]. Just like its name sounds. Emeka On Fri, Aug 12, 2011 at 7:03 PM, Christopher King wrote: >

[Tutor] Using type

2011-08-11 Thread Emeka
Hello All, I need help here, type(item) == [].__class__:. What is the idiomatic way of doing it? def myflatten(my_data): gut = [] for item in my_data: if type(item) == [].__class__: gut = gut + myflatten ( item) else: gut.append(item) return gut print myfl

Re: [Tutor] Python scripts into executable Windows programss

2011-08-03 Thread Emeka
Sumod, Thanks so much ... I was also looking for something like Inno. Emeka On Wed, Aug 3, 2011 at 8:04 AM, wrote: > For a seamless application development experience, you may want to consider > these steps. > 1. Use Eclipse-pydev to write your scripts > 2. Use py2exe to

[Tutor] Python scripts into executable Windows programss

2011-08-02 Thread Emeka
Hello All, I would want to convert Python scripts into executable Windows programs. I have already checked out py2exe, it seems like they support only Python 2.5. Mine is Python 2.7.7. Could anyone here help me out on this issue? ? Regards, Emeka -- *Satajanus Nig. Ltd

Re: [Tutor] How to make tkMessage function to have duration

2011-07-30 Thread Emeka
Steven,, Thanks! Emeka On Sat, Jul 30, 2011 at 12:25 PM, Steven D'Aprano wrote: > Emeka wrote: > >> Hello All, >> >> Say I have the below(code), I would want the message to last say 30 >> seconds and afterwards disappear. I won't want the user to

[Tutor] How to make tkMessage function to have duration

2011-07-30 Thread Emeka
Hello All, Say I have the below(code), I would want the message to last say 30 seconds and afterwards disappear. I won't want the user to be the one to enable it to disappear. Basically, what I want is to be able to show the user some message , and after some seconds, the message goes away

[Tutor] Python Tkinter event activated with time

2011-07-27 Thread Emeka
Hello All, I am putting together a small game, and I would want to enable my callback function using time passed. How to do something like this with Tkinter event. from time import time ftime = time() if ftime - time() > 2000: dosomething -- *Satajanus Nig. Ltd *

Re: [Tutor] Question related to Tkinker

2011-07-24 Thread Emeka
for i,cha in enumerate(wordi): label = Label(root, image=photoimage, text = cha) label.grid(row=1, column=i, columnspan=1, rowspan=1,sticky=W+E+N+S, padx=0, pady=1) label1 = Label(root, image=IMAGE) I used grid ... Though I used labels, I was dealing only on character level. So for

[Tutor] Question related to Tkinker

2011-07-23 Thread Emeka
Hello All, I am putting up a simple game .. the game is about manipulation. If the gets through level one ... I have to change the word with another... Am I going to destroy level window and build level 2 or is there a way to just adjust the word (I used labels) Regards, Janus -- *Satajanus N

Re: [Tutor] Tkinter's Label

2011-02-16 Thread Emeka
Alan, Thanks so much. Is the below the standard way of checking the content of Label in "if" statement? root = Tk() label = Label(root , text = "pure") if label["pure"] == "pure": Regards, Emeka On Wed, Feb 16, 2011 at 10:13 AM, Alan Gauld wro

[Tutor] Tkinter's Label

2011-02-16 Thread Emeka
Hello All, I have the following; root = Tk() label = Label(root , text = "pure") in order to change "text" , I could do the this label[text] = "pool" I do know that there is something like this.. label.config(text = "pool")