I can't run the demo, so I tried just testing from the shell and got the following error.
>>> from wxPython.lib import dialogs
>>> dialogs.fontDialog()
Traceback (most recent call last):
File "<input>", line 1, in ?
File "//Library/Python/2.3/wx/lib/dialogs.py", line 225, in fontDialog
dialog = wx.FontDialog(parent, fontData)
File "//Library/Python/2.3/wx/windows.py", line 2242, in __init__
newobj = _windows.new_FontDialog(*args, **kwargs)
PyAssertionError: C++ assertion "wxAssertFailure" failed in ../src/common/choiccmn.cpp(54): invalid string in wxChoice::SetStringSelection
If the underlying FontDialog isn't broken, then the simple function wrapper is, but it works on other platforms.
I can't run the demo, so I tried just testing from the shell and got the following error.
>>> from wxPython.lib import dialogs
>>> dialogs.fontDialog()
Traceback (most recent call last):
File "<input>", line 1, in ?
File "//Library/Python/2.3/wx/lib/dialogs.py", line 225, in fontDialog
dialog = wx.FontDialog(parent, fontData)
File "//Library/Python/2.3/wx/windows.py", line 2242, in __init__
newobj = _windows.new_FontDialog(*args, **kwargs)
PyAssertionError: C++ assertion "wxAssertFailure" failed in ../src/common/choiccmn.cpp(54): invalid string in wxChoice::SetStringSelection
If the underlying FontDialog isn't broken, then the simple function wrapper is, but it works on other platforms.
wxMac still uses the generic font dialog (#@#$@#!@!) and apparently it has problems if you don't set some of the attributes of the wx.FontData. I'll check in a fix once I've dealt with the other issues in dialogs.py you've pointed out.
···
--
Robin Dunn
Software Craftsman http://wxPython.org Java give you jitters? Relax with wxPython!