Chris Barker wrote:
Ray Pasco wrote:
Chris Barker wrote:
Have you looked at:
(Python 2.3.5, wxPython 2.4.5.1 on XP)
Is there really a 2.4.5.1? Perhaps you mean 2.5.4.1?
^
The wiki example does not work correctly !
The wiki code has been attached.
I just updated it a little, but probably didn’t change anything that
would fix your problem. I’ve tested it with wxGTK 2.5.3.1. I think a
few things with Sizers may have changed a little in the upgrade to
To get it to work right in some fashion I
had to rewrite it extensively by creating a whole new frame
just to display it. On the next image display I destroyed any previous
frame and created a new one,
a weird hack, but at least this works properly.
That is too weird a hack. We need to find a better way. Please try the
enclosed code first, then tell us what your symptoms are. You could
post your version too, if you like. Maybe I’ll try this on 2.5.4.1 on
my Mac.
-Chris
---
#!/usr/bin/env python2.3
# I Always specify the python version in the #! line, it makes it much
# easier to have multiple versions on your system
import wxversion
# This has been tested with 2.4.2 and 2.5.3.1
wxversion.select("2.5")
#wxversion.select("2.4")
No, I really meant 2.5.4.1 (a bit of finger dyslexia at play, I guess)
The attached still does not display correctly. This has been broken for
at least a year.
I remember playing with the wiki example for a long time without
getting it to work
properly until I radically rewrote it in a way that is not generally
useful… The bitmap scaling
and/or display is definitely wacko. IMO this is a bug or at there needs
to be some extra calls
to make it work under MSW.
BTW, having multiple versions of Python on MSW is problematic
since there can only be one set of Registry settings.
The line “#!/usr/bin/env” is totally meaningless for plain MSW. Perhaps
for MinGW or MSYS.
STATICBITMAP.MODIFIED WIKI EXAMPLE.PY (3.17 KB)
···
http://wiki.wxpython.org/index.cgi/wxStaticBitmap