Problem with Image: Opening a file

2008-02-03 Thread mcl
I am obviously doing something stupid or not understanding the difference between HTML file references and python script file references. I am trying to create a thumbnail of an existing .jpg file. It is in the directory 'temp', which is below my script I can display the file with , but Image.ope

Re: Project naming suggestions?

2008-02-03 Thread alex23
On Feb 4, 3:09 pm, alex23 <[EMAIL PROTECTED]> wrote: > Phil Hassey is currently working on a small python derivative called > tinypy. Sorry, I meant to include a relevant link: http://www.philhassey.com/blog/2008/01/31/tinypy-64k-bootstrapped/ -alex23 -- http://mail.python.org/mailman/listinfo/

Re: type, object hierarchy?

2008-02-03 Thread Terry Jones
> "Arnaud" == Arnaud Delobelle <[EMAIL PROTECTED]> writes: Arnaud> Are you suggesting a new axiom for propositional logic: Arnaud> ((P => Q) ^ (R => Q)) => (P => R) ? Arnaud> I.e. in fruit logic: every orange is a fruit and every apple is a Arnaud> fruit, therefore every orange is an apple.

Re: type, object hierarchy?

2008-02-03 Thread Ben Finney
Ben Finney <[EMAIL PROTECTED]> writes: > Robert Kern <[EMAIL PROTECTED]> writes: > > > And if you want to really blow your mind, > > > > print isinstance(type, object) # True > > print isinstance(object, type) # True > > Not what I see here. Ah, you tricked me! The parent message to yours wa

Re: type, object hierarchy?

2008-02-03 Thread Ben Finney
Robert Kern <[EMAIL PROTECTED]> writes: > And if you want to really blow your mind, > > print isinstance(type, object) # True > print isinstance(object, type) # True Not what I see here. Python 2.4.4 (#2, Jan 3 2008, 13:39:07) [GCC 4.2.3 20071123 (prerelease) (Debian 4.2.2-4)] on linux2 Type

Re: type, object hierarchy?

2008-02-03 Thread Arnaud Delobelle
On Feb 4, 5:31 am, 7stud <[EMAIL PROTECTED]> wrote: > On Feb 3, 10:28 pm, 7stud <[EMAIL PROTECTED]> wrote: > > > From the docs: > > > issubclass(class, classinfo) > > Return true if class is a subclass (direct or indirect) of classinfo. > > print issubclass(Dog, object)  #True > print issubclass(ty

Re: Python GUI toolkit

2008-02-03 Thread David Cook
On 2008-02-03, [EMAIL PROTECTED] <[EMAIL PROTECTED]> wrote: > what would be the best python GUI toolkit, it must be cross platform. > > i have tried gtk, but it interface are real bad and its coding was difficult > so i dropped it, > > the only remaining are qt4 and wx, i would like to know if one

Re: type, object hierarchy?

2008-02-03 Thread I V
On Sun, 03 Feb 2008 21:31:44 -0800, 7stud wrote: > On Feb 3, 10:28 pm, 7stud <[EMAIL PROTECTED]> wrote: >> From the docs: >> >> issubclass(class, classinfo) >> Return true if class is a subclass (direct or indirect) of classinfo. > > > print issubclass(Dog, object) #True So Dog is a subclass o

Re: type, object hierarchy?

2008-02-03 Thread Robert Kern
7stud wrote: > On Feb 3, 10:28 pm, 7stud <[EMAIL PROTECTED]> wrote: >> From the docs: >> >> issubclass(class, classinfo) >> Return true if class is a subclass (direct or indirect) of classinfo. > > print issubclass(Dog, object) #True > print issubclass(type, object) #True > print issubclass(Dog,

Re: [2.4.2/Linux] Getting Python to fork?

2008-02-03 Thread Gary Herron
Gilles Ganault wrote: > Hello > > I need to launch a Python script, and fork it so that the calling > script can resume with the next step will the Python script keeps > running. > > I tried those two, but they don't work, as the calling script is stuck > until the Python script ends: > > sys

Re: Does anyone else use this little idiom?

2008-02-03 Thread samwyse
[EMAIL PROTECTED] wrote: > My apologies if any attributions are messed up. > > On Feb 3, 1:28 am, Steven D'Aprano <[EMAIL PROTECTED] > cybersource.com.au> wrote: > >>If you want an explicit name, try a variation of "dontcare". Assuming >>that you're an English speaker. I'm with Steven here. I t

Re: type, object hierarchy?

