默认的控件上的字体锯齿太严重,其实可以这样设置任何控件的字体(button,tab,wnd......)
// 设置字体参数
LOGFONT LogFont;
::memset(&LogFont, 0, sizeof(LOGFONT));
lstrcpyW(LogFont.lfFaceName,L"华文行楷");
LogFont.lfWeight = 400;//字体粗细
LogFont.lfHeight = 20; // 字体大小
LogFont.lfCharSet = 134;//字符集
LogFont.lfOutPrecision = 3;
LogFont.lfClipPrecision = 2;
LogFont.lfOrientation = 45;
LogFont.lfQuality = 1;
LogFont.lfPitchAndFamily = 2;
// 创建字体
HFONT hFont = CreateFontIndirect(&LogFont);
// 设置控件字体
::SendMessage(hwndTab, WM_SETFONT, (WPARAM)hFont, 0);