Methods
(static) getScale(map) → {module:webgis4u/ol/util/getScale~Scale}
Gets the map Scale
Parameters:
Name | Type | Description |
---|---|---|
map |
ol.Map | The map whose scale will be returned. |
- Source:
Returns:
The scale.
Example
// Get the map scale
ugis.ol.util.getScale(myMap);
Type Definitions
Scale
The map scale.
Type:
- Object
Properties:
Name | Type | Description |
---|---|---|
resolution |
number | The map resolution in m per pixel. |
denominator |
number | The map denominator (fraction). |
formated |
string | The pretty formated scale. |
- Source:
Example
{resolution:35.27, denominator: 100000, formated: '1:100.000'}