2008-02-03 Thread 7stud
On Feb 3, 10:28 pm, 7stud <[EMAIL PROTECTED]> wrote: > From the docs: > > issubclass(class, classinfo) > Return true if class is a subclass (direct or indirect) of classinfo. print issubclass(Dog, object) #True print issubclass(type, object) #True print issubclass(Dog, type) #False -- http:/

Re: type, object hierarchy?

2008-02-03 Thread 7stud
On Feb 3, 9:06 pm, Jason <[EMAIL PROTECTED]> wrote: > On Feb 3, 8:36 pm, 7stud <[EMAIL PROTECTED]> wrote: > > > > > print dir(type)      #__mro__ attribute is in here > > print dir(object)   #no __mro__ attribute > > > class Mammals(object): > >     pass > > class Dog(Mammals): > >     pass > > > p

Help installing python spider monkey

2008-02-03 Thread jatin patni
Hi, I am having trouble installing python-spidermonkey module. It requires mozillas spidermonkey to be built and installed. Could anyone guide me in the right direction. I just have python installed and not vc++ etc. Please help.:( -- http://mail.python.org/mailman/listinfo/python-list

Re: Project naming suggestions?

2008-02-03 Thread alex23
I really like the Whython suggestion :) Phil Hassey is currently working on a small python derivative called tinypy. It's so recent I don't think he's gotten a project page up for it, so you'd need to backtrack through his blog posts for an overview. But as he's just done a _lot_ of what you're ab

Re: Python GUI toolkit

2008-02-03 Thread Benjamin
On Feb 3, 10:55 am, Grant Edwards <[EMAIL PROTECTED]> wrote: > On 2008-02-03, Torsten Bronger <[EMAIL PROTECTED]> wrote: > > > Hallöchen! > > > [EMAIL PROTECTED] writes: > > >> [...] > > >> the only remaining are qt4 and wx, i would like to know if one of > >> these or any other toolkit is capable

Re: type, object hierarchy?

2008-02-03 Thread Jason
On Feb 3, 8:36 pm, 7stud <[EMAIL PROTECTED]> wrote: > print dir(type) #__mro__ attribute is in here > print dir(object) #no __mro__ attribute > > class Mammals(object): > pass > class Dog(Mammals): > pass > > print issubclass(Dog, type) #False > print Dog.__mro__ > > --output:-- >

type, object hierarchy?

2008-02-03 Thread 7stud
print dir(type) #__mro__ attribute is in here print dir(object) #no __mro__ attribute class Mammals(object): pass class Dog(Mammals): pass print issubclass(Dog, type) #False print Dog.__mro__ --output:-- (, , ) The output suggests that Dog actually is a subclass of type--desp

Elementary string-parsing

2008-02-03 Thread Odysseus
I'm writing my first 'real' program, i.e. that has a purpose aside from serving as a learning exercise. I'm posting to solicit comments about my efforts at translating strings from an external source into useful data, regarding efficiency and 'pythonicity' both. My only significant programming

Re: Does anyone else use this little idiom?

2008-02-03 Thread Ivan Illarionov
On Feb 4, 12:56 am, Marc 'BlackJack' Rintsch <[EMAIL PROTECTED]> wrote: > On Sun, 03 Feb 2008 05:33:16 -0800, Ivan Illarionov wrote: > > Plain Python function are very often more powerful than classes: > > def go(count): > > ... if not hasattr(go, 'count'): > > ... go.count = count > > .

Re: [2.4.2] Compiling Python with packages?

2008-02-03 Thread Gilles Ganault
On Sun, 03 Feb 2008 09:14:24 +0100, "Martin v. Löwis" <[EMAIL PROTECTED]> wrote: >No, it won't. You don't give any arguments to configure normally, >when building Python. Instead, setup.py will detect what libraries >are on your system, and use them. Thanks for the tip. -- http://mail.python.org/

[2.4.2/Linux] Getting Python to fork?

2008-02-03 Thread Gilles Ganault
Hello I need to launch a Python script, and fork it so that the calling script can resume with the next step will the Python script keeps running. I tried those two, but they don't work, as the calling script is stuck until the Python script ends: sys.stdout = open(os.devnull, 'w')

RE: python for game programming

2008-02-03 Thread Adam Pletcher
In addition to EVE Online, Disney's Toontown Online is another example, along with Psi-Ops and Civ 4. Irrational, DICE, Totally Games and Troika all reportedly use Python in some capacity, either for gameplay scripting or as a development tool. At GDC 2008, a couple weeks from now, there are

Re: Does anyone else use this little idiom?

2008-02-03 Thread Paul Rubin
[EMAIL PROTECTED] writes: > where n is an integer representing how many times you want > to execute "some code." ... I tend to write it as: > > for _ in xrange (1,n): >some code But this does it n-1 times, not n times. -- http://mail.python.org/mailman/listinfo/python-list

