[Tutor] (no subject)

2006-11-24 Thread Gardner, Dean
Hi I was wondering if anyone knew how to control the desktop resolution via python. I have investigated pygame which seems to allow you acces to video settings but it appears to only influence a window rather than the system (I may be totally wrong about this though) What I ideally need is a

[Tutor] a question about indentation

2006-11-24 Thread arildna
Hi, I'm fairly new to python, and trying to get used to the indentation. I just encountered my first problem with it. I wrote the following code: for ord in f_ord: if not ordliste.has_key(ord) : ordliste[ord] = {} for word in e_ord: if ordliste[ord

Re: [Tutor] (no subject)

2006-11-24 Thread Tim Golden
[Gardner, Dean] | I was wondering if anyone knew how to control the desktop | resolution via python. I have investigated pygame which seems | to allow you acces to video settings but it appears to only | influence a window rather than the system (I may be totally | wrong about this though) |

[Tutor] cursor.description

2006-11-24 Thread Antonios Katsikadamos
Hi all. I am new to python and i am trying to execute queries from postgres db. I have a question. What is exactly the operation of cursor.description? Kind regards, Antonios - Sponsored Link Mortgage rates near 39yr lows. $420,000

[Tutor] Having trouble with " table % listTable.values() " line

2006-11-24 Thread Mihai Iacob
Hello, This is my first post so if i make any kind of mistakes take it easy on me :). I don't know how to explain clearly what is the problem but i'll try. table = """ %s |%s |%s --- %s |%s |%s --- %s |%s |%s """ listTable is a dictionary. listTable = {0 :'X', 1 :' ' , 2 :' '

Re: [Tutor] help with Tkinter, please

2006-11-24 Thread Michael Lange
On Thu, 23 Nov 2006 13:08:40 -0800 Dick Moores <[EMAIL PROTECTED]> wrote: > >def compute_fact(): > > value = int(entry_get()) Ooops, sorry for the typo, of course it is entry.get() not entry_get() Michael ___ Tutor maillist - Tutor@python.org ht

Re: [Tutor] How to make the label left justified in a frame

2006-11-24 Thread Michael Lange
-- Forwarded to tutor list -- On Thu, 23 Nov 2006 16:25:41 + "Asrarahmed Kadri" <[EMAIL PROTECTED]> wrote: > Sorry to bother you, > But can u please explain what does grid_columnconfigure() do.. > > The best place for questions like this are usually the Tk man pages :) Once you get used to

Re: [Tutor] a question about indentation

2006-11-24 Thread Christopher Arndt
[EMAIL PROTECTED] schrieb: > I suppose there is a good way to do indent whole blocks like this, but I > haven't found out what it is. Could anybody help me out? Yes, get a good source code editor that has the ability to (de)indent whole blocks of code with one keystroke. This is a must-have for w

Re: [Tutor] a question about indentation

2006-11-24 Thread arildna
Christopher Arndt wrote: > [EMAIL PROTECTED] schrieb: > >> I suppose there is a good way to do indent whole blocks like this, but I >> haven't found out what it is. Could anybody help me out? >> > > Yes, get a good source code editor that has the ability to (de)indent whole > blocks of cod

Re: [Tutor] Having trouble with " table % listTable.values() " line

