Skip to content

FillStyle

Types

decoded

Represents a decoded version of the abstract fillStyle type, used in Context2D.

type decoded =
| String(string)
| CanvasGradient(WebAPI.CanvasAPI.canvasGradient)
| CanvasPattern(WebAPI.CanvasAPI.canvasPattern)

Values

decode

let decode: WebAPI.DOMAPI.fillStyle => decoded

Parameters

WebAPI.DOMAPI.fillStyle

Return type

decoded

fromCanvasGradient

let fromCanvasGradient: WebAPI.CanvasAPI.canvasGradient => WebAPI.DOMAPI.fillStyle

fromCanvasPattern

let fromCanvasPattern: WebAPI.CanvasAPI.canvasGradient => WebAPI.DOMAPI.fillStyle

fromString

let fromString: string => WebAPI.DOMAPI.fillStyle

Parameters

string

Return type

WebAPI.DOMAPI.fillStyle