Re: Is it explicitly specified?

2008-02-03 Thread Arnaud Delobelle
On Feb 3, 11:06 pm, "Terry Reedy" <[EMAIL PROTECTED]> wrote: > If you have multiple optional keywords with default behaviors when they are > not specified, the usually mechanism is the **keywords mechanism.  If you > have just one, that may seem like overkill and some people prefer the > pseudo-d

Re: apache/mod_wsgi daemon mode

2008-02-03 Thread Graham Dumpleton
On Feb 4, 10:33 am, Scott SA <[EMAIL PROTECTED]> wrote: > On 2/3/08, Brian Smith ([EMAIL PROTECTED]) wrote: > >Scott SA wrote: > >> I am trying to configure mod_wsgi to run in daemon mode with > >> Apache. I can easily get it to run 'normally' under Apache > >> but I obtain permission errors _or_ p

Re: Python feature request : operator for function composition

2008-02-03 Thread Kay Schluehr
On Feb 3, 11:34 pm, George Sakkis <[EMAIL PROTECTED]> wrote: > On Feb 3, 12:09 am, Kay Schluehr <[EMAIL PROTECTED]> wrote: > > > As you know, there is no operator for function composition in Python. > > When you have two functions F and G and want to express the > > composition F o G you have to c

Re: Is it explicitly specified?

2008-02-03 Thread Mel
Steve Holden wrote: > Diez B. Roggisch wrote: >> Bjoern Schliessmann schrieb: >>> mario ruggier wrote: >>> It may sometimes be useful to make use of the conceptual difference between these two cases, that is that in one case the user did not specify any key and in the other the user

Re: Is it explicitly specified?

2008-02-03 Thread Paul Boddie
On 3 Feb, 16:41, mario <[EMAIL PROTECTED]> wrote: > > In one case, the collection attributes a specific meaning to > attr=None, but the actual default for attr is something else. However, > if an object explicitly wants to state that his attr=None (that is a > valid value, and has specific meaning)

tkinter, unicode, arabic letter, mac os problem

2008-02-03 Thread Max Guat
Hi, i found a problem with tkinter and mac os x (10.5): tkinter shows chinese (?) letters instead of arabic letters, what it actually should do. Code, file encoding and database are ok: because 1. no problems with windows xp, 2. every other output (console, text file) is correct as well. T

RE: apache/mod_wsgi daemon mode

2008-02-03 Thread Scott SA
On 2/3/08, Brian Smith ([EMAIL PROTECTED]) wrote: >Scott SA wrote: >> I am trying to configure mod_wsgi to run in daemon mode with >> Apache. I can easily get it to run 'normally' under Apache >> but I obtain permission errors _or_ process-failures in >> daemon mode. Specifically: >> >>

Re: translating Python to Assembler

2008-02-03 Thread Albert van der Horst
In article <[EMAIL PROTECTED]>, <[EMAIL PROTECTED]> wrote: > >Once a python py file is compiled into a pyc file, I can disassemble >it into assembler. Assembler is nothing but codes, which are >combinations of 1's and 0's. You can't read a pyc file in a hex >editor, but you can read it in a di

Re: Multiple interpreters retaining huge amounts of memory

2008-02-03 Thread Graham Dumpleton
On Feb 4, 10:03 am, "Martin v. Löwis" <[EMAIL PROTECTED]> wrote: > >>> It means that > >>> environment variable separation for changes made unique to a sub > >>> interpreter is impossible. > >> That's not really true. You can't use os.environ for that, yes. > > > Which bit isn't really true? > > Th

Re: Is it explicitly specified?

2008-02-03 Thread Terry Reedy
"mario" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] | My use case is that I have an object that is part of a collection. The | collection sets what the preferred defaults are for specific object | attributes, but individual objects may override some of these. Thus, | if an object

Re: Multiple interpreters retaining huge amounts of memory

2008-02-03 Thread Martin v. Löwis
>>> It means that >>> environment variable separation for changes made unique to a sub >>> interpreter is impossible. >> That's not really true. You can't use os.environ for that, yes. > > Which bit isn't really true? The last sentence ("It means that..."). > When you do: > > os.environ['XYZ'

FW: apache/mod_wsgi daemon mode

2008-02-03 Thread Brian Smith
Also, mod_wsgi has its own mailing list: http://groups.google.com/group/modwsgi > Scott SA wrote: > I am trying to configure mod_wsgi to run in daemon mode with Apache. I > can easily get it to run 'normally' under Apache but I obtain > permission errors _or_ process-failures in daemon mode. Spe

Re: Project naming suggestions?

