Steps in Creating a Custom Dialog

team bbl


When you start writing your own specialized dialogs, the fun really starts. Here are the steps you'll typically need to take:

1.

Derive a new class from wxDialog.

2.

Decide where the data is stored and how the application accesses user choices.

3.

Write code to create and lay out the controls.

4.

Add code that transfers data between C++ variables and the controls.

5.

Add functions and their event table entries to handle events from controls.

6.

Add user interface (UI) update handlers to set controls to the correct state.

7.

Add help, in particular tooltips, context-sensitive help (not implemented on Mac OS X), and a way of showing an explanation of the dialog in your application's user manual.

8.

Invoke the dialog from a suitable place in your application code.

Let's illustrate these steps with a concrete example.

    team bbl



    Cross-Platform GUI Programming with wxWidgets
    Cross-Platform GUI Programming with wxWidgets
    ISBN: 0131473816
    EAN: 2147483647
    Year: 2005
    Pages: 262

    flylib.com © 2008-2017.
    If you may any questions please contact us: flylib@qtcs.net