|
Posted by dbgrick on September 24, 2007, 9:38 am
Please log in for more thread options
Create a Log font:
LOGFONT lf;
memset(&lf, 0, sizeof(lf));
lf.lfHeight = nSize;
lf.lfWidth = 0;
lf.lfEscapement = 0;
lf.lfOrientation = 0;
lf.lfWeight = MyWeght
lf.lfWeight = bIsBold;
lf.lfItalic = 0;
lf.lfUnderline = bUnderline;
lf.lfStrikeOut = 0;
lf.lfCharSet = ANSI_CHARSET;
lf.lfOutPrecision = OUT_DEFAULT_PRECIS;
lf.lfClipPrecision = CLIP_DEFAULT_PRECIS;
lf.lfQuality = DEFAULT_QUALITY;
lf.lfPitchAndFamily = DEFAULT_PITCH | FF_SWISS;
wsprintf(lf.lfFaceName, TEXT("Arial"));
Once you have the log font, you can SetDltItemFont to set the specific
dialog control's font or for the entire form call SelectObject with the new
font.
Regards,
Rick D.
Contractor
"goacross@gmail.com" wrote:
> Is there any way to set the font size & style programmatically in my
> application window?
> thanks
>
>
|