Class SolidBorder


public class SolidBorder extends UIBorder
This border draws solid colored edges around a UI component. Each edge may be a different thickness and/or color.
  • Constructor Details

    • SolidBorder

      public SolidBorder(int top, int left, int bottom, int right)
      Construct a border with the given thicknesses. Uses the default colors.
      Parameters:
      top - the top
      left - the left
      bottom - the bottom
      right - the right
    • SolidBorder

      public SolidBorder(int top, int left, int bottom, int right, ReadOnlyColorRGBA topColor, ReadOnlyColorRGBA leftColor, ReadOnlyColorRGBA bottomColor, ReadOnlyColorRGBA rightColor)
      Construct a border with the given thicknesses and colors
      Parameters:
      top - the top
      left - the left
      bottom - the bottom
      right - the right
      topColor - the top color
      leftColor - the left color
      bottomColor - the bottom color
      rightColor - the right color
  • Method Details

    • getBottomColor

      public ReadOnlyColorRGBA getBottomColor()
    • setBottomColor

      public void setBottomColor(ReadOnlyColorRGBA color)
    • getLeftColor

      public ReadOnlyColorRGBA getLeftColor()
    • setLeftColor

      public void setLeftColor(ReadOnlyColorRGBA color)
    • getRightColor

      public ReadOnlyColorRGBA getRightColor()
    • setRightColor

      public void setRightColor(ReadOnlyColorRGBA color)
    • getTopColor

      public ReadOnlyColorRGBA getTopColor()
    • setTopColor

      public void setTopColor(ReadOnlyColorRGBA color)
    • setColor

      public void setColor(ReadOnlyColorRGBA solidColor)
      Sets all of the border colors to the given color.
      Parameters:
      solidColor - new color for all borders
    • draw

      public void draw(Renderer renderer, UIComponent comp)
      Description copied from class: UIBorder
      Draw this border. Override this method to do the actual work.
      Specified by:
      draw in class UIBorder
      Parameters:
      renderer - the renderer to use in drawing.
      comp - the UIComponent we are drawing the border for.