PageRenderTime 33ms CodeModel.GetById 10ms RepoModel.GetById 1ms app.codeStats 0ms

/Main/src/DynamicDataDisplay.Maps/DeepZoom/Viewport.cs

#
C# | 38 lines | 17 code | 3 blank | 18 comment | 0 complexity | b7c9efb72912a38f3cfcc5eb6ea80084 MD5 | raw file
Possible License(s): CC-BY-SA-3.0
  1. using System;
  2. using System.Collections.Generic;
  3. using System.Linq;
  4. using System.Text;
  5. using System.Xml.Serialization;
  6. namespace Microsoft.Research.DynamicDataDisplay.Maps.DeepZoom
  7. {
  8. /// <summary>
  9. /// Location of the image in the viewport.
  10. /// </summary>
  11. public class Viewport
  12. {
  13. /// <summary>
  14. /// The width of the area of the image displayed. This value is in logical coordinates.
  15. /// For example a value of 1 displays the entire image (no zoom),
  16. /// a value of 0.5 is 200% zoomed in and a value of 0 is completely zoomed (user cannot see the image at all).
  17. /// A value above 1 is zooming out from the image.
  18. /// For example, a value of 2 means that the image will take up half the size of the MultiScaleSubImage control area (50% zoom).
  19. /// </summary>
  20. [XmlAttribute]
  21. public double Width { get; set; }
  22. /// <summary>
  23. /// The left coordinate of the rectangular area of the image to be displayed.
  24. /// The coordinates of the point are in local coordinates (0-1) relative to the displayed image width.
  25. /// </summary>
  26. [XmlAttribute]
  27. public double X { get; set; }
  28. /// <summary>
  29. /// The top coordinate of the rectangular area of the image to be displayed.
  30. /// The coordinates of the point are in local coordinates (0-1) relative to the displayed image width.
  31. /// </summary>
  32. [XmlAttribute]
  33. public double Y { get; set; }
  34. }
  35. }