Drawing outlined text!

How to draw text like this! Looks interesting right! Well this is done using plain window’s GDI functions, here is a function which does this! [sourcecode language=’cpp’]// Thanks to Charles Petzold! void CCanvas::DrawOutlineText( CDC& dc, const CString& Text ) {  const int RestorePoint = dc.SaveDC(); // Create new font  CFont NewFont;   NewFont.CreatePointFont( 700, TEXT( […]
Continue reading…

 

Changing font of all child controls at one go!

Ever felt the need to change the font of all child controls of a dialog, or a window, and you had to use GetWindow, GetNextWindow and stuff like that to set a font for a window. Well here is an easy way! [sourcecode language=’cpp’]// Idea taken from MSDN… BOOL CSomeDialog::OnInitDialog() { // I am using […]
Continue reading…