issues installing readine-1.12 on WinXP

2005-03-13 Thread Michele Simionato
I have installed Gary Bishop's readline library and Thomas Heller's cypes; I have Python 2.4 ActiveState distribution. When I try to import readline I get the following error: C:\Programmi>python ActivePython 2.4 Build 243 (ActiveState Corp.) based on Python 2.4 (#60, Nov 30 2004, 09:34:21) [MSC v

Re: a program to delete duplicate files

2005-03-13 Thread Patrick Useldinger
John Machin wrote: Test: !for k in range(1000): !open('foo' + str(k), 'w') I ran that and watched it open 2 million files and going strong ... until I figured that files are closed by Python immediately because there's no reference to them ;-) Here's my code: #!/usr/bin/env python import os

Re: Regular Expressions: large amount of or's

2005-03-13 Thread Daniel Yoo
: Otherwise, you may want to look at a specialized data structure for : doing mutiple keyword matching; I had an older module that wrapped : around a suffix tree: :http://hkn.eecs.berkeley.edu/~dyoo/python/suffix_trees/ : It looks like other folks, thankfully, have written other : implementat

Re: Beware complexity

2005-03-13 Thread Harald Massa
Philip, more often than not, all needed was included in Python years ago. Especially: > I wonder if anyone has any thoughts not on where Python should go but > where it should stop? The answer is included within the standard library. On any Python command prompt type: >>>import this The Zen

Re: Why is lower() deprecated and how should I replace it?

2005-03-13 Thread Dan Bishop
gf gf wrote: > I read that lower() is deprecated. Unfortunately, I > can't find the preferred way of lowercasing a string. > What is it? Instead of string.lower(s), use s.lower() -- http://mail.python.org/mailman/listinfo/python-list

Re: bsddb support for berkeley db 4.3?

2005-03-13 Thread "Martin v. Löwis"
Andrew MacIntyre wrote: If you can, I'd suggest posting a bug report on SF against 2.4 to see whether you can encourage the installer builder to upgrade BSD DB - though do be certain to check what's in 2.4.1c1 first. It's 4.2.52, and I don't think I'm going to use anything else for 2.4.1. In fact

Re: Web framework

2005-03-13 Thread andre . p . meyer
Gianluca Sartori wrote: > Hi guys, > > What web framework do you suggest to develop with? I had a look both at > Nevow and Quixote. These seemes to be the most appreciated by the > community. Anyway, I had no luck looking for a complete and coherent > documentation. > > Thanks for any suggestion,

Re: Web framework

2005-03-13 Thread andre . p . meyer
You should definitely have a look at Zope 3. There is good documentation available and it can do a lot of good stuff. -- http://mail.python.org/mailman/listinfo/python-list

Re: Why is lower() deprecated and how should I replace it?

2005-03-13 Thread Robert Kern
gf gf wrote: I read that lower() is deprecated. Most of the functions in the string module are deprecated, yes. They have been replaced by string methods on the string objects themselves. These methods are *not* deprecated. In [1]: s = 'I aM a hApPY lITtLe STRing thAt WAnTS to Be loWEr CaSE.' I

Re: [Python-Dev] RELEASED Python 2.4.1, release candidate 1

2005-03-13 Thread Vincent Wehren
Martin v. Löwis wrote: Vincent Wehren wrote: is there a reason why msiexec iterates through what looks like all (?) files and directories in/under the destination directory? There is massive file I/O going on there (OK, by now you know I didn't de-install 2.4 before trying ;-)) which explains th

Bind Escape to Exit

2005-03-13 Thread Binny V A
Hello Everyone, I am new to python and I am trying to get a program to close a application when the Escape Key is pressed. This is the code that I used - from Tkinter import * class Application(Frame): def createWidgets(self): self.lab =

Searching for a ComboBox for Tkinter?

2005-03-13 Thread Harlin Seritt
I've created a ghetto-ized ComboBox that should work nicely for Tkinter (unfortunately no dropdown capabilities yet). I've found why it's such a pain in the @ss to create one. You have to re-create common methods and make sure they're mapped to the right component (inside this widget are frame, en

Re: Bind Escape to Exit

2005-03-13 Thread Harlin Seritt
Binny, The only way I could think to get this done was like so: from Tkinter import * class Application: # take away the inherited class def end(self, event): self.master.destroy() def createWidgets(self): self.lab = Label(text="Hello World")

Re: Searching for a ComboBox for Tkinter?

2005-03-13 Thread Harlin Seritt
Or if you prefer you can download it here: http://www.seritt.org/pub/tkinter/Tkinter-03132005.py Replace your Tkinter.py with this one. Make sure you back up your old one in case you decide mine sucks. Thanks, Harlin -- http://mail.python.org/mailman/listinfo/python-list

Re: is there a problem on this simple code

2005-03-13 Thread John Machin
jrlen balane wrote: > the hardware is a school project that uses a microcontroller for "light dimming" > the message command "67" will tell the microcontroller (PIC16F877) to > do a command (to control the intensity of a lamp) > the message command "70" should tell the GUI that the microcontroller

Re: Regular Expressions: large amount of or's

2005-03-13 Thread John Machin
Daniel Yoo wrote: > > Here you go: > > http://hkn.eecs.berkeley.edu/~dyoo/python/ahocorasick/ > > This provides an 'ahocorasick' Python C extension module for doing > matching on a set of keywords. I'll start writing out the package > announcements tomorrow. > Looks good. However: tree.sea

Re: Using reverse iteration to clean up a list

2005-03-13 Thread Michael Hoffman
[EMAIL PROTECTED] wrote: L=[['A', 100], ['B', 300], ['A', 400], ['B', -100]] I want to aggregate these lists, i.e. to reduce L to L=[['A', 500], ['B', 200]] #500 = 100+400, 200=300-100 """ from itertools import groupby from operator import itemgetter [(key, sum(item[1] for item in sublist)) for ke

Re: error sending path to Win OS

2005-03-13 Thread Paul Watson
"Earl Eiland" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > os.path.getsize(Inputdirectory + '\\' + Filename) works, but > os.path.getsize(Inputdirectory + '\\' + Filename.split('.') + '.ext') > Fails reporting "no such file or directory > InputDirectory\\Filename.ext". > os.path.g

Re: issues installing readine-1.12 on WinXP

2005-03-13 Thread Simon Percivall
That shouldn't happen AFAICT. Check line 108 in keysyms.py and make sure it says "vk = VkKeyScan(ord(char))". -- http://mail.python.org/mailman/listinfo/python-list

Re: Why does this not work?

2005-03-13 Thread Michael Hoffman
Gensek wrote: Thanks, guys, it works now. I couldn't have done it without your generous help. You're welcome! Any time. -- Michael Hoffman -- http://mail.python.org/mailman/listinfo/python-list

Re: Safe Local XMLRPC

2005-03-13 Thread Diez B. Roggisch
Stephen Waterbury wrote: > Diez B. Roggisch wrote: >> ... corba is 10-100 times faster over >> the network than soap/xmlrpc. ... > > I'm not challenging these statistics (because I don't know), > but I would be interested in the source. Are you referring > to the results of an actual benchmark,

Re: Tkinter Bitmap Newbie question

2005-03-13 Thread Raseliarison nirinA
"Wim Goffin" wrote: >>> Hi, hello, >>> I'm trying to get a bitmap onto a button, but I can't. >>> Can anyone tell me where to look for a solution? >>> >>> The call I use is this one: >>> self.b = Button(toolbar, text="nieuw", bitmap="@/test.xbm", >>> width=20, command=self.print_msg) >>> >>> The

Re: Itertools wishlists

2005-03-13 Thread bearophileHUGS
Thank you for your very good and interesting answer Raymond. In the Itertool library there are functions not really simple to use/remember, but a flatten() and a partition() can probably be easy to remember (your window() function is probably a sliding window, so it's not a partition(), I presume).

Re: Bind Escape to Exit

2005-03-13 Thread Kent Johnson
Binny V A wrote: Hello Everyone, I am new to python and I am trying to get a program to close a application when the Escape Key is pressed. Here is a version that works. The changes from yours: - Bind , not - Bind the key to the root, not the frame - Define a quit() method that takes an event par

Problem in running a python script from XEmacs

2005-03-13 Thread MarcoL
Hi, I've tried to execute from the buffer (C-c C-c) this python script: s='' s=raw_input('Enter a string:') but I got this error: Enter a string:Traceback (most recent call last): File "", line 2, in ? EOFError: EOF when reading a line I'm using Xemacs 21.5.19 compiled on Fedora Core 3 --with-mul

Creating desktop icons for Innosetup file

2005-03-13 Thread Harlin Seritt
I have a test app that I am creating an Innosetup script for. Everything works great except for the fact that my icons (start menu and desktop) are not starting the executable in the appropriate directory. This is causing problems because it can't find "icon.ico" and other stuff. When I go and manu

Re: Creating desktop icons for Innosetup file

2005-03-13 Thread Will McGugan
Harlin Seritt wrote: I have a test app that I am creating an Innosetup script for. Everything works great except for the fact that my icons (start menu and desktop) are not starting the executable in the appropriate directory. This is causing problems because it can't find "icon.ico" and other stuf

Re: is there a problem on this simple code

2005-03-13 Thread jrlen balane
the assembly program for the microcontroller is created by a classmate. he based the protocol for the serial program from a protocol he found in the internet. unfortunately, i can't find the fpdf file, guess i'll just ask him later when he comes back. On 13 Mar 2005 03:28:43 -0800, John Machin <[E

Re: Thank you. New question concerning text encoding

2005-03-13 Thread Andy Dustman
The default character set used by MySQL for the connection is latin1. If you control the server, you can configure this in the system my.cnf. Otherwise, it is possible to set it in a local configuration file and use the read_default_file option to connect to set it. http://dev.mysql.com/doc/mysql/

Re: issues installing readine-1.12 on WinXP

2005-03-13 Thread Michele Simionato
That line seems right. The function is def char_to_keyinfo(char, control=False, meta=False, shift=False): vk = VkKeyScan(ord(char)) if vk & 0x == 0x: print 'VkKeyScan("%s") = %x' % (char, vk) raise ValueError, 'bad key' if vk & 0x100: shift = True if vk & 0x200: con

Extending and Embedding

2005-03-13 Thread Eduardo Rodrigues
How can I load a module (written in C as a shared library (.so)) through "PyRun_SimpleString"? I've tried "from import *", but a got a message: ImportError: No module named Thanks in advance. Erocha Yahoo! Mail - Com 250MB de espaço. Abra sua conta! http://

Re: Creating desktop icons for Innosetup file

2005-03-13 Thread Harlin Seritt
Thanks Will! That did the trick. -- http://mail.python.org/mailman/listinfo/python-list

Re: issues installing readine-1.12 on WinXP

2005-03-13 Thread Simon Percivall
Possibly. Is the ` sign available as an unmodified key? -- http://mail.python.org/mailman/listinfo/python-list

Re: Using reverse iteration to clean up a list

2005-03-13 Thread tkpmep
Thank you all so much for the generous dollop of help: the dictionary suggestion is particularly helpful. The problem arises as follows: A software application stores the securities held in a portfolio in a .csv file, one row per security, with three colulmns. The first has a security identifier o

Re: smtplib / solaris (newbie problem?)

2005-03-13 Thread chuck
Thanks Steve! Your observation was spot-on. Changed to the correct SMTP host name, and it's all set. The error message 'Connection refused' got me thinking that the SMTP server wouldn't allow this or required some authentication, or etc. Chuck -- http://mail.python.org/mailman/listinfo/python

Re: Extending and Embedding

2005-03-13 Thread Diez B. Roggisch
Eduardo Rodrigues wrote: > How can I load a module (written in C as a shared > library (.so)) through "PyRun_SimpleString"? > > I've tried "from import *", but a got a > message: ImportError: No module named You can't do this. You have to either wrap the module - which is possible in several w

Re: Using reverse iteration to clean up a list

2005-03-13 Thread Michael Hoffman
[EMAIL PROTECTED] wrote: Thank you all so much for the generous dollop of help: the dictionary suggestion is particularly helpful. The problem arises as follows: A software application stores the securities held in a portfolio in a .csv file, one row per security, with three colulmns. The first has

Configure this group in email client

2005-03-13 Thread Kanthi Kiran Narisetti
Hi All, I need in help for configuring python news site in Mozilla Thunderbird. What is the address of Python newsgroup site ? Any other newsgroups related to Python or any programming language will be appreicated. Regards, Kanthi -- http://mail.python.org/mailman/listinfo/python-list

Re: is there a problem on this simple code

2005-03-13 Thread Peter Hansen
Bengt Richter wrote: Sorry for jumping in with a largely irrelevant comment. I didn't look at the code, just sought to illustrate the 6/18 thing further, in a kneejerk reaction. Though BTW FWIW the visual sequence of glyphs representing the data was more a str output than repr, I guess: >>> repr

Re: is there a problem on this simple code

2005-03-13 Thread Peter Hansen
Dennis Lee Bieber wrote: rx_data1=0 while (rx_data1 != 0x46): rx_data1 = ser.read(1) (rx_command) = unpack('1B', rx_data1) Isn't this unpack rather redundant -- assuming ser.read(1) only reads one byte, then rx_data1 and rx_command would be identical. Brain fart... unpack converts the raw

Re: confusion around CustomException example in 'Python in a Nutshell'

2005-03-13 Thread Peter Hansen
[EMAIL PROTECTED] wrote: What I am trying to do is get information from a raised custom exception. I am catching the exception in a main() function but it was actually raised in a separate module function. It would be nice if I could print out where the exception was raised from (module.functio

Re: Web framework

2005-03-13 Thread Sridhar
I'd say Nevow! For apache setup, you might be interested in my wsgi [1] implementation. [1] http://twistedmatrix.com/pipermail/twisted-web/2005-March/001293.html -- http://mail.python.org/mailman/listinfo/python-list

Re: Why does this not work?

2005-03-13 Thread Peter Hansen
D H wrote: Ask on the wxpython or python-tutor list instead of this one. You'll get better help than there as you've already found out. Not likely. IMHO he got the best help he could possibly have gotten, but clearly that's debatable. :-) The only thing I'd agree with is what Michael Hoffman sai

tkinter: always scroll to show last line of text

2005-03-13 Thread Benjamin Rutt
I have a tkinter 'Text' and 'Scrollbar' connected and working normally. When a new line of text is inserted (because I'm monitoring an output stream), I'd like the text and scrollbar to be scrolled to the bottom, so the latest line of text is always shown. How to do this? Thanks, -- Benjamin Ru

An array of a "list" of names.

2005-03-13 Thread spencer
Hi, I'm using NumPy to build an array of a list of names that will be of multiple dimensions.I did do a google on this subject, but couldn't find what I was looking for. The problem I'm having is there are space between each character in each name. To fix this I used the attribute 'tostring'. Thi

Re: survey

2005-03-13 Thread Peter Hansen
D H wrote: Peter Hansen wrote: Dave Zhu wrote: Is there any survey on scripting languages? I would like to get information on several scripting languages including Python, Perl, Ruby, Tcl, etc. What kind of information? ... See the other responses to his question. Why would I want to do that? Did

Re: Turning String into Numerical Equation

2005-03-13 Thread Paul McGuire
Almost this exact parser, called fourFn.py, is included in the examples with pyparsing (at http://pyparsing.sourceforge.net). Since it is pure Python, you can extend the grammar with whatever builtin functions you like. But it *is* a parser, not just a short cut. -- Paul -- http://mail.python.

urllib's functionality with urllib2

2005-03-13 Thread Monty
Hello, Sorry for this maybe stupid newbie question but I didn't find any answer in all my readings about python: With urllib, using urlretrieve, it's possible to get the number of blocks transferred and the total size of the file. Is it possible to get those informations with urllib2 ? ( I have

Re: is there a problem on this simple code

2005-03-13 Thread Jan Rienyer Gadil
@ sir Peter so you mean that it is correct (at least on the unpack() part) when i run this program on IDLE , Python 2.3 (enthought edition), nothing is outputted on the shell, until i decide to close the shell, wherein it tells me if i would like to kill a process... import serial import string

Re: Turning String into Numerical Equation

2005-03-13 Thread Brian Kazian
Wow, thanks so much guys! "Michael Spencer" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Brian Kazian wrote: >> Thanks for the help, I didn't even think of that. >> >> I'm guessing there's no easy way to handle exponents or logarithmic >> functions? I will be running into thes

how to delete the close button (the X on the right most corner of the window) on a window

2005-03-13 Thread jrlen balane
i am working on an MDIParentFrame and MDIChildFrame. Now, what i want to do is make the ChildFrame not that easy to close by removing the close button (the X on the right most corner of the window) if this is possible... how am i going to do this? -- http://mail.python.org/mailman/listinfo/python

Linux Multimedia System

2005-03-13 Thread Marek Franke
Hi there, we have started with some people from our LUG (Linux User Group) a 'little' project, called LMMS (Linux Multimedia System). When it's 'finished' it shall be a window-manager for use on TV and handle with joysticks/gamepads. As the name says, it is for multimedia-applications, like list

Re: issues installing readine-1.12 on WinXP

2005-03-13 Thread Michele Simionato
No, I don't even know how to get it under Windows (usually I use Linux). Switching to the US keyboard does not help, anyway. I get the same error. Michele -- http://mail.python.org/mailman/listinfo/python-list

Re: Web framework

2005-03-13 Thread Joe
On 13 Mar 2005 01:13:00 -0800, [EMAIL PROTECTED] wrote: >You should definitely have a look at Zope 3. There is good >documentation available and it can do a lot of good stuff. But then, the thing I hate about Zope, is that source code is not accessible with normal development tools since it's stu

Re: Linux Multimedia System

2005-03-13 Thread Max Erickson
Marek Franke wrote: > Hi there, > > we have started with some people from our LUG (Linux User Group) a 'little' > project, called LMMS (Linux Multimedia System). When it's 'finished' it > shall be a window-manager for use on TV and handle with joysticks/gamepads. > > As the name says, it is for mu

Re: Web framework

2005-03-13 Thread Diez B. Roggisch
Joe wrote: > On 13 Mar 2005 01:13:00 -0800, [EMAIL PROTECTED] wrote: > >>You should definitely have a look at Zope 3. There is good >>documentation available and it can do a lot of good stuff. > > But then, the thing I hate about Zope, is that source code is not > accessible with normal developm

Re: Coding help...very basic

2005-03-13 Thread Igorati
Hello all, I am still needing some help on this code, I have gone a bit further on it. Thank you for the help. I am trying to understand how to make the file searchable and how I am to make the deposit and withdrawl interact with the transaction class. class Account: def __init__(self, initia

Re: Linux Multimedia System

2005-03-13 Thread Marek Franke
> Be sure to check out freevo at http://freevo.sourceforge.net/ as it is > quite similar to what you are describing and they are quite far along. > > max Yes, there are a lot of projects like LMMS, just take a look at www.freshmeat.net or www.sourceforge.net. Or MythTV is something like LMMS too.

Re: is there a problem on this simple code

2005-03-13 Thread Bengt Richter
On Sun, 13 Mar 2005 10:46:52 -0500, Peter Hansen <[EMAIL PROTECTED]> wrote: >Bengt Richter wrote: >> Sorry for jumping in with a largely irrelevant comment. I didn't look >> at the code, just sought to illustrate the 6/18 thing further, in a kneejerk >> reaction. >> Though BTW FWIW the visual seq

Re: Linux Multimedia System

2005-03-13 Thread Roland Heiber
Marek Franke wrote: too. The whole project is just for fun. Afaik Freevo and/or MythTV are written in C/C++ and don't have any support for joysticks (afaik!). And the Freevo is pure python already ;) Greetings, Roland -- http://mail.python.org/mailman/listinfo/python-list

brand new to python

2005-03-13 Thread richard . hubbell
I am sure this is old news, the syntax of python is crazy to me. There I said it, I'm sure I'll get over it or around it. I was trying to make a whois script work and was unable. May be someone with lint-like eyes can tell what's wrong. Using xemacs I had hoped that python mode would do more for

Re: PEP 246 revision

2005-03-13 Thread boisgera
> >Have you read the BDFL's "Python Optional Typechecking Redux" ? > > Yes. > > >(http://www.artima.com/weblogs/viewpost.jsp?thread=89161) > >It's usage of adapt assumes that "a class is a protocol", so I > >guess that it does not work with the new version of PEP 246. > > Why not? There's nothin

Re: how to delete the close button (the X on the right most corner of the window) on a window

2005-03-13 Thread Jeremy Bowers
On Sun, 13 Mar 2005 09:25:43 -0800, jrlen balane wrote: > i am working on an MDIParentFrame and MDIChildFrame. Now, what i want > to do is make the ChildFrame not that easy to close by removing the > close button (the X on the right most corner of the window) if this is > possible... > > how am i

Re: brand new to python

2005-03-13 Thread Dmitry A.Lyakhovets
Hello! You should at least close the 'try' block, which you started at line 68 (if i'm not mistaken): def _whois(domainname, whoisserver): s = None ## try until we are connected while s == None: try: There is no corresponding 'except' till DomainRecord class definition.

Re: Beware complexity

2005-03-13 Thread Brandon J. Van Every
Philip Smith wrote: > > Conventions on type conversion are just one example. Without using > strict coding conventions the richness of the language could, and > often did, result in ambiguity. In my experience too C++ has > defeated its own object (eg portability) - I've given up in many > cases

Re: pyasm 0.2 - dynamic x86 assembler for python

2005-03-13 Thread JanC
Stefan Behnel schreef: > Meaning: Put the assembler into the doc-string of a function. Then > use a decorator to run the assembler on the function's __doc__ string > and build an assembly function that takes the same arguments to make > the assembly function directly callable. That would 'disa

Re: brand new to python

2005-03-13 Thread Bengt Richter
On 13 Mar 2005 11:22:54 -0800, [EMAIL PROTECTED] wrote: >I am sure this is old news, the syntax of python is crazy to me. >There I said it, I'm sure I'll get over it or around it. > >I was trying to make a whois script work and was unable. > >May be someone with lint-like eyes can tell what's wron

Re: tkinter: always scroll to show last line of text

2005-03-13 Thread Martin Franklin
Benjamin Rutt wrote: I have a tkinter 'Text' and 'Scrollbar' connected and working normally. When a new line of text is inserted (because I'm monitoring an output stream), I'd like the text and scrollbar to be scrolled to the bottom, so the latest line of text is always shown. How to do this? Th

Re: Searching for a ComboBox for Tkinter?

2005-03-13 Thread Martin Franklin
Harlin Seritt wrote: I've created a ghetto-ized ComboBox that should work nicely for Tkinter (unfortunately no dropdown capabilities yet). I've found why it's such a pain in the @ss to create one. You have to re-create common methods and make sure they're mapped to the right component (inside this

Re: Overloading the "and" operator

2005-03-13 Thread Terry Reedy
"Fredrik Bertilsson" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] >I am trying to overload the "and" operatior, but my __and__ method is > never called. That is because, properly speaking, 'and' and 'or' are, in Python, in-line flow-control keywords (related to 'if' and 'else'),

Re: Bind Escape to Exit

2005-03-13 Thread Martin Franklin
Kent Johnson wrote: Binny V A wrote: Hello Everyone, I am new to python and I am trying to get a program to close a application when the Escape Key is pressed. Here is a version that works. The changes from yours: - Bind , not These amount to the same thing AFAIK - Bind the key to the root, not

Re: Itertools wishlists

2005-03-13 Thread Terry Reedy
"Raymond Hettinger" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > FWIW, requests for additions to the itertools module have not fallen on > deaf > ears. There are no arbitrary restraints on building out this module. > Each > request has gotten careful thought and a couple of th

Re: Searching for a ComboBox for Tkinter?

2005-03-13 Thread Martin Franklin
Martin Franklin wrote: Harlin Seritt wrote: I've created a ghetto-ized ComboBox that should work nicely for Tkinter (unfortunately no dropdown capabilities yet). I've found why it's such a pain in the @ss to create one. You have to re-create common methods and make sure they're mapped to the right

Re: Linux Multimedia System

2005-03-13 Thread Lucas Raab
Marek Franke wrote: Hi there, we have started with some people from our LUG (Linux User Group) a 'little' project, called LMMS (Linux Multimedia System). When it's 'finished' it shall be a window-manager for use on TV and handle with joysticks/gamepads. As the name says, it is for multimedia-appl

Re: Linux Multimedia System

2005-03-13 Thread Lucas Raab
Marek Franke wrote: Hi there, we have started with some people from our LUG (Linux User Group) a 'little' project, called LMMS (Linux Multimedia System). When it's 'finished' it shall be a window-manager for use on TV and handle with joysticks/gamepads. As the name says, it is for multimedia-appl

Re: autoexecution in Windows

2005-03-13 Thread Thorsten Kampe
On Mon, 07 Mar 2005 16:06:46 -0500, rbt wrote: > Earl Eiland wrote: >> In Linux, if I make the first line #!/path/to/Python, all I have to do >> to execute the program is type ./FileName (assuming my pwd is the same >> as FileName). what's the Windows equivalent? >> Earl >> >> On Mon, 2005-03-07

Re: Huge performance gain compared to perl while loading a text file in a list ...!?

2005-03-13 Thread Martin Franklin
Paul Rubin wrote: "Marc H." <[EMAIL PROTECTED]> writes: I'm fairly new to python, and don't know much of its inner working so I wonder if someone could explain to me why it is so much faster in python to open a file and load it in a list/array ? My guess is readlines() in Python is separating on n

Re: Debugging Python Scripts inside other processes

2005-03-13 Thread Peter Maas
A. Klingenstein schrieb: I embedded Python in a Windows C++ program. Now I want to debug my embedded scripts which of course won't run in any IDE process. Commercial IDEs like WingIDE can attach to external processes by importing a module in the scripts. Is there a debugger capable of this whic

Re: is there a problem on this simple code

2005-03-13 Thread John Machin
Jan Rienyer Gadil wrote: > @ sir Peter > so you mean that it is correct (at least on the unpack() part) No he doesn't mean that at all. All it means is that minor scuffles have broken out among the spectators. Don't worry about them, batons & water cannon will fix them; you concentrate on the foo

Re: Web framework

2005-03-13 Thread Venkat B
> I'd say Nevow! For apache setup, you might be interested in my wsgi [1] > implementation. Hi Sridhar, Are you aware of Nevow's "integrability" with the webservers (CGIHTTPServer in particular) that come packaged with Python itself ? Thanks, /venkat -- http://mail.python.org/mailman/listinfo

Re: Adapting code to multiple platforms

2005-03-13 Thread Paul Watson
"Peter Hansen" <[EMAIL PROTECTED]> wrote in message news:[EMAIL PROTECTED] > Simon John wrote: >> If you're using a GUI, then that may help you decode the platform too - >> for example wxPython has wx.Platform, there's also platform.platform() >> , sys.platform and os.name >> >> You could try impo

Re: Regular Expressions: large amount of or's

2005-03-13 Thread Daniel Yoo
John Machin <[EMAIL PROTECTED]> wrote: : tree.search("I went to alpha beta the other day to pick up some spam") : could use a startpos (default=0) argument for efficiently restarting : the search after finding the first match Ok, that's easy to fix. I'll do that tonight. -- http://mail.python

running a python script in drpython

2005-03-13 Thread john
Haveing problems writeing a program then running it in python 2.3.5 interpreter. Called the program test.py used chmod to make it executable in linux #! /usr/bin/python print 2** 8 print 'the bright side ' + 'of life' >>> python test.py File "", line 1 python test.py ^ Syntax

Re: Licensing Python code under the Python license

2005-03-13 Thread JanC
Martin v. Löwis schreef: > Larry argues that a license should be legally meaningful, and > legally clear - or else there is little point in formulating > a license in the first place. This is difficult to do right, if you have to consider all the laws in different countries... -- JanC "Be str

Re: Extending and Embedding

2005-03-13 Thread Eduardo Rodrigues
Sorry, I guess that I wasn't clear. I've made a module using swig that wrap functions written in C. If I load that module in python using: >>> from import * it works fine. But if I execute this same command using PyRun_SimpleString in another code written in C, it doesn't work, i.e. I can't load

Re: smtplib / solaris (newbie problem?)

2005-03-13 Thread "Martin v. Löwis"
[EMAIL PROTECTED] wrote: The error message 'Connection refused' got me thinking that the SMTP server wouldn't allow this or required some authentication, or etc. In case this isn't clear yet: the "connection refused" error happens in TCP sockets if the remote machine is turned on, but offers no ser

Re: issues installing readine-1.12 on WinXP

2005-03-13 Thread Simon Percivall
Well, just modify the source in that case. -- http://mail.python.org/mailman/listinfo/python-list

Re: Install problem Windows xp HE

2005-03-13 Thread Raseliarison nirinA
"Jan Ekström" wrote: > Here is the error. > IDLE 1.1 > >>> python > > Traceback (most recent call last): > File "", line 1, in -toplevel-python > NameError: name 'python' is not defined > >>> this should be a success install report! not an error. start coding and see what happens. >>> print "He

Re: Searching for a ComboBox for Tkinter?

2005-03-13 Thread Raseliarison nirinA
"Harlin Seritt" wrote: > I've created a ghetto-ized ComboBox that should work nicely for > Tkinter > (unfortunately no dropdown capabilities yet). > how about: >>> import Tix >>> print Tix.ComboBox.__doc__ ComboBox - an Entry field with a dropdown menu. The user can select a choice by either

Re: tkinter: always scroll to show last line of text

2005-03-13 Thread Benjamin Rutt
Martin Franklin <[EMAIL PROTECTED]> writes: > text.yview_pickplace("end") Thank you, works perfectly! -- Benjamin Rutt -- http://mail.python.org/mailman/listinfo/python-list

Re: Licensing Python code under the Python license

2005-03-13 Thread "Martin v. Löwis"
JanC wrote: This is difficult to do right, if you have to consider all the laws in different countries... Right. So he points out that his explanations are for US copyright law only, and then that legislation even in different US states, or perhaps even in districts, might be different. Therefore,

Re: [Python-Dev] RELEASED Python 2.4.1, release candidate 1

2005-03-13 Thread "Martin v. Löwis"
Richie Hindle wrote: I could try again, but maybe there's some useful information you can get from the partially upgraded environment. Here's how the \python24 directory looks: I tried to reproduce it, and failed - if the DLL is not in use, it is updated correctly; if it is in use, a window pops u

Re: pyasm 0.2 - dynamic x86 assembler for python

2005-03-13 Thread Michael Spencer
JanC wrote: [an example of using decorators to control pyasm] Another (perhaps wacky) approach would be to change the assembler source syntax enough to make it legal Python - in particular, this means parenthesizing the arguments - then it can just be stored in-line with other Python source. Thi

Re: running a python script in drpython

2005-03-13 Thread john
john wrote: Haveing problems writeing a program then running it in python 2.3.5 interpreter. Called the program test.py used chmod to make it executable in linux #! /usr/bin/python print 2** 8 print 'the bright side ' + 'of life' >>> python test.py File "", line 1 python test.py

Convert python to exe

2005-03-13 Thread [EMAIL PROTECTED]
Hi I have a python script under linux, I wonder if I can be converted to an executable or not? Richard -- http://mail.python.org/mailman/listinfo/python-list

Determining the length of strings in a list

2005-03-13 Thread robin . siebler
I have a dictionary. Each key contains a list. I am using the contents of the list to build a portion of a command line. However, before I can build the command line, I have to make sure that the command isn't too long. This means that I have to step through each item in the list twice: once to

Apparently, I don't understand threading

2005-03-13 Thread jwsacksteder
The following script does not behave as expected. I wanted to terminate the 'mythread' thread after 5 seconds. What I see is the threading.Thread call blocking until the 15 second sleep is done. Suggestions?   import threading from time import sleep   class FooClass:     def

Re: tkinter: always scroll to show last line of text

2005-03-13 Thread Raseliarison nirinA
"Martin Franklin" wrote: > Benjamin Rutt wrote: > > I have a tkinter 'Text' and 'Scrollbar' connected and working > > normally. When a new line of text is inserted (because I'm > > monitoring > > an output stream), I'd like the text and scrollbar to be scrolled > > to > > the bottom, so the late

Re: Regular Expressions: large amount of or's

2005-03-13 Thread Scott David Daniels
Daniel Yoo wrote: John Machin <[EMAIL PROTECTED]> wrote: : tree.search("I went to alpha beta the other day to pick up some spam") : could use a startpos (default=0) argument for efficiently restarting : the search after finding the first match Ok, that's easy to fix. I'll do that tonight. I have a

Re: pyasm 0.2 - dynamic x86 assembler for python

2005-03-13 Thread olsongt
[JanC] > The code below makes it possible to write assembler code for different > architectures (in case pyasm ever supports that ;) and also a Python > code version to use when running on a system where no assembler code > can be used. It prints: [Michael] > Another (perhaps wacky) approach woul

  1   2   >