KineticJS icon indicating copy to clipboard operation
KineticJS copied to clipboard

Polygon are not being drawn

Open 0xE1 opened this issue 14 years ago • 3 comments

In version 4.0.2 Polygon shapes are not being drawn at all. Sample: http://jsfiddle.net/cZLnM/1/

0xE1 avatar Oct 04 '12 17:10 0xE1

http://jsfiddle.net/cZLnM/3/ Since the setAttrs is refactored you need to write the points as xy-objects. Not sure if this is by design or not..

davonium avatar Oct 04 '12 20:10 davonium

Ah, i see now. Something like that should be mentioned in Change logs since it breaks older realizations.

0xE1 avatar Oct 04 '12 21:10 0xE1

all points attrs now can be set with an array of integers, an array of arrays which contain two elements each, or an array of point objects:

http://kineticjs.com/docs/symbols/Kinetic.Polygon.php#getPoints

ericdrowell avatar Jan 17 '13 05:01 ericdrowell