April 27th, 1999, 11:50 PM
How to change the font of the CEditView?
|
Click to See Complete Forum and Search --> : How to change the font April 27th, 1999, 11:50 PM How to change the font of the CEditView? April 28th, 1999, 01:20 AM You need to declare a CFont object and use the CreateFont function. The following example sets the font to 12 point Arial. [ccode] CFont fontText; fontText.CreateFont(12, 0, 0, 0, 400, FALSE, FALSE, 0, ANSI_CHARSET, OUT_DEFAULT_PRECIS, CLIP_DEFAULT_PRECIS, DEFAULT_QUALITY, DEFAULT_PITCH | FF_SWISS, "Arial"); //You then have to point the device context to the new font. CClientDC dc(this); dc.SelectObject(&fontText); codeguru.com
Copyright Internet.com Inc., All Rights Reserved. |