wxPython 2.5.1.1

The wxPython 2.5.1.1 Release Cantidate has just been uploaded to the Starship and is ready for testing.

http://starship.python.net/crew/robind/wxPython/preview/2.5.1.1/

There have been a lot of little changes since the p8 preview, I'll try to list them all here, but I will surely miss some.

* Added wx.Display

* Fixed some minor Printing Framework issues on Linux

* Changed the build so that libSDL is used on Linux (if available at build time) to play the wave files from wx.Sound. This is because the built-in OSS code for dumping sound data to the DSP woudl not do the right thing if the sound card could not support the format/encoding in the file.

* Reoganized the contents of the OSX Disk Image. Only the readme and the installer package are at the top level, everything else is in sub directories. The wxWidgets docs are also included in the .dmg.

* Added a sample to the demo that shows alpha blenbing of images (for Windows and Mac only)

* There is a menu item in the demo that will let you turn on or off the redirection of stdou/stderr to the window.

* Got rid of the extra Refresh() calls when changing samples in the demo.

* Fixed a bunch of stuff in wx.VListBox. Scrollbar issues on GTK2, bg colour when used in a wx.Notebook in XP, selection with cursor keys on Windows, correct font used, etc.

* Fixed wx.SplitterWindow to not depend on starting out with a small size in order to correctly position the sash when a negative position is specified. Decided to change the default size of windows back to 20x20 anyway--except for top level windows, which have a default size of 400x2500--because I kept running into other similar issues. But I think that the wx.SplitterWindow is better off for the change anyhow :wink: (Oops! The Migration Guide still mentions that all windows have the bigger default size...)

* Updated MaskedEditCtrl and related modules with a patch from Will Sadkin.

* Applied a brute force fix for the too-short wx.Choice and wx.ComboBox windows until the proper way to determine the correct height can be figured out.

* AppleEvents can be handled by overriding wx.App methods MacOpenFile,
MacPrintFile, MacNewFile, and MacReopenApp.

* Added wx.PlatformInfo which is a tuple containing strings that describe the platform and build options of wxPython.

···

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!

I'm running Python 2.3.3 on Windows 2000 and Panther (Python 2.3.0) on my Mac.

I'm not going to do much testing tonight, but so far...

Both platforms:
ErrorDialogs are still in the distribution and demo. Didn't we decide that this was getting dropped since it is no longer supported?

Windows:
The default window size for MultipleChoiceDialog and ScrolledMessageDialog are too small. This is different from 2.5.1.0p8; Mac appears to be okay.

ActiveXWrapper_IE causes a runtime error and crashes the demo.

I'm still getting the python crash when calling webbrowser from within an event handler.

Mac:
The instructions for using viewdocs.pyw in README 1st.txt need a bit more explanation. Since the file isn't a standalone bundle, it won't actually run from the Finder unless the user has installed the PythonLauncher as part of the MacPython add-ons for Panther and associated PythonLauncher with .pyw files instead of the Python IDE. Sadly, instructions will be slightly different still for Jaguar since the add-ons are included with the Jaguar MacPython build, right? Anyway, it is probably simpler to just make a standalone docs app and avoid confusion.

Some scrollbars have an active area for the scrollbars that is just over half of the total area taken up by the scrollbars, which makes them look quite thin. See ListCtrl and ScrolledWindow in the demo for examples.

The demo has crashed a couple of times but I haven't figured out how to reproduce yet.

Sadly it looks like many of the bugs I reported for 2.5.1.0p8 on the Mac are still broken, but I'll double-check them all tomorrow.

ka

It looks like the problem with MultipleChoiceDialog and ScrolledMessageDialog goes back to wxDialog not paying attention to the size arg in the __init__ method. All my custom dialogs based on wxDialog that don't use sizers are too small. This is a show-stopper bug for me.

BitmapButton is still missing from the Core Windows/Controls in the demo.

There is some weird flash/redraw going on when each item in the demo wxPython overview tree control is selected. On the Mac the selection turns into a rectangle outline, implying the tree control is losing focus while the right panel is updated?! Its one of those you gotta see it to know what I mean things :wink:

ImageAlpha Overview has a typo, it says "chennel" instead of "channel"

