MapPolygon.Points Property

Gets or sets a collection of points defining the map polygon.

Namespace: DevExpress.XtraMap

Assembly: DevExpress.XtraMap.v20.1.dll

Declaration

public CoordPointCollection Points { get; set; }
Public Property Points As CoordPointCollection

Property Value

Type Description
CoordPointCollection

A collection of CoordPoint class descendant objects.

Remarks

Note that, a map shape should fulfill the following condition to cross the 180th meridian: one or several points' longitudes should exceed the 180 (-180) limit:


MapPolygon polygon = new MapPolygon();
polygon.Points.Add(new GeoPoint(10, -170));
polygon.Points.Add(new GeoPoint(10, 170));
polygon.Points.Add(new GeoPoint(-10, 170));
polygon.Points.Add(new GeoPoint(-10, -170));
vectorItemStorage.Items.Add(polygon);

// Point longitudes enclose the 180 meridian.
MapPolygon polygonCross180 = New MapPolygon();
polygonCross180.Fill = Color.Orange;
polygonCross180.Points.Add(new GeoPoint(30, 190));
polygonCross180.Points.Add(new GeoPoint(30, 170));
polygonCross180.Points.Add(new GeoPoint(20, 170));
polygonCross180.Points.Add(new GeoPoint(20, 190));
vectorItemStorage.Items.Add(polygon180);

The code above produces the following image:

map-control__cross-180th-meridian

See Also