Java or C++?

2008-04-13 Thread s0suk3
Hello, I was hoping to get some opinions on a subject. I've been programming Python for almost two years now. Recently I learned Perl, but frankly I'm not very comfortable with it. Now I want to move on two either Java or C++, but I'm not sure which. Which one do you think is a softer transition fo

Re: 有中国人乎?

2008-04-13 Thread Penny Y.
Steve Holden 写道: > 但学会从未是立即, 和将需要一点时间。 > What do you mean? If I understand you correctly, maybe it should be, 学习python不可一日而成,需要循序渐进. Am I right? -- http://mail.python.org/mailman/listinfo/python-list

mod_python

2008-04-13 Thread Penny Y.
Hello, I want to rewrite a request url under apache2.0 based on its special header, like, the "Accept-Encoding:" one. With C I think I can do it, but since I get begin with python,so I ask that can I do it under mod_python? what's the guide? Thanks. -- http://mail.python.org/mailman/listinfo/

Re: how to remove \n in the list

2008-04-13 Thread Kam-Hung Soh
On Apr 14, 2:58 pm, "Gabriel Genellina" <[EMAIL PROTECTED]> wrote: > En Mon, 14 Apr 2008 01:41:55 -0300, reetesh nigam > <[EMAIL PROTECTED]> escribió: > > > hi, > > l=['5\n', '2\n', '7\n', '3\n', '6\n'] > > > how to remove \n from the given list > > l is is very poor name... I'll use lines instead:

Re: urllib working differently when run from crontab

2008-04-13 Thread Jonathan Gardner
On Apr 13, 8:50 pm, VictorMiller <[EMAIL PROTECTED]> wrote: > I've written a python script which, using urllib, and urllib2 will > fetch a number of files that that I'm interested in from various > websites (they're updated everyday).  When I run the script from my > command line everything works a

Re: how to remove \n in the list

2008-04-13 Thread Gabriel Genellina
En Mon, 14 Apr 2008 01:41:55 -0300, reetesh nigam <[EMAIL PROTECTED]> escribió: > hi, > l=['5\n', '2\n', '7\n', '3\n', '6\n'] > > how to remove \n from the given list l is is very poor name... I'll use lines instead: lines[:] = [line.rstrip('\n') for line in lines] -- Gabriel Genellina --

Re: Host: header

2008-04-13 Thread Gabriel Genellina
En Mon, 14 Apr 2008 01:04:40 -0300, Penny Y. <[EMAIL PROTECTED]> escribió: > I have a problem with a request url,for example, I have the code below, > > import httplib > > try: > conn = httplib.HTTPConnection("192.168.1.1") > conn.request("GET", "/") > r1 = conn.getresponse() > if

how to remove \n in the list

2008-04-13 Thread reetesh nigam
hi, l=['5\n', '2\n', '7\n', '3\n', '6\n'] how to remove \n from the given list -- http://mail.python.org/mailman/listinfo/python-list

Re: Recommendation for Web Framework

2008-04-13 Thread Daniel Fetchinson
On Sun, Apr 13, 2008 at 12:18 AM, James West <[EMAIL PROTECTED]> wrote: > Let me explain my situation a bit. > > I've been contracted to develop an ecommerce site. It's nothing too > huge but requires a lot of custom development that's not typical for > your run of the mill webstore. I've got abou

ANN: Tobu-0.5.0

2008-04-13 Thread AK
Tobu 0.5.0 is now available. Tobu is something between a freeform information organizer and a database. Changes since last version were: Added multiple undo/redo, toolbar icon for list recent; Fixed loading a previously selected item from listing, disabled closing of last remaining tab, fixed

Re: How is GUI programming in Python?

2008-04-13 Thread Gabriel Genellina
En Sat, 12 Apr 2008 15:38:22 -0300, Michel Bouwmans <[EMAIL PROTECTED]> escribió: > Gabriel Genellina wrote: >> En Fri, 11 Apr 2008 11:31:42 -0300, Michel Bouwmans >> <[EMAIL PROTECTED]> escribió: >>> Gabriel Genellina wrote: >> Another annoying thing with the Qt license is that you have >>>

Host: header

2008-04-13 Thread Penny Y.
Hello, I have a problem with a request url,for example, I have the code below, import httplib try: conn = httplib.HTTPConnection("192.168.1.1") conn.request("GET", "/") r1 = conn.getresponse() if r1.status == 200: result = 0 except Exception: result = -1 but the ser

Re: about the ';'

2008-04-13 Thread Terry Reedy
"Penny Y." <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] |I saw many python programmers add a ';' at the end of each line. | As good style, should or should not we do coding with that? NOO... Read PEP8 for one style guide (for new stdlib code). -- http://mail.python.or

