public static class Options.MultipleLineStringOption extends Options.Option<String,JScrollPane>
Options.StringOptionXMLSerializable.OldVersionCompatible, XMLSerializable.VersionSupportTypeROOT_ELEMENT_NAME| Modifier | Constructor and Description |
|---|---|
protected |
Options.MultipleLineStringOption(org.jdom.Element element)
Constructor for XML Serialization.
|
protected |
Options.MultipleLineStringOption(String name,
String label,
String defaultValue,
int rows,
boolean lineWrap)
Construct a new MultipleLineStringOption
|
| Modifier and Type | Method and Description |
|---|---|
protected JScrollPane |
createComponent()
Create a graphical component representing this option.
|
String |
getValueFromString(String value)
Convert a String into an instance of the object type used by this option.
|
void |
setFixedWidthFont(boolean fixedWidth)
Set whether the font in the text area should be fixed width
|
protected void |
setValueOnComponent(JScrollPane component,
String value)
Set the value on this component.
|
org.jdom.Element |
toXML()
Convert object to a JDOM element.
|
addChangeListener, addChildOptionsDependent, addDependent, fromXML, generateValidValue, getComponent, getDefaultValue, getDescription, getDescriptionAndState, getDisplayedLabel, getExtraPersistentInformation, getLabel, getName, getParentOptions, getPossibleValues, getValue, getValueAsString, getValueAsString, getVerticalWeight, handleSetEnabled, hideWarningMessage, isAdvanced, isEnabled, isFillHorizontalSpace, isProOnly, isRestoreDefaultApplies, isRestorePreferenceApplies, isSpanningComponent, isVisible, moveToOptions, removeChangeListener, restoreDefault, setAdvanced, setAlwaysUsesDefaultPreferenceLocation, setDefaultValue, setDescription, setDisabledValue, setEnabled, setExtraPersistentInformation, setFillHorizontalSpace, setHidden, setLabelComponent, setPreferredHeight, setPreferredWidth, setProOnly, setRestoreDefaultApplies, setRestorePreferenceApplies, setShouldSaveValue, setSpanningComponent, setValue, setValue, setValueFromString, setVerticalWeight, setVisible, setWarningMessage, shouldSaveValue, toStringprotected Options.MultipleLineStringOption(org.jdom.Element element)
throws XMLSerializationException
XMLSerializableXMLSerializationExceptionprotected Options.MultipleLineStringOption(String name, String label, String defaultValue, int rows, boolean lineWrap)
name - the name to be used for referencing this option. For example from scripts or source code which wish to programmatically get or set the value of this option.label - a label describing this option to be displayed to the user. eg. "My Awesome Option"defaultValue - the default value for this optionrows - the number of rows in the text area when displayed to the userlineWrap - true if long lines should be wrapped when the text area is displayed to the userpublic org.jdom.Element toXML()
XMLSerializableXMLSerializable.fromXML(org.jdom.Element) can completely
restore the objects representation.
It is recommended that the returned element use XMLSerializable.ROOT_ELEMENT_NAME as its name,
in which case it must not define an attribute called "type". In this case,
fromXML, will be called with an element whose name may differ from the element
return from this function. This recommendation allows a more compact representation
of the XML can be stored.
This method generally should not be called directly. Instead, you should usually call
XMLSerializer.classToXML(String, XMLSerializable)
which calls this method internally.
PluginDocument implementations of this method may choose to throw an XMLSerializationException,
enclosed in a RuntimeException.toXML in interface XMLSerializabletoXML in class Options.Option<String,JScrollPane>public void setFixedWidthFont(boolean fixedWidth)
fixedWidth - whether the font in the text area should be fixed width. The default behaviour is not fixed widthpublic String getValueFromString(String value)
Options.OptionOptions.Option.getValueAsString(Object) .getValueFromString in class Options.Option<String,JScrollPane>value - the string representation of the object valueprotected void setValueOnComponent(JScrollPane component, String value)
Options.OptionsetValueOnComponent in class Options.Option<String,JScrollPane>component - a component return from Options.Option.createComponent()value - the value to set.protected JScrollPane createComponent()
Options.OptionOptions.Option.getValue().
The implementation is also responsible for making sure that the returned component
listens to any changes made to itself and
reflects those changes in the value of this option
using the Options.Option.setValue(Object) method.
This method will only be called once for each instance of an Option.
After it has been called, getComponent() will return a cached copy of it.createComponent in class Options.Option<String,JScrollPane>