Class Borders
java.lang.Object
com.googlecode.lanterna.gui2.Borders
This class containers a couple of border implementation and utility methods for instantiating them. It also contains
a utility method for joining border line graphics together with adjacent lines so they blend in together:
joinLinesWithFrame(..).-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprivate static classprivate static enumprivate static classprivate static classprivate static classprivate static classprivate static class -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic BorderCreates aBorderthat is drawn as a solid color double line surrounding the wrapped componentstatic BorderdoubleLine(String title) Creates aBorderthat is drawn as a solid color double line surrounding the wrapped component with a title string normally drawn at the top-left sidestatic BorderCreates aBorderthat is drawn as a bevel color double line surrounding the wrapped componentstatic BorderdoubleLineBevel(String title) Creates aBorderthat is drawn as a bevel color double line surrounding the wrapped component with a title string normally drawn at the top-left sidestatic BorderCreates aBorderthat is drawn as a reverse bevel color double line surrounding the wrapped componentstatic BorderdoubleLineReverseBevel(String title) Creates aBorderthat is drawn as a reverse bevel color double line surrounding the wrapped component with a title string normally drawn at the top-left sidestatic voidjoinLinesWithFrame(TextGraphics graphics) This method will attempt to join line drawing characters with the outermost bottom and top rows and left and right columns.static BorderCreates aBorderthat is drawn as a solid color single line surrounding the wrapped componentstatic BordersingleLine(String title) Creates aBorderthat is drawn as a solid color single line surrounding the wrapped component with a title string normally drawn at the top-left sidestatic BorderCreates aBorderthat is drawn as a bevel color single line surrounding the wrapped componentstatic BordersingleLineBevel(String title) Creates aBorderthat is drawn as a bevel color single line surrounding the wrapped component with a title string normally drawn at the top-left sidestatic BorderCreates aBorderthat is drawn as a reverse bevel color single line surrounding the wrapped componentstatic BordersingleLineReverseBevel(String title) Creates aBorderthat is drawn as a reverse bevel color single line surrounding the wrapped component with a title string normally drawn at the top-left side
-
Constructor Details
-
Borders
private Borders()
-
-
Method Details
-
singleLine
Creates aBorderthat is drawn as a solid color single line surrounding the wrapped component- Returns:
- New solid color single line
Border
-
singleLine
Creates aBorderthat is drawn as a solid color single line surrounding the wrapped component with a title string normally drawn at the top-left side- Parameters:
title- The title to draw on the border- Returns:
- New solid color single line
Borderwith a title
-
singleLineBevel
Creates aBorderthat is drawn as a bevel color single line surrounding the wrapped component- Returns:
- New bevel color single line
Border
-
singleLineBevel
Creates aBorderthat is drawn as a bevel color single line surrounding the wrapped component with a title string normally drawn at the top-left side- Parameters:
title- The title to draw on the border- Returns:
- New bevel color single line
Borderwith a title
-
singleLineReverseBevel
Creates aBorderthat is drawn as a reverse bevel color single line surrounding the wrapped component- Returns:
- New reverse bevel color single line
Border
-
singleLineReverseBevel
Creates aBorderthat is drawn as a reverse bevel color single line surrounding the wrapped component with a title string normally drawn at the top-left side- Parameters:
title- The title to draw on the border- Returns:
- New reverse bevel color single line
Borderwith a title
-
doubleLine
Creates aBorderthat is drawn as a solid color double line surrounding the wrapped component- Returns:
- New solid color double line
Border
-
doubleLine
Creates aBorderthat is drawn as a solid color double line surrounding the wrapped component with a title string normally drawn at the top-left side- Parameters:
title- The title to draw on the border- Returns:
- New solid color double line
Borderwith a title
-
doubleLineBevel
Creates aBorderthat is drawn as a bevel color double line surrounding the wrapped component- Returns:
- New bevel color double line
Border
-
doubleLineBevel
Creates aBorderthat is drawn as a bevel color double line surrounding the wrapped component with a title string normally drawn at the top-left side- Parameters:
title- The title to draw on the border- Returns:
- New bevel color double line
Borderwith a title
-
doubleLineReverseBevel
Creates aBorderthat is drawn as a reverse bevel color double line surrounding the wrapped component- Returns:
- New reverse bevel color double line
Border
-
doubleLineReverseBevel
Creates aBorderthat is drawn as a reverse bevel color double line surrounding the wrapped component with a title string normally drawn at the top-left side- Parameters:
title- The title to draw on the border- Returns:
- New reverse bevel color double line
Borderwith a title
-
joinLinesWithFrame
This method will attempt to join line drawing characters with the outermost bottom and top rows and left and right columns. For example, if a vertical left border character is ║ and the character immediately to the right of it is ─, then the border character will be updated to ╟ to join the two together. Please note that this method will only join the outer border columns and rows.- Parameters:
graphics- Graphics to use when inspecting and joining characters
-