Class MapArguments
Contains important properties and methods of current map object.
public class MapArguments
- Inheritance
-
MapArguments
- Inherited Members
Constructors
MapArguments()
Constructor of MapArguments.
public MapArguments()
MapArguments(RectangleShape, GeographyUnit, float, float)
Initializes a new instance of the MapArguments class.
public MapArguments(RectangleShape currentExtent, GeographyUnit mapUnit, float screenWidth, float screenHeight)
Parameters
currentExtent
RectangleShapeThe current extent.
mapUnit
GeographyUnitThe map unit.
screenWidth
floatWidth of the screen.
screenHeight
floatHeight of the screen.
Properties
CenterPoint
public PointShape CenterPoint { get; set; }
Property Value
CurrentExtent
Gets or sets the extent of current map.
public RectangleShape CurrentExtent { get; set; }
Property Value
CurrentResolution
Gets or sets a double value that indicates the current resolution of the map.
public double CurrentResolution { get; set; }
Property Value
- double
A double value that indicates the current resolution of the map.
CurrentScale
Gets or sets the scale factor, this is a value number of device pixels per logical coordinate point.
public double CurrentScale { get; set; }
Property Value
- double
The scale factory value.
Remarks
The coordinate space used by application developers is measured in logical points. High-resolution (Retina) displays will have more than a single physical pixel per logical point and this property specifies the scale factor.
CustomData
Gets the custom data.
public Dictionary<string, object> CustomData { get; }
Property Value
- Dictionary<string, object>
The custom data.
MapHeight
public double MapHeight { get; set; }
Property Value
MapUnit
Gets or sets the GeographyUnit for the map.
public GeographyUnit MapUnit { get; set; }
Property Value
- GeographyUnit
The GeographyUnit object that indicates which geography unit the map is currently using.
MapWidth
public double MapWidth { get; set; }
Property Value
MaxExtent
Gets or sets the max extent of current map.
public RectangleShape MaxExtent { get; set; }
Property Value
MaximumScale
This property gets and sets a maximum scale when navigating the map.
When you keep zooming out, and the target scale is bigger than the maximum scale, the zooming operation will be stopped.
public double MaximumScale { get; set; }
Property Value
MinimumScale
This property gets and sets a minimum scale when navigating the map.
When you keep zooming in, and the target scale is smaller than the minimum scale, the zooming operation will be stopped.
public double MinimumScale { get; set; }
Property Value
PivotScreenPoint
public ScreenPointF PivotScreenPoint { get; set; }
Property Value
PivotWorldPoint
public PointShape PivotWorldPoint { get; set; }
Property Value
RotationAngle
public double RotationAngle { get; set; }
Property Value
RotationEnabled
public bool RotationEnabled { get; set; }
Property Value
ScaleFactor
public float ScaleFactor { get; set; }
Property Value
ScreenHeight
Gets or sets the height of current map object in screen coordinate.It would be the same as ScreenHeight if the map is in rotation
public double ScreenHeight { get; set; }
Property Value
ScreenWidth
Gets or sets the width of current map object in screen coordinate.It would be the same as ScreenHeight if the map is in rotation
public double ScreenWidth { get; set; }
Property Value
ZoomLevelScales
Gets a collection of double values that determines the zoomlevel scales.
public Collection<double> ZoomLevelScales { get; }
Property Value
- Collection<double>
A collection of double values that determines the openlayers' zoomlevel scales.
ZoomLevelSet
This property gets or sets the ZoomLevelSet used for the MapView control.
public ZoomLevelSet ZoomLevelSet { get; set; }
Property Value
- ZoomLevelSet
The zoom level set.
ZoomLevelSnappingMode
public ZoomLevelSnappingMode ZoomLevelSnappingMode { get; set; }
Property Value
Methods
GetSnappedExtent(RectangleShape, ZoomSnapDirection)
public RectangleShape GetSnappedExtent(RectangleShape extent, ZoomSnapDirection zoomSnapDirection)
Parameters
extent
RectangleShapezoomSnapDirection
ZoomSnapDirection
Returns
GetSnappedZoomLevelIndex(double)
Gets a snapped zoom level index from the provided scale.
public int GetSnappedZoomLevelIndex(double scale)
Parameters
scale
doubleA scale to be snapped.
Returns
- int
An integar value that indicates the snapped zoom level index.
Remarks
The scale will automatically snapped a closest scale from the ZoomLevelScale list, and create an extent back with the map's screen width and height.
GetSnappedZoomLevelIndex(RectangleShape)
Gets a snapped zoom level index from the provided extent.
public int GetSnappedZoomLevelIndex(RectangleShape extent)
Parameters
extent
RectangleShapeAn extent to be snapped.
Returns
- int
An integar value that indicates the snapped zoom level index.
Remarks
The extent will automatically snapped a closest scale from the ZoomLevelScale list, and create an extent back with the map's screen width and height.
ToWorldCoordinate(ScreenPointF)
Converts a point from screen coordinate to world coordinate.
public PointShape ToWorldCoordinate(ScreenPointF screenCoordinate)
Parameters
screenCoordinate
ScreenPointFA point in screen coordinate to be converted.
Returns
- PointShape
A point in world coordinate.