/// <summary> Creates a Path object that contains the created path. /// /// </summary> /// <returns> the Path object. /// </returns> public virtual Path createPath() { endSubPath(false); SubPath[] tmp = new SubPath[subPaths.Count]; subPaths.CopyTo(tmp); return(new GenericPath(tmp)); }
private void endSubPath(bool closed) { if (segments.Count > 0) { Segment[] tmp = new Segment[segments.Count]; segments.CopyTo(tmp); SubPath subPath = new SubPath(startX, startY, tmp, closed); subPaths.Add(subPath); segments.Clear(); } hasStartPoint = false; }
/// <summary> /// Creates a path that has the given subpaths. /// </summary> /// <param name="subPaths">the subpaths. /// </param> public GenericPath(SubPath[] subPaths) { this.subPaths = subPaths; }