Package kiyut.swing.text.xml
Class XMLContext
- java.lang.Object
-
- javax.swing.text.StyleContext
-
- kiyut.swing.text.xml.XMLContext
-
- All Implemented Interfaces:
Serializable,AbstractDocument.AttributeContext
public class XMLContext extends StyleContext
A pool of styles and their associated resources- Author:
- KIYUT
- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class javax.swing.text.StyleContext
StyleContext.NamedStyle, StyleContext.SmallAttributeSet
-
-
Field Summary
Fields Modifier and Type Field Description static StringATTRIBUTE_NAME_STYLEstatic StringATTRIBUTE_VALUE_STYLEstatic StringCDATA_STYLEstatic StringCHARACTER_DATA_STYLEstatic StringCOMMENT_STYLEstatic StringDOCTYPE_STYLEstatic StringELEMENT_STYLEprotected Map<String,Font>syntaxFontMapsyntax font mapprotected Map<String,Color>syntaxForegroundMapsyntax foreground mapprotected inttabWidthstatic StringXML_DECLARATION_STYLE-
Fields inherited from class javax.swing.text.StyleContext
DEFAULT_STYLE
-
-
Constructor Summary
Constructors Constructor Description XMLContext()XMLContext(Map<String,Font> syntaxFontMap, Map<String,Color> syntaxForegroundMap)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description FontgetSyntaxFont(int ctx)FontgetSyntaxFont(String name)ColorgetSyntaxForeground(int ctx)ColorgetSyntaxForeground(String name)StringgetSyntaxName(int ctx)intgetTabWidth()voidsetSyntaxFont(Map<String,Font> syntaxFontMap)voidsetSyntaxForeground(Map<String,Color> syntaxForegroundMap)voidsetTabWidth(int width)-
Methods inherited from class javax.swing.text.StyleContext
addAttribute, addAttributes, addChangeListener, addStyle, createLargeAttributeSet, createSmallAttributeSet, getBackground, getChangeListeners, getCompressionThreshold, getDefaultStyleContext, getEmptySet, getFont, getFont, getFontMetrics, getForeground, getStaticAttribute, getStaticAttributeKey, getStyle, getStyleNames, readAttributes, readAttributeSet, reclaim, registerStaticAttributeKey, removeAttribute, removeAttributes, removeAttributes, removeChangeListener, removeStyle, toString, writeAttributes, writeAttributeSet
-
-
-
-
Field Detail
-
XML_DECLARATION_STYLE
public static final String XML_DECLARATION_STYLE
- See Also:
- Constant Field Values
-
DOCTYPE_STYLE
public static final String DOCTYPE_STYLE
- See Also:
- Constant Field Values
-
COMMENT_STYLE
public static final String COMMENT_STYLE
- See Also:
- Constant Field Values
-
ELEMENT_STYLE
public static final String ELEMENT_STYLE
- See Also:
- Constant Field Values
-
CHARACTER_DATA_STYLE
public static final String CHARACTER_DATA_STYLE
- See Also:
- Constant Field Values
-
ATTRIBUTE_NAME_STYLE
public static final String ATTRIBUTE_NAME_STYLE
- See Also:
- Constant Field Values
-
ATTRIBUTE_VALUE_STYLE
public static final String ATTRIBUTE_VALUE_STYLE
- See Also:
- Constant Field Values
-
CDATA_STYLE
public static final String CDATA_STYLE
- See Also:
- Constant Field Values
-
tabWidth
protected int tabWidth
-
-