I have written some code to make rur-ple work on my ubuntu system
which has wxpython 2.8:
def wxversiontuple():
'''returns wx.version() as a tuple of ints for numeric
comparison of versions.
'''
return tuple(map(int, wx.version().split()[0].split('.')))
# version dependent function keycode to make rur-ple work with
# wxpython 2.6 to latest
if wxversiontuple() < (2, 7, 1, 1):
def keycode(event):
return event.KeyCode()
else:
def keycode(event):
return event.KeyCode
I replaced event.KeyCode with keycode in world_display.py and out-
commented wxversion.select('2.6') in rur_start.py. The speed slider
looks alright and works. I'll play a little with the code to see
whether there
are still issues with 2.8.
Regards, Peter
P.S.: Are there code markup rules available for google groops?
Couldn't find any.
Peter Maas, Aachen, Germany.
Hi,
I have written some code to make rur-ple work on my ubuntu system
which has wxpython 2.8:
def wxversiontuple():
'''returns wx.version() as a tuple of ints for numeric
comparison of versions.
'''
return tuple(map(int, wx.version().split()[0].split('.')))
# version dependent function keycode to make rur-ple work with
# wxpython 2.6 to latest
if wxversiontuple() < (2, 7, 1, 1):
def keycode(event):
return event.KeyCode()
else:
def keycode(event):
return event.KeyCode
I replaced event.KeyCode with keycode in world_display.py and out-
commented wxversion.select('2.6') in rur_start.py. The speed slider
looks alright and works. I'll play a little with the code to see
whether there
are still issues with 2.8.
Regards, Peter
P.S.: Are there code markup rules available for google groops?
Couldn't find any.
Peter Maas, Aachen, Germany.
Great and thanks. I've added Peter to the contributor list as he is
maintaining the German translation and fixing bugs... and this way we
can all try out the fixes.
Fred
Andre Roberge wrote:
>
>
> On Sat, Jan 9, 2010 at 6:44 AM, Peter Maas
> <fritz.pe...@googlemail.com
> Andr�
>
> Peter Maas, Aachen, Germany.
>
>
Hi,
I know some versioning programs but I'm not very familiar with SVN.
Guess I should do something like
svn ci rur_start.py rur_py/word_display.py
Is that correct?
I have to admit that I actually use RapidSVN under Linux and I just
right click and commit. Be careful as I just converted all py files to
utf-8 and modified the lightning.py as a lot of strings were not
internationalized (and therefore not in the po file).
If you don t feel comfortable you can email me the file(s) and I'll do
the necessary changes.
Thanks a lot.
Fred
Hi,
good idea! I have NetBeans installed recently which is a decent IDE
for
Java and Python and has good Subversion support. The code is
committed.
I have put wxversiontuple in misc.py because I could not find a better
place.
> Be careful as I just converted all py files to
> utf-8 and modified the lightning.py as a lot of strings were not
> internationalized (and therefore not in the po file).
I have committed rur_start.py, rur_py/misc.py and rur_py/
world_display.py. I think
Subversion would not allow me to do this if the repository versions
were newer.
Regards, Peter.
Peter Maas, Aachen, Germany.
Fred
I get this error at startup:
Traceback (most recent call last):
File "./rur_start.py", line 38, in <module>
if rur_py.misc.wxversiontuple() < (2,6):
File "/home/fred/apps/rurple/rur-ple/rur_py/misc.py", line 26, in
wxversiontuple
return tuple(map(int, wx.version().split()[0].split('.')))
AttributeError: 'module' object has no attribute 'version'
I'm using 2.6.
Also noticed the � from Andr� in rur_start.py became a <?>, but I doubt
that's the problem ;-)
Any idea?
Thanks.
Fred
Hi Fred,
sorry, I was thinking that 2.6 also has a version method. I installed
2.6 additionally, tested under both versions, fixed and committed.
The wx browser uses different fonts in 2.6 and 2.8 by the way.
I wonder how future versions of wxpython will differ. It could be
necessary at some time to raise the lower version limit to avoid
too much testing and version specific code.
> Also noticed the from Andr in rur_start.py became a <?>, but I doubt
> that's the problem ;-)
No, that's because it was still latin-1. I changed it to utf-8.
Thanks a lot.
Fred