2.5.1p5 preview release: some tests

Thanks to all developpers for this new release.

win98se, Python 2.3.3, wxPython 2.5.1.0p5

A small report on the demo (as beta tester)

···

-------------------------------------------

- Starting the demo, the log window shows this message:
Debug: ..\..\src\msw\dc.cpp(2035): 'StretchDIBits' failed with error
0x00000057 (paramètre incorrect.).
(paramètre incorrect.) == incorrect parameter
I did no localize the source of the error. I get this error msg
when
o I resize the demo main frame
o I move one of the splitter bar in the main window.
o I click on a tree item.
o I move some frames or dialogs in the demo like, wxDialog, wxToolbar
demo frame, ...
Note that the same error msg was appearing in wxPy 2.5.1.0p4.

- wx.VListBox : the ForegroundColour of the highlighted item
does not change.

- stock cursors: it seems some predifined cursors do not dispay the
right image, eg wx.Cursor_SPRAY_CAN shows a brush.

- wx.MDIWindows: the 'MDI with SashWindows demo' button opens the
same window as the 'MDI demo' button

- wxPopupWindow: once a popup window is open, it is not moved correctly
with an click and drag. The popup window skips to the right by
let say 200 pixels.

- wxSpinButton: not working. The demo app hangs Ctrl+Alt+Del

- Colour Select: the button corresponding to
the label 'With a label' is too small, the text is truncated.

- wxMultiSash: demo crashes

- MaskedEditControls: demo crashes

- wxIEHtmlWin: in my editor,
import wx.iewin as iewin
ImportError: No module named iewin

-wxTimeCtrl: when clicking on a text control with "spin buttons'
demo hangs, Ctrl-Alt-Del

-CustomDragAndDrop: can not draw on the window.
Problem with one of the new wx.DC functions:
In my editor:
File "C:\PYTHON23\lib\site-packages\wx\gdi.py", line 2203, in DrawLineXY
    return _gdi.DC_DrawLineXY(*args, **kwargs)
TypeError: DC_DrawLineXY() takes exactly 5 arguments (3 given)

-Throbber: appears twice in the demo
in the Using images tree and in the miscellaneous tree

- wxJoyStick: problem in the code:
In my editor:
File "C:\Python23\Lib\site-packages\wxdemo\joystick_wdr.py", line 109, in MakeJoystickTestPanel
    item1.AddSpacer( 20, 10, 0, wxALIGN_CENTRE, 5 )
  File "C:\PYTHON23\lib\site-packages\wx\core.py", line 7128, in Add
    return _core.Sizer_Add(*args, **kwargs)
TypeError: wxWindow, wxSizer, wxSize, or (w,h) expected for item

- wxOGL: starting the ogl demo:
In my editor:
Exception exceptions.TypeError: 'OGLCleanUp() takes exactly 0 arguments (1 given)' in <bound method __Cleanup.__del__ of
<wxOGL.__Cleanup instance at 0x023E38F0>> ignored

-ActiveX wrappers Acrobat and IE: demo crashes.

-wxGLCanvas: not tested

- May I suggest to use the "official" Python boolean type True/False
in the demo.

eg in wxStyledTextCtrl_2.py, line 77

use
if not self.fold_symbols:
...
instead of
if self.fold_symbols == 0:
...

Other issues
------------

If I create a wx.TextCtrl with both the scrollbars
(vertical and horizontal) and if I set the border style
to wx.SIMPLE_BORDER, the border is drawn, but the
scrollbar are not inside the rectangle border. That is
not the case for the other border styles.
Note: this also happens in wxPy 2.4.2.4

Sorry if some issues have already been reported.
I am aware some demo parts are not finished.
Good job. Thanks again.

Jean-Michel Fauth, Switzerland

- Starting the demo, the log window shows this message:
Debug: ..\..\src\msw\dc.cpp(2035): 'StretchDIBits' failed with error
0x00000057 (paramètre incorrect.).
(paramètre incorrect.) == incorrect parameter
I did no localize the source of the error. I get this error msg
when
o I resize the demo main frame
o I move one of the splitter bar in the main window.
o I click on a tree item.
o I move some frames or dialogs in the demo like, wxDialog, wxToolbar
demo frame, ...
Note that the same error msg was appearing in wxPy 2.5.1.0p4.

Is that a sequence of event, or does any one of them cause that to happen?
Doesn't appear under W2K here if the latter.

- wx.VListBox : the ForegroundColour of the highlighted item
does not change.

Same here, noted on demo status page.

- stock cursors: it seems some predifined cursors do not dispay the
right image, eg wx.Cursor_SPRAY_CAN shows a brush.

Noted, I'll look into it if Robin doesn't get it first.

- wx.MDIWindows: the 'MDI with SashWindows demo' button opens the
same window as the 'MDI demo' button

Oops, probably a cut and paste error here. I've fixed it, will get a patch
in to Robin.

- wxPopupWindow: once a popup window is open, it is not moved correctly
with an click and drag. The popup window skips to the right by
let say 200 pixels.

Yeah, I haven't figured that one out yet. Already a note on the demo status
page.

- wxSpinButton: not working. The demo app hangs Ctrl+Alt+Del

Yes, anything using spin buttons will have this problem (the wxCalendar demo
has similar probs). This appears to be a low level library issue.

- Colour Select: the button corresponding to
the label 'With a label' is too small, the text is truncated.

I suspect this is a problem in the colorselect library. I'll make a note of
it.

- wxMultiSash: demo crashes

Not under W2K, though.

- MaskedEditControls: demo crashes

Ditto, no crash here.

- wxIEHtmlWin: in my editor,
import wx.iewin as iewin
ImportError: No module named iewin

Known issue; Robin's on it.

-wxTimeCtrl: when clicking on a text control with "spin buttons'
demo hangs, Ctrl-Alt-Del

See above (spin buttons)

-CustomDragAndDrop: can not draw on the window.
Problem with one of the new wx.DC functions:
In my editor:

Yeah, we're aware of it (haven't sorted it out yet)

- wxJoyStick: problem in the code:
In my editor:
File "C:\Python23\Lib\site-packages\wxdemo\joystick_wdr.py",
line 109, in MakeJoystickTestPanel
    item1.AddSpacer( 20, 10, 0, wxALIGN_CENTRE, 5 )
  File "C:\PYTHON23\lib\site-packages\wx\core.py", line 7128, in Add
    return _core.Sizer_Add(*args, **kwargs)
TypeError: wxWindow, wxSizer, wxSize, or (w,h) expected for item

No big suprise there. The Joystick demo will be totally rewritten. You're
likely to see probs with the MimeTypes demo and ErrorDialogs demo as well.

- wxOGL: starting the ogl demo:
In my editor:
Exception exceptions.TypeError: 'OGLCleanUp() takes exactly 0
arguments (1 given)' in <bound method __Cleanup.__del__ of
<wxOGL.__Cleanup instance at 0x023E38F0>> ignored

Last build, it just up and died when we tried to start it, so believe me,
this is an improvement :slight_smile: Since I couldn'd to much with it on the first
pass, I'm not suprised it has issues now.

-ActiveX wrappers Acrobat and IE: demo crashes.

No crash here, though.

- May I suggest to use the "official" Python boolean type True/False
in the demo.

We're getting it there, but in this case:

eg in wxStyledTextCtrl_2.py, line 77

use
if not self.fold_symbols:
...
instead of
if self.fold_symbols == 0:

Would be fine except there are at least four possible states for
self.fold_symbols (0 through 3). While

    if self.fold_symbols == 0:

and

    if not self.fold_symbols:

are essentially the same, the code would become a lot less readable. Using
numerics for all four states makes it more consistent and readable.

You can also track issues we're aware of via
http://wiki.wxpython.org/index.cgi/wxPython_202_2e5_20Demo_20Update_20Status
and http://wiki.wxpython.org/index.cgi/wxPython_20Third_2dparty_20libraries.

Thanks for the comments!

Jean-Michel Fauth wrote:

<snip>

- wxJoyStick: problem in the code:
In my editor:
File "C:\Python23\Lib\site-packages\wxdemo\joystick_wdr.py", line 109,
in MakeJoystickTestPanel
    item1.AddSpacer( 20, 10, 0, wxALIGN_CENTRE, 5 )
  File "C:\PYTHON23\lib\site-packages\wx\core.py", line 7128, in Add
    return _core.Sizer_Add(*args, **kwargs)
TypeError: wxWindow, wxSizer, wxSize, or (w,h) expected for item

<snip>

This is code created by wxDesigner, which is making (now deprecated?)
calls of the form:
  itemx.AddSpacer( width, height, option, flag, border )
to the method defined in wx\lib\resizer.py.

But the calls are now being processed in wx\core.py where
  AddWindow = AddSizer = AddSpacer = Add
and the parameters for Add, when adding a spacer, are ( (width, height),
option, flag, border )

I'm assuming this was broken intentionally, and that the change needs to
be added to any general purpose script to "convert wx names in user source
code / postprocess wxDesigner-generated code". Is that correct?

