Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- (defn drawnConnectorWithArrow! [canvasCtx points]
- (let [ firstPoint (first points)
- restPoints (rest points)
- lastTwoPoints [(nth points (- (count points) 2)) lastPoint]]
- (.beginPath canvasCtx)
- (.moveTo canvasCtx (:x firstPoint) (:y firstPoint)))
- (doseq [p restPoints] (.lineTo canvasCtx (:x p) (:y p)))
- (drawArrowAtHead canvasCtx lastTwoPoins))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement