private AddPoint ( double x, double y ) : void | ||
x | double | |
y | double | |
return | void |
private void AddPoint(double x, double y)
{
if (_pLine == null)
{
_pLine = new Polyline();
Path path = new Path();
_pLine.AddPath(path);
}
_pLine[0].AddPoint(new Point(x, y));
}
public void ConstructMouseDown(IMapDocument doc, System.Windows.Forms.MouseEventArgs e) { if (ActiveDisplay(doc) == null) { return; } Freehand element = new Freehand(); _addContainer = new GraphicsContainer(); _addContainer.Elements.Add(element); _mousePressed = true; double x = e.X; double y = e.Y; ActiveDisplay(doc).Image2World(ref x, ref y); element.AddPoint(x, y); }