urllib working differently when run from crontab

2008-04-13 Thread VictorMiller
I've written a python script which, using urllib, and urllib2 will fetch a number of files that that I'm interested in from various websites (they're updated everyday). When I run the script from my command line everything works as intended. However, when the script is run from crontab every sing

Re: about the ';'

2008-04-13 Thread Dan Bishop
On Apr 13, 10:33 pm, "Penny Y." <[EMAIL PROTECTED]> wrote: > I saw many python programmers add a ';' at the end of each line. > As good style, should or should not we do coding with that? That's just because their fingers are stuck in C mode. The recommended style is NOT to use unnecessary semico

Re: Best way to update a settings file?

2008-04-13 Thread John Nagle
John Salerno wrote: > I'm thinking about writing a small script that will update an xml file > with whatever game settings the user enters. I imagine that the user > will have a single-screen GUI application with several different > settings, like this: > > CROSSHAIRS ON > LOCATION ON > H

about the ';'

2008-04-13 Thread Penny Y.
I saw many python programmers add a ';' at the end of each line. As good style, should or should not we do coding with that? Thanks. -- http://mail.python.org/mailman/listinfo/python-list

Best way to update a settings file?

2008-04-13 Thread John Salerno
I'm thinking about writing a small script that will update an xml file with whatever game settings the user enters. I imagine that the user will have a single-screen GUI application with several different settings, like this: CROSSHAIRS ON LOCATION ON HEALTHBAROFF etc. These sett

Re: Tkinter, image not appearing in function but without function

2008-04-13 Thread 7stud
On Apr 13, 11:12 am, Marc 'BlackJack' Rintsch <[EMAIL PROTECTED]> wrote: > On Sun, 13 Apr 2008 08:57:29 -0700, skanemupp wrote: > > why is the first program not working? when i click the screen the map > > is not appearing. > > > the second program works. > > > from Tkinter import * > > > master =

Remove my mail, please !

2008-04-13 Thread Alderos Martins
Please, remove my mail in to python list. I don´t receive mails. Thank´s. Alderos. -- http://mail.python.org/mailman/listinfo/python-list

Re: email module windows and suse

2008-04-13 Thread Lev Elbert
On Apr 13, 3:55 pm, Tim Roberts <[EMAIL PROTECTED]> wrote: > Lev Elbert <[EMAIL PROTECTED]> wrote: > > >I have to make a custom email module, based on the standard one. The > >custom module has to be able to work with extremely large mails (1GB > >+), having memory "footprint" much smaller. > > The

Re: py2exe, program has stoped working!?

2008-04-13 Thread John Machin
On Apr 13, 11:52 pm, [EMAIL PROTECTED] wrote: > so i used py2exe and i have the build and the dist-folders. > > in the distfolder there is a Calculator.exe file. > > when i run it it just says "Calculator.exe has stopped working" in a > popup but the program itself never shows up. Is it a console

Re: Controlling copying and pickling of objects written in C

2008-04-13 Thread Adam Bregenzer
On Sun, 13 Apr 2008 16:49:51 -0300, Gabriel Genellina wrote: > En Sun, 13 Apr 2008 01:57:42 -0300, Adam Bregenzer > <[EMAIL PROTECTED]> escribió: > >> I am writing an extension and have "hidden" data included in the >> object's C structure that is not visible to python. I am unsure what >> would

Re: email module windows and suse

2008-04-13 Thread Tim Roberts
Lev Elbert <[EMAIL PROTECTED]> wrote: > >I have to make a custom email module, based on the standard one. The >custom module has to be able to work with extremely large mails (1GB >+), having memory "footprint" much smaller. Then you have a design problem right from the start. It is extremely rar

Re: urllib2 Basic authentication, what am I doing wrong?

2008-04-13 Thread Michel Bouwmans
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Max Erickson wrote: > On Apr 13, 2:11 pm, Michel Bouwmans <[EMAIL PROTECTED]> wrote: > >> Using this nice class (adapted to urllib2) as a basehandler I see that no >> Authentication-header is being send >> out:http://aspn.activestate.com/ASPN/Cookbo

A "Fixed" Tk Text widget

2008-04-13 Thread Ron Provost
I have just completed and uploaded to the Tkinter wiki a "Fixed" version of the Tk Text widget called EnhancedText. This new widget (subclassed from Text) is intended to fix some of the quirks of the Text widget involving cursor movement. Namely, in Text, the cursor moves by paragraph rather t

Re: urllib2 Basic authentication, what am I doing wrong?

2008-04-13 Thread 7stud
Michel Bouwmans wrote: > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA1 > > Hey everybody, > > I'm having a little problem with urllib2 and Basic HTTP authentication. > > I have the following code: > > auth = urllib2.HTTPPasswordMgrWithDefaultRealm() > auth.add_password(None, 'https://webmail.osg-

Re: subprocess.popen function with quotes

2008-04-13 Thread skunkwerk
On Mar 26, 10:33 pm, skunkwerk <[EMAIL PROTECTED]> wrote: > On Mar 26, 8:05 am, Jeffrey Froman <[EMAIL PROTECTED]> wrote: > > > > >skunkwerkwrote: > > > p = subprocess.Popen(['rename','-vn','s/(.*)\.htm$/ > > > model.html/','*.htm'],stdout=subprocess.PIPE,stderr=subprocess.PIPE) > > > print p.commu

Re: class level properties

2008-04-13 Thread Peter Otten
Charles D Hixson wrote: > Peter Otten wrote: >> Charles D Hixson wrote: >> >> >>> I want a hundred or so read-only variables, and I'm not sure the best >>> way to achieve it. >>> >> >> What do you really want to do? I recommend that you forget about bondage >> and rely upon displine: >> >>

Re: PythonWin Print Problem.. Build 210

2008-04-13 Thread Jaguillo
On Apr 13, 9:07 am, "Hutch" <[EMAIL PROTECTED]> wrote: > "Roger Upole" <[EMAIL PROTECTED]> wrote in message > > news:[EMAIL PROTECTED] > > > > > > > "Hutch" <[EMAIL PROTECTED]> wrote in message > >news:[EMAIL PROTECTED] > >> PythonWin has been a very good ide from early version thru 2.4. > > >> All

Re: Interesting math problem

2008-04-13 Thread Arnaud Delobelle
On Apr 13, 5:35 pm, Ivan Illarionov <[EMAIL PROTECTED]> wrote: > On Mar 19, 2:17 pm, "BJörn Lindqvist" <[EMAIL PROTECTED]> wrote: > > > > > On Mon, Mar 17, 2008 at 11:57 PM, Arnaud Delobelle > > > <[EMAIL PROTECTED]> wrote: > > >  > def make_slope(distance, parts): > > >  >     step = distance / fl

Re: Module to read input from commandline

2008-04-13 Thread james
On Apr 13, 7:44 pm, [EMAIL PROTECTED] wrote: > What you're looking for is no module, it is included in the standard > python namespace. > > raw_input > > Use it like this: > > value_a = raw_input("Please give a value for a: ") > # do your thing to value_a > > But this belongs to the real basics, I

Re: urllib2 Basic authentication, what am I doing wrong?

2008-04-13 Thread Max Erickson
On Apr 13, 2:11 pm, Michel Bouwmans <[EMAIL PROTECTED]> wrote: > Using this nice class (adapted to urllib2) as a basehandler I see that no > Authentication-header is being send > out:http://aspn.activestate.com/ASPN/Cookbook/Python/Recipe/440574 > > What am I doing wrong here? I spend almost my e

Re: py2exe, program has stoped working!?

2008-04-13 Thread Gabriel Genellina
En Sun, 13 Apr 2008 10:52:06 -0300, <[EMAIL PROTECTED]> escribió: > so i used py2exe and i have the build and the dist-folders. > > and when im distributing my program i have to include both catalogues > right? You only have to distribute the contents of the "dist" directory. (I have no idea wha

Re: Controlling copying and pickling of objects written in C

2008-04-13 Thread Gabriel Genellina
En Sun, 13 Apr 2008 01:57:42 -0300, Adam Bregenzer <[EMAIL PROTECTED]> escribió: > I am writing an extension and have "hidden" data included in the object's > C structure that is not visible to python. I am unsure what would happen > to that data if the python object were copied or pickled and

Re: toplevel, get latest entry?

2008-04-13 Thread Gabriel Genellina
En Sat, 12 Apr 2008 17:50:36 -0300, <[EMAIL PROTECTED]> escribió: > windows vista and python 2.5, is there a way to get the latest command > entered? would be very useful. > > if not by default, anything i could download or write myself? Do you mean inside the interpreter? Use up arrow/down arrow

Re: Module to read input from commandline

2008-04-13 Thread thashooski
What you're looking for is no module, it is included in the standard python namespace. raw_input Use it like this: value_a = raw_input("Please give a value for a: ") # do your thing to value_a But this belongs to the real basics, I suggest you get some reading done on python. GL -- http://mai

Re: class level properties

2008-04-13 Thread Charles D Hixson
Peter Otten wrote: > Charles D Hixson wrote: > > >> I want a hundred or so read-only variables, and I'm not sure the best >> way to achieve it. >> > > What do you really want to do? I recommend that you forget about bondage and > rely upon displine: > > class Test(object): > """Never ch

urllib2 Basic authentication, what am I doing wrong?

2008-04-13 Thread Michel Bouwmans
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Hey everybody, I'm having a little problem with urllib2 and Basic HTTP authentication. I have the following code: auth = urllib2.HTTPPasswordMgrWithDefaultRealm() auth.add_password(None, 'https://webmail.osg-erasmus.nl/oneNet/NetStorage/', user, pas

Re: Looking for a way to include Pyhtho scripting INSIDE a python program

2008-04-13 Thread Ivan Illarionov
On Apr 13, 8:20 pm, Bryan Oakley <[EMAIL PROTECTED]> wrote: > Ivan Illarionov wrote: > > You don't need to envoke another interpreter. > > Python can interpret arbitrary python code with exec statement. > > Wrap user's string inside function definition, and exec it. > > > You might want to disable

Re: tkinter, canvas, get color of image?

2008-04-13 Thread Bryan Oakley
[EMAIL PROTECTED] wrote: > mapq = PhotoImage(file = 'C:\Users\saftarn\Desktop\elmapovic.gif') > w.create_image(10, 10, image = mapq, anchor = NW) > > after doing this is there any possibility of getting the > characteristics of the GIF-picture(or bitmap if i use that)? > > it would be very helpfu

Re: Tkinter, image not appearing in function but without function

2008-04-13 Thread Marc 'BlackJack' Rintsch
On Sun, 13 Apr 2008 08:57:29 -0700, skanemupp wrote: > why is the first program not working? when i click the screen the map > is not appearing. > > the second program works. > > > > from Tkinter import * > > master = Tk() > > w = Canvas(master, width=700, height=600) > w.pack(expand = YES,

Re: Module to read input from commandline

2008-04-13 Thread Ben Kaplan
Unless I misunderstand your needs, you could just use raw_input(prompt) to get your answers. - Original Message From: "[EMAIL PROTECTED]" <[EMAIL PROTECTED]> To: python-list@python.org Sent: Sunday, April 13, 2008 11:12:06 AM Subject: Module to read input from commandline Hi all, I di

tkinter, canvas, get color of image?

2008-04-13 Thread skanemupp
mapq = PhotoImage(file = 'C:\Users\saftarn\Desktop\elmapovic.gif') w.create_image(10, 10, image = mapq, anchor = NW) after doing this is there any possibility of getting the characteristics of the GIF-picture(or bitmap if i use that)? it would be very helpfull if i for example could do something

Compiling Python 2.5.2 on AIX 5.2

2008-04-13 Thread Randy . Galbraith
I'm investigating the possible use of Mecurial SCM as a replacement for CVS. Mecurial is written in Python. I have a background in GNU/ Linux, Solaris, sparc and Perl. However AIX, powerpc and Python are new to me. --uname output-- $ uname -rvp 2 5 powerpc --end uname output-- I used this scri

Re: Interesting math problem

2008-04-13 Thread Ivan Illarionov
On Mar 19, 2:17 pm, "BJörn Lindqvist" <[EMAIL PROTECTED]> wrote: > On Mon, Mar 17, 2008 at 11:57 PM, Arnaud Delobelle > > > > <[EMAIL PROTECTED]> wrote: > > > def make_slope(distance, parts): > > > step = distance / float(parts) > > > intstep = int(step) > > > floatstep = step - int

Re: Looking for a way to include Pyhtho scripting INSIDE a python program

2008-04-13 Thread Bryan Oakley
Ivan Illarionov wrote: > You don't need to envoke another interpreter. > Python can interpret arbitrary python code with exec statement. > Wrap user's string inside function definition, and exec it. > > You might want to disable words like `import`, `exec` and `eval` in > user's code because it's

Re: C API design flaw (was: Re: Multiple independent Python interpreters in a C/C++ program?)

2008-04-13 Thread Rhamphoryncus
On Apr 12, 2:02 pm, sturlamolden <[EMAIL PROTECTED]> wrote: > On Apr 12, 7:05 pm, sturlamolden <[EMAIL PROTECTED]> wrote: > > > In theory, a GIL private to each (sub)interpreter would make Python > > more scalable. The current GIL behaves like the BKL in earlier Linux > > kernels. However, some thi

Re: Tremendous slowdown due to garbage collection

2008-04-13 Thread Rhamphoryncus
On Apr 12, 6:58 pm, Steve Holden <[EMAIL PROTECTED]> wrote: > Paul Rubin wrote: > > Steve Holden <[EMAIL PROTECTED]> writes: > >> I believe you are making surmises outside your range of competence > >> there. While your faith in the developers is touching, the garbage > >> collection scheme is some

Re: PythonWin Print Problem.. Build 210

2008-04-13 Thread Hutch
"Roger Upole" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > > "Hutch" <[EMAIL PROTECTED]> wrote in message > news:[EMAIL PROTECTED] >> PythonWin has been a very good ide from early version thru 2.4. >> >> All work ok on THREE of my computers with THREE different HP printers. >> >>

Tkinter, image not appearing in function but without function

2008-04-13 Thread skanemupp
why is the first program not working? when i click the screen the map is not appearing. the second program works. from Tkinter import * master = Tk() w = Canvas(master, width=700, height=600) w.pack(expand = YES, fill = BOTH) def mapper(): mapq = PhotoImage(file = 'C:\Users\saftarn\Deskt

Re: str(bytes) in Python 3.0

2008-04-13 Thread Kay Schluehr
On 13 Apr., 09:24, Carl Banks <[EMAIL PROTECTED]> wrote: > On Apr 12, 11:51 am, Kay Schluehr <[EMAIL PROTECTED]> wrote: > > > On 12 Apr., 16:29, Carl Banks <[EMAIL PROTECTED]> wrote: > > > > > And making an utf-8 encoding default is not possible without writing a > > > > new function? > > > > I bel

Re: How to Choose an Unlimited Web Hosting for free

2008-04-13 Thread Marc 'BlackJack' Rintsch
On Sun, 13 Apr 2008 08:42:52 -0700, John Nagle wrote: > Unlimited Free Domain & Web Hosting wrote: >> How to Choose an Unlimited Web Hosting >> 1) Visit www.xxx.com to get domain and hosting >> 2) Unlimited Bandwidth ,this mean unlimited data transmission for your >> client access. >> 2) Unlim

email module windows and suse

2008-04-13 Thread Lev Elbert
Hi, all! I have to make a custom email module, based on the standard one. The custom module has to be able to work with extremely large mails (1GB +), having memory "footprint" much smaller. The modified program has to work in SUSE environment, while the development is done under Windows. I'm not

Re: How to Choose an Unlimited Web Hosting for free

2008-04-13 Thread John Nagle
Unlimited Free Domain & Web Hosting wrote: > How to Choose an Unlimited Web Hosting > 1) Visit www.axealis.com to get domain and hosting > 2) Unlimited Bandwidth ,this mean unlimited data transmission for your > client access. > 2) Unlimited Space , you can upload file for unlimited . > 3) Unlimite

