请教Windows Platform SDK Documentation关于CreateWindow()函数的用法,谢谢!
在Windows Platform SDK Documentation中CreateWindow()的函数原型如下:
HWND CreateWindow(
LPCTSTR lpClassName,
LPCTSTR lpWindowName,
DWORD dwStyle,
int x,
int y,
int nWidth,
int nHeight,
HWND hWndParent,
HMENU hMenu,
HINSTANCE hInstance,
LPVOID lpParam
);
其中形参
nWidth表述为Specifies the width, in device units, of the window.
nHeight表述为Specifies the height, in device units, of the window.
这里的device units指的是象素吗?
是不是设备坐标指的就是以象素为单位的坐标?
谢谢!
问题点数:100、回复次数:8Top
1 楼Jarrylogin(正经事情我不会,歪门邪道样样行)回复于 2005-01-27 16:54:36 得分 10
视口和窗口是不同的概念Top
2 楼vcleaner(我没当大哥很久了.......)回复于 2005-01-27 16:55:27 得分 20
设备坐标在显示的时候就是象素。Top
3 楼vcleaner(我没当大哥很久了.......)回复于 2005-01-27 16:56:44 得分 20
逻辑坐标和设备坐标的转换就是映射模式所做的工作,但是在CreateWindow的时候指定的应该就是象素,即设备坐标。Top
4 楼legendhui(秋天的叶子)回复于 2005-01-27 21:34:41 得分 10
就是象素Top
5 楼I_Love_CPP(Never stop!)回复于 2005-01-27 21:42:46 得分 30
你的理解是正确的。
In all device coordinate systems, units are expressed in terms of pixels. Values on the horizontal x-axis increase from left to right, and values on the vertical y-axis increase from top to bottom.
Top
6 楼windyhui(冷月清风)回复于 2005-01-28 14:55:59 得分 0
帮你顶一下Top
7 楼BlueprintIrene(我只能用程序来麻痹自己)回复于 2005-01-28 16:12:38 得分 0
谢谢各位的解答!Top
8 楼oyljerry(【勇敢的心】→ ㊣提拉米苏√㊣)回复于 2005-01-28 17:08:58 得分 10
就是象素Top