2008-02-03 Thread Robert Kern
[EMAIL PROTECTED] wrote: > On Feb 3, 2:37 pm, Thomas Dybdahl Ahle <[EMAIL PROTECTED]> wrote: > >> Are you really thinking about creating an entire language, simply >> because you don't like 'for dummy in xrange (n):'? > > No. I now wish I had posted this before that. :-) > > Basically, I want t

Re: Python feature request : operator for function composition

2008-02-03 Thread George Sakkis
On Feb 3, 12:09 am, Kay Schluehr <[EMAIL PROTECTED]> wrote: > As you know, there is no operator for function composition in Python. > When you have two functions F and G and want to express the > composition F o G you have to create a new closure > > lambda *args, **kwd: F (G (*args, **kwd)) > >

apache/mod_wsgi daemon mode

2008-02-03 Thread Scott SA
HI, I'm posting this here because it is, I believe, a python config issue (mine) that is not correct, but frustration and inexperience has left me without further [visible] options for rectification. I am trying to configure mod_wsgi to run in daemon mode with Apache. I can easily get it to ru

Re: Multiple interpreters retaining huge amounts of memory

2008-02-03 Thread Graham Dumpleton
On Feb 4, 7:13 am, "Martin v. Löwis" <[EMAIL PROTECTED]> wrote: > > You might also read section 'Application Environment Variables' of > > that document. This talks about the problem of leakage of environment > > variables between sub interpreters. There probably isn't much that one > > can do abou

PyCon 2008 Tutorial Sessions

2008-02-03 Thread Greg Lindstrom
Registration for PyCon 2008 is now open. Held in Chicago March 14-16 with "Tutorial Thursday" on March 13 and sprints afterwards, it is expected that nearly 800 Python enthusiasts will attend at least part of the conference. It is totally run by volunteers and is affordable for just about anyone.

Re: Does anyone else use this little idiom?

2008-02-03 Thread Marc 'BlackJack' Rintsch
On Sun, 03 Feb 2008 05:33:16 -0800, Ivan Illarionov wrote: > Plain Python function are very often more powerful than classes: > def go(count): > ... if not hasattr(go, 'count'): > ... go.count = count > ... if go.count <= 0: > ... del go.count > ... return False > ... go.co

IsNumberType()

2008-02-03 Thread Sarah Orchard
I am writing an IF statement which basically says if the value is a str.isdigit() it should run the command or ELSE print please enter a numeric value next time. Even when I enter a number though ie. An integer it is going straight to the else command - what code do I need to add that will reco

Re: Project naming suggestions?

2008-02-03 Thread miller . paul . w
On Feb 3, 2:37 pm, Thomas Dybdahl Ahle <[EMAIL PROTECTED]> wrote: > Are you really thinking about creating an entire language, simply > because you don't like 'for dummy in xrange (n):'? No. I now wish I had posted this before that. :-) Basically, I want to tweak a programming language and a co

Re: Does anyone else use this little idiom?

2008-02-03 Thread Marc 'BlackJack' Rintsch
On Sun, 03 Feb 2008 15:13:14 +1100, Ben Finney wrote: > "Gabriel Genellina" <[EMAIL PROTECTED]> writes: > >> Should be `for _ in xrange(n)` to match the Ruby example. Both >> iterate n times. > > Only until Python 3.0, since the 'xrange' implementation will become > 'range' at that time. The po

Re: python for game programming

2008-02-03 Thread Richard Jones
t3chn0n3rd wrote: > Is Python program language popular for game programming? http://www.pyweek.org/ Richard -- http://mail.python.org/mailman/listinfo/python-list

Re: Curses and Threading

2008-02-03 Thread Brett . Friermood
> join() is a method on Thread objects. So you'll need a reference to the > Thread you create, then call join() on that. > > thread = cadtime() > thread.start() > thread.join() > > Ian Thanks for all the help guys. It's working great. Just one more question, I think. As you pro

Re: Smart Debugger (Python)

2008-02-03 Thread Norm Matloff
I have something of an obsession with debuggers, so I was glad to see this posting. While we're on the subject, I might as well add my own small contribution, which I call Xpdb. Xpdb is available at http://heather.cs.ucdavis.edu/~matloff/xpdb.html Quoting from the beginning of that page: I t

Re: GUI definition for web and desktop

2008-02-03 Thread Stefan Behnel
Daniel Fetchinson wrote: >>> is there a GUI toolkit library for python which can render html? >> At least GTK comes with libgtkhtml, but I bet there are others, too. Ah, and there is also WebKit. Don't know how stable the Python bindings are, but you might know WebKit as part of Apple's browser.

