From 00898908d332a19b11597ce7465b8a59f3550dee Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=BCrg=20Lehni?= Date: Thu, 27 Dec 2012 19:26:40 +0100 Subject: [PATCH] Write documentation for PathItem#getIntersections(). --- src/path/PathItem.js | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/path/PathItem.js b/src/path/PathItem.js index 3b22c0f9..9cbc5f20 100644 --- a/src/path/PathItem.js +++ b/src/path/PathItem.js @@ -25,6 +25,15 @@ */ var PathItem = this.PathItem = Item.extend(/** @lends PathItem# */{ + /** + * Returns all interesections between two {@link PathItem} items as an array + * of {@link CurveLocation} objects. {@link CompoundPath} items are also + * supported. + * + * @param {PathItem} the other item to find the intersections to. + * @return {CurveLocation[]} the locations of all intersection between the + * paths + */ getIntersections: function(path) { // First check the bounds of the two paths. If they don't intersect, // we don't need to iterate through the whole path.