Skip to content

Interface: CanvasGradient ​

Defined in: types/desktop-engine.d.ts:1023

Gradient object

Methods ​

addColorStop() ​

ts
addColorStop(offset, color): void;

Defined in: types/desktop-engine.d.ts:1025

Adds a color stop (a CSS color, see CanvasRenderingContext2D.fillStyle); invalid colors are ignored

Parameters ​

ParameterType
offsetnumber
colorstring

Returns ​

void

The SDK is released under the Apache License 2.0