Re: Project naming suggestions?

2008-02-03 Thread Stefan Behnel
[EMAIL PROTECTED] wrote: > I'm considering writing a little interpreter for a python-like > language [...] > I'd also like to implement most of the planned Python 3000 changes. In case you're interested in a real project, consider taking a look at Cython, which is a Python-to-C compiler for writin

Re: python for game programming

2008-02-03 Thread Steve Holden
t3chn0n3rd wrote: > Is Python program language popular for game programming? > Python is a core technology for CCP, the producers of EVE Online, which is I believe the largest single-sharded multi-player game currently running, and which has supported over 40,000 simultaneously logged-in users

Re: GUI definition for web and desktop

2008-02-03 Thread Daniel Fetchinson
> >> On the other hand, if you want pure HTML for your web app, maybe you > should > >> consider making the desktop app HTML-based, too? > > > > Jorge Godoy brought that up too, sounds pretty good, but how would > > that work? The desktop app would launch a mini webserver and the user > > would use

Re: GUI definition for web and desktop

2008-02-03 Thread Stefan Behnel
Hi, Daniel Fetchinson wrote: >> On the other hand, if you want pure HTML for your web app, maybe you should >> consider making the desktop app HTML-based, too? > > Jorge Godoy brought that up too, sounds pretty good, but how would > that work? The desktop app would launch a mini webserver and the

Re: Multiple interpreters retaining huge amounts of memory

2008-02-03 Thread Martin v. Löwis
>> - objects can easily get shared across interpreters, and often are. >>This is particularly true for static variables that extensions keep, >>and for static type objects. > > Yep, but basically a problem with how people write C extension > modules. Ie., they don't write them with the fac

Re: Project naming suggestions?

2008-02-03 Thread Thomas Dybdahl Ahle
On Sun, 2008-02-03 at 10:17 -0800, [EMAIL PROTECTED] wrote: > I'm considering writing a little interpreter for a python-like > language and I'm looking for name suggestions. :-) > > Basically, I don't want to change a whole lot about Python. In fact, > I see myself starting with the compiler mod

Re: Does anyone else use this little idiom?

2008-02-03 Thread Thomas Dybdahl Ahle
On Sat, 2008-02-02 at 18:03 -0800, [EMAIL PROTECTED] wrote: > for _ in xrange (1,n): >some code I'd always use i for loop variables I don't know what to call. It stands for iterator or something. In a nested loop the next variable would simply be called j and so on. I also tend to use _, but

Re: psyco question

2008-02-03 Thread miller . paul . w
On Feb 3, 2:19 pm, [EMAIL PROTECTED] wrote: > simple solution is to defer the optimization. That is test the > original code, call Psyco, then test it again: I had thought of that, but it didn't really meet my requirements. I might want the unoptimized function back at some point after I call th

Re: GUI definition for web and desktop

2008-02-03 Thread Daniel Fetchinson
> > I'm looking for a simple text based GUI definition format and > > associated python modules to work with it that is capable of defining > > simple GUI's for *both* the web and the desktop. I have an application > > that is accessible through the web and also through desktop > > applications and

Re: Project naming suggestions?

2008-02-03 Thread miller . paul . w
On Feb 3, 2:36 pm, Wildemar Wildenburger <[EMAIL PROTECTED]> wrote: > [EMAIL PROTECTED] wrote: > > I'm considering writing a little interpreter for a python-like > > language and I'm looking for name suggestions. :-) > > How about "Whython"? > > /W I like it. :P If you were wondering why I was th

Re: GUI definition for web and desktop

2008-02-03 Thread Stefan Behnel
Daniel Fetchinson wrote: > I'm looking for a simple text based GUI definition format and > associated python modules to work with it that is capable of defining > simple GUI's for *both* the web and the desktop. I have an application > that is accessible through the web and also through desktop > a

Re: Python GUI toolkit

2008-02-03 Thread Thomas Dybdahl Ahle
On Sun, 2008-02-03 at 15:18 +, [EMAIL PROTECTED] wrote: > what would be the best python GUI toolkit, it must be cross platform. > > i have tried gtk, but it interface are real bad and its coding was difficult > so i dropped it, I came from Sving to Gtk, so for me also it was a real brainbreak

Re: Project naming suggestions?

2008-02-03 Thread Wildemar Wildenburger
[EMAIL PROTECTED] wrote: > I'm considering writing a little interpreter for a python-like > language and I'm looking for name suggestions. :-) > How about "Whython"? /W -- http://mail.python.org/mailman/listinfo/python-list

Re: Python GUI toolkit