Re: Call a classmethod on a variable class name

2008-04-13 Thread Gary Herron
Matthew Keene wrote: > I would like to be able to call a specific classmethod on a class name > that is going to be passed from another parameter. In other words, I > have a call that looks something like: > >x = Foo.bar() > > and I would like to generalise this so that I can make this call on

Module to read input from commandline

2008-04-13 Thread james
Hi all, I did some quick searching but I haven't found anything like I want. It probably has to do with the terms I am searching for so if I describe what I want then I hope someone can point me to a good module. I want to take input from the user at the command line. e.g.) Would you like to cont

Re: Rounding a number to nearest even

2008-04-13 Thread Mark Dickinson
On Apr 13, 4:18 am, Lie <[EMAIL PROTECTED]> wrote: [...] > it and there is nothing else in it, but in the second number range > (barely above 1 to 2) the number 1.0 is not included while the number > 2.0 is contained in it, clearly not a clean separation of numbers in > the form of y.x where y is p

PIL and true type fonts

2008-04-13 Thread Laszlo Nagy
Attached a screenshot from a text rendered by GIMP (left side) and PIL (right side). Same truetype font. Is this a bug in PIL? Thanks, Laszlo <>-- http://mail.python.org/mailman/listinfo/python-list

py2exe, program has stoped working!?

