The information in this article applies to:
SUMMARY
Most drawing software uses what is termed a "rubber rectangle". This term
is used to describe the situation where
MORE INFORMATIONThe key to making this work is in the following call, which should be made in the WM_LBUTTONDOWN case:
On each WM_MOUSEMOVE message, the rectangle is redrawn in its previous
position. Because of the ROP code, the rectangle appears to be erased. The
new position for the rectangle is calculated and then the rectangle is
drawn.
Note that Windows will only let you draw in the invalid area of the window if you use a DC returned from BeginPaint(). If you want to use the DC returned from BeginPaint(), you must first call InvalidateRect() to specify the region to be updated. With the DC returned from GetWindowDC(), Windows will restrict your drawing to the client and non-client areas. With the hDC returned from CreateDC(), you can write on the entire display, so you must be careful. Additional query words: 3.10 4.00
Keywords : kbNTOS350 kbNTOS351 kbNTOS400 kbSDKWin32 kbWinOS95 |
Last Reviewed: June 16, 1999 © 2000 Microsoft Corporation. All rights reserved. Terms of Use. |