Re: [1/2] richedit: Clip painting to formatting rectangle (try 2)
Jan. 14, 2009
7:21 a.m.
Dylan Smith <dylan.ah.smith(a)gmail.com> writes:
@@ -29,6 +29,17 @@ void ME_PaintContent(ME_TextEditor *editor, HDC hDC, BOOL bOnlyNew, const RECT * ME_Context c; int yoffset; int ys, ye; + HRGN oldRgn, clipRgn; + + oldRgn = CreateRectRgn(0, 0, 0, 0); + if (!GetClipRgn(hDC, oldRgn)) + { + DeleteObject(oldRgn); + oldRgn = NULL; + } + clipRgn = CreateRectRgnIndirect(rcUpdate); + ExtSelectClipRgn(hDC, clipRgn, RGN_AND); + DeleteObject(clipRgn);
IntersectClipRect would be a lot easier. -- Alexandre Julliard julliard(a)winehq.org
6280
Age (days ago)
6280
Last active (days ago)
0 comments
1 participants
participants (1)
-
Alexandre Julliard