Hi
As I haven't had any bites on the getIntersection 'bug', can anyone suggest an alternative method to create a 'line break' tool?
The tool needs to break a curve leaving a gap of (say) 1mm.
Any alternative options ?
Cheers
Neil
The getIntersections() method is not exact, and a couple of bugs are logged on the Scriptographer github page.
I've been working on a tool that's a follow up to this post, but I've been swamped lately.
Here's the basic workflow though:
• Copy selected paths, and give a stroke of 0.15pt, no fill
• Expand paths
• Use the Pathfinder.intersect() function to get a quadrilateral polygon where the paths intersect
• use the center point of each polygon with getLocation() to stick it to a curve
• cut the curve
It's inefficient, but it recognizes all path intersections that I've thrown at it