This might just be a nit, but when alpha channeling was being discussed earlier, I had assumed (stupid me) that meant you could blend images, but the DrawBitmap call as used by ImageAlpha only supports a boolean for transparency. So really all that is supported is a transparency mask. This has some value but it means that we still have to use PIL for many image operations and ImageAlpha is probably a poor name given the limitations. As a side note I wonder if helper functions done in C++: BitmapToPIL, PILToBitmap, ImageToPIL, PILToImage would be any faster than the Python wrappers we currently have to use. Probably not since PILs Image tostring and fromstring are all Python, but I can dream, can't I. :wink:

I'm still getting random crashes in the demo. I just got one after pressing the "Play Sound 1" button under Miscellaneous->Sound but when I ran the demo again and clicked on the button it played the sound fine. Then I started up the demo again and the first time I clicked on the button it didn't play anything, but didn't crash either and a second click caused the sound to play.

Should the section on Original Object Return (OOR) under Process and Events go away or is it still relevant for 2.5.x?

Are there some notes on the initial built-in class and method docs that you're working on? This should probably be mentioned in the migration guide to get feedback from users on the direction you're heading and what you expect to end up with and when (2.5.2?). One completely documented class, even if it has to be done manually would be an excellent way to compare to the existing C++ docs. Due to the large number of methods in the wxWindow class I suggest avoiding classes that subclass it and using something relatively small like wxMenu, wxSizer, or wxDC. The built-in __doc__ strings and HTML docs for those small classes will be the strawman implementations to compare against the C++ wxWidgets docs.

The small dialog problem and crashes in the demo worry me if this release is supposed to last very long, so we need another release candidate after those problems are fixed.

ka

Hi Robin,

Haven't had time to dig into this thoroughly yet, but the AppleEvents (at least MacOpenFile) are working properly! Thanks!

Kevin

···

On Mar 13, 2004, at 7:22 PM, Robin Dunn wrote:

The wxPython 2.5.1.1 Release Cantidate has just been uploaded to the Starship and is ready for testing.

http://starship.python.net/crew/robind/wxPython/preview/2.5.1.1/

There have been a lot of little changes since the p8 preview, I'll try to list them all here, but I will surely miss some.

* Added wx.Display

* Fixed some minor Printing Framework issues on Linux

* Changed the build so that libSDL is used on Linux (if available at build time) to play the wave files from wx.Sound. This is because the built-in OSS code for dumping sound data to the DSP woudl not do the right thing if the sound card could not support the format/encoding in the file.

* Reoganized the contents of the OSX Disk Image. Only the readme and the installer package are at the top level, everything else is in sub directories. The wxWidgets docs are also included in the .dmg.

* Added a sample to the demo that shows alpha blenbing of images (for Windows and Mac only)

* There is a menu item in the demo that will let you turn on or off the redirection of stdou/stderr to the window.

* Got rid of the extra Refresh() calls when changing samples in the demo.

* Fixed a bunch of stuff in wx.VListBox. Scrollbar issues on GTK2, bg colour when used in a wx.Notebook in XP, selection with cursor keys on Windows, correct font used, etc.

* Fixed wx.SplitterWindow to not depend on starting out with a small size in order to correctly position the sash when a negative position is specified. Decided to change the default size of windows back to 20x20 anyway--except for top level windows, which have a default size of 400x2500--because I kept running into other similar issues. But I think that the wx.SplitterWindow is better off for the change anyhow :wink: (Oops! The Migration Guide still mentions that all windows have the bigger default size...)

* Updated MaskedEditCtrl and related modules with a patch from Will Sadkin.

* Applied a brute force fix for the too-short wx.Choice and wx.ComboBox windows until the proper way to determine the correct height can be figured out.

* AppleEvents can be handled by overriding wx.App methods MacOpenFile,
MacPrintFile, MacNewFile, and MacReopenApp.

* Added wx.PlatformInfo which is a tuple containing strings that describe the platform and build options of wxPython.

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!

---------------------------------------------------------------------
To unsubscribe, e-mail: wxPython-dev-unsubscribe@lists.wxwidgets.org
For additional commands, e-mail: wxPython-dev-help@lists.wxwidgets.org

Kevin Altis wrote:

I'm running Python 2.3.3 on Windows 2000 and Panther (Python 2.3.0) on my Mac.

I'm not going to do much testing tonight, but so far...

Both platforms:
ErrorDialogs are still in the distribution and demo. Didn't we decide that this was getting dropped since it is no longer supported?

