Package jexer

Class TPanel

  • All Implemented Interfaces:
    java.lang.Comparable<TWidget>

    public class TPanel
    extends TWidget
    TPanel is an empty container for other widgets.
    • Constructor Detail

      • TPanel

        public TPanel​(TWidget parent,
                      int x,
                      int y,
                      int width,
                      int height)
        Public constructor.
        Parameters:
        parent - parent widget
        x - column relative to parent
        y - row relative to parent
        width - width of widget
        height - height of widget
    • Method Detail

      • onResize

        public void onResize​(TResizeEvent resize)
        Method that subclasses can override to handle window/screen resize events.
        Overrides:
        onResize in class TWidget
        Parameters:
        resize - resize event
      • draw

        public void draw()
        Draw an optional border and title.
        Overrides:
        draw in class TWidget
      • getTitle

        public java.lang.String getTitle()
        Get panel title.
        Returns:
        the panel title
      • setTitle

        public void setTitle​(java.lang.String title)
        Set panel title.
        Parameters:
        title - the new panel title
      • getTitleDirection

        public TPanel.Direction getTitleDirection()
        Get panel title direction.
        Returns:
        one of Direction.TOP_LEFT, Direction.TOP, etc.
      • setTitleDirection

        public void setTitleDirection​(TPanel.Direction direction)
        Set panel title direction.
        Parameters:
        direction - one of Direction.TOP_LEFT, Direction.TOP, etc.
      • setBorderStyle

        public void setBorderStyle​(java.lang.String borderStyle)
        Set the border style for the panel.
        Parameters:
        borderStyle - the border style string, one of: "default", "none", "single", "double", "singleVdoubleH", "singleHdoubleV", or "round"; or null to use the value from jexer.TPanel.borderStyle.
      • getBorderStyle

        public BorderStyle getBorderStyle()
        Get the border style for the panel.
        Returns:
        the border style