Class Navigator
Inheritance
System.Object
Navigator
Implements
Inherited Members
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Mapsui
Assembly: Mapsui.dll
Syntax
public class Navigator : INavigator
Constructors
| Improve this Doc View SourceNavigator(Map, IViewport)
Declaration
public Navigator(Map map, IViewport viewport)
Parameters
Type | Name | Description |
---|---|---|
Map | map | |
IViewport | viewport |
Properties
| Improve this Doc View SourceNavigated
Declaration
public EventHandler Navigated { get; set; }
Property Value
Type | Description |
---|---|
System.EventHandler |
Methods
| Improve this Doc View SourceCenterOn(Point)
Change center of viewport
Declaration
public void CenterOn(Point center)
Parameters
Type | Name | Description |
---|---|---|
Point | center | New center point of viewport |
CenterOn(Double, Double)
Change center of viewport to X/Y coordinates
Declaration
public void CenterOn(double x, double y)
Parameters
Type | Name | Description |
---|---|---|
System.Double | x | X value of the new center |
System.Double | y | Y value of the new center |
NavigateTo(BoundingBox, ScaleMethod)
Navigate center of viewport to center of extent and change resolution
Declaration
public void NavigateTo(BoundingBox extent, ScaleMethod scaleMethod = ScaleMethod.Fit)
Parameters
Type | Name | Description |
---|---|---|
BoundingBox | extent | New extent for viewport to show |
ScaleMethod | scaleMethod | Scale method to use to determine resolution |
NavigateTo(Point, Double)
Change both center and resolution of the viewport
Declaration
public void NavigateTo(Point center, double resolution)
Parameters
Type | Name | Description |
---|---|---|
Point | center | The new center |
System.Double | resolution | The new resolution |
NavigateToFullEnvelope(ScaleMethod)
Declaration
public void NavigateToFullEnvelope(ScaleMethod scaleMethod = ScaleMethod.Fill)
Parameters
Type | Name | Description |
---|---|---|
ScaleMethod | scaleMethod |
RotateTo(Double)
Change rotation of viewport
Declaration
public void RotateTo(double rotation)
Parameters
Type | Name | Description |
---|---|---|
System.Double | rotation | New rotation in degrees of viewport> |
ZoomIn()
Declaration
public void ZoomIn()
ZoomIn(Point)
Declaration
public void ZoomIn(Point centerOfZoom)
Parameters
Type | Name | Description |
---|---|---|
Point | centerOfZoom |
ZoomOut()
Declaration
public void ZoomOut()
ZoomOut(Point)
Declaration
public void ZoomOut(Point centerOfZoom)
Parameters
Type | Name | Description |
---|---|---|
Point | centerOfZoom |
ZoomTo(Double)
Change resolution of viewport
Declaration
public void ZoomTo(double resolution)
Parameters
Type | Name | Description |
---|---|---|
System.Double | resolution | New resolution to use |
ZoomTo(Double, Point)
Declaration
public void ZoomTo(double resolution, Point centerOfZoom)
Parameters
Type | Name | Description |
---|---|---|
System.Double | resolution | |
Point | centerOfZoom |