Version: 3.2.7
wxPreferencesPage Class Referenceabstract

#include <wx/preferences.h>

+ Inheritance diagram for wxPreferencesPage:

Detailed Description

One page of preferences dialog.

This is the base class for implementation of application's preferences. Its methods return various properties of the page, such as title or icon. The actual page is created by CreateWindow().

See also
wxStockPreferencesPage

Library:  wxCore
Since
2.9.5

Public Member Functions

 wxPreferencesPage ()
 Constructor. More...
 
virtual ~wxPreferencesPage ()
 Destructor. More...
 
virtual wxString GetName () const =0
 Return name of the page. More...
 
virtual wxBitmapBundle GetIcon () const =0
 Return the icon to be used for the page on some platforms. More...
 
virtual wxBitmap GetLargeIcon () const =0
 
virtual wxWindowCreateWindow (wxWindow *parent)=0
 Create a window for this page. More...
 

Constructor & Destructor Documentation

◆ wxPreferencesPage()

wxPreferencesPage::wxPreferencesPage ( )

Constructor.

◆ ~wxPreferencesPage()

virtual wxPreferencesPage::~wxPreferencesPage ( )
virtual

Destructor.

Member Function Documentation

◆ CreateWindow()

virtual wxWindow* wxPreferencesPage::CreateWindow ( wxWindow parent)
pure virtual

Create a window for this page.

The window will be placed into the preferences dialog in platform-specific manner. Depending on the platform, this method may be called before showing the preferences window, when switching to its tab or even more than once. Don't make assumptions about the number of times or the specific time when it is called.

The caller takes ownership of the window.

wxPanel is usually used, but doesn't have to be.

Parameters
parentParent window to use.

◆ GetIcon()

virtual wxBitmapBundle wxPreferencesPage::GetIcon ( ) const
pure virtual

Return the icon to be used for the page on some platforms.

Currently only used on macOS.

Note
This method is not pure virtual, but must be implemented on the platforms that require it (macOS). The preprocessor symbol wxHAS_PREF_EDITOR_ICONS is defined if this method must be implemented.
Since
3.1.6

Implemented in wxStockPreferencesPage.

◆ GetLargeIcon()

virtual wxBitmap wxPreferencesPage::GetLargeIcon ( ) const
pure virtual
Deprecated:
This function is deprecated, override GetIcon() instead.

◆ GetName()

virtual wxString wxPreferencesPage::GetName ( ) const
pure virtual

Return name of the page.

The name is used for notebook tab's label, icon label etc., depending on the platform.

Implemented in wxStockPreferencesPage.