Hermy
asked on
Drawing in a View window problem
Hello,
I want to draw in the View window of a MFC application. This can be done with LineTo, MoveTo, etc. Now when I want to draw a rect, that moves when my mouse moves, the old rects are still there. I can update de view window with pDoc->UpdateAllViews() but this causes my application to crasch sometimes and the View window flickers with this 'animation'.
Is there another appraoch how you can avoid this problem?
Herman
I want to draw in the View window of a MFC application. This can be done with LineTo, MoveTo, etc. Now when I want to draw a rect, that moves when my mouse moves, the old rects are still there. I can update de view window with pDoc->UpdateAllViews() but this causes my application to crasch sometimes and the View window flickers with this 'animation'.
Is there another appraoch how you can avoid this problem?
Herman
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
draw the rectangle with this coordinates but with background color and then draw
new rectangle with your forground color and save coordinates