Class DOMRectangle


  • @JsType(isNative=true,
            name="DOMRect",
            namespace="<global>")
    public final class DOMRectangle
    extends Object
    Describes the size and position of a rectangle of a BaseElement.
    Author:
    Andrea "Stock" Stocchero
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      double getBottom()
      Returns the bottom coordinate value of the rectangle (has the same value as y + height, or y if height is negative).
      double getHeight()
      Returns the height of the rectangle.
      double getLeft()
      Returns the left coordinate value of the rectangle (has the same value as x, or x + width if width is negative).
      double getRight()
      Returns the right coordinate value of the rectangle (has the same value as x + width, or x if width is negative).
      double getTop()
      Returns the top coordinate value of the rectangle (has the same value as y, or y + height if height is negative).
      double getWidth()
      Returns the width of the rectangle.
      double getX()
      Returns the x coordinate of the origin (typically the top-left corner of the rectangle).
      double getY()
      Returns the y coordinate of the origin (typically the top-left corner of the rectangle).
    • Method Detail

      • getBottom

        @JsProperty
        public double getBottom()
        Returns the bottom coordinate value of the rectangle (has the same value as y + height, or y if height is negative).
        Returns:
        the bottom coordinate value of the rectangle
      • getHeight

        @JsProperty
        public double getHeight()
        Returns the height of the rectangle.
        Returns:
        the height of the rectangle
      • getLeft

        @JsProperty
        public double getLeft()
        Returns the left coordinate value of the rectangle (has the same value as x, or x + width if width is negative).
        Returns:
        the left coordinate value of the rectangle
      • getRight

        @JsProperty
        public double getRight()
        Returns the right coordinate value of the rectangle (has the same value as x + width, or x if width is negative).
        Returns:
        the right coordinate value of the rectangle
      • getTop

        @JsProperty
        public double getTop()
        Returns the top coordinate value of the rectangle (has the same value as y, or y + height if height is negative).
        Returns:
        the top coordinate value of the rectangle
      • getWidth

        @JsProperty
        public double getWidth()
        Returns the width of the rectangle.
        Returns:
        the width of the rectangle
      • getX

        @JsProperty
        public double getX()
        Returns the x coordinate of the origin (typically the top-left corner of the rectangle).
        Returns:
        the x coordinate of the origin (typically the top-left corner of the rectangle)
      • getY

        @JsProperty
        public double getY()
        Returns the y coordinate of the origin (typically the top-left corner of the rectangle).
        Returns:
        the y coordinate of the origin (typically the top-left corner of the rectangle).