public SPoint MapToScreen(ICoor coor) { double realX = (coor.X - MapFrame.Start.X) * MapFrame.Scale; double realY = (coor.Y - MapFrame.Start.Y) * MapFrame.Scale; return(new SPoint((int)realX, (int)realY)); }
public Point(ICoor coor) { Coors = new List <ICoor> { coor }; Painter = new PointPainter(); }
public void Zoom(ICoor coor, double scale) { if (scale < 0) { scale = 0.05; } ISize oldSize = (ISize)MapFrame.Size.Clone(); MapFrame.Scale = scale; var Width = (MapFrame.Size.Width - oldSize.Width) / 2; var Height = (MapFrame.Size.Height - oldSize.Height) / 2; MapFrame.Start.X -= Width; MapFrame.Start.Y -= Height; }
public void Goto(ICoor coor) { MapFrame.Start = new Coor(coor.X, coor.Y); Refresh(); }
public Coordinata(ICoor coor) { _x = coor.X; _y = coor.Y; }