static fromSegments(segments) {
    const path = new PathParser();

    path.resetSegments(segments);
    return path;
  }
make rect path

@param {number} x
@param {number} y
@param {number} width
@param {number} height
@returns {PathParser}