Предположим, что один конец моей полилинии зафиксирован, скажем, в 0,0, и когда я перемещаю мышь, я хочу, чтобы другой конец полилинии был точно на моем указателе мыши. Что мне делать в этом случае?
Извините, я новичок в Silverlight.
System.Windows.Point staticPoint = new System.Windows.Point(100, 100); System.Windows.Point mousePoint = e.GetPosition(CanvasContainer); PointCollection polygonPoints = new PointCollection(); polygonPoints.Add(staticPoint); polygonPoints.Add(mousePoint); polyline.Points = polygonPoints;