Classes
Type Definitions
-
Options{Object}
-
Properties:
Name Type Description idnumber | string | undefined Set the overlay id. The overlay id can be used with the
getOverlayByIdmethod.elementHTMLElement | undefined The overlay element.
offsetArray.<number>
(defaults to [0, 0])Offsets in pixels used when positioning the overlay. The first element in the array is the horizontal offset. A positive value shifts the overlay right. The second element in the array is the vertical offset. A positive value shifts the overlay down.
positionCoordinate | undefined The overlay position in map projection.
positioningPositioning
(defaults to 'top-left')Defines how the overlay is actually positioned with respect to its
positionproperty. Possible values are'bottom-left','bottom-center','bottom-right','center-left','center-center','center-right','top-left','top-center', and'top-right'.stopEventboolean
(defaults to true)Whether event propagation to the map viewport should be stopped. If
truethe overlay is placed in the same container as that of the controls (CSS class nameol-overlaycontainer-stopevent); iffalseit is placed in the container with CSS class name specified by theclassNameproperty.insertFirstboolean
(defaults to true)Whether the overlay is inserted first in the overlay container, or appended. If the overlay is placed in the same container as that of the controls (see the
stopEventoption) you will probably setinsertFirsttotrueso the overlay is displayed below the controls.autoPanPanIntoViewOptions | boolean
(defaults to false)Pan the map when calling
setPosition, so that the overlay is entirely visible in the current viewport.classNamestring
(defaults to 'ol-overlay-container ol-selectable')CSS class name.
-
OverlayObjectEventTypes{Types} {'change:element'} {'change:map'} {'change:offset'} {'change:position'} {'change:positioning'}
-
-
PanIntoViewOptions{Object}
-
Properties:
Name Type Description animationPanOptions
(defaults to {})The animation parameters for the pan
marginnumber
(defaults to 20)The margin (in pixels) between the overlay and the borders of the map when panning into view.
-
PanOptions{Object}
-
Positioning{'bottom-left'} {'bottom-center'} {'bottom-right'} {'center-left'} {'center-center'} {'center-right'} {'top-left'} {'top-center'} {'top-right'}
-
The overlay position:
'bottom-left','bottom-center','bottom-right','center-left','center-center','center-right','top-left','top-center', or'top-right'.