You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Add a color stop with opacity 0,
The opacity is ignored and treated as 1
constcanvas=createCanvas(200,200);constctx=canvas.getContext("2d");constgradientFrom="rgba(53,83,192,0.9)"constgradientTo="rgba(58,69,110,0)"// opacity 0constgradient=ctx.createLinearGradient(0,0,0,400)gradient.addColorStop(0,gradientFrom)gradient.addColorStop(1,gradientTo)ctx.fillStyle=gradient;ctx.fillRect(0,0,200,200);// etc.
see output for corresponding opacity
Your Environment
Version of node-canvas (output of npm list canvas or yarn list canvas): 2.9.0+
Environment (e.g. node 4.2.0 on Mac OS X 10.8): node v16.14.2 on Windows 10 64bit
The text was updated successfully, but these errors were encountered:
ShaMan123
changed the title
v2.9.0
v2.9.0 addColorStop with opacity 0
Sep 7, 2022
Issue or Feature
Issue, might be related to #2043
Steps to Reproduce
Add a color stop with opacity 0,
The opacity is ignored and treated as 1
see output for corresponding opacity
Your Environment
npm list canvas
oryarn list canvas
): 2.9.0+The text was updated successfully, but these errors were encountered: