Documenti di Didattica
Documenti di Professioni
Documenti di Cultura
=====================================================================
2.5.3.1
-------
Added support to XRC and XRCed for the 3-state checkbox flags and also
for wx.ToggleButton. Updated the generic window styles supported by
XRCed.
b = wx.Button(parent, wx.ID_CANCEL)
Removed my copy of distutils from the wxPython source tree. Now that
I am no longer doing builds on Python 2.1 the newest distutils is no
longer needed. (There is still one small bug in Python 2.2 distutils
on win32, but it is easily worked around.) This sovles the problem of
incorrect builds on some systems where the system installed distutils
has been patched to behave slightly differently, for example SuSE on
x86_64 or Chandler's build.
The C++ xrc lib has been moved out of contrib and into the core, so it
is always built by default. wxPython's build has also changed
accordingly and will build the xrc module as part of the core set of
modules built by default. If you were axplicitly using BUILD_XRC then
it will no longer be recognized as a build option, otherwise you
should notice no difference.
Added ability to create a font based on pixel size rather than point
size via the FontFromPixelSize constructor.
Added wx.App.IsMainLoopRunning.
wxGTK: Make wxComboBox spit out a bit fewer surplus events when
holding down the mouse button.
wxPython on OSX can now be built in Unicode mode, can support multiple
version installs, and comes with an uninstaller script.
2.5.2.8
-------
* Add wx.Image.ConvertAlphaToMask
* Add support for all wxListBox styles to the XRC handler for
wxCheckListBox.
* etc.
2.5.2.7
-------
Added new MaskedEditControl code from Will Sadkin. The modules are
now locaed in their own sub-package, wx.lib.masked. Demos updated.
OGL is dead! LONG LIVE OGL! (Oops, sorry. A bit of my dramatic side
leaked out there...) The wx.ogl module has been deprecated in favor
of the new Python port of the OGL library located at wx.lib.ogl
contributed by Pierre Hj�lm. This will hopefully greatly extend the
life of OGL within wxPython by making it more easily maintainable and
less prone to getting rusty as there seems to be less and less
interest in maintaining the C++ version. At this point there are just
a couple minor known compatibility differences, please see the
MigrationGuide_ file for details.
.. _MigrationGuide: MigrationGuide.html
All the Window and GDI (pen, bitmap, etc.) class constructors and also
many toplevel functions and static methods will now check that a
wx.App object has already been created and will raise a
wx.PyNoAppError exception if not.
Added a new version (0.8.3) of FloatCanvas from Chris Barker. It's now
in a subpackage of wx.lib.
Added a menu item in the demo that will open a PyShell window that has
the app and demo frame preloaded in the namespace. This is another
good way to explore and play with the objects in the currently running
sample. For example, load the Button sample and then do the following
in the PyShell::
>>> b = frame.demoPage.GetChildren()[0]
>>> for x in range(0, 500, 10):
... b.Move((x, 50))
... app.Yield(True)
... wx.MilliSleep(10)
2.5.1.5
-------
(See also the MigrationGuide_ file for details about some of the
big changes that have happened in this release and how you should
adapt your code.)
.. _MigrationGuide: MigrationGuide.html
Many, many little fixes, changes and additions done as part of the move
to wxWidgets 2.5 that I have forgotten about.
Added wxMirrorDC.
Added wxIconLocation
I made a small but important change in the code that aquires the
Python Global Interpreter Lock to try and prevent deadlocks that can
happen when there are nested attempts to aquire the GIL.
The RPMs are now built on a fairly generic RH-9 box, and I have tested
installing them also on my main Mandrake 9.2 box.
There are some big changes in the OS X disk image. The actual
Installer package now *only* installs the wxMac dynlibs, wxPython
extension modules and Python packages, and also the command-line tool
scripts. The remaining items (demo, samples, and application bundles
for the Demo, PyCrust and XRCed) are now top-level items in the disk
image (.dmg file) that users can just drag and drop to wherever they
want to put them.
The wxWave class has been renamed to wxSound, and now has a slightly
different API.
.. _wxActiveX: http://members.optusnet.com.au/~blackpaw1/wxactivex.html
Floats are allowed again as function parameters where ints are expected.
2.4.2.4
-------
Use wxSTC in the demo for displaying the soucre code of the samples.
Updates to wxMaskedEditCtrl.
Added wxMaskedNumCtrl.
2.4.1.2
-------
Changed wxSWIG to not generate Python code using apply, (since it will
be deprecated in the future) wxSWIG will use ``spam(*args, **kw)`` syntax
instead. Also changed the generated __repr__ methods to be a bit more
informative.
Made the version number information more robust and uh, informative.
Also added asserts to check that the major.minor versions of wxPython
and wxWindows match.
Added the new wx "renamer" package that will dynamically import from
the wxPython package and rename wxFooBar --> FooBar. That means that
people can do imports without ``"import *"`` and can use names like
wx.Frame instead of wx.wxFrame. This is phase 1 of a full transition
to the new namespace.
Simplified how the wxSizer methods are wrapped, changed the name of
the "option" parameter to "proportion" to match the docs ("option" is
still accepted for compatibility, but this will go away in a future
release,) SetItemMinSize can now take a wxSize (or 2-tuple) parameter,
and Spacers can be specified with a wxSize (or 2-tuple) parameter
Added wxCursorFromBits.
2.4.0.7
-------
The new deprecation class for the old true/false symbols can now be
returned from OnInit. And I promise to be sure I am testing what I
think I am testing in the future...
Updated pycolourchooser.
2.4.0.4
-------
Added missing wxRect methods
Fixed SF Bug #689481, a method in the OGL wrappers was using the wrong
return type.
Changed how the dynamic event tables (used for all Python wx classes,
C++ wx classes typically use static event tables) are searched such
that they behave from a Python perspective more like the static tables
in C++. Namely that if there are identical event bindings in a base
Python class and a derived Python class that the one in the derived
class will be found first and that if Skip is called that the one in
the base class will still be found instead of skipping directly to the
static stable in the C++ class.
Added some static wxApp functions that help with integration with the
Mac UI. They are no-ops on other platforms so it doesn't hurt to
always call them. The functions are:
wxApp_GetMacDefaultEncodingIsPC
wxApp_GetMacSupportPCMenuShortcuts
wxApp_GetMacAboutMenuItemId
wxApp_GetMacPreferencesMenuItemId
wxApp_GetMacExitMenuItemId
wxApp_GetMacHelpMenuTitleName
wxApp_SetMacDefaultEncodingIsPC
wxApp_SetMacSupportPCMenuShortcuts
wxApp_SetMacAboutMenuItemId
wxApp_SetMacPreferencesMenuItemId
wxApp_SetMacExitMenuItemId
wxApp_SetMacHelpMenuTitleName
2.4.0.2
-------
Several bug fixes.
Added wxIntCtrl from Will Sadkin.
2.4.0.1
-------
No major new features since 2.3.4.2, mostly bug fixes and minor
enhancements.
Added function wrappers for the common dialogs from Kevin Altis. See
wxPython/lib/dialogs.py for more details.
2.3.4.2
-------
Various bug fixes.
2.3.4.1
-------
Updated XRCed and wxTimeCtrl contribs.
Added wxHtmlFilter.
You can now overload OnInitGui, OnExit and OnAssert in your classes
derived from wxApp.
Added Throbber from Cliff Wells to the library and the demo.
2.3.3.1
-------
Added wxSplashScreen.
Added wxGenericDirCtrl.
Added wxMultiChoiceDialog.
The calltip window and autocomplete window in wxSTC will now use a
wxPopupWindow if available on the platform (and functioning correctly)
so they can extend beyond the client area of the STC if needed.
Changed the img2py tool to use PNG instead of XPM for embedding image
data in Python source code, and the generated code now uses streams to
convert the image data to wxImage, wxBitmap, or wxIcon.
Added wxBufferedDC.
Upgraded wxSTC from Scintilla 1.40 to Scintilla 1.45, and then again
to version 1.47, and one more time to 1.48! <wink>
UNICODE!
wxWindows/wxPython can be compiled with unicode support enabled or
disabled. Previous to wxPython 2.3.3 non-unicode mode was always
used. Starting with 2.3.3 either mode is supported, but only if
it is also available in wxWindows on the platform. Currently
wxWindows only supports unicode on MS Windows platforms, but with
the recent release of GTK+ 2.0 it is only a matter of time until
it can be done on wxGTK (Linux and other unixes) as well.
So how do you use it? It's very simple. When unicode is enabled,
then all functions and methods in wxPython that return a wxString
from the C++ function will return a Python unicode object, and
parameters to C++ functions/methods that expect a wxString can
accept either a Python string or unicode object. If a string
object is passed then it will be decoded into unicode using the
converter pointed to by wxConvCurrent, which will use the default
system encoding. If you need to use a string in some other
encoding then you should convert it to unicode using the Python
codecs first and then pass the unicode string to the wxPython
method.
Added wxPyWindow, wxPyPanel and wxPyControl which are just like their
wx counterparts except they allow some of the more common C++ virtual
methods to be overridden in Python derived classes. The methods
supported are:
DoMoveWindow
DoSetSize
DoSetClientSize
DoSetVirtualSize
DoGetSize
DoGetClientSize
DoGetPosition
DoGetVirtualSize
DoGetBestSize
InitDialog
TransferDataFromWindow
TransferDataToWindow
Validate
AcceptsFocus
AcceptsFocusFromKeyboard
GetMaxSize
AddChild
RemoveChild
Added wxArtProvider.
Added a sample to the demo that catches various key events and
displays the details of the event.
2.3.2.1
-------
Changed (again) how the Python global interpreter lock is handled as
well as the Python thread state. This time it works on SMP machines
without barfing and is also still compatible with Python debuggers.
2.3.2
-----
Added EVT_HELP, EVT_HELP_RANGE, EVT_DETAILED_HELP,
EVT_DETAILED_HELP_RANGE, EVT_CONTEXT_MENU, wxHelpEvent,
wxContextMenuEvent, wxContextHelp, wxContextHelpButton, wxTipWindow,
and a demo to show them in action.
Added a wxSTC style editor from Riaan Booysen to the sample apps.
Added a new "constructor" to most of the window classes that calls the
default C++ constructor, (the one with no parameters) and also added the
corresponding Create(...) method. This allows you to do a 2-step
creation of windows which is sometimes required for doing things such
as setting extended style flags before the window is created, or for
passing the object to the XRC resource system to be created from the
resource. The name of the new "constructor" is the original name of
the class with a "Pre" in it. For example, wxPreWindow, wxPreFrame,
etc.
Significantly changed how the Python interpreter lock and thread state
are managed, which should fix the problem of running on a
multi-processor machine.
Added wxFindReplaceDialog.
Added wxStopWatch.
Passing None for the handler parameter to one of the EVT_** functions
will now Disconnect the event.
Added wxFileHistory.
Updated wxEditor with lots of enhancements from Steve Howell and Adam
Feuer.
2.3.1
-----
Added EVT_GRID_EDITOR_CREATED and wxGridEditorCreatedEvent so the user
code can get access to the edit control when it is created, (to push
on a custom event handler for example.)
Added wxTextAttr class and SetStyle, SetDefaultStyle and
GetDefaultStyle methods to wxTextCtrl.
Added ability to use xml resource files. Still need to add ability to
subclass wxXmlResourceHandler, etc...
2.3.0
-----
Removed initial startup dependency on the OpenGL DLLs so only the
glcanvasc.pyd depends on them, (on wxMSW.)
Added tools that will take an image file in a wx supported format and
convert it to data embedded in a Python source file. The image is
converted to XPM format which is essentially a list of strings
containing info about each pixel. The image's transparency mask is
included, if there is one, or a mask can be added if a mask colour is
specified on the command line. It is then pickled and optionally
compressed and written to a Python source file along with functions to
convert it to either a wxBitmap or a wxImage. See
wxPython/demo/images.py for examples, and wxPython/Tools/img2py.py for
the implementation.
Added wxToggleButton.
OOR:
Implemented the first phase of OOR (Original Object Return). See
the text in the demo for more details of what this means, but in a
nutshell methods such as wxWindow.GetParent or FindWindowById will
now return a shadow object of the proper type if it can. By
"proper type" I mean that if the wxWindow pointer returned from
FindWindowById really points to a wxButton then the Python object
constructed will be of a wxButtonPtr class instead of wxWindowPtr
as before. This should reduce or eliminiate the need for
wxPyTypeCast. (Woo Hoo!) The objects returned are still not the
original Python object, but that is the next step. (Although it
will probably only work on Python 2.1 and beyond because it will
use weak references.)
This first phase of the OOR plan is fairly significant and has
required a lot of changes all over wxPython, most of which should
be transparent to you, however I'm not 100% sure that it didn't
introduce any new bugs that are hiding somewhere and didn't get
stomped on during my testing. So please be sure to test everything
thoroughly when you install this version and be sure to report any
object-type related oddities to me.
There is now a wxObject class that most other classes derive from like
in C++, but the methods provided don't really match but are wxPython
specific. It could have been added long ago but OOR required it so it
finally got done.
Added wxWave.
2.2.6
-----
2.2.5
-----
New typemaps for wxString when compiling for Python 2.0 and beyond
that allow Unicode objects to be passed as well as String objects. If
a Unicode object is passed PyString_AsStringAndSize is used to convert
it to a wxString using the default encoding.
Added a listbox to the listbox demo that shows how to find items with
a matching prefix as keys are typed.
Added code to the wxListCtrl demo to show how to get text from a
column in report mode.
Added code to the toolbar demo to clear the long help from the status
bar after 2 seconds.
Added wxJoystick.
New in 2.2.2
------------
I am now using the Python Distutils to build wxPython and to make some
of the distribution files. (See http://www.python.org/sigs/distutils-sig/)
This means no more messing with my kludgy build.py/Makefile hack,
builds will be more consistent with other Python extensions that also
use Distutils, and will hopefully make wxPython easier to build for
platforms where there have been troubles before. If you are building
wxPython for Python 1.5.2 or for 1.6, then you will need to get and
install version 1.0 of Distutils from the website above. If you are
using Python 2.0 then you already have it.
Added __add__, __sub__ and __cmp__ (equality check only) for wxPoint
and wxRealPoint.
Changed the build to make one big extension module instead of one for
the core and each contrib. This allowed me to do away with the
libwxPyHelpers.so on unix systems.
Some hacks on wxGTK to try and make the AutoComplete listbox in the
wxStyledTextCtrl to behave better. It's still not as nice as on
wxMSW, but at least it's a bit more usable now.
New in 2.2.1
------------
New in 2.2.0
------------
New in 2.1.16
-------------
Added wxDragImage.
Added wxCalendarCtrl.
WARNING: A while back I asked what should be done about the Magic
Method Names. (Methods that are automatically turned into event
handlers by virtue of their name.) The consensus was that it is more
confusing to have them than to try and expand them to have greater
coverage. I am finally getting around to removing the code that
generates the event binding. This means that if you are using any of
the following method names without a EVT_* call that you need to
modify your code to add the EVT_* to hook the event to the method.
OnChar
OnSize
OnEraseBackground
OnSysColourChanged
OnInitDialog
OnPaint
OnIdle
OnActivate
OnMenuHighlight
OnCloseWindow
OnScroll
Added wxSpinCtrl.
New in 2.1.15
-------------
Added wxListCtrl.SortItems and changed the demo to show how to use it.
Wrapped the new wxGrid and friends. The old wxGrid class is no longer
available. There are some incompatibilities, and unfortunately the
new classes are not documented yet, (however the methods are more
consistent with each other now so you may be able to guess pretty
good...)
Updated wxMVCTree and added a demo for it, also fixed layout on GTK
and some flicker problems.
Added a wrapper class for the Visualization ToolKit (or VTK) in the
wxPython.lib.vtk module. (http://www.kitware.com/)
The C++ wxToolBar classes have been redone, and so have the wxPython
wrappers. There have been slight modifications to some of the methods
but shouldn't impact anybody too much. I took the opportunity to add
support for setting user data on each toolbar tool. The new AddTool
methods look like this:
def AddTool(ID,
bitmap,
pushedBitmap = wxNullBitmap,
toggle = FALSE,
clientData = NULL,
shortHelpString = "",
longHelpString = "")
def AddSimpleTool(ID,
bitmap,
shortHelpString = "",
longHelpString = "",
toggle=FALSE)
wxRect now simulates attributes named left, right, top and bottom.
Removed all non wx stuff from the glcanvas module since DA's PyOpenGL
is better and compatible with the wxGLCanvas. You can get it at
http://starship.python.net:9673/crew/da/Code/PyOpenGL.
Changed all the "LIST" parameter names to "choices" to match the docs.
More fixes for the wxFloatBar, and it now works on wxGTK even better
than wxMSW! (The feat is accomplished by using the wxTB_DOCKABLE
style flag instead of trying to float it ourselves.)
Fixed wxMSW's notebook so the pages get their size set as they are
being added. This should remove the need for our
wxNotebook.ResizeChildren hack.
Added wxWindow.GetHandle
Added wxFontEnumerator.
wxPyEvent and wxPyCommandEvent derived classes now give you the actual
Python object in the event handler instead of a new shadow.
Added typemaps for wxSize, wxPoint, wxRealPoint, and wxRect that allow
either the actual objects or Python sequence values to be used. For
example, the following are equivallent:
Super-charged the wxHtml module. You can now create your own tag
handlers and also have access to the parser and cell classes. There
is a tag handler in the library at wxPython.lib.wxpTag that
understands the WXP tag and is able to place wxPython windows on HTML
pages. See the demo for an example.
I've finally added a feature that has been on my list for close to two
years! Ever wondered what that zero is for when you create your app
object? Well now you can leave it out or explicitly set it to a true
value. This value now controls what is to be done with sys.stdout and
sys.stderr. A false value leaves them alone, and a true value sets
them to an instance of wxPyOnDemandOutputWindow. (On windows the
default is true, on unix platforms the default is false.) This class
creates a frame containing a wxTextCtrl as soon as anything is written
to sys.stdout or sys.stderr. If you close the window it will come
back again the next time something is written. (You can call
app.RestoreStdio to turn this off.) If you would rather that the stdio be
redirected to a file, you can provide a second parameter to your app
object's constructor that is a filename. If you want to use your own
class instead of wxPyOnDemandOutputWindow you can either implement
RedirectStdio() in you app class or change the value of
wxApp.outputWindowClass like this:
class MyApp(wxApp):
outputWindowClass = MyClass
def OnInit(self):
frame = MyFrame()
self.SetTopWindow(frame)
return true
wxDC.Bilt now includes the useMask parameter, and has been split into
two different versions. wxDC.BlitXY is like what was there before and
takes raw coordinants and sizes, and the new wxDC.Blit is for the new
interface using wxPoints and a wxSize.
It is now possible to run through MainLoop more than once in any one
process. The cleanup that used to happen as MainLoop completed (and
prevented it from running again) has been delayed until the wxc module
is being unloaded by Python.
Got the in-place-edit for the wxTreeCtrl fixed and added some demo
code to show how to use it.
Put the wxIcon constructor back in for GTK as it now has one that
matches MSW's.
Added wxGrid.GetCells
Fixed wxImage GetData and SetData to properly use String objects for
data transfer.
Fixes for the wxGLCanvas demo to work around a strange bug in gtk.
Switched back to using the wxWindows DLL for the pre-built Win32
version. The problem was needing to reinitialize static class info
data after loading each extension module.
wxSizer and friends. Sizers are layout tools that manage a colection
of windows and sizers. Different types of sizers apply different
types of layout algorithms. You saw it here first! These classes are
not even in the wxWindows C++ library yet!
Awesome new Demo Framework for showing off wxPython and for learning
how it all works.
Fixed some problems with how SWIG was wrapping some wxTreeCtrl
methods.
What's new in 2.0b8
-------------------
Support for using Python threads in wxPython apps.
Added wxConfig.
Changed many of the args and return values that were pointers to gdi
objects to references to reflect changes in the wxWindows API.