-
February 8th, 2008, 05:53 AM
#1
Erasing the line drawn using CDC
Hi,
I draw a line using CDC's LineTo method. After sometime, I want to erase the line. I dont know how to do it. Is there any method in CDC by which we can erase a line or drawing segment?
Thanks,
Luke.
-
February 8th, 2008, 06:06 AM
#2
Re: Erasing the line drawn using CDC
Draw the line again with the background color.
Laitinen
-
February 8th, 2008, 06:54 AM
#3
Re: Erasing the line drawn using CDC
you can do it to draw a line using XOR brush
-
February 8th, 2008, 07:35 AM
#4
Re: Erasing the line drawn using CDC
Thank you both. It was helpful. I am doing it with the background color.
-
April 12th, 2010, 09:44 PM
#5
Re: Erasing the line drawn using CDC
What do you do if the background is set to transparent?
-
April 12th, 2010, 09:59 PM
#6
Re: Erasing the line drawn using CDC
Originally Posted by lukevprem
Thank you both. It was helpful. I am doing it with the background color.
This is not going to work if you, for example, drew a second line across - you will erase an intersection point.
The only proper way is to redraw everything except for the line you want to erase.
Vlad - MS MVP [2007 - 2012] - www.FeinSoftware.com
Convenience and productivity tools for Microsoft Visual Studio:
FeinWindows - replacement windows manager for Visual Studio, and more...
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
|