+ A dialog box is a window with a title bar and sometimes a system menu,
+ which can be moved around the screen. It can contain controls and other
+ windows and is often used to allow the user to make some choice or to
+ answer a question.
+
+ Dialogs can be made scrollable, automatically, for computers with low
+ resolution screens: please see @ref overview_dialog_autoscrolling for
+ further details.
+
+ Dialogs usually contains either a single button allowing to close the
+ dialog or two buttons, one accepting the changes and the other one
+ discarding them (such button, if present, is automatically activated if the
+ user presses the "Esc" key). By default, buttons with the standard wxID_OK
+ and wxID_CANCEL identifiers behave as expected. Starting with wxWidgets 2.7
+ it is also possible to use a button with a different identifier instead,
+ see SetAffirmativeId() and SetEscapeId().
+
+ Also notice that the CreateButtonSizer() should be used to create the
+ buttons appropriate for the current platform and positioned correctly
+ (including their order which is platform-dependent).
+
+ @section dialog_modal Modal and Modeless
+
+ There are two kinds of dialog, modal and modeless. A modal dialog blocks
+ program flow and user input on other windows until it is dismissed, whereas
+ a modeless dialog behaves more like a frame in that program flow continues,
+ and input in other windows is still possible. To show a modal dialog you
+ should use the ShowModal() method while to show a dialog modelessly you
+ simply use Show(), just as with frames.
+
+ Note that the modal dialog is one of the very few examples of
+ wxWindow-derived objects which may be created on the stack and not on the
+ heap. In other words, while most windows would be created like this:
+
+ @code
+ void AskUser()
+ {
+ MyAskDialog *dlg = new MyAskDialog(...);
+ if ( dlg->ShowModal() == wxID_OK )
+ // ...
+ //else: dialog was cancelled or some another button pressed
+
+ dlg->Destroy();
+ }
+ @endcode
+
+ You can achieve the same result with dialogs by using simpler code:
+
+ @code
+ void AskUser()
+ {
+ MyAskDialog dlg(...);
+ if ( dlg.ShowModal() == wxID_OK )
+ // ...
+
+ // no need to call Destroy() here
+ }
+ @endcode
+
+ An application can define a wxCloseEvent handler for the dialog to respond
+ to system close events.