#include <GFontSelect.h>
Public Member Functions | |
GFontSelect (GView *Parent, void *Init=0) | |
Create the dialog. | |
int | OnNotify (GViewI *Ctrl, int Flags) |
Called when a child view or view with it's SetNotify() set to this window changes. | |
bool | Serialize (void *Data, bool Write) |
Public Attributes | |
char * | Face |
The face of the font selected. | |
int | Size |
The point size of the font selected. | |
bool | Bold |
True if the font should be bold. | |
bool | Underline |
True if the font should be underline. | |
bool | Italic |
True if the font should be italic. |
Example:
#if defined WIN32 LOGFONT Info; #else char Info[256]; #endif ZeroObj(Info); GFontSelect Dlg(MyWindow, Info); if (Dlg.DoModal() == IDOK) { Dlg.Serialize(Info, true); }
GFontSelect::GFontSelect | ( | GView * | Parent, | |
void * | Init = 0 | |||
) |
Create the dialog.
Parent | The parent window |
Init | The initial font information, or NULL if not available |
References GList::AddColumn(), GView::AddView(), Bold, Face, IDCANCEL, IDOK, GCombo::Insert(), List< Type >::Insert(), Italic, LGI_MET_DECOR_X, LGI_MET_DECOR_Y, LgiApp, GView::MoveToCenter(), GList::MultiSelect(), GWindow::Name(), OnNotify(), Serialize(), GView::SetParent(), GWindow::SetPos(), Size, Underline, GCheckBox::Value(), and GCombo::Value().
int GFontSelect::OnNotify | ( | GViewI * | Ctrl, | |
int | Flags | |||
) |
Called when a child view or view with it's SetNotify() set to this window changes.
The event by default will bubble up to the GWindow at the top of the window heirarchy visiting each GView on the way. If it reaches a GView that processes it then the event stops propergating up the heirarchy.
Reimplemented from GView.
References GDialog::EndModal(), GLIST_NOTIFY_SELECT, IDCANCEL, IDOK, GCombo::Name(), and GView::SetCtrlValue().
Referenced by GFontSelect().
bool GFontSelect::Serialize | ( | void * | Data, | |
bool | Write | |||
) |