public class RenderAppendable extends Object implements ScreenContext
Modifier and Type | Field and Description |
---|---|
private ScreenContext |
context
.
|
private LinkedList<Style.Composite> |
stack
.
|
Constructor and Description |
---|
RenderAppendable(ScreenContext context) |
Modifier and Type | Method and Description |
---|---|
Screenable |
append(char c) |
RenderAppendable |
append(CharSequence s) |
Screenable |
append(CharSequence csq,
int start,
int end) |
Screenable |
append(Style style) |
Screenable |
cls() |
void |
enterStyle(Style.Composite style) |
void |
flush()
Flush the stream.
|
private Boolean |
foo(Boolean last,
Boolean merged) |
private Color |
foo(Color last,
Color merged,
Color def) |
int |
getHeight()
Returns the screen height in chars.
|
private Style.Composite |
getMerged()
Compute the current merged style.
|
int |
getWidth()
Returns the screen width in chars.
|
Style.Composite |
leaveStyle() |
void |
styleOff() |
void |
styleOn() |
private final ScreenContext context
private LinkedList<Style.Composite> stack
public RenderAppendable(ScreenContext context)
public RenderAppendable append(CharSequence s)
append
in interface Appendable
public Screenable append(char c)
append
in interface Appendable
public Screenable append(CharSequence csq, int start, int end)
append
in interface Appendable
public Screenable append(Style style)
append
in interface Screenable
public Screenable cls()
cls
in interface Screenable
public int getWidth()
ScreenContext
getWidth
in interface ScreenContext
public int getHeight()
ScreenContext
getHeight
in interface ScreenContext
public void flush() throws IOException
ScreenContext
flush
in interface ScreenContext
IOException
- any io exceptionpublic void enterStyle(Style.Composite style)
public Style.Composite leaveStyle()
private Style.Composite getMerged()
public void styleOff()
public void styleOn()
Copyright © 2015 eXo Platform SAS. All Rights Reserved.