 |
Gridarta Editor
|
Go to the documentation of this file.
20 package net.sf.gridarta.gui.dialog.gameobjectattributes;
22 import javax.swing.AbstractButton;
23 import javax.swing.text.Document;
24 import javax.swing.text.Style;
30 import org.jetbrains.annotations.NotNull;
40 private final AbstractButton
input;
55 final String archetypeAttributeName =
getRef().getArchetypeAttributeName();
56 if (
input.isSelected() != (archetype.getAttributeInt(archetypeAttributeName) == 1)) {
57 return archetypeAttributeName +
" " + (
input.isSelected() ? 1 : 0);
64 public void appendSummary(@NotNull
final Document doc, @NotNull
final Style style) {
65 if (!
input.isSelected()) {
final T ref
Reference to the attribute data.
Defines types of GameObjects with corresponding attributes.
T getRef()
Returns the attribute data.
final AbstractButton input
The input ui component for editing the value.
Base package of all Gridarta classes.
String getObjectText(@NotNull final G gameObject, @NotNull final Archetype< G, A, R > archetype, @NotNull final String @NotNull[] newMsg, @NotNull final ArchetypeType archetypeType)
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).
An ArchetypeAttribute for selecting boolean values.
A single Attribute, combining an ArchetypeAttribute with its input component(s).
GameObjects are the objects based on Archetypes found on maps.
Interface for MapArchObjects.
DialogAttributeBool(@NotNull final ArchetypeAttributeBool ref, @NotNull final AbstractButton input)
Creates a new instance.
void appendSummary(@NotNull final Document doc, @NotNull final Style style)
Contains the data of one Gridarta Object-Type.