VOID BackgroundObject::DrawOverlay(WCHAR *wChar, UINT length)
{
D2D1_SIZE_F renderTargetSize = m_pRenderTarget->GetSize();
m_pRenderTarget->SetTransform(Matrix3x2F::Identity());
m_pRenderTarget->DrawText(wChar,
length - 1,
m_pD2DDriver->GetTextFormat(),
RectF(g_metrics.UnscaleX(10), 0, renderTargetSize.width, renderTargetSize.height),
m_pD2DDriver->GetBrush(DrawingColor::White));
}
上面的代码是将字体绘制到窗口上,但我想改变字体的大小。 我该怎么做?
我是MSDN的新手,无论如何......非常感谢任何帮助!