Classes
Type Definitions
-
DeclutterMode{"declutter"} {"obstacle"} {"none"}
-
Defines how symbols and text are decluttered on layers ith
declutterset totrue- declutter: Overlapping symbols and text are decluttered.
- obstacle: Symbols and text are rendered, but serve as obstacle for subsequent attempts to place a symbol or text at the same location.
- none: No decluttering is done.
-
A function that takes a
Featureas argument and returns anGeometrythat will be rendered and styled for the feature. -
Options{Object}
-
Properties:
Name Type Description geometrystring | Geometry | GeometryFunction | undefined Feature property or geometry or function returning a geometry to render for this style.
fillFill | undefined Fill style.
imageImageStyle | undefined Image style.
rendererRenderFunction | undefined Custom renderer. When configured,
fill,strokeandimagewill be ignored, and the provided function will be called with each render frame for each geometry.hitDetectionRendererRenderFunction | undefined Custom renderer for hit detection. If provided will be used in hit detection rendering.
strokeStroke | undefined Stroke style.
textText | undefined Text style.
zIndexnumber | undefined Z index.
-
Custom renderer function. Takes two arguments:
- The pixel coordinates of the geometry in GeoJSON notation.
- The
Stateof the layer renderer.
-
A function that takes a
Featureand a{number}representing the view's resolution. The function should return aStyleor an array of them. This way e.g. a vector layer can be styled. If the function returnsundefined, the feature will not be rendered. -
StyleLike{Style} {Array<Style>} {StyleFunction}
-
A
Style, an array ofStyle, or aStyleFunction.