Class Insets

java.lang.Object
com.ardor3d.extension.ui.util.Insets
Direct Known Subclasses:
UIBorder

public class Insets extends Object
This class is patterned after awt's Insets class. It describes the margins on four sides of a rectangular area and is the foundation of our UIBorder class.
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final Insets
    0, 0, 0, 0
  • Constructor Summary

    Constructors
    Constructor
    Description
    Constructs a new insets with 0 size on each side.
    Insets(int top, int left, int bottom, int right)
    Constructs a new insets using the given sizes.
    Insets(Insets source)
    Constructs a new insets using the sizes from the given source.
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
     
    int
     
    int
     
    int
     
    int
     
    int
     
    void
    set(int top, int left, int bottom, int right)
    Set the size of the sides to the given values.
    void
    set(Insets other)
     
    void
    setBottom(int size)
     
    void
    setLeft(int size)
     
    void
    setRight(int size)
     
    void
    setTop(int size)
     

    Methods inherited from class java.lang.Object

    clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • EMPTY

      public static final Insets EMPTY
      0, 0, 0, 0
  • Constructor Details

    • Insets

      public Insets()
      Constructs a new insets with 0 size on each side.
    • Insets

      public Insets(int top, int left, int bottom, int right)
      Constructs a new insets using the given sizes.
      Parameters:
      top - the top
      left - the left
      bottom - the bottom
      right - the right
    • Insets

      public Insets(Insets source)
      Constructs a new insets using the sizes from the given source.
      Parameters:
      source - the source insets
  • Method Details

    • set

      public void set(int top, int left, int bottom, int right)
      Set the size of the sides to the given values.
      Parameters:
      top - the top
      left - the left
      bottom - the bottom
      right - the right
    • set

      public void set(Insets other)
    • getLeft

      public int getLeft()
    • getTop

      public int getTop()
    • getRight

      public int getRight()
    • getBottom

      public int getBottom()
    • setLeft

      public void setLeft(int size)
    • setRight

      public void setRight(int size)
    • setTop

      public void setTop(int size)
    • setBottom

      public void setBottom(int size)
    • equals

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

      public int hashCode()
      Overrides:
      hashCode in class Object