Canvas Nasal API: Difference between revisions

Jump to navigation Jump to search
no edit summary
(→‎set: Explained how blending works.)
No edit summary
Line 514: Line 514:


Add a (rounded) rectangle to the path
Add a (rounded) rectangle to the path
=== square ===
''' available on next, expected release 2019.1 '''
'''Parameters:''' (x, y, length, cfg = nil)
alias for rect(x, y, length, length, cfg)
Add a (rounded) square to the path
=== arcSmallCCWTo ===
=== arcSmallCCWTo ===
=== arcSmallCCW ===
=== arcSmallCCW ===
Line 575: Line 585:
         fpv.createChild("path").setStrokeLineWidth(4).set("stroke", "rgba(255,0,5
         fpv.createChild("path").setStrokeLineWidth(4).set("stroke", "rgba(255,0,5
</syntaxhighlight>
</syntaxhighlight>
=== ellipse ===
''' available on next, expected release 2019.1 '''
'''Parameters:''' (rx, ry, cx = nil, cy = nil)
rx, ry are the radii of the ellipse
cx, cy is optional for the center coordinates
Add an ellipse to the path
=== circle ===
''' available on next, expected release 2019.1 '''
'''Parameters:''' (r, cx, cy)
alias for ellipse(r, r, cx, cy), cx, cy optional for center coordinates
Add a circle to the path.


=== close ===
=== close ===
252

edits

Navigation menu