|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectnet.ranides.assira.text.format.AnsiCharLiveSequence
public class AnsiCharLiveSequence
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from interface net.ranides.assira.text.format.AnsiAttr |
|---|
AnsiAttr.IndirectAt |
| Field Summary |
|---|
| Fields inherited from interface net.ranides.assira.text.format.AnsiAttr |
|---|
bold, BOLD, changed, CHANGED, fresh, FRESH, invert, INVERT, MASK_INTERNAL, MASK_PUBLIC, narrow, NARROW, normal, NORMAL, SPLIT_ALL, SPLIT_BACK, SPLIT_FLAGS, SPLIT_FLAGS_ALL, SPLIT_FONT, SPLIT_FORE, strike, STRIKE, symbol, SYMBOL, underline, UNDERLINE |
| Constructor Summary | |
|---|---|
AnsiCharLiveSequence(AnsiCharSequence source,
int left,
int right)
|
|
| Method Summary | |
|---|---|
char |
charAt(int index)
|
boolean |
equals(Object obj)
|
AnsiAttr |
getAttr()
Zwraca wszystkie domyślne właściwości przypisane do ciągu tekstowego (kolor, tło, czcionka, styl). |
AnsiAttr |
getAttrAt(int index)
Zwraca wszystkie właściwości przypisane do znaku o podanym indeksie (kolor, tło, czcionka, styl). |
int |
getBack()
Zwraca przypisany numer koloru tła. |
int |
getBackAt(int index)
Zwraca numer koloru tła przypisany do znaku o podanym indeksie. |
char |
getCharAt(int index)
Odczytuje z sekwencji znak o podanym indeksie. |
Color |
getComputedBack()
Metoda opcjonalna: zwraca przypisany kolor tła. |
Color |
getComputedBackAt(int index)
Metoda opcjonalna: zwraca kolor tła przypisany do znaku o podanym indeksie. |
Font |
getComputedFont()
Metoda opcjonalna: zwraca przypisaną czcionkę. |
Font |
getComputedFontAt(int index)
Metoda opcjonalna: zwraca numer czcionki przypisany do znaku o podanym indeksie. |
Color |
getComputedFore()
Metoda opcjonalna: zwraca przypisany kolor tekstu. |
Color |
getComputedForeAt(int index)
Metoda opcjonalna: zwraca kolor tekstu przypisany do znaku o podanym indeksie. |
int |
getFlags()
Zwraca przypisane atrybuty tekstu. |
int |
getFlagsAt(int index)
Zwraca atrybuty przypisane do znaku o podanym indeksie. |
int |
getFont()
Zwraca przypisany numer czcionki. |
int |
getFontAt(int index)
Zwraca numer czcionki przypisany do znaku o podanym indeksie. |
AnsiFontScheme |
getFonts()
Zwraca schemat czcionek skojarzony z sekwencją znaków. |
int |
getFore()
Zwraca przypisany numer koloru tekstu. |
int |
getForeAt(int index)
Zwraca numer koloru tekstu przypisany do znaku o podanym indeksie. |
AnsiColorScheme |
getScheme()
Zwraca schemat kolorów skojarzony z sekwencją znaków. |
int |
hashCode()
|
int |
length()
|
Iterable<? extends AnsiCharSequence> |
split(int options)
Rozbija tekst na fragmenty zawierające znaki zgrupowane według kryteriów podanych w opcjach. |
AnsiCharSequence |
subAnsiSequence(int begin,
int end)
Returns a new AnsiCharSequence that is a subsequence of this sequence. |
CharSequence |
subSequence(int start,
int end)
|
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
getClass, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public AnsiCharLiveSequence(AnsiCharSequence source,
int left,
int right)
| Method Detail |
|---|
public Color getComputedFore()
AnsiAttrAnsiColorScheme.
getComputedFore in interface AnsiAttrpublic Color getComputedForeAt(int index)
AnsiCharSequenceAnsiColorScheme.
getComputedForeAt in interface AnsiCharSequencepublic Color getComputedBack()
AnsiAttrAnsiColorScheme.
getComputedBack in interface AnsiAttrpublic Color getComputedBackAt(int index)
AnsiCharSequenceAnsiColorScheme.
getComputedBackAt in interface AnsiCharSequencepublic int getFore()
AnsiAttrAnsiColorScheme.
getFore in interface AnsiAttrAnsiAttr.getComputedFore()public int getForeAt(int index)
AnsiCharSequenceAnsiColorScheme.
getForeAt in interface AnsiCharSequenceAnsiCharSequence.getComputedForeAt(int)public int getBack()
AnsiAttrAnsiColorScheme.
getBack in interface AnsiAttrAnsiAttr.getComputedBack()public int getBackAt(int index)
AnsiCharSequenceAnsiColorScheme.
getBackAt in interface AnsiCharSequenceAnsiCharSequence.getComputedBackAt(int)public int getFlagsAt(int index)
AnsiCharSequence
getFlagsAt in interface AnsiCharSequencepublic int getFlags()
AnsiAttr
getFlags in interface AnsiAttrpublic Font getComputedFont()
AnsiAttrAnsiFontScheme.
getComputedFont in interface AnsiAttrpublic Font getComputedFontAt(int index)
AnsiCharSequenceAnsiFontScheme.
getComputedFontAt in interface AnsiCharSequencepublic int getFont()
AnsiAttrAnsiFontScheme.
getFont in interface AnsiAttrAnsiAttr.getComputedFont()public int getFontAt(int index)
AnsiCharSequenceAnsiFontScheme.
getFontAt in interface AnsiCharSequenceAnsiCharSequence.getComputedFontAt(int)public AnsiAttr getAttr()
AnsiCharSequence
getAttr in interface AnsiCharSequencepublic AnsiAttr getAttrAt(int index)
AnsiCharSequence
getAttrAt in interface AnsiCharSequencepublic Iterable<? extends AnsiCharSequence> split(int options)
AnsiCharSequence
Rozbija tekst na fragmenty zawierające znaki zgrupowane według kryteriów
podanych w opcjach. Opcje są zbiorem flag z klasy AnsiAttr.
Rozdziela tekst na fragmenty o jednym kolorze tekstu i tła:
text.split(AnsiAttr.SPLIT_FORE | AnsiAttr.SPLIT_BACK)
Rozdziela tekst na fragmenty o tym samym stylu pogrubienia:
text.split(AnsiAttr.SPLIT_FLAGS | AnsiAttr.BOLD)
split in interface AnsiCharSequence
public AnsiCharSequence subAnsiSequence(int begin,
int end)
AnsiCharSequenceAnsiCharSequence that is a subsequence of this sequence.
The subsequence starts with the char value at the specified index and
ends with the char value at index end - 1. The length
(in chars) of the
returned sequence is end - start, so if start == end
then an empty sequence is returned.
subAnsiSequence in interface AnsiCharSequencebegin - the start index, inclusiveend - the end index, exclusive
public int length()
length in interface CharSequencepublic char charAt(int index)
charAt in interface CharSequencepublic char getCharAt(int index)
AnsiCharSequenceCharSequence.charAt(int). Metoda istniejąca w celu uzyskania pełnej kompatybilności
sekwencji znaków z konwencją JavaBeans.
getCharAt in interface AnsiCharSequence
public CharSequence subSequence(int start,
int end)
subSequence in interface CharSequencepublic AnsiColorScheme getScheme()
AnsiCharSequenceAnsiAttr.getComputedFore(),
AnsiAttr.getComputedBack() oraz pochodnych.
getScheme in interface AnsiCharSequencepublic AnsiFontScheme getFonts()
AnsiCharSequenceAnsiAttr.getComputedFont()
oraz AnsiCharSequence.getComputedFontAt(int)
getFonts in interface AnsiCharSequencepublic String toString()
toString in interface CharSequencetoString in class Objectpublic boolean equals(Object obj)
equals in class Objectpublic int hashCode()
hashCode in class Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||