public class JSyntaxKit extends StyledEditorKit implements ViewFactory
StyledEditorKit.AlignmentAction, StyledEditorKit.BoldAction, StyledEditorKit.FontFamilyAction, StyledEditorKit.FontSizeAction, StyledEditorKit.ForegroundAction, StyledEditorKit.ItalicAction, StyledEditorKit.StyledTextAction, StyledEditorKit.UnderlineActionDefaultEditorKit.BeepAction, DefaultEditorKit.CopyAction, DefaultEditorKit.CutAction, DefaultEditorKit.DefaultKeyTypedAction, DefaultEditorKit.InsertBreakAction, DefaultEditorKit.InsertContentAction, DefaultEditorKit.InsertTabAction, DefaultEditorKit.PasteActionbackwardAction, beepAction, beginAction, beginLineAction, beginParagraphAction, beginWordAction, copyAction, cutAction, defaultKeyTypedAction, deleteNextCharAction, deleteNextWordAction, deletePrevCharAction, deletePrevWordAction, downAction, endAction, endLineAction, EndOfLineStringProperty, endParagraphAction, endWordAction, forwardAction, insertBreakAction, insertContentAction, insertTabAction, nextWordAction, pageDownAction, pageUpAction, pasteAction, previousWordAction, readOnlyAction, selectAllAction, selectionBackwardAction, selectionBeginAction, selectionBeginLineAction, selectionBeginParagraphAction, selectionBeginWordAction, selectionDownAction, selectionEndAction, selectionEndLineAction, selectionEndParagraphAction, selectionEndWordAction, selectionForwardAction, selectionNextWordAction, selectionPreviousWordAction, selectionUpAction, selectLineAction, selectParagraphAction, selectWordAction, upAction, writableAction| Constructor and Description |
|---|
JSyntaxKit() |
JSyntaxKit(net.thevpc.jeep.JContext jcontext,
JSyntaxStyleManager styles)
Create a new Kit for the given language
|
| Modifier and Type | Method and Description |
|---|---|
void |
addSyntaxActions(Keymap map,
String prefix)
Add keyboard actions to this control using the Configuration we have
|
View |
create(Element element) |
Document |
createDefaultDocument()
This is called by Swing to create a Document for the JEditorPane document
This may be called before you actually get a reference to the control.
|
void |
deinstall(JEditorPane editorPane) |
protected JSyntaxStyle |
getBackgroundStyle(int ii) |
static String[] |
getContentTypes()
Return all the content types supported by this library.
|
protected JSyntaxStyle |
getForegroundStyle(int ii) |
JSyntaxStyleManager |
getStyles() |
protected JSyntaxStyle |
getTitleStyle(int ii) |
ViewFactory |
getViewFactory() |
void |
install(JEditorPane editorPane)
Install the View on the given EditorPane.
|
static void |
registerContentType(String type,
String classname)
Register the given content type to use the given class name as its kit
When this is called, an entry is added into the private HashMap of the
registered editors kits.
|
JSyntaxKit |
setJcontext(net.thevpc.jeep.JContext jcontext) |
static void |
setMenuSelectedIndex(JPopupMenu popupMenu,
int index) |
JSyntaxKit |
setStyles(JSyntaxStyleManager styles) |
clone, createInputAttributes, getActions, getCharacterAttributeRun, getInputAttributescreateCaret, getContentType, read, read, write, writepublic static final String UI_KEY_DEFAULT
public static final String UI_KEY_RESERVED_WORD
public static final String UI_KEY_RESERVED_WORD2
public static final String UI_KEY_RESERVED_WORD3
public static final String UI_KEY_COMMENTS
public static final String UI_KEY_LITERAL_STRING
public static final String UI_KEY_LITERAL_STRING2
public static final String UI_KEY_DIRECTIVE
public static final String UI_KEY_LITERAL_NUMBER
public static final String UI_KEY_SUCCESS
public static final String UI_KEY_ERROR
public static final String UI_KEY_LITERAL_DATE
public static final String UI_KEY_WARNING
public static final String UI_KEY_INFO
public static final String UI_KEY_LITERAL_REGEXP
public static final String UI_KEY_LITERAL_BOOLEAN
public static final String UI_KEY_TYPE_PRIMITIVE
public static final String UI_KEY_SEPARATOR
public static final String UI_KEY_OPERATOR
public static final String UI_KEY_FORE1
public static final String UI_KEY_FORE2
public static final String UI_KEY_FORE3
public static final String UI_KEY_FORE4
public static final String UI_KEY_FORE5
public static final String UI_KEY_FORE6
public static final String UI_KEY_FORE7
public static final String UI_KEY_FORE8
public static final String UI_KEY_FORE9
public static final String UI_KEY_FORE10
protected JSyntaxStyle STYLE_KEYWORDS
protected JSyntaxStyle STYLE_COMMENTS
protected JSyntaxStyle STYLE_STRING
protected JSyntaxStyle STYLE_NUMBERS
protected JSyntaxStyle STYLE_OPERATORS
protected JSyntaxStyle STYLE_SEPARATORS
protected JSyntaxStyle STYLE_REGEXPS
protected JSyntaxStyle STYLE_TEMPORALS
protected JSyntaxStyle STYLE_DIRECTIVES
protected JSyntaxStyle STYLE_PRIMITIVE_TYPES
protected JSyntaxStyle STYLE_BOOLEAN_LITERALS
protected JSyntaxStyle STYLE_KEYWORDS2
protected JSyntaxStyle STYLE_STRINGS
protected JSyntaxStyle STYLE_STRINGS2
protected JSyntaxStyle STYLE_TITLE1
protected JSyntaxStyle STYLE_TITLE2
protected JSyntaxStyle STYLE_TITLE3
protected JSyntaxStyle STYLE_TITLE4
protected JSyntaxStyle STYLE_TITLE5
protected JSyntaxStyle STYLE_TITLE6
protected JSyntaxStyle STYLE_TITLE7
protected JSyntaxStyle STYLE_TITLE8
protected JSyntaxStyle STYLE_TITLE9
protected JSyntaxStyle STYLE_BG1
protected JSyntaxStyle STYLE_BG2
protected JSyntaxStyle STYLE_BG3
protected JSyntaxStyle STYLE_BG4
protected JSyntaxStyle STYLE_BG5
protected JSyntaxStyle STYLE_BG6
protected JSyntaxStyle STYLE_BG7
protected JSyntaxStyle STYLE_BG8
protected JSyntaxStyle STYLE_BG9
protected JSyntaxStyle STYLE_BOLD
protected JSyntaxStyle STYLE_ITALIC
protected JSyntaxStyle STYLE_CROSS_OUT
protected JSyntaxStyle STYLE_UNDERLINE
protected JSyntaxStyle STYLE_BOLD_ITALIC
protected JSyntaxStyle STYLE_PRE
protected JSyntaxStyle STYLE_CODE
protected JSyntaxStyle STYLE_SUCCESS
protected JSyntaxStyle STYLE_ERROR
protected JSyntaxStyle STYLE_WARN
protected JSyntaxStyle STYLE_INFO
public JSyntaxKit(net.thevpc.jeep.JContext jcontext,
JSyntaxStyleManager styles)
jcontext - public JSyntaxKit()
public JSyntaxStyleManager getStyles()
public JSyntaxKit setJcontext(net.thevpc.jeep.JContext jcontext)
public JSyntaxKit setStyles(JSyntaxStyleManager styles)
public ViewFactory getViewFactory()
getViewFactory in class StyledEditorKitpublic View create(Element element)
create in interface ViewFactorypublic void install(JEditorPane editorPane)
install in class StyledEditorKiteditorPane - public void deinstall(JEditorPane editorPane)
deinstall in class StyledEditorKitpublic static void setMenuSelectedIndex(JPopupMenu popupMenu, int index)
public void addSyntaxActions(Keymap map, String prefix)
map - prefix - public Document createDefaultDocument()
createDefaultDocument in class StyledEditorKitpublic static void registerContentType(String type, String classname)
type - classname - public static String[] getContentTypes()
protected JSyntaxStyle getTitleStyle(int ii)
protected JSyntaxStyle getForegroundStyle(int ii)
protected JSyntaxStyle getBackgroundStyle(int ii)
Copyright © 2021 vpc open source initiative. All rights reserved.