// TODO: Change any attributes of the DC here if(IDC_STATIC1 == pWnd->GetDlgCtrlID()) { pDC->SetTextCharacterExtra(10); } // TODO: Return a different brush if the default is not desired return hbr; }
// TODO: Change any attributes of the DC here if(IDC_STATIC1 == pWnd->GetDlgCtrlID()) { pDC->SetTextCharacterExtra(10); } // TODO: Return a different brush if the default is not desired return hbr; }
{
HBRUSH hbr = CDialog::OnCtlColor(pDC, pWnd, nCtlColor);
// TODO: Change any attributes of the DC here
if(IDC_STATIC1 == pWnd->GetDlgCtrlID())
{
pDC->SetTextCharacterExtra(10);
}
// TODO: Return a different brush if the default is not desired
return hbr;
}
{
HBRUSH hbr = CDialog::OnCtlColor(pDC, pWnd, nCtlColor);
// TODO: Change any attributes of the DC here
if(IDC_STATIC1 == pWnd->GetDlgCtrlID())
{
pDC->SetTextCharacterExtra(10);
}
// TODO: Return a different brush if the default is not desired
return hbr;
}
没好用~我试过不用静态控件显示文字,在 OnPaint SetTextCharacterExtra,并DrawText出来,(我的窗体是动态移动的,即规定时间内 是移动状态),这时候文字就闪烁~