2008-04-13 Thread skanemupp
so i used py2exe and i have the build and the dist-folders. in the distfolder there is a Calculator.exe file. when i run it it just says "Calculator.exe has stopped working" in a popup but the program itself never shows up. wtf!? and when im distributing my program i have to include both catal

Re: tkinter, annoying grid-problem

2008-04-13 Thread Bryan Oakley
[EMAIL PROTECTED] wrote: > so my little calculator works perfectly now. just having some trouble > with the layout. > this whole tkinter-thing seems to be more tricky than it should be. > how can i make the 4 column of buttons have the same distance and > size between them as the other 3 columns?

Re: Looking for a way to include Pyhtho scripting INSIDE a python program

2008-04-13 Thread Ivan Illarionov
On Apr 13, 7:16 am, John Antypas <[EMAIL PROTECTED]> wrote: > Hello all, > > I'm writing in tool in Python that manipulates various data objects read > from various streams. I wanted to give the user a chance to do advanced > work that could not easily be done from a GUI. > > At first, I tried put

Re: from __future__ import print

2008-04-13 Thread Roy Smith
In article <[EMAIL PROTECTED]>, Lie <[EMAIL PROTECTED]> wrote: > I wish py3k > would make it an option whether to treat print as statement or > function though. Arrrggh! No, don't even go there. If you want optional parens, use Perl :-) -- http://mail.python.org/mailman/listinfo/python

