描述
CreateRectRgn函数创建一个矩形区域。
C++ 语法
HRGN CreateRectRgn( __in int nLeftRect, __in int nTopRect, __in int nRightRect, __in int nBottomRect ); |
PowerBASIC 语法
FUNCTION CreateRectRgn ( _ BYVAL nLeftRect AS LONG, _ BYVAL nTopRect AS LONG, _ BYVAL nRightRect AS LONG, _ BYVAL nBottomRect AS LONG _ ) AS DWORD |
参数
nLeftRect
[in]以逻辑单位指定区域左上角的x坐标。
nTopRect
[in]以逻辑单位指定区域左上角的y坐标。
nRightRect
[in]以逻辑单位指定区域右下角的x坐标。
nBottomRect
[in]以逻辑单位指定区域右下角的y坐标。
返回值
如果函数成功,则返回值是该区域的句柄。
如果函数失败,返回值为NULL。
备注
当您不再需要HRGN对象时,调用DeleteObject功能将其删除。
区域坐标表示为27位有符号整数。
该区域将不包括底部和右侧边缘。
引用文件 #INCLUDE Once
WinGdi.inc