Class Dimension

java.lang.Object
com.ardor3d.extension.ui.util.Dimension

public class Dimension extends Object
This class is patterned after awt's Dimension class. It describes the width and height of something (in our case, generally a UI element.)
  • Constructor Details

    • Dimension

      public Dimension()
      Construct a new 0x0 dimension object.
    • Dimension

      public Dimension(int width, int height)
      Construct a new dimension object using the given values.
      Parameters:
      width - the width
      height - the height
    • Dimension

      public Dimension(Dimension source)
      Construct a new dimension object using the values of the given source.
      Parameters:
      source - the source dimension
  • Method Details

    • getWidth

      public int getWidth()
    • setWidth

      public void setWidth(int width)
    • getHeight

      public int getHeight()
    • setHeight

      public void setHeight(int height)
    • set

      public void set(int width, int height)
    • set

      public void set(Dimension d)
    • contains

      public boolean contains(double x, double y)
    • contains

      public boolean contains(int x, int y)
    • equals

      public boolean equals(Object obj)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • toString

      public String toString()
      Overrides:
      toString in class Object