Contents Up Previous Next

wxFontData

wxFontDialog overview

This class holds a variety of information related to font dialogs.

Derived from

wxObject

Include files

<wx/cmndata.h>

See also

Overview, wxFont, wxFontDialog

Members

wxFontData::wxFontData
wxFontData::EnableEffects
wxFontData::GetAllowSymbols
wxFontData::GetColour
wxFontData::GetChosenFont
wxFontData::GetEnableEffects
wxFontData::GetInitialFont
wxFontData::GetShowHelp
wxFontData::SetAllowSymbols
wxFontData::SetChosenFont
wxFontData::SetColour
wxFontData::SetInitialFont
wxFontData::SetRange
wxFontData::SetShowHelp
wxFontData::operator =


wxFontData::wxFontData

wxFontData()

Constructor. Initializes fontColour to black, showHelp to black, allowSymbols to true, enableEffects to true, minSize to 0 and maxSize to 0.


wxFontData::EnableEffects

void EnableEffects(bool enable)

Enables or disables 'effects' under MS Windows or generic only. This refers to the controls for manipulating colour, strikeout and underline properties.

The default value is true.


wxFontData::GetAllowSymbols

bool GetAllowSymbols()

Under MS Windows, returns a flag determining whether symbol fonts can be selected. Has no effect on other platforms.

The default value is true.


wxFontData::GetColour

wxColour& GetColour()

Gets the colour associated with the font dialog.

The default value is black.


wxFontData::GetChosenFont

wxFont GetChosenFont()

Gets the font chosen by the user if the user pressed OK (wxFontDialog::ShowModal returned wxID_OK).


wxFontData::GetEnableEffects

bool GetEnableEffects()

Determines whether 'effects' are enabled under Windows. This refers to the controls for manipulating colour, strikeout and underline properties.

The default value is true.


wxFontData::GetInitialFont

wxFont GetInitialFont()

Gets the font that will be initially used by the font dialog. This should have previously been set by the application.


wxFontData::GetShowHelp

bool GetShowHelp()

Returns true if the Help button will be shown (Windows only).

The default value is false.


wxFontData::SetAllowSymbols

void SetAllowSymbols(bool allowSymbols)

Under MS Windows, determines whether symbol fonts can be selected. Has no effect on other platforms.

The default value is true.


wxFontData::SetChosenFont

void SetChosenFont(const wxFont& font)

Sets the font that will be returned to the user (for internal use only).


wxFontData::SetColour

void SetColour(const wxColour& colour)

Sets the colour that will be used for the font foreground colour.

The default colour is black.


wxFontData::SetInitialFont

void SetInitialFont(const wxFont&font)

Sets the font that will be initially used by the font dialog.


wxFontData::SetRange

void SetRange(int min, int max)

Sets the valid range for the font point size (Windows only).

The default is 0, 0 (unrestricted range).


wxFontData::SetShowHelp

void SetShowHelp(bool showHelp)

Determines whether the Help button will be displayed in the font dialog (Windows only).

The default value is false.


wxFontData::operator =

void operator =(const wxFontData& data)

Assignment operator for the font data.