Class: Fill

ol.style.Fill

Set fill style for vector features.

new ol.style.Fill(opt_options) experimental

src/ol/style/fill.js, line 15
Name Type Description
options

Options.

Name Type Description
color ol.Color | ol.ColorLike | undefined experimental

A color, gradient or pattern. See ol.color and ol.colorlike for possible formats. Default null; if null, the Canvas/renderer default black will be used.

Methods

getColor(){ol.Color|ol.ColorLike} experimental

src/ol/style/fill.js, line 38

Get the fill color.

Returns:
Color.

setColor(color) experimental

src/ol/style/fill.js, line 49

Set the color.

Name Type Description
color ol.Color | ol.ColorLike

Color.