Class AbstractPathShape

    • Field Detail

      • properties

        protected java.util.Map<java.lang.String,​java.lang.String> properties
        The properties of this shape.
      • relative

        protected boolean relative
        Whether this is a relative operator or not.
      • coordinates

        protected java.lang.String[] coordinates
    • Constructor Detail

      • AbstractPathShape

        public AbstractPathShape()
      • AbstractPathShape

        public AbstractPathShape​(boolean relative)
      • AbstractPathShape

        public AbstractPathShape​(boolean relative,
                                 IOperatorConverter copier)
    • Method Detail

      • isRelative

        public boolean isRelative()
        Description copied from interface: IPathShape
        Returns true when this shape is a relative operator. False if it is an absolute operator.
        Specified by:
        isRelative in interface IPathShape
        Returns:
        true if relative, false if absolute
      • createPoint

        protected Point createPoint​(java.lang.String coordX,
                                    java.lang.String coordY)
      • getEndingPoint

        public Point getEndingPoint()
        Description copied from interface: IPathShape
        Gets the ending point on the canvas after the path shape has been drawn via the IPathShape.draw(PdfCanvas) method, in SVG space coordinates.
        Specified by:
        getEndingPoint in interface IPathShape
        Returns:
        The Point representing the final point in the drawn path. If the point does not exist or does not change null may be returned.
      • getPathShapeRectangle

        public Rectangle getPathShapeRectangle​(Point lastPoint)
        Get bounding rectangle of the current path shape.
        Specified by:
        getPathShapeRectangle in interface IPathShape
        Parameters:
        lastPoint - start point for this shape
        Returns:
        calculated rectangle