Class TextConfigurer
java.lang.Object
VASSAL.configure.Configurer
VASSAL.configure.TextConfigurer
- All Implemented Interfaces:
ConfigurerFactory
A Configurer that allows multi-line string input via a JTextArea
-
Nested Class Summary
Nested classes/interfaces inherited from class VASSAL.configure.Configurer
Configurer.ContextLevel
-
Field Summary
Fields inherited from class VASSAL.configure.Configurer
changeSupport, context, contextLevel, frozen, hint, key, LIST_ENTRY_HIGHLIGHT_COLOR, name, NAME_PROPERTY, noUpdate, value
-
Constructor Summary
ConstructorDescriptionTextConfigurer
(String key, String name) TextConfigurer
(String key, String name, String val) TextConfigurer
(String key, String name, String val, boolean wrap) -
Method Summary
Modifier and TypeMethodDescriptionstatic String
Encodes a string by replacing newlines with '|' charactersgetConfigurer
(AutoConfigurable c, String key, String name) GUI interface for setting the option in an editing windowvoid
Move the cursor to the first input field of this Configurerstatic String
Restores a string by replacing '|' with newlinesvoid
Set the Object valuevoid
Set the Object value from a Stringvoid
setWordWrap
(boolean b) Methods inherited from class VASSAL.configure.Configurer
addFocusListener, addPropertyChangeListener, fireUpdate, getContext, getContextLevel, getHint, getKey, getName, getScreenSize, getValue, initCustomControls, isFrozen, isHighlighted, isPieceContext, removeFocusListener, removePropertyChangeListener, repack, repack, setContext, setContext, setContext, setContextLevel, setEnabled, setFrozen, setHighlighted, setHint, setHintKey, setLabelVisibile, setLabelVisible, setName
-
Constructor Details
-
TextConfigurer
public TextConfigurer() -
TextConfigurer
-
TextConfigurer
-
TextConfigurer
-
-
Method Details
-
getConfigurer
- Specified by:
getConfigurer
in interfaceConfigurerFactory
-
getValueString
- Specified by:
getValueString
in classConfigurer
- Returns:
- a String representation of the Object value
-
setWordWrap
public void setWordWrap(boolean b) -
escapeNewlines
-
setValue
Description copied from class:Configurer
Set the Object value from a String- Specified by:
setValue
in classConfigurer
-
setValue
Description copied from class:Configurer
Set the Object value- Overrides:
setValue
in classConfigurer
-
restoreNewlines
-
requestFocus
public void requestFocus()Description copied from class:Configurer
Move the cursor to the first input field of this Configurer- Overrides:
requestFocus
in classConfigurer
-
getControls
Description copied from class:Configurer
GUI interface for setting the option in an editing window- Specified by:
getControls
in classConfigurer
-