Line Drawing problem
Divya Rathore <[email protected]>
| Newsgroups | gmane.comp.programming.cppug |
|---|---|
| Message-ID | <[email protected]> |
How do I do the following?
A pair of lines is to be moved along with the cursor in a View as in the attached file.
How do I delete the previously drawn lines?
void CMyView::OnMouseMove(UINT nFlags, CPoint point)
{
// TODO: Add your message handler code here and/or call default
CClientDC ClientDC (this);
ClientDC.SetROP2 (R2_NOT);
ClientDC.MoveTo (point.x,0);
ClientDC.LineTo (point.x,point.y-5);
ClientDC.MoveTo (0,point.y);
ClientDC.LineTo (point.x-5,point.y);
CView::OnMouseMove(nFlags, point);
}
regards,
-D
---------------------------------
Do you Yahoo!?
Yahoo! Movies - Buy advance tickets for 'Shrek 2'
My.zip
(application/x-zip-compressed, 34.2 KB) - not displayed