Yes. I forgot about that. I'll remove from the demo and raise a DeprecationWarning from the module.

Windows:
The default window size for MultipleChoiceDialog and ScrolledMessageDialog are too small. This is different from 2.5.1.0p8; Mac appears to be okay.

I think I know what this is related to, I'll check it.

ActiveXWrapper_IE causes a runtime error and crashes the demo.

<grumble...>

I'm still getting the python crash when calling webbrowser from within an event handler.

I looked pretty deep on this one and was not able to find the source of the problem. It's still on the todo list though.

Mac:
The instructions for using viewdocs.pyw in README 1st.txt need a bit more explanation. Since the file isn't a standalone bundle, it won't actually run from the Finder unless the user has installed the PythonLauncher as part of the MacPython add-ons for Panther and associated PythonLauncher with .pyw files instead of the Python IDE. Sadly, instructions will be slightly different still for Jaguar since the add-ons are included with the Jaguar MacPython build, right? Anyway, it is probably simpler to just make a standalone docs app and avoid confusion.

Yes, I thought about this but since it was kind of a last-minute change I didn't want to mess with it too much just in case I broke something in the process. Part of the problem with making a bundle out of it is that the .zip book files would need to go into the bundle as well but that means that viewdocs.py would have to be rewritten to look for them there (not a big deal, it's only about a dozen lines long right now,) and people would have to dig into the bundle to find the .zip files if they wanted to unzip them and view with a normal browser.

Anyway, it is still on my mind and at the least I will put more info into the readme.

Some scrollbars have an active area for the scrollbars that is just over half of the total area taken up by the scrollbars, which makes them look quite thin. See ListCtrl and ScrolledWindow in the demo for examples.

There was a recent change to allow the different controls size variants that Aqua supports to be chosen by the app. It probably has something to do with this, I'll ask on wx-dev.

Sadly it looks like many of the bugs I reported for 2.5.1.0p8 on the Mac are still broken, but I'll double-check them all tomorrow.

Yeah, I think Stefan is waiting until after the compositing controls patch and classic/carbon split are finished before working on other bugs. His local workspace is probably pretty torn up at the moment.

···

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!

Kevin Altis wrote:

It looks like the problem with MultipleChoiceDialog and ScrolledMessageDialog goes back to wxDialog not paying attention to the size arg in the __init__ method. All my custom dialogs based on wxDialog that don't use sizers are too small. This is a show-stopper bug for me.

Yep.

BitmapButton is still missing from the Core Windows/Controls in the demo.

There is a BitmapButton in the Button demo. If you think that it needs its own demo please send me a module to drop into the demo dir.

There is some weird flash/redraw going on when each item in the demo wxPython overview tree control is selected.

Look in demo/Main.py at the RunDemo method. It changes the selected page to 0, removes page 2 loads the new module, adds a new notbook page, and then selects it. I don't think that much that can be done to reduce the flashing there, but you are welcome to try. Maybe the switch to page 0 isn't required anymore...

On the Mac the selection turns into a rectangle outline, implying the tree control is losing focus while the right panel is updated?! Its one of those you gotta see it to know what I mean things :wink:

Yep, I've seen it and already fixed it.

ImageAlpha Overview has a typo, it says "chennel" instead of "channel"

Thanks.

This might just be a nit, but when alpha channeling was being discussed earlier, I had assumed (stupid me) that meant you could blend images, but the DrawBitmap call as used by ImageAlpha only supports a boolean for transparency. So really all that is supported is a transparency mask.

No, the flag is saying that the transparency built-in to the image should be used (or not) If the image has a 1-bit alpha (a mask) then it will be used. If it has an 8-bit alpha like the toucan image then alpha blending with the current contents of the DC is used. Take another look at the sample and notice that the text on the background is not clipped at the borders of the image like it would be with a 1-bit mask, but it is blended with the shadow part of the image.

This has some value but it means that we still have to use PIL for many image operations and ImageAlpha is probably a poor name given the limitations. As a side note I wonder if helper functions done in C++: BitmapToPIL, PILToBitmap, ImageToPIL, PILToImage would be any faster than the Python wrappers we currently have to use. Probably not since PILs Image tostring and fromstring are all Python, but I can dream, can't I. :wink:

It would certainly be a nice thing to have. I started looking into it once but ran out of time. If somebody is already familiar with the PIL C code it woudl probably not be too big of a task to do.

