Crossfire JXClient, Trunk
|
Protected Member Functions | |
DefaultBuffer (@NotNull final Fonts fonts, @NotNull final FontRenderContext context, final int renderWidth) | |
int | getSegmentWidth (@NotNull final TextSegment segment, final int characters) |
TextSegment | newTextSegment (final @NotNull String text, final boolean bold, final boolean italic, final boolean underline, final @NotNull FontID fontID, final @NotNull Color color, final @NotNull Color selectionColor) |
Protected Member Functions inherited from com.realtime.crossfire.jxclient.gui.log.Buffer | |
Buffer (final int maxLines, final int renderWidth) | |
Private Attributes | |
final FontRenderContext | context |
final Fonts | fonts |
Static Private Attributes | |
static final int | MAX_LINES = 1000 |
Additional Inherited Members | |
Public Member Functions inherited from com.realtime.crossfire.jxclient.gui.log.Buffer | |
void | addBufferListener (@NotNull final BufferListener listener) |
void | addLine (@NotNull final Line line) |
void | addTextSegment (@NotNull final Line line, @NotNull final String text, final boolean bold, final boolean italic, final boolean underline, @NotNull final FontID fontID, @NotNull final Color color, @NotNull final Color selectionColor) |
void | clear () |
int | coordinateToPosition (final int x, final int y) |
int | getLastCount () |
Line | getLine (final int line) |
Object | getSyncObject () |
String | getText (final int beginSelection, final int endSelection) |
int | getTotalHeight () |
Iterable< Line > | lines (final int line) |
boolean | mergeLines (@NotNull final String text, final int type, final int subtype, @Nullable final Color color) |
void | prune () |
void | removeBufferListener (@NotNull final BufferListener listener) |
void | replaceLine (@NotNull final Line line) |
void | setRenderWidth (final int renderWidth) |
void | setShowSentCommands (final boolean showSentCommands) |
void | setShowTimestamps (final boolean showTimestamps) |
int | size () |
Default Buffer implementation.
Definition at line 13 of file DefaultBuffer.java.
|
protected |
Creates a new instance.
fonts | the Fonts
|
context | the FontRenderContext
|
renderWidth | the width to render |
Definition at line 38 of file DefaultBuffer.java.
References com.realtime.crossfire.jxclient.gui.log.DefaultBuffer.context, com.realtime.crossfire.jxclient.gui.log.DefaultBuffer.fonts, com.realtime.crossfire.jxclient.gui.log.DefaultBuffer.MAX_LINES, and com.realtime.crossfire.jxclient.gui.log.Buffer.renderWidth.
|
protected |
Returns the width of a prefix of a TextSegment.
segment | the text segment |
characters | the number of characters in the prefix |
Reimplemented from com.realtime.crossfire.jxclient.gui.log.Buffer.
Definition at line 56 of file DefaultBuffer.java.
References com.realtime.crossfire.jxclient.gui.log.DefaultBuffer.context.
|
protected |
Creates a new segment.
text | the text to display |
bold | whether bold face is enabled |
italic | whether italic face is enabled |
underline | whether underlining is enabled |
fontID | the font to use |
color | the color to use |
selectionColor | the selection color to use |
Reimplemented from com.realtime.crossfire.jxclient.gui.log.Buffer.
Definition at line 46 of file DefaultBuffer.java.
References com.realtime.crossfire.jxclient.gui.log.DefaultBuffer.context, com.realtime.crossfire.jxclient.gui.log.DefaultBuffer.fonts, com.realtime.crossfire.jxclient.gui.log.Fonts.getFont(), and com.realtime.crossfire.jxclient.gui.log.Buffer.size().
|
private |
The FontRenderContext to use.
Definition at line 30 of file DefaultBuffer.java.
Referenced by com.realtime.crossfire.jxclient.gui.log.DefaultBuffer.DefaultBuffer(), com.realtime.crossfire.jxclient.gui.log.DefaultBuffer.getSegmentWidth(), and com.realtime.crossfire.jxclient.gui.log.DefaultBuffer.newTextSegment().
|
private |
The
instance for looking up fonts.
Definition at line 24 of file DefaultBuffer.java.
Referenced by com.realtime.crossfire.jxclient.gui.log.DefaultBuffer.DefaultBuffer(), and com.realtime.crossfire.jxclient.gui.log.DefaultBuffer.newTextSegment().
|
staticprivate |
The maximum number of lines the buffer can hold.
Definition at line 18 of file DefaultBuffer.java.
Referenced by com.realtime.crossfire.jxclient.gui.log.DefaultBuffer.DefaultBuffer().