1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
/// The factor that keeps a map from looking stretched.
///
/// ECharts shortens the height of a map by the same factor, and so
/// does this crate: the distance of a degree of longitude shrinks
/// towards the poles, and a map drawn without the correction looks
/// stretched sideways.
pub const DEFAULT_ASPECT_SCALE: f64 = 0.75;
/// The share of the plot area a map takes up.
///
/// The rest of the area stays empty, so that a map never touches the
/// edges of the chart.
pub const DEFAULT_MAP_FILL: f64 = 0.8;
/// The GeoJSON field that names the kind of a document or a geometry.
pub const GEO_FIELD_TYPE: &str = "type";
/// The GeoJSON field that carries the properties of a feature.
pub const GEO_FIELD_PROPERTIES: &str = "properties";
/// The GeoJSON field that carries the name of a feature.
pub const GEO_FIELD_NAME: &str = "name";
/// The GeoJSON field that carries the uppercase name of a feature.
pub const GEO_FIELD_NAME_UPPER: &str = "NAME";
/// The GeoJSON field that carries the identifier of a feature.
pub const GEO_FIELD_ID: &str = "id";
/// The GeoJSON field that carries the geometry of a feature.
pub const GEO_FIELD_GEOMETRY: &str = "geometry";
/// The GeoJSON field that carries the coordinates of a geometry.
pub const GEO_FIELD_COORDINATES: &str = "coordinates";
/// The GeoJSON field that carries the features of a collection.
pub const GEO_FIELD_FEATURES: &str = "features";
/// The GeoJSON kind of a collection of features.
pub const GEO_KIND_FEATURE_COLLECTION: &str = "FeatureCollection";
/// The GeoJSON kind of a single feature.
pub const GEO_KIND_FEATURE: &str = "Feature";
/// The GeoJSON kind of a polygon.
pub const GEO_KIND_POLYGON: &str = "Polygon";
/// The GeoJSON kind of a list of polygons.
pub const GEO_KIND_MULTI_POLYGON: &str = "MultiPolygon";
/// The GeoJSON kind of a single point.
pub const GEO_KIND_POINT: &str = "Point";
/// The GeoJSON kind of a list of points.
pub const GEO_KIND_MULTI_POINT: &str = "MultiPoint";
/// The GeoJSON kind of a line of points.
pub const GEO_KIND_LINE_STRING: &str = "LineString";
/// The GeoJSON kind of a list of lines of points.
pub const GEO_KIND_MULTI_LINE_STRING: &str = "MultiLineString";
/// The message of a geometry that carries no coordinates.
pub const GEO_ERROR_NO_COORDINATES: &str = "the geometry has no coordinates";
/// The message of a multi polygon that is not a list.
pub const GEO_ERROR_MULTI_POLYGON_NOT_A_LIST: &str = "a multi polygon has to be a list";
/// The message of a polygon that is not a list of rings.
pub const GEO_ERROR_POLYGON_NOT_A_LIST: &str = "a polygon has to be a list of rings";
/// The message of a ring that is not a list of points.
pub const GEO_ERROR_RING_NOT_A_LIST: &str = "a ring has to be a list of points";
/// The message of a point that is not a pair of numbers.
pub const GEO_ERROR_POINT_NOT_A_PAIR: &str = "a point has to be a pair of numbers";
/// The message of a polygon that has no outer ring.
pub const GEO_ERROR_NO_OUTER_RING: &str = "a polygon needs an outer ring";