示例#1
0
        public override Location PointToLocation(Point point)
        {
            if (InverseTransform == null)
            {
                throw new InvalidOperationException("The CoordinateSystem property is not set.");
            }

            var coordinate = InverseTransform.Transform(new Coordinate(point.X, point.Y));

            return(new Location(coordinate.Y, coordinate.X));
        }
 /// <summary>
 /// Convert the given rectangle from virtual space to item space.
 /// </summary>
 public RectangleF ToLocal(RectangleF rect)
 {
     return(InverseTransform.Transform(rect));
 }