|
-
September 21st, 2003, 11:37 PM
#1
Simple question: Invalidate() vs InvalidateRect()
M....
I am wondering whether:
1. InvalidateRect(NULL) is having the same effect as Invalidate().
2. In MSDN, it says: " If bErase is TRUE for any part of the update region, the background in the entire region, not just in the given part, is erased. ".
So is this mean if we use Invalidate(), then no matter how small the clip regions are, all client area will be set invalid? (Repaint the complete client area?)
Thanks for you guys' help.
-
September 22nd, 2003, 08:45 AM
#2
Hi myron,
for both of your questions the answer is true.
-
September 22nd, 2003, 10:06 AM
#3
Re: Simple question: Invalidate() vs InvalidateRect()
Yes, if you pass in true for the erase param or specify Null for the rect param, InvalidateRect is the same as Invalidate. However it's usefulness is in specifying a rect and bErase = FALSE; this allows the just the clip region to be updated.
It should also be noted that this behavior can be modified by overriding the OnEraseBkgnd handler; if you just return TRUE then the current background will not be redrawn, but the clip region will be whatever was specified by the call...
bytz
--This signature left intentionally blank--
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|