22 package com.realtime.crossfire.jxclient.gui.log;
26 import java.awt.Color;
27 import java.awt.Image;
28 import org.jetbrains.annotations.NotNull;
29 import org.jetbrains.annotations.Nullable;
66 super(tooltipManager, elementListener, name, backgroundImage, fonts);
74 public void updateText(@NotNull
final CharSequence
string) {
77 parser.
parse(
string, defaultColor, buffer);
Listener for GUIElement related events.
void scrollTo(final int pos)
Scrolls to the given location.The possible range is given by a previous notification through a listen...
final Color defaultColor
The default color to use for text message not specifying a color.
GUILabelLog(@NotNull final TooltipManager tooltipManager, @NotNull final GUIElementListener elementListener, @NotNull final String name, @Nullable final Image backgroundImage, @NotNull final Fonts fonts, @NotNull final Color defaultColor)
Creates a new instance.
final TooltipManager tooltipManager
The TooltipManager to update.
static final long serialVersionUID
The serial version UID.
void clear()
Clears all lines from the buffer.
Parser for parsing drawextinfo messages received from a Crossfire server to update a Buffer instance...
final GUIElementListener elementListener
The GUIElementListener to notify.
void updateText(@NotNull final CharSequence string)
Sets the displayed text by parsing a string.
A gui element implementing a static text field which may contain media tags.
final Image backgroundImage
The background image drawn below the text contents.
final String name
The name of this element.
final Fonts fonts
The Fonts instance for looking up fonts.
Buffer getBuffer()
Returns the Buffer instance containing the text messages.
Manages the contents of the contents of a log window.
final Buffer buffer
The Buffer containing all received text messages.
void parse(@NotNull final CharSequence text, @Nullable final Color defaultColor, @NotNull final Buffer buffer)
Parses a text message.
final Parser parser
The Parser instance for parsing drawextinfo messages.
Abstract base class for gui elements implementing text fields.