Class RectSegment

java.lang.Object
com.datalogics.PDFL.Segment
com.datalogics.PDFL.RectSegment

public class RectSegment extends Segment
A rectangle path operator. RectSegment represents a single path, or line, within a rectangle, with coordinates xy, xy for the beginning and end of the line.
  • Constructor Summary

    Constructors
    Constructor
    Description
    RectSegment(double x, double y, double width, double height)
    Append a rectangle to the current path as a complete subpath, with lower-left corner (x, y) and dimensions width and height in user space.
    RectSegment(Point point, double width, double height)
    Append a rectangle to the current path as a complete subpath, with lower-left corner point and dimensions width and height in user space.
  • Method Summary

    Modifier and Type
    Method
    Description
    void
     
    double
    The height of the rectangle.
    The lower left corner of the rectangle.
    double
    The width of the rectangle.
    void
    setHeight(double value)
    The height of the rectangle.
    void
    setPoint(Point value)
    The lower left corner of the rectangle.
    void
    setWidth(double value)
    The width of the rectangle.
     

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • RectSegment

      public RectSegment(Point point, double width, double height)
      Append a rectangle to the current path as a complete subpath, with lower-left corner point and dimensions width and height in user space.

      Parameters:
      point - the lower left corner of the rectangle.
      width - the width of the rectangle.
      height - the height of the rectangle.
    • RectSegment

      public RectSegment(double x, double y, double width, double height)
      Append a rectangle to the current path as a complete subpath, with lower-left corner (x, y) and dimensions width and height in user space.

      Parameters:
      x - the left edge of the rectangle.
      y - the right edge of the rectangle.
      width - the width of the rectangle.
      height - the height of the rectangle.
  • Method Details

    • delete

      public void delete()
      Overrides:
      delete in class Segment
    • toString

      public String toString()
      Overrides:
      toString in class Segment
    • setPoint

      public void setPoint(Point value)
      The lower left corner of the rectangle.
    • getPoint

      public Point getPoint()
      The lower left corner of the rectangle.
    • setWidth

      public void setWidth(double value)
      The width of the rectangle.
    • getWidth

      public double getWidth()
      The width of the rectangle.
    • setHeight

      public void setHeight(double value)
      The height of the rectangle.
    • getHeight

      public double getHeight()
      The height of the rectangle.