Package nl.siegmann.epublib.viewer
Class MyHtmlEditorKit
- java.lang.Object
-
- javax.swing.text.EditorKit
-
- javax.swing.text.DefaultEditorKit
-
- javax.swing.text.StyledEditorKit
-
- javax.swing.text.html.HTMLEditorKit
-
- nl.siegmann.epublib.viewer.MyHtmlEditorKit
-
- All Implemented Interfaces:
java.io.Serializable,java.lang.Cloneable,javax.accessibility.Accessible
class MyHtmlEditorKit extends javax.swing.text.html.HTMLEditorKitWraps a HTMLEditorKit so we can make getParser() public.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class javax.swing.text.html.HTMLEditorKit
javax.swing.text.html.HTMLEditorKit.HTMLFactory, javax.swing.text.html.HTMLEditorKit.HTMLTextAction, javax.swing.text.html.HTMLEditorKit.InsertHTMLTextAction, javax.swing.text.html.HTMLEditorKit.LinkController, javax.swing.text.html.HTMLEditorKit.Parser, javax.swing.text.html.HTMLEditorKit.ParserCallback
-
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 Modifier and Type Field Description private javax.swing.text.html.HTMLEditorKithtmlEditorKit-
Fields inherited from class javax.swing.text.html.HTMLEditorKit
BOLD_ACTION, COLOR_ACTION, DEFAULT_CSS, FONT_CHANGE_BIGGER, FONT_CHANGE_SMALLER, IMG_ALIGN_BOTTOM, IMG_ALIGN_MIDDLE, IMG_ALIGN_TOP, IMG_BORDER, ITALIC_ACTION, LOGICAL_STYLE_ACTION, PARA_INDENT_LEFT, PARA_INDENT_RIGHT
-
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
-
-
Constructor Summary
Constructors Constructor Description MyHtmlEditorKit(javax.swing.text.html.HTMLEditorKit htmlEditorKit)
-
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)booleanequals(java.lang.Object obj)javax.accessibility.AccessibleContextgetAccessibleContext()javax.swing.Action[]getActions()javax.swing.text.ElementgetCharacterAttributeRun()java.lang.StringgetContentType()java.awt.CursorgetDefaultCursor()javax.swing.text.MutableAttributeSetgetInputAttributes()java.awt.CursorgetLinkCursor()javax.swing.text.html.HTMLEditorKit.ParsergetParser()javax.swing.text.html.StyleSheetgetStyleSheet()javax.swing.text.ViewFactorygetViewFactory()inthashCode()voidinsertHTML(javax.swing.text.html.HTMLDocument doc, int offset, java.lang.String html, int popDepth, int pushDepth, javax.swing.text.html.HTML.Tag insertTag)voidinstall(javax.swing.JEditorPane c)booleanisAutoFormSubmission()voidread(java.io.InputStream in, javax.swing.text.Document doc, int pos)voidread(java.io.Reader in, javax.swing.text.Document doc, int pos)voidsetAutoFormSubmission(boolean isAuto)voidsetDefaultCursor(java.awt.Cursor cursor)voidsetLinkCursor(java.awt.Cursor cursor)voidsetStyleSheet(javax.swing.text.html.StyleSheet s)java.lang.StringtoString()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
-
getParser
public javax.swing.text.html.HTMLEditorKit.Parser getParser()
- Overrides:
getParserin classjavax.swing.text.html.HTMLEditorKit
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
getCharacterAttributeRun
public javax.swing.text.Element getCharacterAttributeRun()
- Overrides:
getCharacterAttributeRunin classjavax.swing.text.StyledEditorKit
-
createCaret
public javax.swing.text.Caret createCaret()
- Overrides:
createCaretin classjavax.swing.text.DefaultEditorKit
-
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
-
equals
public boolean equals(java.lang.Object obj)
- Overrides:
equalsin classjava.lang.Object
-
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
-
getContentType
public java.lang.String getContentType()
- Overrides:
getContentTypein classjavax.swing.text.html.HTMLEditorKit
-
getViewFactory
public javax.swing.text.ViewFactory getViewFactory()
- Overrides:
getViewFactoryin classjavax.swing.text.html.HTMLEditorKit
-
createDefaultDocument
public javax.swing.text.Document createDefaultDocument()
- Overrides:
createDefaultDocumentin classjavax.swing.text.html.HTMLEditorKit
-
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.html.HTMLEditorKit- Throws:
java.io.IOExceptionjavax.swing.text.BadLocationException
-
insertHTML
public void insertHTML(javax.swing.text.html.HTMLDocument doc, int offset, java.lang.String html, int popDepth, int pushDepth, javax.swing.text.html.HTML.Tag insertTag) throws javax.swing.text.BadLocationException, java.io.IOException- Overrides:
insertHTMLin classjavax.swing.text.html.HTMLEditorKit- Throws:
javax.swing.text.BadLocationExceptionjava.io.IOException
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
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.html.HTMLEditorKit- Throws:
java.io.IOExceptionjavax.swing.text.BadLocationException
-
install
public void install(javax.swing.JEditorPane c)
- Overrides:
installin classjavax.swing.text.html.HTMLEditorKit
-
deinstall
public void deinstall(javax.swing.JEditorPane c)
- Overrides:
deinstallin classjavax.swing.text.html.HTMLEditorKit
-
setStyleSheet
public void setStyleSheet(javax.swing.text.html.StyleSheet s)
- Overrides:
setStyleSheetin classjavax.swing.text.html.HTMLEditorKit
-
getStyleSheet
public javax.swing.text.html.StyleSheet getStyleSheet()
- Overrides:
getStyleSheetin classjavax.swing.text.html.HTMLEditorKit
-
getActions
public javax.swing.Action[] getActions()
- Overrides:
getActionsin classjavax.swing.text.html.HTMLEditorKit
-
getInputAttributes
public javax.swing.text.MutableAttributeSet getInputAttributes()
- Overrides:
getInputAttributesin classjavax.swing.text.html.HTMLEditorKit
-
setDefaultCursor
public void setDefaultCursor(java.awt.Cursor cursor)
- Overrides:
setDefaultCursorin classjavax.swing.text.html.HTMLEditorKit
-
getDefaultCursor
public java.awt.Cursor getDefaultCursor()
- Overrides:
getDefaultCursorin classjavax.swing.text.html.HTMLEditorKit
-
setLinkCursor
public void setLinkCursor(java.awt.Cursor cursor)
- Overrides:
setLinkCursorin classjavax.swing.text.html.HTMLEditorKit
-
getLinkCursor
public java.awt.Cursor getLinkCursor()
- Overrides:
getLinkCursorin classjavax.swing.text.html.HTMLEditorKit
-
isAutoFormSubmission
public boolean isAutoFormSubmission()
- Overrides:
isAutoFormSubmissionin classjavax.swing.text.html.HTMLEditorKit
-
setAutoFormSubmission
public void setAutoFormSubmission(boolean isAuto)
- Overrides:
setAutoFormSubmissionin classjavax.swing.text.html.HTMLEditorKit
-
clone
public java.lang.Object clone()
- Overrides:
clonein classjavax.swing.text.html.HTMLEditorKit
-
getAccessibleContext
public javax.accessibility.AccessibleContext getAccessibleContext()
- Specified by:
getAccessibleContextin interfacejavax.accessibility.Accessible- Overrides:
getAccessibleContextin classjavax.swing.text.html.HTMLEditorKit
-
-