Class AutoSpellEditorKit
- java.lang.Object
-
- javax.swing.text.EditorKit
-
- javax.swing.text.DefaultEditorKit
-
- javax.swing.text.StyledEditorKit
-
- com.swabunga.spell.swing.autospell.AutoSpellEditorKit
-
- All Implemented Interfaces:
AutoSpellConstants,java.io.Serializable,java.lang.Cloneable
public class AutoSpellEditorKit extends javax.swing.text.StyledEditorKit implements AutoSpellConstants
This editorkit just forwards all method calls to the original EditorKit for all method but getAction where it also adds a "MarkAsMisspelled" action and getViewFactory where we return our own ViewFactory (Based on the original).- Author:
- Robert Gustavsson (robert@lindesign.se)
- See Also:
- Serialized Form
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class javax.swing.text.StyledEditorKit
javax.swing.text.StyledEditorKit.AlignmentAction, javax.swing.text.StyledEditorKit.BoldAction, javax.swing.text.StyledEditorKit.FontFamilyAction, javax.swing.text.StyledEditorKit.FontSizeAction, javax.swing.text.StyledEditorKit.ForegroundAction, javax.swing.text.StyledEditorKit.ItalicAction, javax.swing.text.StyledEditorKit.StyledTextAction, javax.swing.text.StyledEditorKit.UnderlineAction
-
Nested classes/interfaces inherited from class javax.swing.text.DefaultEditorKit
javax.swing.text.DefaultEditorKit.BeepAction, javax.swing.text.DefaultEditorKit.CopyAction, javax.swing.text.DefaultEditorKit.CutAction, javax.swing.text.DefaultEditorKit.DefaultKeyTypedAction, javax.swing.text.DefaultEditorKit.InsertBreakAction, javax.swing.text.DefaultEditorKit.InsertContentAction, javax.swing.text.DefaultEditorKit.InsertTabAction, javax.swing.text.DefaultEditorKit.PasteAction
-
-
Field Summary
-
Fields inherited from class javax.swing.text.DefaultEditorKit
backwardAction, 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
-
Fields inherited from interface com.swabunga.spell.swing.autospell.AutoSpellConstants
wordMisspelled, wordMisspelledTrue
-
-
Constructor Summary
Constructors Constructor Description AutoSpellEditorKit(javax.swing.text.StyledEditorKit editorKit)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.Objectclone()javax.swing.text.CaretcreateCaret()javax.swing.text.DocumentcreateDefaultDocument()voiddeinstall(javax.swing.JEditorPane c)javax.swing.Action[]getActions()javax.swing.text.ElementgetCharacterAttributeRun()java.lang.StringgetContentType()javax.swing.text.MutableAttributeSetgetInputAttributes()javax.swing.text.StyledEditorKitgetStyledEditorKit()javax.swing.text.ViewFactorygetViewFactory()voidinstall(javax.swing.JEditorPane c)voidread(java.io.InputStream in, javax.swing.text.Document doc, int pos)voidread(java.io.Reader in, javax.swing.text.Document doc, int pos)voidwrite(java.io.OutputStream out, javax.swing.text.Document doc, int pos, int len)voidwrite(java.io.Writer out, javax.swing.text.Document doc, int pos, int len)
-
-
-
Method Detail
-
getStyledEditorKit
public javax.swing.text.StyledEditorKit getStyledEditorKit()
-
clone
public java.lang.Object clone()
- Overrides:
clonein classjavax.swing.text.StyledEditorKit
-
deinstall
public void deinstall(javax.swing.JEditorPane c)
- Overrides:
deinstallin classjavax.swing.text.StyledEditorKit
-
getCharacterAttributeRun
public javax.swing.text.Element getCharacterAttributeRun()
- Overrides:
getCharacterAttributeRunin classjavax.swing.text.StyledEditorKit
-
getInputAttributes
public javax.swing.text.MutableAttributeSet getInputAttributes()
- Overrides:
getInputAttributesin classjavax.swing.text.StyledEditorKit
-
install
public void install(javax.swing.JEditorPane c)
- Overrides:
installin classjavax.swing.text.StyledEditorKit
-
getContentType
public java.lang.String getContentType()
- Overrides:
getContentTypein classjavax.swing.text.DefaultEditorKit
-
getActions
public javax.swing.Action[] getActions()
- Overrides:
getActionsin classjavax.swing.text.StyledEditorKit
-
createCaret
public javax.swing.text.Caret createCaret()
- Overrides:
createCaretin classjavax.swing.text.DefaultEditorKit
-
createDefaultDocument
public javax.swing.text.Document createDefaultDocument()
- Overrides:
createDefaultDocumentin classjavax.swing.text.StyledEditorKit
-
getViewFactory
public javax.swing.text.ViewFactory getViewFactory()
- Overrides:
getViewFactoryin classjavax.swing.text.StyledEditorKit
-
read
public void read(java.io.InputStream in, javax.swing.text.Document doc, int pos) throws java.io.IOException, javax.swing.text.BadLocationException- Overrides:
readin classjavax.swing.text.DefaultEditorKit- Throws:
java.io.IOExceptionjavax.swing.text.BadLocationException
-
write
public void write(java.io.OutputStream out, javax.swing.text.Document doc, int pos, int len) throws java.io.IOException, javax.swing.text.BadLocationException- Overrides:
writein classjavax.swing.text.DefaultEditorKit- Throws:
java.io.IOExceptionjavax.swing.text.BadLocationException
-
read
public void read(java.io.Reader in, javax.swing.text.Document doc, int pos) throws java.io.IOException, javax.swing.text.BadLocationException- Overrides:
readin classjavax.swing.text.DefaultEditorKit- Throws:
java.io.IOExceptionjavax.swing.text.BadLocationException
-
write
public void write(java.io.Writer out, javax.swing.text.Document doc, int pos, int len) throws java.io.IOException, javax.swing.text.BadLocationException- Overrides:
writein classjavax.swing.text.DefaultEditorKit- Throws:
java.io.IOExceptionjavax.swing.text.BadLocationException
-
-