mirror of
https://github.com/konvajs/konva.git
synced 2026-01-22 21:02:26 +08:00
clean
This commit is contained in:
@@ -118,33 +118,17 @@ suite('Arrow', function() {
|
|||||||
points: [50, 50, 150, 50],
|
points: [50, 50, 150, 50],
|
||||||
stroke: 'blue',
|
stroke: 'blue',
|
||||||
fill: 'blue',
|
fill: 'blue',
|
||||||
strokeWidth: 1,
|
// large stroke width will not work :(
|
||||||
|
strokeWidth: 5,
|
||||||
draggable: true,
|
draggable: true,
|
||||||
tension: 0,
|
tension: 0
|
||||||
});
|
});
|
||||||
layer.add(arrow);
|
layer.add(arrow);
|
||||||
|
|
||||||
stage.add(layer);
|
stage.add(layer);
|
||||||
|
arrow.cache();
|
||||||
|
layer.draw();
|
||||||
|
|
||||||
cloneAndCompareLayer(layer, 200);
|
cloneAndCompareLayer(layer, 200);
|
||||||
|
|
||||||
// visual debug
|
|
||||||
// var back = new Konva.Rect({
|
|
||||||
// stroke: 'black'
|
|
||||||
// });
|
|
||||||
// layer.add(back);
|
|
||||||
// stage.on('mousemove',() => {
|
|
||||||
// const pos = stage.getPointerPosition();
|
|
||||||
|
|
||||||
// const points = [arrow.points()[0], arrow.points()[1], pos.x, pos.y];
|
|
||||||
// arrow.points(points);
|
|
||||||
// arrow.cache();
|
|
||||||
|
|
||||||
// console.log(arrow.points());
|
|
||||||
// back.setAttrs(arrow.getClientRect());
|
|
||||||
// layer.batchDraw();
|
|
||||||
// })
|
|
||||||
|
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user