Re: Rounding a number to nearest even

2008-04-13 Thread Steve Holden
Lie wrote: > On Apr 12, 3:44 am, hdante <[EMAIL PROTECTED]> wrote: [snip] > > In short, choosing that x.0 is rounded down and x.5 is rounded up is > arbitrary but not without a reason. Don't "arbitrary" and "not without a reason" directly contradict one another? regards Steve -- Steve Holden

How to Choose an Unlimited Web Hosting for free

2008-04-13 Thread Unlimited Free Domain & Web Hosting
How to Choose an Unlimited Web Hosting 1) Visit www.axealis.com to get domain and hosting 2) Unlimited Bandwidth ,this mean unlimited data transmission for your client access. 2) Unlimited Space , you can upload file for unlimited . 3) Unlimited Email , many of email account can created . 5) SSL Se

Re: String Literal to Blob

2008-04-13 Thread Steve Holden
Jason Scheirer wrote: [...] > > There _is_ a way to embed image data in HTML that is supported by > every major browser. It is ugly. Using the RFC 2397 (http:// > www.ietf.org/rfc/rfc2397) spec for data URLs you could go > > '' % base64.b64encode(image_data) > > Obviously you need to import the

Re: C to python conversion

2008-04-13 Thread Ivan Illarionov
On Apr 13, 7:58 am, "Gabriel Genellina" <[EMAIL PROTECTED]> wrote: > En Sat, 12 Apr 2008 07:58:47 -0300, Michele Petrazzo > <[EMAIL PROTECTED]> escribió: > > > > > Hi all, > > I'm trying to translate a simple C code into a python + ctypes (where > > need), but I have some problems on char conversio

Re: 有中国人乎?

2008-04-13 Thread Steve Holden
[EMAIL PROTECTED] wrote: > Python这种语言有前途吗?在下想学他一学. 是, Python 有未来。但学会从未是立即, 和将需要一点时间。 regards Steve -- Steve Holden+1 571 484 6266 +1 800 494 3119 Holden Web LLC http://www.holdenweb.com/ -- http://mail.python.org/mailman/listinfo/python-list

Re: Looking for a way to include Pyhtho scripting INSIDE a python program

2008-04-13 Thread Paddy
On Apr 13, 4:16 am, John Antypas <[EMAIL PROTECTED]> wrote: > Hello all, > > I'm writing in tool in Python that manipulates various data objects read > from various streams. I wanted to give the user a chance to do advanced > work that could not easily be done from a GUI. > > At first, I tried put

Re: SQLite OperationalError near "?"

2008-04-13 Thread Hexade
On 13 avr, 03:00, John Machin <[EMAIL PROTECTED]> wrote: > On Apr 13, 8:45 am, Hexade <[EMAIL PROTECTED]> wrote: > > > Hello > > > I would like to use the safe "?" placeholder in my SQLite requests but > > I got the following error: > > > Traceback (most recent call last): > >   (...) > >   cursor.

Re: 有中国人乎?

2008-04-13 Thread Penny Y.
[EMAIL PROTECTED] 写道: > Python这种语言有前途吗?在下想学他一学. hehe, so humorous you are! Yes I think python has good future. But it depends on what you use it to do. If you're a singer, a financier, a historian etc, you don't need python. But if you are playing in computer programming, it's valuable for you to

latest command from toplevel?

2008-04-13 Thread skanemupp
windows vista and python 2.5, is there a way to get the latest command entered? would be very useful. if not by default, anything i could download or write myself? -- http://mail.python.org/mailman/listinfo/python-list

Re: Call a classmethod on a variable class name

2008-04-13 Thread Matthew Keene
Arnaud Delobelle wrote: > > If your class lives in the current global namespace, you can get it > with > > >>> cls = globals()[classname] > > Then you can access its .bar() method directly: > > >>> cls.bar() > > Example: > > >>> class Foo(object): > ... @classmethod > ... def

Re: How is GUI programming in Python?

2008-04-13 Thread Michel Bouwmans
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Torsten Bronger wrote: > Hallöchen! Und auch ein hallo, aus den Niederlanden! :P > Michel Bouwmans writes: > >> Gabriel Genellina wrote: >> >>> Michel Bouwmans <[EMAIL PROTECTED]> escribió: >>> Gabriel Genellina wrote: > Another annoy

Re: from __future__ import print

2008-04-13 Thread Lie
On Apr 11, 7:26 pm, Bruno Desthuilliers wrote: > [EMAIL PROTECTED] a écrit : > > > Am I the only one that thinks this would be useful? :) > > > I'd really like to be able to use python 3.0's print statement in > > 2.x. > > > FWIW, the whole point is that in 3.0, print stop being a statement to >

