|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjackpal.androidterm.emulatorview.ColorScheme
public class ColorScheme
A class describing a color scheme for a 16-color VT100 terminal.
A 16-color VT100 has two separate color maps, one for foreground colors and one for background colors. Each one contains eight colors, which are traditionally found in the following order:
{ black, red, green, yellow, blue, magenta, cyan, white }
In addition, each of the foreground colors has a corresponding "bright" version. Traditionally, the "dim" white is actually a light gray, while the "bright" black is a dark gray color.
EmulatorView
supports limited changes to the default color maps
via the color scheme mechanism. Passing a ColorScheme
to
setColorScheme
will cause the
foreground color with map index foreColorIndex
to be replaced
with the provided foreColor
, and the background color with map
index backColorIndex
to be replaced with the provided
backColor
. The provided colors will then become the default
foreground and background colors for the EmulatorView
.
EmulatorView.setColorScheme(jackpal.androidterm.emulatorview.ColorScheme)
Constructor Summary | |
---|---|
ColorScheme(int[] scheme)
Creates a ColorScheme object from an array. |
|
ColorScheme(int foreColorIndex,
int foreColor,
int backColorIndex,
int backColor)
Creates a ColorScheme object. |
Method Summary | |
---|---|
int |
getBackColor()
|
int |
getBackColorIndex()
|
int |
getForeColor()
|
int |
getForeColorIndex()
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ColorScheme(int foreColorIndex, int foreColor, int backColorIndex, int backColor)
ColorScheme
object.
foreColorIndex
- The VT100 color map index the foreground color
should map to.foreColor
- The foreground color as an ARGB hex value.backColorIndex
- The VT100 color map index the background color
should map to.backColor
- The background color as an ARGB hex value.public ColorScheme(int[] scheme)
ColorScheme
object from an array.
scheme
- An integer array { foreColorIndex, foreColor,
backColorIndex, backColor }
.Method Detail |
---|
public int getForeColor()
ColorScheme
's foreground color as an ARGB
hex value.public int getBackColor()
ColorScheme
's background color as an ARGB
hex value.public int getForeColorIndex()
ColorScheme
's foreground color's VT100 color
map index.public int getBackColorIndex()
ColorScheme
's background color's VT100 color
map index.
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |