As explained in the manual (see MDI versus SDI), wxWindows takes an automated view of Microsoft Windows's MDI (Multiple Document Interface) since it is a very platform-specific feature. The special MDI 'Window' menu, allowing the user to switch between child windows, is provided automatically, though without any accelerators and without a choice of position. Also, instead of deriving frames from distinct classes for MDI versus SDI, the approach taken in Microsoft's class library, wxWindows uses an option in the frame constructor to switch between styles. This allows the programmer to delay the MDI/SDI decision, perhaps even providing a command-line switch to let the user decide.
The mdi example program shows this run-time switching. Invoked without a command line switch, it defaults to SDI. Invoked with the switch -mdi it runs as an MDI program, but only under Windows 3.1.
There are a few extra considerations when programming an MDI applications. One is the choice of menu items. An SDI program might have a main window and several child windows, where the main window menu has options for quitting the program and other global matters, while child window menus have child-specific options. In MDI, the child window menu visually replaces the main window menu when activated, and so it must duplicate some main window menu options. One solution is to include logic to add extra menu items depending on whether MDI or SDI is specified, as the mdi example does.
Also, for programs which must be both SDI and MDI (on non-Windows 3.1 platforms SDI mode is mandatory), the main window must not have subwindows (i.e. panels, canvases or text subwindows) since the client area may be occupied with child MDI windows under Windows 3.1.
MDI icons pose a small technical difficulty, in that for some reason it is not possible to use the same technique of dynamically painting the icon onto the iconized frame client area as with SDI frames. Consequently the programmer must insert some lines into the resource file for providing icons (see mdi.rc) as well as using the SetIcon call in the program for non-Windows 3.1 platforms. Only one icon image for child MDI frames may be provided.