JavaTM 2 Platform
Std. Ed. v1.3

javax.swing.text.html
クラス HTMLEditorKit.HTMLTextAction

java.lang.Object
  |
  +--javax.swing.AbstractAction
        |
        +--javax.swing.text.TextAction
              |
              +--javax.swing.text.StyledEditorKit.StyledTextAction
                    |
                    +--javax.swing.text.html.HTMLEditorKit.HTMLTextAction
すべての実装インタフェース:
Action, ActionListener, Cloneable, EventListener, Serializable
直系の既知のサブクラス:
HTMLEditorKit.InsertHTMLTextAction
含まれているクラス:
HTMLEditorKit

public abstract static class HTMLEditorKit.HTMLTextAction
extends StyledEditorKit.StyledTextAction

既存のドキュメントに HTML を挿入するために使用する各種の簡易メソッドを提供する、抽象 Action です。

注: 簡易メソッドは、ドキュメントのロックを取得しません。他のスレッドがテキストを変更している場合、これらのメソッドの動作の一貫性は保証されず、誤った値を返すことがあります。

関連項目:
直列化された形式

クラス javax.swing.AbstractAction から継承したフィールド
changeSupport, enabled
 
インタフェース javax.swing.Action から継承したフィールド
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SHORT_DESCRIPTION, SMALL_ICON
 
コンストラクタの概要
HTMLEditorKit.HTMLTextAction(String name)
           
 
メソッドの概要
protected  int elementCountToTag(HTMLDocument doc, int offset, HTML.Tag tag)
          もっとも深い葉を始点として、tag を表す要素に至るまでに必要な要素の数を返します。
protected  Element findElementMatchingTag(HTMLDocument doc, int offset, HTML.Tag tag)
          offset の位置で、 tag に一致するもっとも深い要素を返します。
protected  Element[] getElementsAt(HTMLDocument doc, int offset)
          offset が格納されている Element の配列を返します。
protected  HTMLDocument getHTMLDocument(JEditorPane e)
           
protected  HTMLEditorKit getHTMLEditorKit(JEditorPane e)
           
 
クラス javax.swing.text.StyledEditorKit.StyledTextAction から継承したメソッド
getEditor, getStyledDocument, getStyledEditorKit, setCharacterAttributes, setParagraphAttributes
 
クラス javax.swing.text.TextAction から継承したメソッド
augmentList, getFocusedComponent, getTextComponent
 
クラス javax.swing.AbstractAction から継承したメソッド
addPropertyChangeListener, clone, firePropertyChange, getKeys, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
 
クラス java.lang.Object から継承したメソッド
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
インタフェース java.awt.event.ActionListener から継承したメソッド
actionPerformed
 

コンストラクタの詳細

HTMLEditorKit.HTMLTextAction

public HTMLEditorKit.HTMLTextAction(String name)
メソッドの詳細

getHTMLDocument

protected HTMLDocument getHTMLDocument(JEditorPane e)
戻り値:
e の HTMLDocument

getHTMLEditorKit

protected HTMLEditorKit getHTMLEditorKit(JEditorPane e)
戻り値:
e で使用する HTMLEditorKit

getElementsAt

protected Element[] getElementsAt(HTMLDocument doc,
                                  int offset)
offset が格納されている Element の配列を返します。最初の要素が root に相当します。

elementCountToTag

protected int elementCountToTag(HTMLDocument doc,
                                int offset,
                                HTML.Tag tag)
もっとも深い葉を始点として、tag を表す要素に至るまでに必要な要素の数を返します。tag を表す要素が見つからない場合は -1 を返し、offset にある葉の親が tag を表す場合は 0 を返します。

findElementMatchingTag

protected Element findElementMatchingTag(HTMLDocument doc,
                                         int offset,
                                         HTML.Tag tag)
offset の位置で、 tag に一致するもっとも深い要素を返します。

JavaTM 2 Platform
Std. Ed. v1.3

バグや機能要求の報告
さらに詳しい API リファレンスおよび開発者ドキュメントについては、 Java 2 SDK SE Developer Documentation を参照してください。このドキュメントには、概念、用語の定義、回避策、 実用的なコード例など、開発者を対象にした詳細な解説が掲載されています。

Java、Java 2D、JDBC は、米国およびその他の国における米国 Sun Microsystems, Inc. の商標もしくは登録商標です。
Copyright 1993-2000 Sun Microsystems, Inc. 901 San Antonio Road,
Palo Alto, California, 94303, U.S.A. All Rights Reserved.