2008-02-03 Thread Guilherme Polo
2008/2/3, Guilherme Polo <[EMAIL PROTECTED]>: > 2008/2/3, Thomas Pani <[EMAIL PROTECTED]>: > > > Guilherme Polo wrote: > > > PyQt follows same licensing as Qt, so what licenses does Qt4 supports > > > besides GPL and Qt commercial license ? > > > > Qt4 has a special exception to the GPL, allo

Re: psyco question

2008-02-03 Thread bearophileHUGS
miller: > Is there any simple/easy/elegant way to retain a reference to the > *unoptimized* version of f so I can call them both and compare > performance? A simple solution is to defer the optimization. That is test the original code, call Psyco, then test it again: def somefunc(): ... from

Re: psyco question

2008-02-03 Thread miller . paul . w
Thanks for your reply. It's been a while since I've used psyco, and it seems either some functions have been added, or I've never needed the other ones. :-) For the record, it looks like psyco.bind (f) f2 = psyco.unproxy(f) would leave me with an optimized f and a function f2 which is the unopt

Re: Python GUI toolkit

2008-02-03 Thread Guilherme Polo
2008/2/3, Thomas Pani <[EMAIL PROTECTED]>: > Guilherme Polo wrote: > > PyQt follows same licensing as Qt, so what licenses does Qt4 supports > > besides GPL and Qt commercial license ? > > Qt4 has a special exception to the GPL, allowing the use of free > software licenses not compatible with th

Re: GUI definition for web and desktop

2008-02-03 Thread Daniel Fetchinson
> > It's clear to me that the logic behind a web interface and a desktop > > interface are two totally different things. I don't want a magic > > method to convert an html/javascript based web app to a desktop app as > > this is clearly impossible. > > But it is not impossible to embed a server on

Re: ANN: eric4 4.1.0 released

2008-02-03 Thread Antoni Aloy
El Diumenge, 03-02-08 a les 16:45 escrigueres: > Hi, > > eric4 4.1.0 was just released. This is a major feature release. Compared > to 4.0.4 it contains these features next to bug fixes. > Hello! This is the first version in many month on which I have no problems with dead key characters, suc as

Re: Python GUI toolkit

2008-02-03 Thread miller . paul . w
I'd like to offer you one suggestion about coding your app. You'll be best served if you can either write it as a command-line app and write a separate GUI-front end for it, or use an abstraction layer between your app and the display logic that allows you to easily plug in other GUI toolkits. Th

Re: Python GUI toolkit

2008-02-03 Thread Thomas Pani
Guilherme Polo wrote: > PyQt follows same licensing as Qt, so what licenses does Qt4 supports > besides GPL and Qt commercial license ? Qt4 has a special exception to the GPL, allowing the use of free software licenses not compatible with the GPL: http://trolltech.com/products/qt/gplexception/ Che

Re: Python GUI toolkit

2008-02-03 Thread miller . paul . w
On Feb 3, 10:39 am, [EMAIL PROTECTED] wrote: > also, is qt4 apps better looking in both win/linux than wx apps, coz the > main thing i m looking for is visual appeal of the gui. Well, well... this wasn't in your original post. I had assumed ease of programming and cross-platform-ness were the on

Re: ANN: eric4 4.1.0 released

2008-02-03 Thread dmitrey
Hi all, I prefer the Eric Python IDE to all other, however, unfortunately, Eric4.x (as well as the latest snapshot mentioned in the ann) fails to debug any py-file (while Eric3.9.5 from Kubuntu software channel works ok): The debugged program raised the exception unhandled TypeError "not all argum

Re: GUI definition for web and desktop

2008-02-03 Thread Jorge Godoy
Daniel Fetchinson wrote: > It's clear to me that the logic behind a web interface and a desktop > interface are two totally different things. I don't want a magic > method to convert an html/javascript based web app to a desktop app as > this is clearly impossible. But it is not impossible to emb

Re: Python GUI toolkit

2008-02-03 Thread Guilherme Polo
2008/2/3, Christian Heimes <[EMAIL PROTECTED]>: > Jorge Godoy wrote: > > Qt is a the best choice, IMHO. Nice support, free if you write free > > software, very nice API, nice tools to develop with and the best looking > > widget system for *nix and mobile phones. > > > PyQt4 forces you to eithe

Re: python for game programming

2008-02-03 Thread miller . paul . w
On Feb 3, 9:05 am, t3chn0n3rd <[EMAIL PROTECTED]> wrote: > Is Python program language popular for game programming? Well, Python is at the center of my favorite game, Sid Meier's Civilization 4. :-) Another poster mentioned the pygame and pyglet libraries. I'd suggest you look into them if you w

Re: psyco question

