Click here to get back home

how to set font style

 HomeNewsGroups | Search | About
 microsoft.public.smartphone.developer    Post an article   get this group's latest topics as an RSS feed add this group's latest topics to your My MSN content add this group's latest topics to your My Yahoo content
Subject Author Date
how to set font style goacross 09-21-2007
Get Chitika Premium
Posted by goacross on September 21, 2007, 11:03 pm
Please log in for more thread options
Is there any way to set the font size & style programmatically in my
application window?
thanks


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
>
>

Similar ThreadsPosted
Window style July 22, 2005, 1:25 am
Contact list style behavior September 10, 2007, 2:16 pm
VB.NET createfontindirect monospace font issue September 27, 2005, 11:39 am
How to custom the font and background of control? April 19, 2006, 5:07 am
Home plugin font size September 3, 2008, 6:06 am
Change font color on mouseover - PIE(Pocket PC Internet Explorer) October 30, 2006, 11:54 pm

Our other projects:

Art Dolls, Fairies and Mermaids - Sunnyfaces.net

Roy's Linux, Programming and Search Engines messages

1-Script XML SitemapXML Sitemap