 |
Gridarta Editor
|
Go to the documentation of this file.
20 package net.sf.gridarta.gui.dialog.gameobjectattributes;
22 import javax.swing.text.AttributeSet;
23 import javax.swing.text.BadLocationException;
24 import javax.swing.text.Document;
25 import javax.swing.text.Style;
31 import org.apache.log4j.Category;
32 import org.apache.log4j.Logger;
33 import org.jetbrains.annotations.NotNull;
91 public abstract void appendSummary(@NotNull Document doc, @NotNull Style style);
101 protected void addLine(@NotNull
final Document doc, @NotNull
final AttributeSet style, @NotNull
final String prefix, @NotNull
final String postfix) {
103 doc.insertString(doc.getLength(), prefix +
ref.getAttributeName() + postfix +
"\n", style);
104 }
catch (
final BadLocationException e) {
105 LOG.error(
"toggleSummary: Bad Location in Document!", e);
final T ref
Reference to the attribute data.
Defines types of GameObjects with corresponding attributes.
T getRef()
Returns the attribute data.
DialogAttribute(@NotNull final T ref)
Creates a new instance.
Base package of all Gridarta classes.
Indicates that an attribute cannot be encoded.
void addLine(@NotNull final Document doc, @NotNull final AttributeSet style, @NotNull final String prefix, @NotNull final String postfix)
Appends a line to a Document.
Reflects a game object (object on a map).
A single Attribute, combining an ArchetypeAttribute with its input component(s).
abstract void appendSummary(@NotNull Document doc, @NotNull Style style)
Appends a summary line for this attribute to a Document.
GameObjects are the objects based on Archetypes found on maps.
This Class contains the data of one archetype attribute.
Interface for MapArchObjects.
Contains the data of one Gridarta Object-Type.
static final Category LOG
The Logger for printing log messages.
abstract String getObjectText(@NotNull G gameObject, @NotNull Archetype< G, A, R > archetype, @NotNull String @NotNull[] newMsg, @NotNull ArchetypeType archetypeType)
Returns the attribute text for this attribute.