主题:关于MASM32中绘制文本的问题
hztaza
[专家分:0] 发布于 2006-01-30 11:37:00
我只知道怎样把文本绘制成单行显示、水平居中、垂直居中几种形式,怎样才能把它写在窗口任意位置上啊?
谢谢关注,谢谢回复!
回复列表 (共1个回复)
沙发
jhkdiy [专家分:1620] 发布于 2006-01-31 05:56:00
使用TextOut函数可以在指定的位置输出文本:
The TextOut function writes a character string at the specified location, using the currently selected font, background color, and text color.
BOOL TextOut(
HDC hdc, // handle to DC
int nXStart, // x-coordinate of starting position
int nYStart, // y-coordinate of starting position
LPCTSTR lpString, // character string
int cbString // number of characters
);
我来回复