I'm still getting random crashes in the demo. I just got one after pressing the "Play Sound 1" button under Miscellaneous->Sound but when I ran the demo again and clicked on the button it played the sound fine. Then I started up the demo again and the first time I clicked on the button it didn't play anything, but didn't crash either and a second click caused the sound to play.

I've also seen this (not playing the first time) but I don't know yet what is causing it.

Should the section on Original Object Return (OOR) under Process and Events go away or is it still relevant for 2.5.x?

It could go away.

Are there some notes on the initial built-in class and method docs that you're working on? This should probably be mentioned in the migration guide to get feedback from users on the direction you're heading and what you expect to end up with and when (2.5.2?). One completely documented class, even if it has to be done manually would be an excellent way to compare to the existing C++ docs. Due to the large number of methods in the wxWindow class I suggest avoiding classes that subclass it and using something relatively small like wxMenu, wxSizer, or wxDC. The built-in __doc__ strings and HTML docs for those small classes will be the strawman implementations to compare against the C++ wxWidgets docs.

I havn't gone very far down the HTML path yet. Riaan has sent me a script to work on the metdata file, but it still needs some work, and I still need to decide exactly how the full process shoudl work...

The small dialog problem and crashes in the demo worry me if this release is supposed to last very long, so we need another release candidate after those problems are fixed.

Yep.

···

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!

Other classes have their own panels, so it seems natural to have one for BitmapButton. I'll go ahead and look at trimming the existing Button panel for a BitmapButton panel.

ka

···

On Mar 15, 2004, at 10:53 AM, Robin Dunn wrote:

Kevin Altis wrote:

BitmapButton is still missing from the Core Windows/Controls in the demo.

There is a BitmapButton in the Button demo. If you think that it needs its own demo please send me a module to drop into the demo dir.

Hi Robin,

[snip]

ActiveXWrapper_IE causes a runtime error and crashes the demo.

<grumble...>

BTW, couldn't we just leave the Acrobat demo in and remove the IE demo? Should anyone be using this now that wxIEHTMLWin is in place? I know the ActiveXWrappers should work, but if it's less reliable than the wxIEHTMLWin control (I've found the win32all COM wrappers to be finicky as well, depending quite a bit on the platform and configuration the user was on...) then I think we should just leave the Acrobat control in place and promote wxIEHTMLWin for anyone wanting to embed IE. Just my two cents.

[snip]

Yes, I thought about this but since it was kind of a last-minute change I didn't want to mess with it too much just in case I broke something in the process. Part of the problem with making a bundle out of it is that the .zip book files would need to go into the bundle as well but that means that viewdocs.py would have to be rewritten to look for them there (not a big deal, it's only about a dozen lines long right now,) and people would have to dig into the bundle to find the .zip files if they wanted to unzip them and view with a normal browser.

Anyway, it is still on my mind and at the least I will put more info into the readme.

I think that it's OK if the zip files go into the bundle, as most Mac developers are familiar with how to get into a bundle. If someone doesn't know, we should add a note about it so that they can learn. =) BTW, if you put the files into the Contents/Resources folder, you don't have to have separate logic for loading on Mac. For EClass, this is what I do and it works for all platforms:

rootdir = os.path.join(os.path.abspath(sys.path[0])
#rootdir now points to Contents/Resources inside the bundle on Mac because the script is actually run from that folder

That's how I load everything that should go inside the bundle. Works like a charm. =)

Sadly it looks like many of the bugs I reported for 2.5.1.0p8 on the Mac are still broken, but I'll double-check them all tomorrow.

Yeah, I think Stefan is waiting until after the compositing controls patch and classic/carbon split are finished before working on other bugs. His local workspace is probably pretty torn up at the moment.

He sounds like he's made great progress already. He's really taken things about 10 levels above what I did in the patch. Compositing support, a CoreGraphics-based DC, brushed metal support, and other goodies. =) IMHO, it's really amazing what he has done with this! I thought we had at least another month or so of work to get this all straightened out, but Stefan sounds like he may have things ready in a week or two. As soon as he gets this out, I'll do some tests including wxPython tests to see if maybe we can put out an extra release for wxMac. It certainly sounds like it would be worth the effort. =)

Thanks,

Kevin

···

On Mar 15, 2004, at 10:53 AM, Robin Dunn wrote: