Write documentation for PathItem#getIntersections().

This commit is contained in:
Jürg Lehni 2012-12-27 19:26:40 +01:00
parent 68ad4bb5ba
commit 00898908d3

View file

@ -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.