Re: Call a classmethod on a variable class name

2008-04-13 Thread Arnaud Delobelle
On Apr 13, 9:51 am, Matthew Keene <[EMAIL PROTECTED]> wrote: > I would like to be able to call a specific classmethod on a class name > that is going to be passed from another parameter.  In other words, I > have a call that looks something like: > >    x = Foo.bar() > > and I would like to general

Graphical grammar in python

2008-04-13 Thread alefajnie
hi Is exist any graphical library with resize, rotate, shape recognition, ...? suitable for graphical grammar at this moment I have OpenGL (resize & rotate) and recognition solved as saved set of shapes (classes) feel free to write down any ideas :) -- http://mail.python.org/mailman/listinfo/py

Call a classmethod on a variable class name

2008-04-13 Thread Matthew Keene
I would like to be able to call a specific classmethod on a class name that is going to be passed from another parameter. In other words, I have a call that looks something like: x = Foo.bar() and I would like to generalise this so that I can make this call on any particular class which provi

Re: Recommendation for Web Framework

2008-04-13 Thread Arnaud Delobelle
On Apr 13, 8:18 am, James West <[EMAIL PROTECTED]> wrote: [...] > Ideally, I'd like something like Ruby on Rails that would provide > scaffolding support so I can bootstrap the system, so to speak. I've > looked at Django, but the client is only running Apache 1.x and Python > 2.3. Django only req

Re: 有中国人乎?

2008-04-13 Thread Jeroen Ruigrok van der Werven
(My Mandarin is not very good.) -On [20080413 09:24], [EMAIL PROTECTED] ([EMAIL PROTECTED]) wrote: >Python这种语言有前途吗?在下想学他一学. Python indeed does have a good future. I am not quite sure with 在下想学他一学 if you are asking for someone to teach to you or if you want to teach others. -- Jeroen Ruig

Re: Rounding a number to nearest even

2008-04-13 Thread Lie
On Apr 12, 3:44 am, hdante <[EMAIL PROTECTED]> wrote: (snip) > > In this table, we consider that a number is rounded down when the > > But then, the "Round up" table gives inconsistent results if, by the > same argument, we consider 2.0 -> 2 rounding up. (you get 12 round ups > and 8 round downs j

Re: str(bytes) in Python 3.0

2008-04-13 Thread Carl Banks
On Apr 12, 11:51 am, Kay Schluehr <[EMAIL PROTECTED]> wrote: > On 12 Apr., 16:29, Carl Banks <[EMAIL PROTECTED]> wrote: > > > > And making an utf-8 encoding default is not possible without writing a > > > new function? > > > I believe the Zen in effect here is, "In the face of ambiguity, refuse > >

Re: class level properties

2008-04-13 Thread Peter Otten
Charles D Hixson wrote: > I want a hundred or so read-only variables, and I'm not sure the best > way to achieve it. What do you really want to do? I recommend that you forget about bondage and rely upon displine: class Test(object): """Never change an attribute with an uppercase name."""

有中国人乎?

2008-04-13 Thread [EMAIL PROTECTED]
Python这种语言有前途吗?在下想学他一学. -- http://mail.python.org/mailman/listinfo/python-list

Recommendation for Web Framework

2008-04-13 Thread James West
Let me explain my situation a bit. I've been contracted to develop an ecommerce site. It's nothing too huge but requires a lot of custom development that's not typical for your run of the mill webstore. I've got about three weeks to get the project delivered and I've written quite a bit of code

Re: Where is the function of 'apply' always used?

2008-04-13 Thread [EMAIL PROTECTED]
楼主,为何不用中英又语呢?这里也有其它中国人的. -- http://mail.python.org/mailman/listinfo/python-list