Re: [Tutor] help for building tui?

2008-07-04 Thread Wolfram Kraus
Am 04.07.2008 08:33, Dong Li schrieb: Hi, everyone If I want to create a text user interface for my application, is there any existed module to facilitate such building? Yes, there is curses: http://docs.python.org/lib/module-curses.html http://www.amk.ca/python/howto/curses/ HTH, Wolfram

Re: [Tutor] help for building tui?

2008-07-04 Thread Alan Gauld
Dong Li [EMAIL PROTECTED] wrote If I want to create a text user interface for my application, is there any existed module to facilitate such building? Yes, Python includes the cmd module which is a framework for a menu driven command line. It is very like the help system that Python uses

[Tutor] Init Scripts

2008-07-04 Thread Stephen Nelson-Smith
Hello, I've been wrestling with some badly written init scripts, and picking my way through the redhat init script system. I'm getting to the point of thinking I could do this sort of thing in Python just as effectively. Are there any pointers available? Eg libraries that give process

[Tutor] Where is this tr function?

2008-07-04 Thread Kelie
Hello, I see a lots tr('some string') in codes, especially the ones related to wxPython. Where is this tr function defined and what does it do? To make the argument a raw string? When I type print tr('some string') in PyShell that comes with wxPython, no error. But if I type that line in a .py

Re: [Tutor] Where is this tr function?

2008-07-04 Thread Kent Johnson
On Fri, Jul 4, 2008 at 6:25 AM, Kelie [EMAIL PROTECTED] wrote: Hello, I see a lots tr('some string') in codes, especially the ones related to wxPython. Where is this tr function defined and what does it do? To make the argument a raw string? tr() is not a standard part of Python. My guess is

[Tutor] open-file GUI

2008-07-04 Thread Eli Brosh
Hello, I am starting to use Python+NumPy+SciPy+Matplotlib as a substitute to MATLAB. I need a simple GUI that can help me to open files and save file i.e. something similar to uigetfile in MATLAB. Is there a simple script that opens a window with a possibility to browse through the file system

[Tutor] tic tac toe

2008-07-04 Thread Akanskha Kumar
how can i make tic tac toe game using python programing.  ___ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor

[Tutor] file object in memory

2008-07-04 Thread Monika Jisswel
Hi everyone, In my program I have this code : self.run_cmd_0 = subprocess.Popen(self.cmd_0, stdout = subprocess.PIPE, shell = True) #(1) self.run_cmd_1 = subprocess.Popen(self.TOCOL, stdin = self.run_cmd_0.stdout, stdout = subprocess.PIPE, shell = True)#(2) self.result_0 =

Re: [Tutor] open-file GUI

2008-07-04 Thread Alan Gauld
Eli Brosh [EMAIL PROTECTED] wrote I need a simple GUI that can help me to open files and save file i.e. something similar to uigetfile in MATLAB. Google for easygui I think it will do what you want. Otherwise any GUI toolkit will have similar dialiogs but will require that you write a

Re: [Tutor] tic tac toe

2008-07-04 Thread Alan Gauld
Akanskha Kumar [EMAIL PROTECTED] wrote how can i make tic tac toe game using python programing. Do you know how to program at all? How much Python do you know? Is this a homework assignment? We need to know of these before we can give you the best answer. If you are experienced uin

Re: [Tutor] open-file GUI

2008-07-04 Thread FT
Hi! My demo is from wspython. Hello, I am starting to use Python+NumPy+SciPy+Matplotlib as a substitute to MATLAB. I need a simple GUI that can help me to open files and save file i.e. something similar to uigetfile in MATLAB. Is there a simple script that opens a window with a

Re: [Tutor] open-file GUI

2008-07-04 Thread Monika Jisswel
Go for wxPython, they have a pretty good tutorial on thier website ( wxpython.org) If you can use Python_Numpy_Scipy_Matplotlib then I can assure you that you will learn wxpython in a matter of minutes. 2008/7/4 Eli Brosh [EMAIL PROTECTED]: Hello, I am starting to use

Re: [Tutor] tic tac toe

