All Classes and Interfaces
Class
Description
Layout manager that places components where they are manually specified to be and sizes them to the size they are
manually assigned to.
This abstract implementation of
BasePane
has the common code shared by all different concrete
implementations.Abstract implementation of
Border
interface that has some of the methods filled out.AbstractComponent provides some good default behaviour for a
Component
, all components in Lanterna extends
from this class in some way.This abstract implementation contains common code for the different
Composite
implementations.Abstract class for dialog building, containing much shared code between different kinds of dialogs
Default implementation of Interactable that extends from AbstractComponent.
Base class for several list box implementations, this will handle things like list of items and the scrollbar.
The default renderer for
AbstractListBox
and all its subclasses.The default list item renderer class, this can be extended and customized it needed.
This class implements some of the Screen logic that is not directly tied to the actual implementation of how the
Screen translate to the terminal.
Containing a some very fundamental functionality that should be common (and usable) to all terminal implementations.
This class hold the default logic for drawing the basic text graphic as exposed by TextGraphic.
This abstract implementation of TextGUI contains some basic management of the underlying Screen and other common code
that can be shared between different implementations.
Abstract implementation of
TextGUIThread
with common logic for both available concrete implementations.Abstract
Theme
implementation that manages a hierarchical tree of theme nodes ties to Class objects.Abstract Window has most of the code requiring for a window to function, all concrete window implementations extends
from this in one way or another.
This class is a list box implementation that displays a number of items that has actions associated with them.
Dialog containing a multiple item action list box
Dialog builder for the
ActionListDialog
class, use this to create instances of that class and to customize
themCharacter pattern that matches characters pressed while ALT key is held down
This is a special label that contains not just a single text to display but a number of frames that are cycled
through.
Class containing graphics code for ANSI compliant text terminals and terminal emulators.
Extended interface of TextGUIThread for implementations that uses a separate thread for all GUI event processing and
updating.
Enum representing the states of the GUI thread life-cycle
This class provides an AWT implementation of the Terminal interface that is an embeddable component you can put into
an AWT container.
This class encapsulates the font information used by an
AWTTerminal
.Controls how the SGR bold will take effect when enabled on a character.
This class is similar to what SwingTerminal used to be before Lanterna 3.0; a Frame that contains a terminal
emulator.
AWT implementation of
GraphicalTerminalImplementation
that contains all the overrides for AWT
Created by martin on 08/02/16.BasePane is the base container in a Text GUI.
Very simple pattern that matches the input stream against a pre-defined list of characters.
Simple implementation of TextImage that keeps the content as a two-dimensional TextCharacter array.
Simple AbstractWindow implementation that you can use as a building block when creating new windows without having
to create new classes.
Main interface for different border classes, with additional methods to help lanterna figure out the size and offset
of components wrapped by borders.
BorderLayout imitates the BorderLayout class from AWT, allowing you to add a center component with optional
components around it in top, bottom, left and right locations.
This type is what you use as the layout data for components added to a panel using
BorderLayout
for its
layout manager.This class containers a couple of border implementation and utility methods for instantiating them.
This class permits to deal easily with bundles.
Simple labeled button that the user can trigger by pressing the Enter or the Spacebar key on the keyboard when the
component is in focus.
Helper interface that doesn't add any new methods but makes coding new button renderers a little bit more clear
This is the default button renderer that is used if you don't override anything.
Alternative button renderer that displays buttons with just the label and minimal decoration
Listener interface that can be used to catch user events on the button
Used to compare a list of character if they match a particular pattern, and in that case, return the kind of
keystroke this pattern represents
This immutable class describes a matching result.
The checkbox component looks like a regular checkbox that you can find in modern graphics user interfaces, a label
and a space that the user can toggle on and off by using enter or space keys.
Helper interface that doesn't add any new methods but makes coding new check box renderers a little bit more clear
The default renderer that is used unless overridden.
Listener interface that can be used to catch user events on the check box
This is a list box implementation where each item has its own checked state that can be toggled on and off
Default renderer for this component which is used unless overridden.
Listener interface that can be attached to the
CheckBoxList
in order to be notified on user actionsThis is a simple combo box implementation that allows the user to select one out of multiple items through a
drop-down menu.
Helper interface that doesn't add any new methods but makes coding new combo box renderers a little bit more clear
This class is the default renderer implementation which will be used unless overridden.
Listener interface that can be used to catch user events on the combo box
This is the main interface defining a component in Lanterna, although you will probably not implement this directly
but rather extend the
AbstractComponent
or another one of the sub-classes instead to avoid implementing most
of the methods in this interface.This interface defines a renderer for a component, an external class that does the sizing and rendering.
A Composite is a Container that contains only one (or zero) component.
Container is a component that contains a collection of child components.
Character pattern that matches characters pressed while ALT and CTRL keys are held down
Character pattern that matches characters pressed while CTRL key is held down
This class extends UnixLikeTerminal and implements the Cygwin-specific implementations.
This profile attempts to collect as many code combinations as possible without causing any collisions between
patterns.
This basic implementation of ThemeStyle keeps the styles in its internal state and allows you to mutate them.
Default implementation of ShapeRenderer.
Default implementation of
TableCellRenderer
Default implementation of
TableHeaderRenderer
Default implementation of
TableRenderer
This TerminalFactory implementation uses a simple auto-detection mechanism for figuring out which terminal
implementation to create based on characteristics of the system the program is running on.
Created by Martin on 2017-08-11.
Default window decoration renderer that is used unless overridden with another decoration renderer.
The default window manager implementation used by Lanterna.
Allows you to more easily wrap an existing theme and alter the behaviour in some special cases.
Allows you to more easily wrap an existing theme definion and alter the behaviour in some special cases.
Thin layer on top of the
AbstractWindow
class that automatically sets properties and hints to the window to
make it act more like a modal dialog windowEnum for distinguishing between horizontal and vertical directions.
Dialog that allows the user to iterate the file system and pick directory.
Dialog builder for the
DirectoryDialog
class, use this to create instances of that class and to customize
them.This TextGraphics implementation wraps another TextGraphics and forwards all operations to it, but with a few
differences.
Simple component which draws a solid color over its area.
Implementation of WindowDecorationRenderer that is doesn't render any window decorations
This implementation of CharacterPattern matches two similar patterns
of Escape sequences, that many terminals produce for special keys.
This class extends the normal Terminal interface and adds a few more methods that are considered rare and shouldn't
be encouraged to be used.
Dialog that allows the user to iterate the file system and pick file to open/save
Dialog builder for the
FileDialog
class, use this to create instances of that class and to customize
themUsing this terminal size provider, your terminal will be set to a fixed size and will never receive any resize
events.
This is the class that does the heavy lifting for both
AWTTerminal
and SwingTerminal
.This emulates the behaviour of the GridLayout in SWT (as opposed to the one in AWT/Swing).
The enum is used to specify where in a grid cell a component should be placed, in the case that the preferred
size of the component is smaller than the space in the cell.
Special component that is by default displayed as the background of a text gui unless you override it with something
else.
Used to read the input stream character by character and generate
Key
objects to be put in the input queue.This interface can be used to programmatically intercept input from the user and decide if the input should be passed
on to the interactable.
Objects implementing this interface can read character streams and transform them into
Key
objects which can
be read in a FIFO manner.This interface marks a component as able to receive keyboard input from the user.
When focus has changed, which direction.
Enum to represent the various results coming out of the handleKeyStroke method
This class is used to keep a 'map' of the usable area and note where all the interact:ables are.
Extended interface for component renderers used with interactable components.
Interface extending ExtendedTerminal that removes the IOException throw clause.
Interface extending Terminal that removes the IOException throw clause.
This class exposes methods for converting a terminal into an IOSafeTerminal.
This class exposes methods for converting an extended terminal into an IOSafeExtendedTerminal.
In order to convert a stream of characters into objects representing keystrokes, we need to apply logic on this
stream to detect special characters.
Represents the user pressing a key on the keyboard.
an F3-KeyStroke that is distinguishable from a CursorLocation report.
This enum is a categorization of the various keys available on a normal computer keyboard that are usable
(detectable) by a terminal environment.
Label is a simple read-only text display component.
Catalog of available themes, this class will initially contain the themes bundled with Lanterna but it is possible to
add additional themes as well.
Empty interface to use for values that can be used as a layout meta-data on components.
A layout manager is a class that takes an area of usable space and a list of components to fit on that space.
Simple layout manager the puts all components on a single line, either horizontally or vertically.
This enum type will decide the alignment of a component on the counter-axis, meaning the horizontal alignment on
vertical
LinearLayout
s and vertical alignment on horizontal LinearLayout
s.This enum type will what to do with a component if the container has extra space to offer.
Dialog that allows the user to select an item from a list
Dialog builder for the
ListSelectDialog
class, use this to create instances of that class and to customize
themSet of predefined localized string.
All this strings are localized by using
Changing the locale by calling
All this strings are localized by using
LocalizedUIBundle
.Changing the locale by calling
Locale.setDefault(Locale)
.This class permits to get easily localized strings about the UI.
A menu bar offering drop-down menus.
This class is a single item that appears in a
Menu
with an optional action attached to itDefault renderer for menu items (both sub-menus and regular items)
Helper interface that doesn't add any new methods but makes coding new menu renderers a little bit more clear
This class is a
Window
implementation that automatically sets some common settings that you'd want on
specifically popup windows with menu items.Simple message dialog that displays a message and has optional selection/confirmation buttons
Dialog builder for the
MessageDialog
class, use this to create instances of that class and to customize
themThis enum has the available selection of buttons that you can add to a
MessageDialog
.MouseAction, a KeyStroke in disguise, this class contains the information of a single mouse action event.
Enum type for the different kinds of mouse actions supported
Constant describing different modes for capturing mouse input.
Pattern used to detect Xterm-protocol mouse events coming in on the standard input channel
Created by martin on 19/07/15.
This is the main Text GUI implementation built into Lanterna, supporting multiple tiled windows and a dynamic
background area that can be fully customized.
Character pattern that matches one character as one KeyStroke with the character that was read
TextGraphics implementation that does nothing, but has a pre-defined size
This class is the basic building block for creating user interfaces, being the standard implementation of
Container
that supports multiple children.Utility class for quickly bunching up components in a panel, arranged in a particular pattern
This GUI element gives a visual indication of how far a process of some sort has progressed at any given time.
Default implementation of the progress bar GUI component renderer.
This progress bar renderer implementation takes slightly more space (three rows) and draws a slightly more
complicates progress bar with fixed measurers to mark 25%, 50% and 75%.
Theme
implementation that stores the theme definition in a regular java Properties object.The list box will display a number of items, of which one and only one can be marked as selected.
Listener interface that can be attached to the
RadioBoxList
in order to be notified on user actionsDefault renderer for this component which is used unless overridden.
This
TextGUIThread
implementation is assuming the GUI event thread will be the same as the thread that
creates the TextGUI
objects.Default factory class for
SameTextGUIThread
, you need to pass this to the TextGUI
constructor if
you want it to use this classScreen is a fundamental layer in Lanterna, presenting the terminal as a bitmap-like surface where you can perform
smaller in-memory operations to a back-buffer, effectively painting out the terminal as you'd like it, and then call
refresh
to have the screen automatically apply the changes in the back-buffer to the real terminal.This enum represents the different ways a Screen can refresh the screen, moving the back-buffer data into the
front-buffer that is being displayed.
Defines a buffer used by AbstractScreen and its subclasses to keep its state of what's currently displayed and what
the edit buffer looks like.
ScreenInfoAction, a KeyStroke in disguise, this class contains the reported position of the screen cursor.
This class recognizes character combinations which are actually a cursor position report.
This is an implementation of TextGraphics that targets the output to a Screen.
Describes an area that can be 'scrolled', by moving a range of lines up or down.
Classic scrollbar that can be used to display where inside a larger component a view is showing.
Default renderer for
ScrollBar
which will be used unless overridden.Helper class for making new
ScrollBar
renderers a little bit cleanerThis is a AWT Container that carries an
AWTTerminal
with a scrollbar, effectively implementing a
pseudo-terminal with scrollback history.This is a Swing JComponent that carries a
SwingTerminal
with a scrollbar, effectively implementing a
pseudo-terminal with scrollback history.Default implementation of TextGUIThread, this class runs the GUI event processing on a dedicated thread.
Factory class for creating SeparateTextGUIThread objects
Static non-interactive component that is typically rendered as a single line.
This is the default separator renderer that is used if you don't override anything.
Helper interface that doesn't add any new methods but makes coding new button renderers a little bit more clear
SGR - Select Graphic Rendition, changes the state of the terminal as to what kind of text to print after this
command.
This package private interface exposes methods for translating abstract lines, triangles and rectangles to discreet
points on a grid.
This class is a simple implementation of Terminal.ResizeListener which will keep track of the size of the terminal
and let you know if the terminal has been resized since you last checked.
Very basic implementation of
Theme
that allows you to quickly define a theme in code.Internal class inside
SimpleTheme
used to allow basic editing of the default style and the optional
overrides.An abstract terminal implementing functionality for terminals using OutputStream/InputStream.
This implementation of TextGraphics will take a 'proper' object and composite a view on top of it, by using a
top-left position and a size.
This class provides an Swing implementation of the
Terminal
interface that
is an embeddable component you can put into a Swing container.Font configuration class for
SwingTerminal
that is extending from AWTTerminalFontConfiguration
This class is similar to what SwingTerminal used to be before Lanterna 3.0; a JFrame that contains a terminal
emulator.
Concrete implementation of
GraphicalTerminalImplementation
that adapts it to SwingSome text graphics, taken from http://en.wikipedia.org/wiki/Codepage_437 but converted to its UTF-8 counterpart.
What to do about the tab character when putting on a
Screen
.The table class is an interactable component that displays a grid of cells containing data along with a header of
labels.
Describing how table cells are separated when drawn
The main interface to implement when you need to customize the way table cells are drawn
This interface can be implemented if you want to customize how table headers are drawn.
A
TableModel
contains the data model behind a table, here is where all the action cell values and header
labels are stored.Listener interface for the
TableModel
class which can be attached to a TableModel
to be notified
of changes to the table model.Formalized interactable renderer for tables
Contains the telnet protocol commands, although not a complete set.
This class is used by the
TelnetTerminalServer
class when a client has connected in; this class will be the
interaction point for that client.This class contains some of the various states that the Telnet negotiation protocol defines.
This class implements a Telnet server, capable of accepting multiple clients and presenting each one as their own
Terminal.
This is the main terminal interface, at the lowest level supported by Lanterna.
This enum stored various ways the AWTTerminalFrame and SwingTerminalFrame can automatically close (hide and dispose)
themselves when a certain condition happens.
Color configuration settings to be using with SwingTerminal.
Object that encapsulates the configuration parameters for the terminal 'device' that a SwingTerminal is emulating.
Different cursor styles supported by SwingTerminal
This class specifies the palette of colors the terminal will use for the normally available 8 + 1 ANSI colors but
also their 'bright' versions with are normally enabled through bold mode.
This interface is for abstracting the creation of your Terminal object.
A 2-d position in 'terminal space'.
This class is immutable and cannot change its internal state after creation.
Listener interface that can be used to be alerted on terminal resizing
This is the default concrete implementation of the Screen interface, a buffered layer sitting on top of a Terminal.
This interface can be used to control the backlog scrolling of a SwingTerminal.
Implementation of
TerminalScrollController
that does nothingTerminal dimensions in 2-d space, measured in number of rows and columns.
This is the terminal's implementation of TextGraphics.
This class contains a number of utility methods for analyzing characters and strings in a terminal context.
This component keeps a text content that is editable by the user.
This is the default text box renderer that is used if you don't override anything.
Enum value to force a
TextBox
to be either single line or multi line.Helper interface that doesn't add any new methods but makes coding new text box renderers a little bit more clear
Listener interface for when the
TextBox
content has changed.This class is used to store lines of text inside of a terminal emulator.
Represents a single character with additional metadata such as colors and modifiers.
This is an abstract base class for terminal color definitions.
This class represent classic ANSI colors that are likely to be very compatible with most terminal
implementations.
Utility class to instantiate colors from other types and definitions
This class represents a color expressed in the indexed XTerm 256 color extension, where each color is defined in a
lookup-table.
This class can be used to specify a color in 24-bit color space (RGB with 8-bit resolution per color).
This interface exposes functionality to 'draw' text graphics on a section of the terminal.
This is the base interface for advanced text GUIs supported in Lanterna.
Listener interface for TextGUI, firing on events related to the overall GUI
This interface is the base part in the Lanterna Text GUI component hierarchy
TextGraphics implementation used by TextGUI when doing any drawing operation.
Class that represents the thread this is expected to run the event/input/update loop for the
TextGUI
.This interface defines an exception handler, that is used for looking at exceptions that occurs during the main
event loop of the TextGUIThread.
Factory class for creating
TextGUIThread
objects.An 'image' build up of text characters with color and style information.
TextInputDialog
is a modal text input dialog that prompts the user to enter a text string.Dialog builder for the
TextInputDialog
class, use this to create instances of that class and to customize
themInterface to implement for custom validation of text input in a
TextInputDialog
The main theme interface, from which you can retrieve theme definitions
A ThemeDefinition contains a collection of ThemeStyle:s, which defines on a lower level which colors and SGRs to
apply if you want to draw according to the theme.
Expanded TextGraphics that adds methods to interact with themes
ThemeStyle is the lowest entry in the theme hierarchy, containing the actual colors and SGRs to use.
Base class for all terminals that generally behave like Unix terminals.
This enum lets you control how Lanterna will handle a ctrl+c keystroke from the user.
UnixLikeTerminal extends from ANSITerminal and defines functionality that is common to
UnixTerminal
and CygwinTerminal
, like setting tty modes; echo, cbreak
and minimum characters for reading as well as a shutdown hook to set the tty back to
original state at the end.This class extends UnixLikeTerminal and implements the Unix-specific parts.
This class allows you to override by what means Lanterna detects the size of
the terminal.
VirtualScreen wraps a normal screen and presents it as a screen that has a configurable minimum size; if the real
screen is smaller than this size, the presented screen will add scrolling to get around it.
Interface for rendering the virtual screen's frame when the real terminal is too small for the virtual screen
A virtual terminal is a kind of terminal emulator implemented inside of Lanterna that exposes the Terminal interface
and maintains its state completely internally.
Interface used by
VirtualTerminal.BufferWalker
to repressent a line in the text buffer when iterating over a range of
linesCallback interface that is used by
VirtualTerminal.forEachLine(int, int, BufferWalker)
as a way to iterate over a range
of lines in the text bufferListener class for
VirtualTerminal
that allows you to receive callbacks on certain events.Implementation of
TextGraphics
for VirtualTerminal
Dialog that displays a text message, an optional spinning indicator and an optional progress bar.
Window is a base unit in the TextGUI system, it represents a collection of components grouped together, usually
surrounded by a border and a title.
Window hints are meta-data stored along with the window that can be used to give the GUI system some ideas of how
this window wants to be treated.
Extension of the TextGUI interface, this is intended as the base interface for any TextGUI that intends to make use
of the Window class.
Interface that defines a class that draws window decorations, i.e.
Extended
BasePaneListener
for Window
that exposes additional events that are specific to windowsAdapter class for
WindowListener
to make it easier to create listeners without having to implement every
interface method.Window manager is a class that is plugged in to a
WindowBasedTextGUI
to manage the position and placement
of windows.Classes implementing this interface can be used along with DefaultWindowManagerTextGUI to put some extra processing
after a window has been rendered.
This WindowPostRenderer implementation draws a shadow under the window
What to do when line length is exceeded.