When I used the following line to play a midi file in linux,
return_value = os.system('timidity test.mid')
I have encountered two problems.
1. The python script halts until timidity has finished.
2. If I had control of the script, I can't think how I would stop timidity.
Any advice on the 'area'
Simon Brunning wrote:
> The subprocess module might be worth a look.
That looks about right for what I need (once I understand it!).
Thanks very much.
--
http://mail.python.org/mailman/listinfo/python-list
Is it possible to to detect a Tkinter top-level window being closed with the
close icon/button (top right), for example to call a function before the
window actually closes?
Python 2.4 / Linux (2.6 kernel) if that makes any difference.
Any info would be greatly appreciated.
Thanks
Glen
--
http
Thanks Fredrik and Adonis that's just what I needed, plus a bit more to
learn about.
--
http://mail.python.org/mailman/listinfo/python-list
;when' is an EOF received.
Glen
--
http://mail.python.org/mailman/listinfo/python-list
> > Could someone explain what "cooked data" is.
> discussed in the telnet RFC, which is in RFC854 telnetlib docstring.
> "Cooked" data is data after these special sequences are removed.
>
>>'when' is an EOF received.
> the only EOF in telnet is when the other side closes the socket.
Thanks, thats
Being a new'ish user to both Linux and Python, I've been 'happily'
learning Python (2.3) with Idle and Tkinter as installed with Mandrake
10.
Thought I would try installing Python 2.4 (to completely replace 2.3)
(first time I've tried installing anything from source)
Followed the readme file (all
> > Being a new'ish user to both Linux and Python, I've been 'happily'
> > learning Python (2.3) with Idle and Tkinter as installed with Mandrake
> > 10.
> > All seemed to work without any errors, but starting Python from Idle
> > or a console displays the same statup text,
> >
> > Python 2.3.3
#!/usr/local/bin/python
import sys
print "1.\tDo Something"
print "2.\tDo Something"
print "3.\tDo Something"
print "4.\tDo Something"
print "5.\tDo Something"
print "6.\tExit"
choice=raw_input("Please Enter Choice: ")
if int(choice)==1:
print "Here"
else:
pass
if int(choice)==2:
else:
String( str(tL2[i][0])
).rightJustified(2)
+ ':' + QtCore.QString( str(tL2[i][1]) ).rightJustified(4) )
This still gives me uneven columns.
Any suggestions?
Thanks,
Glen
--
http://mail.python.org/mailman/listinfo/python-list
On Wed, 18 Apr 2007 22:50:14 +, Glen wrote:
Ok, obviously, my post didn't come out the way I wanted it to. In the
first example from my text file below, the dictionary pairs, constructed
from sorted tuples were in straight columns. When I write them to my
QTextEdit, however, the column
e hearing from me pretty
regularly, since I'm in the process of learning Python and PyQt
simultaneously.
Glen
--
http://mail.python.org/mailman/listinfo/python-list
On Sat, 21 Apr 2007 03:15:00 +0200, David Boddie wrote:
> On Tuesday 17 April 2007 07:42, Glen wrote:
>
# Just to avoid any misunderstanding: the form is actually stored as XML.
# You can create C++ code with uic or Python code with pyuic4.
Right. I do remember noticing that when I open
gridlayout(dldialog)
What exactly is going on here? Are these instances that are defined
somewhere else (their not in the local scope.)? Can I do the same in my
code when I import something?
Thanks,
Glen
Glen
--
http://mail.python.org/mailman/listinfo/python-list
7;s ok now. Maybe vim was just displaying the text wrong for a
minute. Had me going though.
Thanks again.
Glen
> Are you sure? That's strange. I have never seen that. Here is a
snippet
> of one of my typical .py files generated by 'pyuic4':
>
> self.gridlayout =
Hello,
I've written a script in python and put together a simple QFrame with a
QTextBrowser with Designer. I've translated the C++ into python using
puic4. The .py file is called outputWin.py. My Script and its
functions are in cnt.py. Finally, my main is in pball.py which follows
her
opriate time (Just In Time) compile that to
machine code and execute it. This is common for Java, and more recently
for languages like Matlab.
-- glen
--
https://mail.python.org/mailman/listinfo/python-list
In comp.lang.fortran Rainer Weikusat wrote:
> glen herrmannsfeldt writes:
>> In comp.lang.fortran E.D.G. wrote:
>>>>> "E.D.G." wrote in message
>>>>> news:ro-dnch2dptbrhnpnz2dnuvz_rsdn...@earthlink.com...
>>> Posted by E.D.G. on Nove
In IPython:
>import struct
>struct.calcsize('4s')
4
>struct.calcsize('Q')
8
>struct.calcsize('4sQ')
16
This doesn't make sense to me. Can anyone explain?
--
http://mail.python.org/mailman/listinfo/python-list
On Dec 4, 9:38 am, Duncan Booth wrote:
> Glen Rice wrote:
> > In IPython:
> >>import struct
> >>struct.calcsize('4s')
> > 4
> >>struct.calcsize('Q')
> > 8
> >>struct.calcsize('4sQ')
> > 16
>
>
On Thu, 17 Apr 2008 13:30:18 -0500, Grant Edwards wrote:
> When using Google Groups can one kill all posts made via Google Groups?
> Presuming he has no burning need to see his own posts (something that
> can't be said for everybody in the history of Usenet), it might still be
> a viable approach
On Tue, 09 Sep 2008 08:32:29 +1000, Tom Harris wrote:
> I agree. So did Forth's early designers. That is why Forth's number
> parser considers a word that starts with a number and has embedded
> punctuation to be a 32 bit integer, and simply ignores the punctuation.
> I haven't used Forth in years
ith this. The usual way would be to
pass the length, as with assumed size arrays. I believe terminating
strings with unusual (likely not null) characters was also done.
-- glen
--
http://mail.python.org/mailman/listinfo/python-list
fld = [ ]
data = shlex.split(ln)
for item in data:
fld.append(item)
fld = fld + [0] * (5 - len(data))
On Sat, 29 Sep 2018 at 11:03, Glen D souza wrote:
> i have a approach, it may not be best
>
> fld = [ ]
> for data in shlex.split(ln):
>fld.append(data)
>
&g
i have a approach, it may not be best
fld = [ ]
for data in shlex.split(ln):
fld.append(data)
On Sat, 29 Sep 2018 at 07:52, wrote:
> On Friday, September 28, 2018 at 11:03:17 AM UTC-7, Chris Green wrote:
> > I have a list created by:-
> >
> > fld = shlex.split(ln)
> >
> > It may co
;)]) for
> p in '[EMAIL PROTECTED]'.split('@')])"
Thanks Bruno. I came up with a similar solution today at work, which
involves an 'init' method which is called at the bottom of each module
that defines subclasses of Exposed and sets up static mappings for the
exposed methods. I guess my solution is slightly less elegant because
it requires this ugly explicit init call outside the classes that it
actually deals with, however it is more efficient because the dir()
pass happens once on module load, instead of every time I want the list
of exposed methods.
Thanks for the help though,
Glen
--
http://mail.python.org/mailman/listinfo/python-list
quot;
) )
That's better, but still ugly. Is there a better way?
Thanks for all the help thus far guys,
Glen
Maric Michaud wrote:
> Le jeudi 05 octobre 2006 17:18, [EMAIL PROTECTED] a écrit :
> > I guess my solution is slightly less elegant because
> > it requires this ugly e
le type. Is the Splat/SplatType pairing really a common design
pattern when trying to use metaclasses in this way?
Also ... as for the 'inspect' based solution, yeah I can see that would
work, but it seems very hacky to me and my gut reaction is to avoid
that kind of thing ...
Cheers,
Glen
--
http://mail.python.org/mailman/listinfo/python-list
enclosing class into the decorator, which in turn
means that static tracking of the list of exposed methods is impossible
(at least, if I want to use decorators).
Any ideas that will enable my initial design, or suggestions for an
elegant, workable alternative would be much appreciated.
Cheers,
29 matches
Mail list logo