2008-07-04 Thread bhaaluu
On Fri, Jul 4, 2008 at 12:14 PM, Akanskha Kumar [EMAIL PROTECTED] wrote: how can i make tic tac toe game using python programing. There is an excellent tic-tac-toe tutorial in Michael Dawson's book, Python Programming for the Absolute Beginner Second Edition (ISBN-13: 978-1-59863-112-8).Chapter

Re: [Tutor] Init Scripts

2008-07-04 Thread Monika Jisswel
IMHO the Linux OS itself relays heavily on python in some way or the other, but as far as the boot process is concerned I think you should consider the fact that it was engeneered by very smart poeple, very security aware poeple, so you will have to give a really good ALTERNATIVE to thier

Re: [Tutor] open-file GUI

2008-07-04 Thread FT
Hi! My demo is from wspython. Hello, I am starting to use Python+NumPy+SciPy+Matplotlib as a substitute to MATLAB. I need a simple GUI that can help me to open files and save file i.e. something similar to uigetfile in MATLAB. Is there a simple script that opens a window with a

Re: [Tutor] open-file GUI

2008-07-04 Thread FT
Hi! My demo is from wspython. The Hebrew window messed up my reading and now I have included the imports and the initial assignment. You can place them in caps for global vars, but place them inside a class so they are self...calls. Hello, I am starting to use Python+NumPy+SciPy+Matplotlib

Re: [Tutor] open-file GUI

2008-07-04 Thread Eli Brosh
Many thanks for the tutor mailing-list members for their replies, The EasyGui is just what I was looking for. Regards Eli Brosh ___ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor

[Tutor] graphs diagrams in python

2008-07-04 Thread Monika Jisswel
Hi Again, What is the best library for drawing graphs diagrams to ilustrate some statistics ? ___ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tutor

Re: [Tutor] graphs diagrams in python

2008-07-04 Thread Patrick
Hey Monika How about Matplotlib AKA Pylab? http://matplotlib.sourceforge.net/ -Patrick Monika Jisswel wrote: Hi Again, What is the best library for drawing graphs diagrams to ilustrate some statistics ?

Re: [Tutor] pygame event.type == QUIT

2008-07-04 Thread Nick Marmion
I am learning pygame using begining game development w/ python and pygame. I am doing 'Hello World Redux #!/usr/bin/env python background_image_filename = 'sushiplate.jpg'mouse_image_filename = 'fugu.png' import pygamefrom pygame.locals import *from sys import exit pygame.init() screen =

Re: [Tutor] directory traversal help

2008-07-04 Thread Monika Jisswel
the fact that it fails shoul be due to some windows restriction about trash some hidden files, to bypass that you can add a filter in here def walk(dir): for name in os.listdir(dir): #the following line is the filter if name != 'Trash can' or name != 'some hidden directory name':

Re: [Tutor] Where is this tr function?

2008-07-04 Thread Kelie
Alan Gauld alan.gauld at btinternet.com writes: To the OP: Are you importing any other modules? Is this a specific application's code you are looking at? Thanks Alan. You're right. I was reading Ulipad's source code. ___ Tutor maillist -

Re: [Tutor] file object in memory

2008-07-04 Thread bob gailer
Monika Jisswel wrote: Hi everyone, In my program I have this code : self.run_cmd_0 = subprocess.Popen(self.cmd_0, stdout = subprocess.PIPE, shell = True) #(1) self.run_cmd_1 = subprocess.Popen(self.TOCOL, stdin = self.run_cmd_0.stdout, stdout = subprocess.PIPE, shell =

Re: [Tutor] file object in memory

2008-07-04 Thread Monika Jisswel
You know bob, you are very clever, I have used RAM disk for realtime recording of audio before but it never occured to me to use it for light jobs like this one, I just compeletely ignored it as an option by the way this openes a lot of doors for many of my other programs. but wouldn't it be

Re: [Tutor] file object in memory

2008-07-04 Thread bob gailer
Monika Jisswel wrote: You know bob, you are very clever Yes. I've observed that before. , I have used RAM disk for realtime recording of audio before but it never occured to me to use it for light jobs like this one, I just compeletely ignored it as an option by the way this openes a lot of