src/main/java/com/mxgraph/util/mxCurve.java
protected int intersectRectPerimeterSeg(String index, mxRectangle rect,
			int startSegment)
	{
		mxPoint[] pointsCurve = getCurvePoints(index);

		if (pointsCurve != null && pointsCurve.length > 1)
		{
			for (int i = startSegment; i < pointsCurve.length; i++)
			{
				if (rect.intersectLine(pointsCurve[i].getX(),
						pointsCurve[i].getY(), pointsCurve[i - 1].getX(),
						pointsCurve[i - 1].getY()) != null)
				{
					return i;
				}
			}
		}

		return -1;
	}
/**
	 * Utility method to determine within which segment the specified rectangle
	 * intersects the specified curve. This method specifies which segment to
	 * start searching at.
	 * 
	 * @param index the curve index specifying the curve to analyse
	 * @param rect the whose boundary is to be tested for intersection
	 * with this curve
	 * @param startSegment the segment to start searching at. To start at the 
	 * 			beginning of the curve, use 1, not 0.
	 * @return the point at which this curve intersects the boundary of 
	 * the given rectangle, if it does so. If it does not intersect, 
	 * -1 is returned
	 */
Utility method to determine within which segment the specified rectangle
intersects the specified curve. This method specifies which segment to
start searching at.

@param index the curve index specifying the curve to analyse
@param rect the whose boundary is to be tested for intersection
with this curve
@param startSegment the segment to start searching at. To start at the
beginning of the curve, use 1, not 0.
@return the point at which this curve intersects the boundary of
the given rectangle, if it does so. If it does not intersect,
-1 is returned
Utility method to determine within which segment the specified rectangle intersects the specified curve . This method specifies which segment to start searching at . @param index the curve index specifying the curve to analyse @param rect the whose boundary is to be tested for intersection with this curve @param startSegment the segment to start searching at . To start at the beginning of the curve use 1 not 0 . @return the point at which this curve intersects the boundary of the given rectangle if it does so . If it does not intersect - 1 is returned
protected int intersectRectPerimeterSeg(String index, mxRectangle rect,
			int startSegment)
	{
		mxPoint[] pointsCurve = getCurvePoints(index);
		if (pointsCurve != null && pointsCurve.length > 1)
		{
			for (int i = startSegment; i < pointsCurve.length; i++)
			{
				if (rect.intersectLine(pointsCurve[i].getX(),
						pointsCurve[i].getY(), pointsCurve[i - 1].getX(),
						pointsCurve[i - 1].getY()) != null)
				{
					return i;
				}
			}
		}
		return -1;
	}
protected int intersectRectPerimeterSeg ( String index , mxRectangle rect , int startSegment ) { mxPoint [ ] pointsCurve = getCurvePoints ( index ) ; if ( pointsCurve != null && pointsCurve . length > 1 ) { for ( int i = startSegment ; i < pointsCurve . length ; i ++ ) { if ( rect . intersectLine ( pointsCurve [ i ] . getX ( ) , pointsCurve [ i ] . getY ( ) , pointsCurve [ i - 1 ] . getX ( ) , pointsCurve [ i - 1 ] . getY ( ) ) != null ) { return i ; } } } return - 1 ; }
Utility method to determine within which segment the specified rectangle
 intersects the specified curve.
Utility method to determine within which segment the specified rectangle intersects the specified curve .