2006-11-24 Thread Jason Massey
So you want to convert a list into a tuple. Here ya go, using your example of the table setup: raw_table =""" %s | %s | %s -- %s | %s | %s -- %s | %s | %s """ from random import choice x_o = [choice(['x','o']) for i in range(9)] x_o ['x', 'x', 'x', 'x', 'o', 'o', 'o',

Re: [Tutor] (no subject)

2006-11-24 Thread Tim Golden
[Gardner, Dean] | I was wondering if anyone knew how to control the desktop | resolution via python. | | What I ideally need is a small app that will swap resolution | between 1600*1200 and 1280*1024 OK. Had a bit of time to look into this. The following code snippet is (hopefully) fairly se

[Tutor] One question......

2006-11-24 Thread Asrarahmed Kadri
Hi Folks, I am constructing a bar-chart using Tkinter. The function takes a list 'data' and draws horizontal bar for each value. Now what I want is the the canvas widget should be able to handle variable number of data-items. I cannot figure out how to do that, because I have hard coded the leng

Re: [Tutor] cursor.description

2006-11-24 Thread Tim Golden
[Antonios Katsikadamos] | Hi all. I am new to python and i am trying to execute queries | from postgres db. I have a question. | | What is exactly the operation of cursor.description? Ultimately, the doc you want to look at is this: http://www.python.org/dev/peps/pep-0249/ Here's the relevan

Re: [Tutor] a question about indentation

2006-11-24 Thread Danny Yoo
> I'm fairly new to python, and trying to get used to the indentation. I > just encountered my first problem with it. I wrote the following code: > > for ord in f_ord: >if not ordliste.has_key(ord) : >ordliste[ord] = {} >for word in e_ord: >if ordliste[ord].h

Re: [Tutor] One question......

2006-11-24 Thread Luke Paireepinart
Asrarahmed Kadri wrote: > > > Hi Folks, > > I am constructing a bar-chart using Tkinter. The function takes a list > 'data' and draws horizontal bar for each value. > Now what I want is the the canvas widget should be able to handle > variable number of data-items. I cannot figure out how to

Re: [Tutor] A Million Sevens

2006-11-24 Thread Andreas Kostyrka
* Chris Hengge <[EMAIL PROTECTED]> [061119 00:44]: > That must be part of Pythons shiny ability of dynamic data types? Must be a > messy operation to change data-types like that.. I think I'll just do my > best to work with the right data-types the whole time ;D Well, huge miss understanding: a =

[Tutor] Please suggest a python book

2006-11-24 Thread Narasimha
Hi! Friends, I am new to python. I have a vacation of 15 days. Please suggest me a python book (or a website). I already know C language. I have heard much about Python. ___ Tutor maillist - Tutor@python.org http://mail.python.org/mailman/listinfo/tu

Re: [Tutor] Please suggest a python book

2006-11-24 Thread hacktavist
you could look into www.diveintopython.com it is an online book for people who are already versed in a prior language. Ray On Sat, 25 Nov 2006, Narasimha wrote: > Hi! Friends, > > I am new to python. I have a vacation of 15 days. Please suggest me a python > book (or a website). > > I already kn

[Tutor] (no subject)

2006-11-24 Thread Narasimha
Is it possible to create stand-alone programs(like exe files in dos and a.out files in UNIX) with Python? If possible please tell me how to make them. I am planning to distribute my python code to friends. They don't have python interpreters nor they know how to use them. Please suggest a solut

Re: [Tutor] Please suggest a python book

2006-11-24 Thread Jalil
If you already know C you should be fine with python ref book. *Python Essential Reference (2nd Edition)* On 11/24/06, Narasimha <[EMAIL PROTECTED]> wrote: Hi! Friends, I am new to python. I have a vacation of 15 days. Please suggest me a python book (or a website). I already know C lang

[Tutor] Auto-hyperlinking ignoring html tags

2006-11-24 Thread anil maran
Hey I m trying to auto-hyperlink urls, i found libcia.web.Regextransform.py but the problem is it applies auto hyperlink on html tags for eg < img src = " http://www.google.com/a.gif " > becomes *gta* img src=" < a href= "http://www.google.com/a.gif " *lt is there any way to auto-hyperlink on te

Re: [Tutor] (no subject)

2006-11-24 Thread Luke Paireepinart
Narasimha wrote: > > Is it possible to create stand-alone programs(like exe files in dos > and a.out files in UNIX) with Python? > > If possible please tell me how to make them. > > I am planning to distribute my python code to friends. > > They don’t have python interpreters nor they know how to