2008-02-03 Thread Marc 'BlackJack' Rintsch
On Sun, 03 Feb 2008 10:06:04 -0800, miller.paul.w wrote: > Say I have a module with a function f in it, and I do > > psyco.bind (f) > > Is there any simple/easy/elegant way to retain a reference to the > *unoptimized* version of f so I can call them both and compare > performance? What about `p

Re: Python GUI toolkit

2008-02-03 Thread Christian Heimes
Jorge Godoy wrote: > Qt is a the best choice, IMHO. Nice support, free if you write free > software, very nice API, nice tools to develop with and the best looking > widget system for *nix and mobile phones. PyQt4 forces you to either release your software under GPL or buy a license. Qt3 and Qt4

Re: Python GUI toolkit

2008-02-03 Thread Christian Heimes
James Matthews wrote: > Just a side question! > > Does QT support Events from multiple threads without any special calls! > Example when i use WX i have to call wx.CallAfter() Yes, you can send signal across threads with some precaution. Christian -- http://mail.python.org/mailman/listinfo/pyt

Re: Python GUI toolkit

2008-02-03 Thread James Matthews
Just a side question! Does QT support Events from multiple threads without any special calls! Example when i use WX i have to call wx.CallAfter() Thanks! On Feb 3, 2008 6:05 PM, Jorge Godoy <[EMAIL PROTECTED]> wrote: > [EMAIL PROTECTED] wrote: > > > what i meant was, i tried gtk, didnt like it

Re: GUI definition for web and desktop

2008-02-03 Thread Daniel Fetchinson
> >> >> > I'm looking for a simple text based GUI definition format and > >> > >> [...] > >> > I believe Glade produces XML descriptions of its interfaces, so wxGlade > >> >> would be one possible starting-point. > >> >> > >> > > >> > Glade does, but dont confuse it with wxGlade. wxGlad

Project naming suggestions?

2008-02-03 Thread miller . paul . w
I'm considering writing a little interpreter for a python-like language and I'm looking for name suggestions. :-) Basically, I don't want to change a whole lot about Python. In fact, I see myself starting with the compiler module from Python 2.5 and building from there. This language would be mo

psyco question

2008-02-03 Thread miller . paul . w
Say I have a module with a function f in it, and I do psyco.bind (f) Is there any simple/easy/elegant way to retain a reference to the *unoptimized* version of f so I can call them both and compare performance?I've tried f2 = copy.deepcopy (f) psyco.bind (f) but that doesn't work. Other wa

Re: Python GUI toolkit

2008-02-03 Thread Gary Herron
[EMAIL PROTECTED] wrote: > what would be the best python GUI toolkit, it must be cross platform. > > i have tried gtk, but it interface are real bad and its coding was difficult > so i dropped it, > > the only remaining are qt4 and wx, i would like to know if one of these or > any other toolkit is

Re: interested????

2008-02-03 Thread Steve Holden
no -- 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: GUI definition for web and desktop

2008-02-03 Thread Steve Holden
Guilherme Polo wrote: > 2008/2/3, Steve Holden <[EMAIL PROTECTED]>: >> Guilherme Polo wrote: >> > 2008/2/3, Steve Holden <[EMAIL PROTECTED]>: >> >> Daniel Fetchinson wrote: >> >> > Hi pythoneans, >> >> > >> >> > I'm looking for a simple text based GUI definition format and >> >> [...] >> >>

Re: Why chdir command doesn't work with client.get_transport() ?

2008-02-03 Thread Charles_hans
Thank you, Martin! I think that you are right. But I can't use rsh since I am on XP to send commands to UNIX. I used telnet before. Now I am converting to ssh/sftp, which is my purpose. I put some more efforts in the following code: t = paramiko.Transport((hostname, port)) t.connect(user

Re: Does anyone else use this little idiom?

2008-02-03 Thread Troels Thomsen
>for action in repeat(f, n): action() >I don't know how 'Pythonic' this would be... agree, or this: import itertools def f1(): print "hello" [f() for f in itertools.repeat(f1,6)] tpt -- http://mail.python.org/mailman/listinfo/python-list

Re: Python GUI toolkit

2008-02-03 Thread miller . paul . w
On Feb 3, 10:18 am, [EMAIL PROTECTED] wrote: > what would be the best python GUI toolkit, it must be cross platform. > > i have tried gtk, but it interface are real bad and its coding was difficult > so i dropped it, > [...] If "cross-platform," and "nice API" are your requirements, I recommend yo

Re: GUI definition for web and desktop

2008-02-03 Thread Guilherme Polo
2008/2/3, Steve Holden <[EMAIL PROTECTED]>: > Guilherme Polo wrote: > > 2008/2/3, Steve Holden <[EMAIL PROTECTED]>: > >> Daniel Fetchinson wrote: > >> > Hi pythoneans, > >> > > >> > I'm looking for a simple text based GUI definition format and > > [...] > > >> I believe Glade produces XML d

Re: Does anyone else use this little idiom?

2008-02-03 Thread miller . paul . w
My apologies if any attributions are messed up. On Feb 3, 1:28 am, Steven D'Aprano <[EMAIL PROTECTED] cybersource.com.au> wrote: > On Sun, 03 Feb 2008 15:08:34 +1100, Ben Finney wrote: > >> But I like using _ because it's only 1 character and communicates well > >> the idea "I don't care about thi

Re: fast method accessing large, simple structured data

2008-02-03 Thread Stefan Behnel
agc wrote: > I guess an important feature of what I'm looking for is > some kind of mapping from *exact* title to corresponding article, > i.e. if my data set wasn't so large, I would just keep all my > data in a in-memory Python dictionary, which would be very fast. > > But I have about 2 million

Re: How to convert markup text to plain text in python?

2008-02-03 Thread Stefan Behnel
geoffbache wrote: > I have some marked up text and would like to convert it to plain text, > by simply removing all the tags. Of course I can do it from first > principles but I felt that among all Python's markup tools there must > be something that would do this simply, without having to create a

Re: Does anyone else use this little idiom?

2008-02-03 Thread miller . paul . w
On Feb 3, 11:20 am, Paul McGuire <[EMAIL PROTECTED]> wrote: [... some code... some words ... more code, etc. ...] > But this still seems like a lot of work to avoid "for x in range(n):". I agree. The point of me using "for _ in xrange (n)" isn't to avoid the for loop at all. What I wanted was

Re: Does anyone else use this little idiom?

2008-02-03 Thread miller . paul . w
On Feb 3, 10:42 am, Zentrader <[EMAIL PROTECTED]> wrote: > > Not to me. If I read "for _ in ...", I wouldn't be quite sure what _ was. > > Is it some magic piece of syntax I've forgotten about? Or something new > > added to language while I wasn't paying attention (I still consider most > > stuff

Re: Python GUI toolkit

2008-02-03 Thread Grant Edwards
On 2008-02-03, Jorge Godoy <[EMAIL PROTECTED]> wrote: >> And they don't look native on systems that don't use Qt as the >> native widget set. > > But then, there's no toolkit that does. > > GTK based toolkits don't look native on Qt based systems. > Same for a lot of others. Quite true. > What

Re: Python GUI toolkit

2008-02-03 Thread Torsten Bronger
Hallöchen! Grant Edwards writes: > On 2008-02-03, Torsten Bronger <[EMAIL PROTECTED]> wrote: >> Hallöchen! >> >> [EMAIL PROTECTED] writes: >> >>> [...] >>> >>> the only remaining are qt4 and wx, i would like to know if one >>> of these or any other toolkit is capable of creating >>> good-looking

Re: Python GUI toolkit

2008-02-03 Thread Dotan Cohen
On 03/02/2008, Grant Edwards <[EMAIL PROTECTED]> wrote: > On 2008-02-03, Torsten Bronger <[EMAIL PROTECTED]> wrote: > > Hallöchen! > > > > [EMAIL PROTECTED] writes: > > > >> [...] > >> > >> the only remaining are qt4 and wx, i would like to know if one of > >> these or any other toolkit is capable

Re: Python GUI toolkit

2008-02-03 Thread Jorge Godoy
[EMAIL PROTECTED] wrote: > what i meant was, i tried gtk, didnt like it, the main reason was that it > had a very bad gui appeal for me, i did try my hand at wx , and i would > have stuck with it, but then i saw the qt4 screenshot and couple of > examples of its code and i liked it, so i was wonde

Re: Python GUI toolkit

2008-02-03 Thread Jorge Godoy
Grant Edwards wrote: > On 2008-02-03, Dotan Cohen <[EMAIL PROTECTED]> wrote: > >> I would recommend Qt, as it is cross-platform and can look native on >> all systems. > > Qt doesn't look native on my system. I run XFCE, and "native" > is GTK. > >> Opera, KDE, GoogleEarth, Acrobat, and lots of o

Re: "ping" not reconnecting in Python MySQLdb client interface

2008-02-03 Thread John Nagle
JJohn Nagle wrote: >I have some long-running Python programs that can be idle > for hours, and, of course, the MySQL connection times out. > So I call > > db.ping() > > at the beginning of a new request cycle. This should > reestablish the connection, but it doesn't. ... > I suspe

  1   2   >