网站首页  词典首页

请输入您要查询的函数:

 

术语 invalidaterect
释义 InvalidateRect
语法:
BOOL InvalidateRect(
__in HWND hWnd,
__in const RECT *lpRect,
__in BOOL bErase
);
InvalidateRect函数
该InvalidateRect函数将一个矩形到指定窗口的更新区域。更新区域代表窗口的客户区的一部分,必须重新划定。
参数
hWnd [in]
一个句柄,的更新区域改变窗口。如果该参数为NULL,系统无效,并重绘所有窗口,并发送函数返回前的WM_ERASEBKGND和WM_NCPAINT消息到窗口过程。
lpRect [in]
一个矩形结构,它包含客户端指针坐标添加到更新区域的矩形。如果该参数为NULL,则整个客户区域被添加到更新区域。
bErase [in]
指定是否在更新区域的背景是被删除时,更新区域被处理。如果此参数为TRUE,被删除的背景时,BeginPaint函数被调用。如果此参数为FALSE,背景保持不变。
返回值
如果函数成功,返回值为非零。
如果函数失败,返回值是零。
备注
在无效领域积累的更新区域,直到该地区的未来时处理WM_PAINT消息时,或直至该地区使用ValidateRect或ValidateRgn功能验证。
该系统发送WM_PAINT消息到一个窗口时,它的更新区域不是空的,而且是在该窗口的应用程序队列中没有其他消息。
如果bErase参数是任何更新的部分地区为TRUE,背景擦除整个区域,不仅在指定的一部分。
实例
有关示例,请参阅无效的客户区。
要求:
最低支持:client-Windows 2000专业版
最低支持server-Windows 2000服务器
HeaderWinuser.h(头文件:winuser.h)
LibraryUser32.lib
DLLUser32.dll
参见
绘画和绘图概述
绘画和绘图功能
调用BeginPaint
InvalidateRgn
RECT
ValidateRect
ValidateRgn
WM_ERASEBKGND
WM_NCPAINT
WM_PAINT消息
如果有任何问题和意见,请发送给微软(wsddocfb@microsoft.com)
生成日期:2009年7月11日
==英文原文==InvalidateRect Function
The InvalidateRect function adds a rectangle to the specified window's update region. The update region represents the portion of the window's client area that must be redrawn.
Syntax
BOOL InvalidateRect(
__in HWND hWnd,
__in const RECT *lpRect,
__in BOOL bErase
);
Parameters
hWnd [in]
A handle to the window whose update region has changed. If this parameter is NULL, the system invalidates and redraws all windows, and sends the WM_ERASEBKGND and WM_NCPAINT messages to the window procedure before the function returns.
lpRect [in]
A pointer to a RECT structure that contains the client coordinates of the rectangle to be added to the update region. If this parameter is NULL, the entire client area is added to the update region.
bErase [in]
Specifies whether the background within the update region is to be erased when the update region is processed. If this parameter is TRUE, the background is erased when the BeginPaint function is called. If this parameter is FALSE, the background remains unchanged.
Return Value
If the function succeeds, the return value is nonzero.
If the function fails, the return value is zero.
Remarks
The invalidated areas accumulate in the update region until the region is processed when the next WM_PAINT message occurs or until the region is validated by using the ValidateRect or ValidateRgn function.
The system sends a WM_PAINT message to a window whenever its update region is not empty and there are no other messages in the application queue for that window.
If the bErase parameter is TRUE for any part of the update region, the background is erased in the entire region, not just in the specified part.
Examples
For an example, see Invalidating the Client Area .
Requirements
Minimum supported clientWindows 2000 Professional
Minimum supported serverWindows 2000 Server
HeaderWinuser.h (include Windows.h)
LibraryUser32.lib
DLLUser32.dll
See Also
Painting and Drawing Overview
Painting and Drawing Functions
BeginPaint
InvalidateRgn
RECT
ValidateRect
ValidateRgn
WM_ERASEBKGND
WM_NCPAINT
WM_PAINT
Send comments about this topic to Microsoft
Build date: 7/11/2009
==原始网址==http://msdn.microsoft.com/en-us/library/dd145002(VS.85).aspx\n
随便看

 

windows api函数参考手册包含2258条windows api函数文档,详细介绍nodejs、java、rust调用windows api的方法技巧,是学习windows api编程的入门中文文档。

 

Copyright © 2004-2023 Winrtm.com All Rights Reserved
京ICP备2021023879号-40 更新时间:2024/10/6 13:19:46