Regards,

David Hughes
Forestfield Software Ltd
www.forestfield.co.uk

Jean-Michel Fauth wrote:

Thanks to all developpers for this new release.

win98se, Python 2.3.3, wxPython 2.5.1.0p5

A small report on the demo (as beta tester)
-------------------------------------------

- Starting the demo, the log window shows this message:
Debug: ..\..\src\msw\dc.cpp(2035): 'StretchDIBits' failed with error
0x00000057 (paramètre incorrect.).
(paramètre incorrect.) == incorrect parameter
I did no localize the source of the error. I get this error msg
when
o I resize the demo main frame
o I move one of the splitter bar in the main window.
o I click on a tree item.
o I move some frames or dialogs in the demo like, wxDialog, wxToolbar
demo frame, ...
Note that the same error msg was appearing in wxPy 2.5.1.0p4.

Yes, I've seen it too but only on win9x. My guess is that it is a bug in the win9x StretchDIBits API (incorrectly reporting an error) because nothing seems to actually be broken in the drawing of the windows. Narrowing it down to specific code that causes it to happen would probably help, if anybody has the time and inclination to do so. The line number reported above is in the wxDC::Blit method.

- wx.VListBox : the ForegroundColour of the highlighted item
does not change.

Fixed.

- stock cursors: it seems some predifined cursors do not dispay the
right image, eg wx.Cursor_SPRAY_CAN shows a brush.

As mentioned on the demo panel, not all stock cursor IDs have meaningful representations on all platforms. There is no spay can available (although one could be added id somebody wants to donate a .cur file for it) on MSW and so it is currently a duplicate of the paint brush.

- wx.MDIWindows: the 'MDI with SashWindows demo' button opens the
same window as the 'MDI demo' button

Jeff has fixed this.

- wxPopupWindow: once a popup window is open, it is not moved correctly
with an click and drag. The popup window skips to the right by
let say 200 pixels.

Hmmm... Looks like the coordinants are not converting correctly. It works fine on wxGTK so something MSW-specific has changed. I'll try to track it down.

- wxSpinButton: not working. The demo app hangs Ctrl+Alt+Del

I'm aware of this but havn't tried to track it down yet. I think it may be something in the C++ code.

- Colour Select: the button corresponding to
the label 'With a label' is too small, the text is truncated.

Yep.

- wxMultiSash: demo crashes

Works fine here. Does it crash at startup or what do you do that makes it crash?

- MaskedEditControls: demo crashes

Jeff has fixed this.

- wxIEHtmlWin: in my editor,
import wx.iewin as iewin
ImportError: No module named iewin

Yep.

-wxTimeCtrl: when clicking on a text control with "spin buttons'
demo hangs, Ctrl-Alt-Del

-CustomDragAndDrop: can not draw on the window.
Problem with one of the new wx.DC functions:
In my editor:
File "C:\PYTHON23\lib\site-packages\wx\gdi.py", line 2203, in DrawLineXY
    return _gdi.DC_DrawLineXY(*args, **kwargs)
TypeError: DC_DrawLineXY() takes exactly 5 arguments (3 given)

Fixed. Along with a couple others.

-Throbber: appears twice in the demo
in the Using images tree and in the miscellaneous tree

There are a few that appear twice. It is intended.

[...]

Other issues
------------

If I create a wx.TextCtrl with both the scrollbars
(vertical and horizontal) and if I set the border style
to wx.SIMPLE_BORDER, the border is drawn, but the
scrollbar are not inside the rectangle border. That is
not the case for the other border styles.
Note: this also happens in wxPy 2.4.2.4

On windows the border styles are translated to win32 API styles and passed on to the native control. So it is up to the native control to decide how (or if) to handle the style.

···

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

> - stock cursors: it seems some predifined cursors do not dispay the
> right image, eg wx.Cursor_SPRAY_CAN shows a brush.

As mentioned on the demo panel, not all stock cursor IDs have meaningful
representations on all platforms. There is no spay can available
(although one could be added id somebody wants to donate a .cur file for
it) on MSW and so it is currently a duplicate of the paint brush.

Ah, so that's one that doesn't exist in MSW, then? I'll update the wiki.

> - wxPopupWindow: once a popup window is open, it is not moved correctly
> with an click and drag. The popup window skips to the right by
> let say 200 pixels.

Hmmm... Looks like the coordinants are not converting correctly. It
works fine on wxGTK so something MSW-specific has changed. I'll try to
track it down.

Yeah, it's on my to-do list too, just haven't had a chance to go back to it
yet.