This document describes the API to wx.NET. This is complete referring to the synopsis of classes and methods since it is generated directly from source code. Unfortunately, several classes and functions are not yet described. In these cases, refer to the original wxWidgets documentation. Usually, wx.NET provides the same entities as wxWidgets does, for instance class wxWindow in wxWidgets is wrapped by a class wx.Window in wx.NET and method wx.Window.Show() wrapps method wxWindow.Show().
If you start working with wx.NET, please consult Known Problems And Pitfalls.
Since Release 0.9.1 several methods changed their signature, so you probably will have to adjust existing code. These changes have been motivated by the goal to make wx.NET a real .NET library rather than a more or less complete binding of wxWidgets. So, wx.NET will use enumerations with attribute Flags like wx.WindowStyles instead of unsigned integers whereever possible in order to represend flags and styles. This eases use of the library dramatically since developers can use IntelliSense to list viable options on typing in methods.
The classes of wx.NET have been reorganized into several namespaces like wx.GridCtrl. This eases use of IntelliSense and navigation through the classes using the object manager.
Some concepts of wxWidgets simply do not fit into the .NET world like e.g. validators. Refer to wx.ComponentModel instead.
Refer to Building From Source for notes on how to build wx.NET.
wx.WindowStyles) and sizers are now enumerations. So, you can use IntelliSense when using controls and sizers. wx.StyledText, wx.Globalization, and wx.MaskedEdit have been added.helpview.exe has been added to the distribution in order to present platform independent HTB documentations on wx.NET, the samples and the original wxWidgets library. Unfortunately, programmers often have to consult the original documentation since the new wx.net.htb file is far from being complete. The text of this documentation is directly compiled from the C# source files. Additionally, a .NET XML documentation can be compiled from these remarks on the source code. Furthermore, this release introduces wx.Archive, the first pure .NET implementation of wx.NET. Many small changes on drawing, fonts, colours, and several controls increased reliability of the system.
STAThreadAttribute on the entry point/ main function). wxWidgets as well as .NET will conduct OLE initialization and these initializations must be done consistently. using to inform .NET to dispose the object immediately after leaving the block (this is equivalent to the standard behavious in C++) or you may call wx.Object.Dispose() explicitely on the device context. wxWindow.Destroy() by the destructor. In .NET, destruction of objects will usually be deferred. So, wx.Window.Destroy() must be called explicitely to destroy a control that shall be replaced by another. As an examply refer to wx.HtmlWidgetCell that register themselves at the wx.HtmlWindow when they are inserted into that window. When a new page is loaded into that window, these widgets cells and the contained controls are no longer needed. The wx.HtmlWindow can destroy them automatically because they registered themselves. wx.Object explicitely using wx.Object.Dispose() in order to avoid memory leaks, since the wrappers will live until the system is sure that wxWidgets will not need their letter in the further more. Refer to wx.Object.InstancesCount and wx.Object.SavedInstancesCount to test this. wx.ColourDatabase.TheColourDatabase, wx.Pen.ThePenList, wx.Brush.TheBruchList, and wx.Font.TheFontList whenever possible. Get pens, brushes, and fonts from a window only once and cache them in a member variable. uint. This practice unfortunately disables editor features like IntelliSence. Refer to files Defs.cs ans Window.cs for the most globally used styles and IDs. At some places, uint styles have been replaced by enumerations (refer to wx.ListCtrl). Use wx.WindowStyles for style flags of windows. wx.Samples.ListCtrlApp and wx.Samples.MyHtmlListBox. Since the .NET framework uses an automatic memory management, use method wx.Window.Destroy() to eliminate the old window before adding the new one.
(c) 2003-2009 the wx.NET project