q
('D:\\music\\D', 'Daniel Lanois')
>>> q = os.path.split(q[0])
>>> q
('D:\\music', 'D')
And another idea might be to do a split using os.sep:
>>> import os
>>> d = 'D:\\music\\D\\Daniel Lanois\\For the beauty of Wynona'
>>> d.split(os.sep)
['D:', 'music', 'D', 'Daniel Lanois', 'For the beauty of Wynona']
Hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
It looks like the docs could use some examples of the various
assignments it refers to.
I think something like Bengt posted would be a nice addition if it
included assignments with slices and dicts too.
Just a thought.
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
Fredrik and Bengt:
Thank you for the time.
I will study the docs and play with the shell till this is firm.
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
etting
overloaded.
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
s is not ordinarily a useful entry point, and is
documented here only for the sake of completeness.)
# Just like in my first post
>>> from StringIO import StringIO
>>> from shlex import shlex
>>> t = shlex(StringIO("2>&1"))
>>> t.get_token()
'2'
>>> t.get_token()
'>'
>>> t.get_token()
'&'
>>> t.get_token()
'1'
>>> t.get_token()
''
# Your way
>>> t = shlex(StringIO("2>&1"))
>>> t.read_token()
'2'
>>> t.read_token()
'&'
>>> t.read_token()
'1'
>>> t.read_token()
''
>>>
Hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
t; sh.get_token()
etc...
Python 2.2 and maybe lower:
>>> import shlex
>>> import StringIO
>>> s = StringIO.StringIO('$(which sh)')
>>> sh = shlex.shlex(s)
>>> sh.get_token()
'$'
>>> sh.get_token()
'('
>>> sh.get_token()
'which'
>>> sh.get_token()
'sh'
>>> sh.get_token()
')'
>>> sh.get_token()
etc...
Hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
I think they that
should be avoided for clarity.
Steve thanks for your time. I always learn a little from you ;)
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
es sense
>>> w = 1,2,3
>>> w.__doc__
"""tuple() -> an empty tuple
tuple(sequence) -> tuple initialized from sequence's items
If the argument is a tuple, the return value is the same object."""
Thanks for your time Bengt!
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
.
The problem is why should this be the same:
a,b,c=(1,2,3)
(a,b,c)=(1,2,3)
Seems weird, non-intuitive that a tuple unpacking and tuple creation
have the same bytecode.
So why is this done? What is the reason, I am sure there are a few ;)
p.s. I am leaving out for a while and will read/followup later if
needed. Thank you all for your time.
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
27;__name__', 'a', 'b', 'c', 'd', 'f',
'shell']
>>> del a,b,c,d
>>> # Where is the tuple (a,b,c,d)? There isn't one.
>>> # assign to a single name ( don't do tuple unpacking )
>>> tup=f(1,2,3,4)
>>> dir()
['__builtins__', '__doc__', '__name__', 'f', 'shell', 'tup']
Now there is.
Steve since you are closer to expert than novice you understand the
difference.
I feel this can be confusing to newbies, maybe you disagree.
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
ltins__', '__doc__', '__name__', 'a', 'b', 'c', 'd', 'f',
'shell']
>>> del a,b,c,d
>>> # Where is the tuple (a,s,d,f)? There isn't one.
>>> # assign to a single name ( don't do tuple
(x,y,dotp,sumx,maxv) = abc(x,y,dotp,sumx,maxv)
This will only create a tuple in memory that has no name to reference
it by!
How would you access the returned value?
If you want a tuple you need to assign all the return vales to a single
name.
mytup = abc(x,y,dotp,sumx,maxv)
M.E.Farmer
--
http
abc(x,y,0,0,0)
> print 'Calling function abc'
> print 'Array X:',abcinfo[0]
> print 'Array Y:',abcinfo[1]
> print 'Dot Product of X and Y:',abcinfo[2]
> print 'Sum of array X:',abcinfo[3]
> print 'Max value of array Y:',abcinfo[4]
Or you could use a dictionary, or etc...
The possibilities are endless.
Be sure to study up on namespaces, it will ease your Python woes.
Namespaces are the most fundamental part of Python that new users don't
understand. Namespace mastery will take you far.
Just remember there are only two scopes local and global ;)
http://docs.python.org
hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
This could be fun!
# random clicks
# play with values to maximize annoyance
if __name__ == "__main__":
import random
for i in range(1000):
x = random.randint(0,800)
y = random.randint(0,600)
Click(x,y)
time.sleep(random.randint(0,20))
--
http://mail.python.
't logical till you see the full issue.
In plain english: I couldn't refuse the temptation to guess( and
guessed wrong ).
+1 on the bzip2
Thanks,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
ring.','\n']
It would be hard to get to the next prompt after a print "dsfdfdssd",
if the shell didn't add the \n to get it there.
Also note most shells use repr or str behind the scenes for output to
sys.stdout sys.stderr.
>>> def g():
... pass
...
&g
Thank you!
"""ZIP_DEFLATED
The numeric constant for the usual ZIP compression method. This
requires the zlib module. No other compression methods are currently
supported."""
That is where I got the 'only compression type'.
It all makes sense
ot;C:\Python22\Lib\zipfile.py", line 169, in __init__
raise RuntimeError, "That compression method is not supported"
RuntimeError: That compression method is not supported
>>> a = zipfile.ZipFile('c:\tmp\z.zip', 'w', compression=8)
I saw compression=0 and assumed that 1 would mean true, but no!
zipfile.ZIP_DEFLATED = 8, defies logic, it is the only compression type
why not accept any non zero as compression.
Got any answers to the problems I outlined or have they been fixed yet
?
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
n overwrite the original.
You can have mulitple files with the same name!
Obviusly that can cause problems.
This can be very confusing.
hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
No book just these lectures that cover
everything you want '
I knew I was asking the right person ;)
Now I just need to read your lectures...but first I am going to wrap my
head in duct tape.
( prevents/contains explosions )
Thanks for your time,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
oved from the language; a part for that consideration,
> the typical
> use for classmethods is as object factories, to provide alternative
> constructors.
>
>Michele Simionato
Thank you, I had a feeling that it was just extra fluff.
But I felt/feel that way about list comprehensions and decorators too
;)
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
amp;lr=')
webbrowser('http://python.org')
#####
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
Awesome! works perfectly on win2k -> I.E 6
Python makes COM almost readable ;)
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
.
Michele Simionato wrote:
> > M.E.Farmer:
>
> >Your answer lies somewhere in this page ;)
> >http://www.python.org/2.2.2/descrintro.html
>
> Yes, when it refers to
>
> http://www.python.org/2.3/mro.html
>
> (section Bad Method Resolution
Your answer lies somewhere in this page ;)
http://www.python.org/2.2.2/descrintro.html
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
bsequent
expressions are printed to this file object. If the first expression
evaluates to None, then sys.stdout is used as the file for output.
hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
Look inthe demo that comes with wxPython it is in tree process and
events -> threads .
There is a nice demo of PostEvent().
Another way would be to use Queues as others have mention .
You can create a new frame and have it call the queue for data.
M.E.Farmer
--
http://mail.python.org/mail
t open a new window.
Have not looked into it but you can probably do this easily with
win32api .
Search MSDN and then translate that into win32api for Python.
hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
l signals.
"""
Be sure to check out the examples.
Might be worth a look:
http://www.speech.kth.se/projects/speech_projects.html
http://www.speech.kth.se/cost250/
You might also have luck with Windows using Microsoft Speech SDK ( it
is huge ).
Combined with Python scrtiptng you can go far
er !
For what it is worth +1 ;)
On another note why is maketrans in the string module
I was a bit lost finding it the first time should it be builtin?
transtable = "abcdefg".maketrans("qwertyu")
Probably missing something.
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
eventually be revamped when the 'new' game engine is stable.
Until then you might be able to use the old one but I have had many
problems getting it to work reliably on Firefox or Mozilla, it works
well with I.E. but
Have fun and experiment.
M.E.Farmer
--
http://mail.python.o
What's wrong with :
s = s.replace('badchars', "")
It seems obvious to replace a char ( to me anyway ) with a blank
string, rather than to 'translate' it to None.
I am sure you have a reason what am I missing ?
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
I found an excellent example that was posted by the F-bot.
Fredrik Lundh May 26 2000
From: "Fredrik Lundh" <[EMAIL PROTECTED]>
Date: 2000/05/26
richard_chamberl...@ wrote:
> I'm having great difficulties getting Python to work via CGI.
> Is there anyway I can get the traceback on to the web p
Just in case you don't have a clue what they are talking about ;)
import traceback
try:
#your stuff here
except:
traceback.print_exc()
That should return any exceptions you may be throwing.
--
http://mail.python.org/mailman/listinfo/python-list
Appears that most of the relevant code is in the Helper and TextDoc
classes of pydoc also might need the doc() function.
My head hurts every time I stare at the internals of pydoc ;)
I guess it is time for a lunch break.
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
se?
>
> I think we don't need the mro, or any of the magic methods inherited
> from the builtin.
> --
> Michael Hoffman
The help code is part of pydoc, IIRC, feel free to have a go at it ;)
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
def __init__(self):
"""Python calls me if I am defined"""
base.__init__(self)
You will see this in more than GUI code, it is part of Python's OO
design.
I first saw this in some threading code , thru me for a loop too ;)
search strategy:
Python OO
Python i
t; im = Image.open(c)
>>> im.show()
Alternatively you can create a StringIO object and pickle that in your
dictionary so you can just load it later with PIL.
Pickling will bloat the size of your file so you might want to use some
compression, although most formats will compress very little the
pickling overhead can __mostly__ be avoided.
There are boundless ways to do this and this just one of them.
hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
> You're use of the word "driver" is one with which I'm not
> familiar. But I don't really "do windows" so it's probably a
> Widnowism.
It is a windowism but not exclusively ;).
http://www.collaborium.org/onsite/romania/UTILS/Printing-HOWTO/winprinters.html
This is the first link I found that men
##
u'People do this sometime for a block comment type of thing' \
r"This type of string should be removed also" \
""" and this one too! """
# did I forget anything obvious ?
#
When the docstring is removed it should also consume the blank line
that is left behind.
Got to go to work, I'll think about it over the weekend.
If anyone else wants to play you are welcome to join.
Can pyparsing do this easily?( Paul probably has a 'six-line' solution
tucked away somewhere ;)
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
e names are not shared.
Also this next bit can bite you.
Don't use list it is builtin name and can cause problems when you
rebind it.
Others to avoid are keywords and file, dict, tuple, object, etc...
They can be tempting to use, resist, it will save you debug time later.
hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
uses Python for it's scripting. You can create a game and never
touch a piece of code if you use the builtin actuators and sensors, or
you can script with Python.
hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
in.isatty():
"direct"
else:
"redirected"
This snippet can determine if you have redirected IO.
I just found this and it looks informative.
http://www.jpsdomain.org/windows/redirection.html
hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
I have the feeling that I came a cross some very simple way to
extract
> the filename, but I can't find my mental note ;-)
Maybe you found some black magic ;)
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
ys import argv
>
> print argv[0].split(sep)[-1]
> # or
> print locals()['__file__'].split(sep)[-1]
> # or
> print globals()['__file__'].split(sep)[-1]
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
...
Updates available at
> The script is located at:
> http://bellsouthpwp.net/m/e/mefjr75/python/stripper.py
>
> M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
Google has now 'fixed' there whitespace issue and now has an auto-quote
issue argggh!
The script is located at:
http://bellsouthpwp.net/m/e/mefjr75/python/stripper.py
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
hanges.
>
##
> > # Python source stripper
> >
>
##
> >
> > import os
> > import sys
> > import token
> >
##
import os
import sys
import token
import keyword
import StringIO
import tokenize
import traceback
__credits__ = '''
Jürgen Hermann
M.E.Farmer
Jean Brouwers
'''
__version__ = '.8'
__author__ = 'M.E.Farmer'
__date__ = 'Apr 1
method so tokenize sends really sends the five part
info to __call__ for every token.
If this was obvious then ignore it ;)
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
Sounds good should work fine ;)
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
tokens missing that should be added,
or extra tokens that should be removed please comment.
If all is well I will post the updated
PySourceColor module and PyrexColor script to my website for download.
http://bellsouthpwp.net/m/e/mefjr75/python/PyrexTest_XHTML2.htm
M.E.Farmer
--
http
t believe GNU "bc" is available for Windows, is it?
>
> Thanks,
>
> Dick Moores
> [EMAIL PROTECTED]
Nice collection of unix tools, Cygwin not needed.
http://unxutils.sourceforge.net/
hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
sends multiline strings and comments as a single token.
##
# python comment and whitespace stripper :)
######
import keyword, os, sys, traceback
i
to be a nested function, it really
depends on what you are trying to achieve.
hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
'abc\n']
Notice that it does not modify the list in any way.
You are trying to loop thru the list and modify the items in place, it
just won't work.
When you rebind the item name to a new value ' ' it does not rebind the
element in the list just the current item.
It is also
Lines = theInFile.readlines()
theInFile.close()
outLines = []
for line in allLines:
if not line.startswith('Bill'):
outLines.append(line)
theOutFile.writelines(outLines)
theOutFile.close()
#
hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
h more content and detail.
Py> you = 'Cesar Andres Roldan Garcia'
Py> answer = PyAnswers(you)
Py> print answer
For further help please repost answer or the error message ;)
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
jects
hth,
M.E.Farmer
Sells, Fred wrote:
> I have a legacy system with data stored in binary files on a remote
server.
> I need to access and modify the content of those files from a
webserver
> running on a different host. (All Linux)
>
> I would like to install a server on the l
', 'islower', 'isspace', 'istitle', 'isupper',
'join', 'ljust', 'lower', 'lstrip', 'replace', 'rfind', 'rindex',
'rjust', 'rstrip', 'split', 'splitlines', 'startswith', 'strip',
'swapcase', 'title', 'translate', 'upper', 'zfill']
Py> help(''.zfill)
Help on built-in function zfill:
zfill(...)
S.zfill(width) -> string
Pad a numeric string S with zeros on the left, to fill a field
of the specified width. The string S is never truncated.
Hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
ult, so no need to
click it.
Proportional still retains spaces but is less tidy.
M.E.Farmer
>> Terry,
>> This was posted from google groups, can you see the indents?
>Yes, looks good
>> # code snippet
>>convertpage = 0
>>form = None
>>f
ot;--out"]:
output = a
if o in ["-i", "--input", "--in"]:
input = a
if input in [".", "cwd"]:
input = os.getcwd()
Notice the 'fixed font / proportional font' link in the top r
This comes up so often on this list that there are many examples and
recipes.
You are looking for a dictionary sort by value.
search strategy:
Python sorting dictionary
44,000+ hits on google.
First entry:
http://aspn.activestate.com/ASPN/Python/Cookbook/Recipe/52306
hth,
M.E.Farmer
--
http
re appropriate for you right now till you
are up and running. http://www.python.org/mailman/listinfo/tutor
-Just keep reading and writing Python , you will 'get it'.
hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
l","w"]:
self.withdraw(amount)
else:
self.deposit(amount)
hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
Survey says.
...wxYield()
;)
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
#x27;)
eos = f.seek(107).read(1)
r = f.read()
f.close()
r = r.replace('\r', '')
r = r.replace('\n', '')
r = r.replace(eos, '\n')
f = open('yourrecord', 'w')
f.write(r)
f.close()
hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
the question :
#contents of myfile.py:
testvar = [1,2,3,4]
# someother.py
# the problem is you are executing a script
# then searching in the wrong namespace.
def myfunction(filename):
execfile(filename, globals())
print testvar
hth,
M.E.Farmer
--
http://mail.python.org/mailman/listi
that works ;)
"c:/windows/dir"
Windows uses '\' as a path sep but it also understands '/'.
*nix uses '/' as a path sep.
hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
__mul__',
'__ne__', '__new__', '__reduce__', '__repr__', '__rmul__',
'__setattr__', '__setitem__', '__setslice__', '__str__', 'append',
'count', 'extend', 'index', 'insert', 'pop', 'remove', 'reverse',
'sort']
Then you can try and get some help from Python.
Py>help(a.extend)
Help on built-in function extend:
extend(...)
L.extend(iterable) -- extend list by appending elements from the
iterable
And finally use pydoc it is very helpful.
Cl> python pydoc -g
hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
Your welcome for the help , be sure to pass it on ;)
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
eter and try playing with them and see what they do.
If you weant to know what an object or methods docs say, use help().
Py> help(q.count)
Help on built-in function count:
count(...)
L.count(value) -> integer -- return number of occurrences of value
If you want to know the number of items in a list ( or most builtins )
use len().
Py> len(q)
8
Spend time reading the docs. It will save you months of work.
Also learn the library it has many modules that will simplify your code
and save your mind.
http://www.python.org/doc/
hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
le):
...print 'you have %s apples' % apple
py>f1(4)
'you have 5 apples'
Read the docs this is pretty basic, it will save you time.
If in doubt try it out.
Use the interpreter, it is your friend.
hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
02': "''' Store the source text & set some flags.\n'''",
's03': "'unix'"}
You can also strip out comments with a few line.
It can easily get single comments or doubles.
add this in your __call__ function
This may help.
http://linuxgazette.net/107/pai.html
Also be sure to google.
search strategy:
Python threading
Python threads
Python thread tutorial
threading.py example
Python threading example
Python thread safety
hth,
M.E.Farmer
--
http://mail.python.org/mailman
ewpos + len(toktext)
if toktype in [token.NEWLINE, tokenize.NL]:
self.out.write('\n')
return
if newpos > oldpos:
self.out.write(self.raw[oldpos:newpos])
if toktype in [token.INDENT, token.DEDENT]:
self.pos = newpos
return
if (toktype == token.STRING):
sname = self.StringName.next()
self.StringMap[sname] = toktext
toktext = sname
self.out.write(toktext)
self.out.flush()
return
hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
_init__(self, msg)
def __repr__(self):
return self._msg
__str__ = __repr__
class PathError(PSCError):
def __init__(self, msg):
PSCError.__init__(self,
'Path error! : %s'% msg)
class InputError(PSCError):
def __init__(self, msg):
PSCError.__init__(self,
'Input error! : %s'% msg)
# and you use it like this
raise PathError, 'Please check path'
raise InputError, 'Improper input try again'
hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
x27;myrecords.txt')
Py> first_record = records.next()
Py> second_record = records.next()
Py> # or you can do this
Py> for record in records:
Py> print record
Getting them in a single file is easy, and will be an excercise left to
the reader.
The fileinput module is your f
line 95, in copy
> return _reconstruct(x, rv, 0)
> File "C:\Python24\lib\copy.py", line 320, in _reconstruct
> y = callable(*args)
> File "C:\Python24\lib\copy_reg.py", line 92, in __newobj__
> return cls.__new__(cls, *args)
> TypeError: objec
details. If I am wrong someone correct me
;)
If you search around you can find many pointers to memory effecient
coding style in Python( never add a string together, use a list and
append then join, etc.)
Stick to profiling it will serve you better. But do not let me stop you
from writing a memory
Steve Holden wrote:
> M.E.Farmer wrote:
>
> >>Jeffrey Borkent
> >>Systems Specialist
> >>Information Technology Services
> >
> >
> > With that kind of credentials, and the fact that you claim you are
a
> > system specialists
> >
to take out the garbage or look at it?
Python does it for you so you don't have too.
But don't let me stop you.
You can probably still find some way to do it.
It is open source after all.
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
Sweet!
Glad you fixed it, and documented it all!
Thanks for the followups.
Now the next poor soul to stumble in can get the right fix.
Never know when it could be me ;)
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
py hacking,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
7;t ask a 2nd grade question yet
claim/pretend to be some sorta system specialists.
You tried searching the archives first I am sure.
Go here http://www.python.org and *read*, come back when you are
really stuck.
M.E.Farmer
P.S. YES the __ matter, they identify special methods ! __init__ is the
class CON
Just curious what is not suitable about FMOD ?
It seems to be exactly what you are looking for.
Cross platform, free, great sound, python bindings, no compiler needed.
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
http://sourceforge.net/projects/uncassist
the people who wrote pyFMOD (lots of stuff there)
http://www.cs.unc.edu/~parente/tech/tr01.shtml
Hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
return pathlist
.
. def list_dir(dir):
. ''' Another way to filter a dir '''
. import os
. pathlist = os.listdir(dir)
. # Now filter out all but py and pyw
. filterlist = [x for x in pathlist
.if x.endswith('.py')
.or x.endswith('.pyw')]
.return filterlist
hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
game
Py> pygame.mixer.init()
Py> pygame.mixer.music.load('c:/everyday.mp3')
Py> pygame.mixer.play()
Py> pygame.mixer.music.fadeout(4000)
You have a typo in the code you posted that may be your problem.
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
u have had a bit of a snag , sorry to
hear that.
I am glad you are at least learning new things, 'cause if you had used
CherryPy2 you would have be done by now :P
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
I guess it depends :)
Let us know what works for you.
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
th Python.
hth ,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
that do exactly one thing each and use them as your
interface.
Py> def fun_helper(d):
... d['z'] = func(d['x']+d['y']+d['whatever']['as']+d[a][0])
... return d
and use them as needed.
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
Yes you can use absolute positioning.
You do not need sizers ( but they are very nice )
Most all the widgets have a pos keyword in there constructor. Just use
them.
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
them in the dictionary they come in
and acess the members as needed. I really don't see your need.
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
Hello Bo,
Don't use dict it is a builtin ;)
Also try this stuff out in an interpreter session it is easy and fast
to get your own answers.
>>> def fun(d):
... __dict__ = d
... return __dict__
hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
ioned it.
Overall I agree with your statement you *should* not nest div inside of
span, BUT...
Div *can* be nested inside a span. I just tried it in Firefox , I.E. ,
and Opera to be sure and it does work ;)
Probably not w3c compliant though.
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
ound-color:#11;}
hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
ound-color:#11;}
hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
ound-color:#11;}
hth,
M.E.Farmer
--
http://mail.python.org/mailman/listinfo/python-list
1 - 100 of 164 matches
Mail list logo