Package org.jline.builtins
Class ScreenTerminal
java.lang.Object
org.jline.builtins.ScreenTerminal
Screen terminal implementation.
This class is copied from Apache Karaf WebConsole Gogo plugin
and slightly adapted to support alternate screen / resizing / 256 colors.
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionprivate longprivate intprivate intprivate AtomicBooleanprivate booleanprivate intprivate final List<long[]> private long[][]private long[][]private intprivate intprivate intprivate intprivate int[]private intprivate int[]private booleanprivate booleanprivate booleanprivate intprivate booleanprivate booleanprivate booleanprivate booleanprivate booleanprivate booleanprivate booleanprivate booleanprivate booleanprivate booleanprivate Stringprivate intprivate intprivate Stringprivate ScreenTerminal.Stateprivate intprivate intprivate int -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprivate voidclear(int y0, int x0, int y1, int x1) private longcol24(int col) private voidprivate voidprivate voidprivate voidprivate voidprivate voidprivate voidprivate voidprivate voidprivate voidprivate voidprivate voidprivate voidprivate voidprivate voidprivate voidcsi_DECSTR(String p) private voidprivate voidprivate voidprivate voidprivate voidprivate voidprivate voidprivate voidprivate voidprivate voidprivate voidprivate voidprivate voidprivate voidprivate voidprivate voidprivate voidprivate voidprivate voidprivate voidprivate voidprivate voidctrl_BS()private voidctrl_CR()private voidctrl_HT()private voidctrl_HT(int n) private voidctrl_LF()private voidctrl_SI()private voidctrl_SO()private voidprivate voidcursor_down(int n) private voidprivate voidcursor_left(int n) private int[]cursor_line_width(int next_char) private voidprivate voidcursor_right(int n) private voidcursor_set(int y, int x) private voidcursor_set_x(int x) private voidcursor_set_y(int y) private voidprivate voidcursor_up(int n) private voiddumb_echo(int c) private booleandumb_write(int c) voiddump(long[] fullscreen, int ftop, int fleft, int fheight, int fwidth, int[] cursor) dump(long timeout, boolean forceDump) private voidesc_APC()private voidesc_CSI()private voidesc_DCS()private voidprivate voidprivate voidprivate voidprivate voidesc_G0_0()private voidesc_G0_1()private voidesc_G0_2()private voidesc_G0_3()private voidesc_G0_4()private voidesc_G1_0()private voidesc_G1_1()private voidesc_G1_2()private voidesc_G1_3()private voidesc_G1_4()private voidesc_HTS()private voidesc_IND()private voidesc_NEL()private voidesc_OSC()private voidesc_PM()private voidesc_RI()private voidesc_RIS()private voidesc_SOS()private voidesc_SS2()private voidesc_SS3()private voidesc_ST()private voidfill(int y0, int x0, int y1, int x1, long c) booleanisDirty()private long[]peek(int y0, int x0, int y1, int x1) private voidpoke(int y, int x, long[] s) read()private voidprivate voidprivate voidprivate voidscroll_area_down(int y0, int y1) private voidscroll_area_down(int y0, int y1, int n) private voidscroll_area_set(int y0, int y1) private voidscroll_area_up(int y0, int y1) private voidscroll_area_up(int y0, int y1, int n) private voidscroll_line_left(int y, int x) private voidscroll_line_left(int y, int x, int n) private voidscroll_line_right(int y, int x) private voidscroll_line_right(int y, int x, int n) protected voidsetDirty()booleansetSize(int w, int h) toString()private intutf8_charwidth(int c) private voidvt100_charset_select(int g, int charset) private voidvt100_charset_set(int g) private voidprivate int[]vt100_parse_params(String p, int[] defaults) private String[]vt100_parse_params(String p, String[] defaults) private voidprivate voidprivate voidprivate voidvt100_setmode(String p, boolean state) private booleanvt100_write(int c) voidboolean
-
Field Details
-
width
private int width -
height
private int height -
attr
private long attr -
eol
private boolean eol -
cx
private int cx -
cy
private int cy -
screen
private long[][] screen -
screen2
private long[][] screen2 -
vt100_parse_state
-
vt100_parse_len
private int vt100_parse_len -
vt100_lastchar
private int vt100_lastchar -
vt100_parse_func
private int vt100_parse_func -
vt100_parse_param
-
vt100_mode_autowrap
private boolean vt100_mode_autowrap -
vt100_mode_insert
private boolean vt100_mode_insert -
vt100_charset_is_single_shift
private boolean vt100_charset_is_single_shift -
vt100_charset_is_graphical
private boolean vt100_charset_is_graphical -
vt100_mode_lfnewline
private boolean vt100_mode_lfnewline -
vt100_mode_origin
private boolean vt100_mode_origin -
vt100_mode_inverse
private boolean vt100_mode_inverse -
vt100_mode_cursorkey
private boolean vt100_mode_cursorkey -
vt100_mode_cursor
private boolean vt100_mode_cursor -
vt100_mode_alt_screen
private boolean vt100_mode_alt_screen -
vt100_mode_backspace
private boolean vt100_mode_backspace -
vt100_mode_column_switch
private boolean vt100_mode_column_switch -
vt100_keyfilter_escape
private boolean vt100_keyfilter_escape -
vt100_charset_graph
private int[] vt100_charset_graph -
vt100_charset_g_sel
private int vt100_charset_g_sel -
vt100_charset_g
private int[] vt100_charset_g -
vt100_saved
-
vt100_saved2
-
vt100_alternate_saved_cx
private int vt100_alternate_saved_cx -
vt100_alternate_saved_cy
private int vt100_alternate_saved_cy -
vt100_saved_cx
private int vt100_saved_cx -
vt100_saved_cy
private int vt100_saved_cy -
vt100_out
-
scroll_area_y0
private int scroll_area_y0 -
scroll_area_y1
private int scroll_area_y1 -
tab_stops
-
history
-
dirty
-
-
Constructor Details
-
ScreenTerminal
public ScreenTerminal() -
ScreenTerminal
public ScreenTerminal(int width, int height)
-
-
Method Details
-
reset_hard
private void reset_hard() -
reset_soft
private void reset_soft() -
reset_screen
private void reset_screen() -
utf8_charwidth
private int utf8_charwidth(int c) -
peek
private long[] peek(int y0, int x0, int y1, int x1) -
poke
private void poke(int y, int x, long[] s) -
fill
private void fill(int y0, int x0, int y1, int x1, long c) -
clear
private void clear(int y0, int x0, int y1, int x1) -
scroll_area_up
private void scroll_area_up(int y0, int y1) -
scroll_area_up
private void scroll_area_up(int y0, int y1, int n) -
scroll_area_down
private void scroll_area_down(int y0, int y1) -
scroll_area_down
private void scroll_area_down(int y0, int y1, int n) -
scroll_area_set
private void scroll_area_set(int y0, int y1) -
scroll_line_right
private void scroll_line_right(int y, int x) -
scroll_line_right
private void scroll_line_right(int y, int x, int n) -
scroll_line_left
private void scroll_line_left(int y, int x) -
scroll_line_left
private void scroll_line_left(int y, int x, int n) -
cursor_line_width
private int[] cursor_line_width(int next_char) -
cursor_up
private void cursor_up() -
cursor_up
private void cursor_up(int n) -
cursor_down
private void cursor_down() -
cursor_down
private void cursor_down(int n) -
cursor_left
private void cursor_left() -
cursor_left
private void cursor_left(int n) -
cursor_right
private void cursor_right() -
cursor_right
private void cursor_right(int n) -
cursor_set_x
private void cursor_set_x(int x) -
cursor_set_y
private void cursor_set_y(int y) -
cursor_set
private void cursor_set(int y, int x) -
ctrl_BS
private void ctrl_BS() -
ctrl_HT
private void ctrl_HT() -
ctrl_HT
private void ctrl_HT(int n) -
ctrl_LF
private void ctrl_LF() -
ctrl_CR
private void ctrl_CR() -
dumb_write
private boolean dumb_write(int c) -
dumb_echo
private void dumb_echo(int c) -
vt100_charset_update
private void vt100_charset_update() -
vt100_charset_set
private void vt100_charset_set(int g) -
vt100_charset_select
private void vt100_charset_select(int g, int charset) -
vt100_setmode
-
ctrl_SO
private void ctrl_SO() -
ctrl_SI
private void ctrl_SI() -
esc_CSI
private void esc_CSI() -
esc_DECALN
private void esc_DECALN() -
esc_G0_0
private void esc_G0_0() -
esc_G0_1
private void esc_G0_1() -
esc_G0_2
private void esc_G0_2() -
esc_G0_3
private void esc_G0_3() -
esc_G0_4
private void esc_G0_4() -
esc_G1_0
private void esc_G1_0() -
esc_G1_1
private void esc_G1_1() -
esc_G1_2
private void esc_G1_2() -
esc_G1_3
private void esc_G1_3() -
esc_G1_4
private void esc_G1_4() -
esc_DECSC
private void esc_DECSC() -
esc_DECRC
private void esc_DECRC() -
esc_IND
private void esc_IND() -
esc_NEL
private void esc_NEL() -
esc_HTS
private void esc_HTS() -
esc_RI
private void esc_RI() -
esc_SS2
private void esc_SS2() -
esc_SS3
private void esc_SS3() -
esc_DCS
private void esc_DCS() -
esc_SOS
private void esc_SOS() -
esc_DECID
private void esc_DECID() -
esc_ST
private void esc_ST() -
esc_OSC
private void esc_OSC() -
esc_PM
private void esc_PM() -
esc_APC
private void esc_APC() -
esc_RIS
private void esc_RIS() -
csi_ICH
-
csi_CUU
-
csi_CUD
-
csi_CUF
-
csi_CUB
-
csi_CNL
-
csi_CPL
-
csi_CHA
-
csi_CUP
-
csi_CHT
-
csi_ED
-
csi_EL
-
csi_IL
-
csi_DL
-
csi_DCH
-
csi_SU
-
csi_SD
-
csi_CTC
-
csi_ECH
-
csi_CBT
-
csi_HPA
-
csi_HPR
-
csi_REP
-
csi_DA
-
csi_VPA
-
csi_VPR
-
csi_HVP
-
csi_TBC
-
csi_SM
-
csi_RM
-
csi_SGR
-
col24
private long col24(int col) -
csi_DSR
-
csi_DECSTBM
-
csi_SCP
-
csi_RCP
-
csi_DECREQTPARM
-
csi_DECSTR
-
vt100_parse_params
-
vt100_parse_params
-
vt100_parse_reset
private void vt100_parse_reset() -
vt100_parse_reset
-
vt100_parse_process
private void vt100_parse_process() -
vt100_write
private boolean vt100_write(int c) -
isDirty
public boolean isDirty() -
waitDirty
- Throws:
InterruptedException
-
setDirty
protected void setDirty() -
setSize
public boolean setSize(int w, int h) -
read
-
pipe
-
write
-
dump
public void dump(long[] fullscreen, int ftop, int fleft, int fheight, int fwidth, int[] cursor) -
dump
- Throws:
InterruptedException
-
toString
-