javax.swing.text
Class JTextComponent.AccessibleJTextComponent

java.lang.Object sample code for java.lang.Object definition code for java.lang.Object 
  extended by javax.accessibility.AccessibleContext sample code for javax.accessibility.AccessibleContext definition code for javax.accessibility.AccessibleContext 
      extended by java.awt.Component.AccessibleAWTComponent sample code for java.awt.Component.AccessibleAWTComponent definition code for java.awt.Component.AccessibleAWTComponent 
          extended by java.awt.Container.AccessibleAWTContainer sample code for java.awt.Container.AccessibleAWTContainer definition code for java.awt.Container.AccessibleAWTContainer 
              extended by javax.swing.JComponent.AccessibleJComponent sample code for javax.swing.JComponent.AccessibleJComponent definition code for javax.swing.JComponent.AccessibleJComponent 
                  extended by javax.swing.text.JTextComponent.AccessibleJTextComponent
All Implemented Interfaces:
Serializable sample code for java.io.Serializable definition code for java.io.Serializable , EventListener sample code for java.util.EventListener definition code for java.util.EventListener , AccessibleAction sample code for javax.accessibility.AccessibleAction definition code for javax.accessibility.AccessibleAction , AccessibleComponent sample code for javax.accessibility.AccessibleComponent definition code for javax.accessibility.AccessibleComponent , AccessibleEditableText sample code for javax.accessibility.AccessibleEditableText definition code for javax.accessibility.AccessibleEditableText , AccessibleExtendedComponent sample code for javax.accessibility.AccessibleExtendedComponent definition code for javax.accessibility.AccessibleExtendedComponent , AccessibleText sample code for javax.accessibility.AccessibleText definition code for javax.accessibility.AccessibleText , CaretListener sample code for javax.swing.event.CaretListener definition code for javax.swing.event.CaretListener , DocumentListener sample code for javax.swing.event.DocumentListener definition code for javax.swing.event.DocumentListener
Direct Known Subclasses:
JEditorPane.AccessibleJEditorPane sample code for javax.swing.JEditorPane.AccessibleJEditorPane definition code for javax.swing.JEditorPane.AccessibleJEditorPane , JTextArea.AccessibleJTextArea sample code for javax.swing.JTextArea.AccessibleJTextArea definition code for javax.swing.JTextArea.AccessibleJTextArea , JTextField.AccessibleJTextField sample code for javax.swing.JTextField.AccessibleJTextField definition code for javax.swing.JTextField.AccessibleJTextField
Enclosing class:
JTextComponent sample code for javax.swing.text.JTextComponent definition code for javax.swing.text.JTextComponent

public class JTextComponent.AccessibleJTextComponent
extends JComponent.AccessibleJComponent sample code for javax.swing.JComponent.AccessibleJComponent definition code for javax.swing.JComponent.AccessibleJComponent
implements AccessibleText sample code for javax.accessibility.AccessibleText definition code for javax.accessibility.AccessibleText , CaretListener sample code for javax.swing.event.CaretListener definition code for javax.swing.event.CaretListener , DocumentListener sample code for javax.swing.event.DocumentListener definition code for javax.swing.event.DocumentListener , AccessibleAction sample code for javax.accessibility.AccessibleAction definition code for javax.accessibility.AccessibleAction , AccessibleEditableText sample code for javax.accessibility.AccessibleEditableText definition code for javax.accessibility.AccessibleEditableText

This class implements accessibility support for the JTextComponent class. It provides an implementation of the Java Accessibility API appropriate to menu user-interface elements.

Warning: Serialized objects of this class will not be compatible with future Swing releases. The current serialization support is appropriate for short term storage or RMI between applications running the same version of Swing. As of 1.4, support for long term storage of all JavaBeansTM has been added to the java.beans package. Please see XMLEncoder sample code for java.beans.XMLEncoder definition code for java.beans.XMLEncoder .

See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class javax.swing.JComponent.AccessibleJComponent sample code for javax.swing.JComponent.AccessibleJComponent definition code for javax.swing.JComponent.AccessibleJComponent
JComponent.AccessibleJComponent.AccessibleContainerHandler sample code for javax.swing.JComponent.AccessibleJComponent.AccessibleContainerHandler definition code for javax.swing.JComponent.AccessibleJComponent.AccessibleContainerHandler , JComponent.AccessibleJComponent.AccessibleFocusHandler sample code for javax.swing.JComponent.AccessibleJComponent.AccessibleFocusHandler definition code for javax.swing.JComponent.AccessibleJComponent.AccessibleFocusHandler
 
Nested classes/interfaces inherited from class java.awt.Component.AccessibleAWTComponent sample code for java.awt.Component.AccessibleAWTComponent definition code for java.awt.Component.AccessibleAWTComponent
Component.AccessibleAWTComponent.AccessibleAWTComponentHandler sample code for java.awt.Component.AccessibleAWTComponent.AccessibleAWTComponentHandler definition code for java.awt.Component.AccessibleAWTComponent.AccessibleAWTComponentHandler , Component.AccessibleAWTComponent.AccessibleAWTFocusHandler sample code for java.awt.Component.AccessibleAWTComponent.AccessibleAWTFocusHandler definition code for java.awt.Component.AccessibleAWTComponent.AccessibleAWTFocusHandler
 
Field Summary
 
Fields inherited from class javax.swing.JComponent.AccessibleJComponent sample code for javax.swing.JComponent.AccessibleJComponent definition code for javax.swing.JComponent.AccessibleJComponent
accessibleContainerHandler sample code for javax.swing.JComponent.AccessibleJComponent.accessibleContainerHandler definition code for javax.swing.JComponent.AccessibleJComponent.accessibleContainerHandler , accessibleFocusHandler sample code for javax.swing.JComponent.AccessibleJComponent.accessibleFocusHandler definition code for javax.swing.JComponent.AccessibleJComponent.accessibleFocusHandler
 
Fields inherited from class java.awt.Component.AccessibleAWTComponent sample code for java.awt.Component.AccessibleAWTComponent definition code for java.awt.Component.AccessibleAWTComponent
accessibleAWTComponentHandler sample code for java.awt.Component.AccessibleAWTComponent.accessibleAWTComponentHandler definition code for java.awt.Component.AccessibleAWTComponent.accessibleAWTComponentHandler , accessibleAWTFocusHandler sample code for java.awt.Component.AccessibleAWTComponent.accessibleAWTFocusHandler definition code for java.awt.Component.AccessibleAWTComponent.accessibleAWTFocusHandler
 
Fields inherited from class javax.accessibility.AccessibleContext sample code for javax.accessibility.AccessibleContext definition code for javax.accessibility.AccessibleContext
ACCESSIBLE_ACTION_PROPERTY sample code for javax.accessibility.AccessibleContext.ACCESSIBLE_ACTION_PROPERTY definition code for javax.accessibility.AccessibleContext.ACCESSIBLE_ACTION_PROPERTY , ACCESSIBLE_ACTIVE_DESCENDANT_PROPERTY sample code for javax.accessibility.AccessibleContext.ACCESSIBLE_ACTIVE_DESCENDANT_PROPERTY definition code for javax.accessibility.AccessibleContext.ACCESSIBLE_ACTIVE_DESCENDANT_PROPERTY , ACCESSIBLE_CARET_PROPERTY sample code for javax.accessibility.AccessibleContext.ACCESSIBLE_CARET_PROPERTY definition code for javax.accessibility.AccessibleContext.ACCESSIBLE_CARET_PROPERTY , ACCESSIBLE_CHILD_PROPERTY sample code for javax.accessibility.AccessibleContext.ACCESSIBLE_CHILD_PROPERTY definition code for javax.accessibility.AccessibleContext.ACCESSIBLE_CHILD_PROPERTY , ACCESSIBLE_COMPONENT_BOUNDS_CHANGED sample code for javax.accessibility.AccessibleContext.ACCESSIBLE_COMPONENT_BOUNDS_CHANGED definition code for javax.accessibility.AccessibleContext.ACCESSIBLE_COMPONENT_BOUNDS_CHANGED , ACCESSIBLE_DESCRIPTION_PROPERTY sample code for javax.accessibility.AccessibleContext.ACCESSIBLE_DESCRIPTION_PROPERTY definition code for javax.accessibility.AccessibleContext.ACCESSIBLE_DESCRIPTION_PROPERTY , ACCESSIBLE_HYPERTEXT_OFFSET sample code for javax.accessibility.AccessibleContext.ACCESSIBLE_HYPERTEXT_OFFSET definition code for javax.accessibility.AccessibleContext.ACCESSIBLE_HYPERTEXT_OFFSET , ACCESSIBLE_INVALIDATE_CHILDREN sample code for javax.accessibility.AccessibleContext.ACCESSIBLE_INVALIDATE_CHILDREN definition code for javax.accessibility.AccessibleContext.ACCESSIBLE_INVALIDATE_CHILDREN , ACCESSIBLE_NAME_PROPERTY sample code for javax.accessibility.AccessibleContext.ACCESSIBLE_NAME_PROPERTY definition code for javax.accessibility.AccessibleContext.ACCESSIBLE_NAME_PROPERTY , ACCESSIBLE_SELECTION_PROPERTY sample code for javax.accessibility.AccessibleContext.ACCESSIBLE_SELECTION_PROPERTY definition code for javax.accessibility.AccessibleContext.ACCESSIBLE_SELECTION_PROPERTY , ACCESSIBLE_STATE_PROPERTY sample code for javax.accessibility.AccessibleContext.ACCESSIBLE_STATE_PROPERTY definition code for javax.accessibility.AccessibleContext.ACCESSIBLE_STATE_PROPERTY , ACCESSIBLE_TABLE_CAPTION_CHANGED sample code for javax.accessibility.AccessibleContext.ACCESSIBLE_TABLE_CAPTION_CHANGED definition code for javax.accessibility.AccessibleContext.ACCESSIBLE_TABLE_CAPTION_CHANGED , ACCESSIBLE_TABLE_COLUMN_DESCRIPTION_CHANGED sample code for javax.accessibility.AccessibleContext.ACCESSIBLE_TABLE_COLUMN_DESCRIPTION_CHANGED definition code for javax.accessibility.AccessibleContext.ACCESSIBLE_TABLE_COLUMN_DESCRIPTION_CHANGED , ACCESSIBLE_TABLE_COLUMN_HEADER_CHANGED sample code for javax.accessibility.AccessibleContext.ACCESSIBLE_TABLE_COLUMN_HEADER_CHANGED definition code for javax.accessibility.AccessibleContext.ACCESSIBLE_TABLE_COLUMN_HEADER_CHANGED , ACCESSIBLE_TABLE_MODEL_CHANGED sample code for javax.accessibility.AccessibleContext.ACCESSIBLE_TABLE_MODEL_CHANGED definition code for javax.accessibility.AccessibleContext.ACCESSIBLE_TABLE_MODEL_CHANGED , ACCESSIBLE_TABLE_ROW_DESCRIPTION_CHANGED sample code for javax.accessibility.AccessibleContext.ACCESSIBLE_TABLE_ROW_DESCRIPTION_CHANGED definition code for javax.accessibility.AccessibleContext.ACCESSIBLE_TABLE_ROW_DESCRIPTION_CHANGED , ACCESSIBLE_TABLE_ROW_HEADER_CHANGED sample code for javax.accessibility.AccessibleContext.ACCESSIBLE_TABLE_ROW_HEADER_CHANGED definition code for javax.accessibility.AccessibleContext.ACCESSIBLE_TABLE_ROW_HEADER_CHANGED , ACCESSIBLE_TABLE_SUMMARY_CHANGED sample code for javax.accessibility.AccessibleContext.ACCESSIBLE_TABLE_SUMMARY_CHANGED definition code for javax.accessibility.AccessibleContext.ACCESSIBLE_TABLE_SUMMARY_CHANGED , ACCESSIBLE_TEXT_ATTRIBUTES_CHANGED sample code for javax.accessibility.AccessibleContext.ACCESSIBLE_TEXT_ATTRIBUTES_CHANGED definition code for javax.accessibility.AccessibleContext.ACCESSIBLE_TEXT_ATTRIBUTES_CHANGED , ACCESSIBLE_TEXT_PROPERTY sample code for javax.accessibility.AccessibleContext.ACCESSIBLE_TEXT_PROPERTY definition code for javax.accessibility.AccessibleContext.ACCESSIBLE_TEXT_PROPERTY , ACCESSIBLE_VALUE_PROPERTY sample code for javax.accessibility.AccessibleContext.ACCESSIBLE_VALUE_PROPERTY definition code for javax.accessibility.AccessibleContext.ACCESSIBLE_VALUE_PROPERTY , ACCESSIBLE_VISIBLE_DATA_PROPERTY sample code for javax.accessibility.AccessibleContext.ACCESSIBLE_VISIBLE_DATA_PROPERTY definition code for javax.accessibility.AccessibleContext.ACCESSIBLE_VISIBLE_DATA_PROPERTY , accessibleDescription sample code for javax.accessibility.AccessibleContext.accessibleDescription definition code for javax.accessibility.AccessibleContext.accessibleDescription , accessibleName sample code for javax.accessibility.AccessibleContext.accessibleName definition code for javax.accessibility.AccessibleContext.accessibleName , accessibleParent sample code for javax.accessibility.AccessibleContext.accessibleParent definition code for javax.accessibility.AccessibleContext.accessibleParent
 
Fields inherited from interface javax.accessibility.AccessibleAction sample code for javax.accessibility.AccessibleAction definition code for javax.accessibility.AccessibleAction
DECREMENT sample code for javax.accessibility.AccessibleAction.DECREMENT definition code for javax.accessibility.AccessibleAction.DECREMENT , INCREMENT sample code for javax.accessibility.AccessibleAction.INCREMENT definition code for javax.accessibility.AccessibleAction.INCREMENT , TOGGLE_EXPAND sample code for javax.accessibility.AccessibleAction.TOGGLE_EXPAND definition code for javax.accessibility.AccessibleAction.TOGGLE_EXPAND
 
Constructor Summary
JTextComponent.AccessibleJTextComponent sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.JTextComponent.AccessibleJTextComponent() definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.JTextComponent.AccessibleJTextComponent() ()
          Constructs an AccessibleJTextComponent.
 
Method Summary
 void caretUpdate sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.caretUpdate(javax.swing.event.CaretEvent) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.caretUpdate(javax.swing.event.CaretEvent) (CaretEvent sample code for javax.swing.event.CaretEvent definition code for javax.swing.event.CaretEvent  e)
          Handles caret updates (fire appropriate property change event, which are AccessibleContext.ACCESSIBLE_CARET_PROPERTY and AccessibleContext.ACCESSIBLE_SELECTION_PROPERTY).
 void changedUpdate sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.changedUpdate(javax.swing.event.DocumentEvent) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.changedUpdate(javax.swing.event.DocumentEvent) (DocumentEvent sample code for javax.swing.event.DocumentEvent definition code for javax.swing.event.DocumentEvent  e)
          Handles document remove (fire appropriate property change event, which is AccessibleContext.ACCESSIBLE_TEXT_PROPERTY).
 void cut sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.cut(int, int) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.cut(int, int) (int startIndex, int endIndex)
          Cuts the text between two indices into the system clipboard.
 void delete sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.delete(int, int) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.delete(int, int) (int startIndex, int endIndex)
          Deletes the text between two indices
 boolean doAccessibleAction sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.doAccessibleAction(int) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.doAccessibleAction(int) (int i)
          Performs the specified Action on the object
 AccessibleAction sample code for javax.accessibility.AccessibleAction definition code for javax.accessibility.AccessibleAction getAccessibleAction sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleAction() definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleAction() ()
          Gets the AccessibleAction associated with this object that supports one or more actions.
 int getAccessibleActionCount sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleActionCount() definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleActionCount() ()
          Returns the number of accessible actions available in this object If there are more than one, the first one is considered the "default" action of the object.
 String sample code for java.lang.String definition code for java.lang.String getAccessibleActionDescription sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleActionDescription(int) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleActionDescription(int) (int i)
          Returns a description of the specified action of the object.
 AccessibleEditableText sample code for javax.accessibility.AccessibleEditableText definition code for javax.accessibility.AccessibleEditableText getAccessibleEditableText sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleEditableText() definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleEditableText() ()
          Returns the AccessibleEditableText interface for this text component.
 AccessibleRole sample code for javax.accessibility.AccessibleRole definition code for javax.accessibility.AccessibleRole getAccessibleRole sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleRole() definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleRole() ()
          Gets the role of this object.
 AccessibleStateSet sample code for javax.accessibility.AccessibleStateSet definition code for javax.accessibility.AccessibleStateSet getAccessibleStateSet sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleStateSet() definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleStateSet() ()
          Gets the state set of the JTextComponent.
 AccessibleText sample code for javax.accessibility.AccessibleText definition code for javax.accessibility.AccessibleText getAccessibleText sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleText() definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleText() ()
          Get the AccessibleText associated with this object.
 String sample code for java.lang.String definition code for java.lang.String getAfterIndex sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAfterIndex(int, int) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAfterIndex(int, int) (int part, int index)
          Returns the String after a given index.
 String sample code for java.lang.String definition code for java.lang.String getAtIndex sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAtIndex(int, int) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAtIndex(int, int) (int part, int index)
          Returns the String at a given index.
 String sample code for java.lang.String definition code for java.lang.String getBeforeIndex sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getBeforeIndex(int, int) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getBeforeIndex(int, int) (int part, int index)
          Returns the String before a given index.
 int getCaretPosition sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getCaretPosition() definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getCaretPosition() ()
          Returns the zero-based offset of the caret.
 AttributeSet sample code for javax.swing.text.AttributeSet definition code for javax.swing.text.AttributeSet getCharacterAttribute sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getCharacterAttribute(int) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getCharacterAttribute(int) (int i)
          Returns the AttributeSet for a given character (at a given index).
 Rectangle sample code for java.awt.Rectangle definition code for java.awt.Rectangle getCharacterBounds sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getCharacterBounds(int) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getCharacterBounds(int) (int i)
          Determines the bounding box of the character at the given index into the string.
 int getCharCount sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getCharCount() definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getCharCount() ()
          Returns the number of characters (valid indices)
 int getIndexAtPoint sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getIndexAtPoint(java.awt.Point) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getIndexAtPoint(java.awt.Point) (Point sample code for java.awt.Point definition code for java.awt.Point  p)
          Given a point in local coordinates, return the zero-based index of the character under that Point.
 String sample code for java.lang.String definition code for java.lang.String getSelectedText sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getSelectedText() definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getSelectedText() ()
          Returns the portion of the text that is selected.
 int getSelectionEnd sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getSelectionEnd() definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getSelectionEnd() ()
          Returns the end offset within the selected text.
 int getSelectionStart sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getSelectionStart() definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getSelectionStart() ()
          Returns the start offset within the selected text.
 String sample code for java.lang.String definition code for java.lang.String getTextRange sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getTextRange(int, int) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getTextRange(int, int) (int startIndex, int endIndex)
          Returns the text string between two indices.
 void insertTextAtIndex sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.insertTextAtIndex(int, java.lang.String) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.insertTextAtIndex(int, java.lang.String) (int index, String sample code for java.lang.String definition code for java.lang.String  s)
          Inserts the specified string at the given index
 void insertUpdate sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.insertUpdate(javax.swing.event.DocumentEvent) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.insertUpdate(javax.swing.event.DocumentEvent) (DocumentEvent sample code for javax.swing.event.DocumentEvent definition code for javax.swing.event.DocumentEvent  e)
          Handles document insert (fire appropriate property change event which is AccessibleContext.ACCESSIBLE_TEXT_PROPERTY).
 void paste sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.paste(int) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.paste(int) (int startIndex)
          Pastes the text from the system clipboard into the text starting at the specified index.
 void removeUpdate sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.removeUpdate(javax.swing.event.DocumentEvent) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.removeUpdate(javax.swing.event.DocumentEvent) (DocumentEvent sample code for javax.swing.event.DocumentEvent definition code for javax.swing.event.DocumentEvent  e)
          Handles document remove (fire appropriate property change event, which is AccessibleContext.ACCESSIBLE_TEXT_PROPERTY).
 void replaceText sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.replaceText(int, int, java.lang.String) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.replaceText(int, int, java.lang.String) (int startIndex, int endIndex, String sample code for java.lang.String definition code for java.lang.String  s)
          Replaces the text between two indices with the specified string.
 void selectText sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.selectText(int, int) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.selectText(int, int) (int startIndex, int endIndex)
          Selects the text between two indices.
 void setAttributes sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.setAttributes(int, int, javax.swing.text.AttributeSet) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.setAttributes(int, int, javax.swing.text.AttributeSet) (int startIndex, int endIndex, AttributeSet sample code for javax.swing.text.AttributeSet definition code for javax.swing.text.AttributeSet  as)
          Sets attributes for the text between two indices.
 void setTextContents sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.setTextContents(java.lang.String) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.setTextContents(java.lang.String) (String sample code for java.lang.String definition code for java.lang.String  s)
          Sets the text contents to the specified string.
 
Methods inherited from class javax.swing.JComponent.AccessibleJComponent sample code for javax.swing.JComponent.AccessibleJComponent definition code for javax.swing.JComponent.AccessibleJComponent
addPropertyChangeListener sample code for javax.swing.JComponent.AccessibleJComponent.addPropertyChangeListener(java.beans.PropertyChangeListener) definition code for javax.swing.JComponent.AccessibleJComponent.addPropertyChangeListener(java.beans.PropertyChangeListener) , getAccessibleChild sample code for javax.swing.JComponent.AccessibleJComponent.getAccessibleChild(int) definition code for javax.swing.JComponent.AccessibleJComponent.getAccessibleChild(int) , getAccessibleChildrenCount sample code for javax.swing.JComponent.AccessibleJComponent.getAccessibleChildrenCount() definition code for javax.swing.JComponent.AccessibleJComponent.getAccessibleChildrenCount() , getAccessibleDescription sample code for javax.swing.JComponent.AccessibleJComponent.getAccessibleDescription() definition code for javax.swing.JComponent.AccessibleJComponent.getAccessibleDescription() , getAccessibleKeyBinding sample code for javax.swing.JComponent.AccessibleJComponent.getAccessibleKeyBinding() definition code for javax.swing.JComponent.AccessibleJComponent.getAccessibleKeyBinding() , getAccessibleName sample code for javax.swing.JComponent.AccessibleJComponent.getAccessibleName() definition code for javax.swing.JComponent.AccessibleJComponent.getAccessibleName() , getBorderTitle sample code for javax.swing.JComponent.AccessibleJComponent.getBorderTitle(javax.swing.border.Border) definition code for javax.swing.JComponent.AccessibleJComponent.getBorderTitle(javax.swing.border.Border) , getTitledBorderText sample code for javax.swing.JComponent.AccessibleJComponent.getTitledBorderText() definition code for javax.swing.JComponent.AccessibleJComponent.getTitledBorderText() , getToolTipText sample code for javax.swing.JComponent.AccessibleJComponent.getToolTipText() definition code for javax.swing.JComponent.AccessibleJComponent.getToolTipText() , removePropertyChangeListener sample code for javax.swing.JComponent.AccessibleJComponent.removePropertyChangeListener(java.beans.PropertyChangeListener) definition code for javax.swing.JComponent.AccessibleJComponent.removePropertyChangeListener(java.beans.PropertyChangeListener)
 
Methods inherited from class java.awt.Container.AccessibleAWTContainer sample code for java.awt.Container.AccessibleAWTContainer definition code for java.awt.Container.AccessibleAWTContainer
getAccessibleAt sample code for java.awt.Container.AccessibleAWTContainer.getAccessibleAt(java.awt.Point) definition code for java.awt.Container.AccessibleAWTContainer.getAccessibleAt(java.awt.Point)
 
Methods inherited from class java.awt.Component.AccessibleAWTComponent sample code for java.awt.Component.AccessibleAWTComponent definition code for java.awt.Component.AccessibleAWTComponent
addFocusListener sample code for java.awt.Component.AccessibleAWTComponent.addFocusListener(java.awt.event.FocusListener) definition code for java.awt.Component.AccessibleAWTComponent.addFocusListener(java.awt.event.FocusListener) , contains sample code for java.awt.Component.AccessibleAWTComponent.contains(java.awt.Point) definition code for java.awt.Component.AccessibleAWTComponent.contains(java.awt.Point) , getAccessibleComponent sample code for java.awt.Component.AccessibleAWTComponent.getAccessibleComponent() definition code for java.awt.Component.AccessibleAWTComponent.getAccessibleComponent() , getAccessibleIndexInParent sample code for java.awt.Component.AccessibleAWTComponent.getAccessibleIndexInParent() definition code for java.awt.Component.AccessibleAWTComponent.getAccessibleIndexInParent() , getAccessibleParent sample code for java.awt.Component.AccessibleAWTComponent.getAccessibleParent() definition code for java.awt.Component.AccessibleAWTComponent.getAccessibleParent() , getBackground sample code for java.awt.Component.AccessibleAWTComponent.getBackground() definition code for java.awt.Component.AccessibleAWTComponent.getBackground() , getBounds sample code for java.awt.Component.AccessibleAWTComponent.getBounds() definition code for java.awt.Component.AccessibleAWTComponent.getBounds() , getCursor sample code for java.awt.Component.AccessibleAWTComponent.getCursor() definition code for java.awt.Component.AccessibleAWTComponent.getCursor() , getFont sample code for java.awt.Component.AccessibleAWTComponent.getFont() definition code for java.awt.Component.AccessibleAWTComponent.getFont() , getFontMetrics sample code for java.awt.Component.AccessibleAWTComponent.getFontMetrics(java.awt.Font) definition code for java.awt.Component.AccessibleAWTComponent.getFontMetrics(java.awt.Font) , getForeground sample code for java.awt.Component.AccessibleAWTComponent.getForeground() definition code for java.awt.Component.AccessibleAWTComponent.getForeground() , getLocale sample code for java.awt.Component.AccessibleAWTComponent.getLocale() definition code for java.awt.Component.AccessibleAWTComponent.getLocale() , getLocation sample code for java.awt.Component.AccessibleAWTComponent.getLocation() definition code for java.awt.Component.AccessibleAWTComponent.getLocation() , getLocationOnScreen sample code for java.awt.Component.AccessibleAWTComponent.getLocationOnScreen() definition code for java.awt.Component.AccessibleAWTComponent.getLocationOnScreen() , getSize sample code for java.awt.Component.AccessibleAWTComponent.getSize() definition code for java.awt.Component.AccessibleAWTComponent.getSize() , isEnabled sample code for java.awt.Component.AccessibleAWTComponent.isEnabled() definition code for java.awt.Component.AccessibleAWTComponent.isEnabled() , isFocusTraversable sample code for java.awt.Component.AccessibleAWTComponent.isFocusTraversable() definition code for java.awt.Component.AccessibleAWTComponent.isFocusTraversable() , isShowing sample code for java.awt.Component.AccessibleAWTComponent.isShowing() definition code for java.awt.Component.AccessibleAWTComponent.isShowing() , isVisible sample code for java.awt.Component.AccessibleAWTComponent.isVisible() definition code for java.awt.Component.AccessibleAWTComponent.isVisible() , removeFocusListener sample code for java.awt.Component.AccessibleAWTComponent.removeFocusListener(java.awt.event.FocusListener) definition code for java.awt.Component.AccessibleAWTComponent.removeFocusListener(java.awt.event.FocusListener) , requestFocus sample code for java.awt.Component.AccessibleAWTComponent.requestFocus() definition code for java.awt.Component.AccessibleAWTComponent.requestFocus() , setBackground sample code for java.awt.Component.AccessibleAWTComponent.setBackground(java.awt.Color) definition code for java.awt.Component.AccessibleAWTComponent.setBackground(java.awt.Color) , setBounds sample code for java.awt.Component.AccessibleAWTComponent.setBounds(java.awt.Rectangle) definition code for java.awt.Component.AccessibleAWTComponent.setBounds(java.awt.Rectangle) , setCursor sample code for java.awt.Component.AccessibleAWTComponent.setCursor(java.awt.Cursor) definition code for java.awt.Component.AccessibleAWTComponent.setCursor(java.awt.Cursor) , setEnabled sample code for java.awt.Component.AccessibleAWTComponent.setEnabled(boolean) definition code for java.awt.Component.AccessibleAWTComponent.setEnabled(boolean) , setFont sample code for java.awt.Component.AccessibleAWTComponent.setFont(java.awt.Font) definition code for java.awt.Component.AccessibleAWTComponent.setFont(java.awt.Font) , setForeground sample code for java.awt.Component.AccessibleAWTComponent.setForeground(java.awt.Color) definition code for java.awt.Component.AccessibleAWTComponent.setForeground(java.awt.Color) , setLocation sample code for java.awt.Component.AccessibleAWTComponent.setLocation(java.awt.Point) definition code for java.awt.Component.AccessibleAWTComponent.setLocation(java.awt.Point) , setSize sample code for java.awt.Component.AccessibleAWTComponent.setSize(java.awt.Dimension) definition code for java.awt.Component.AccessibleAWTComponent.setSize(java.awt.Dimension) , setVisible sample code for java.awt.Component.AccessibleAWTComponent.setVisible(boolean) definition code for java.awt.Component.AccessibleAWTComponent.setVisible(boolean)
 
Methods inherited from class javax.accessibility.AccessibleContext sample code for javax.accessibility.AccessibleContext definition code for javax.accessibility.AccessibleContext
firePropertyChange sample code for javax.accessibility.AccessibleContext.firePropertyChange(java.lang.String, java.lang.Object, java.lang.Object) definition code for javax.accessibility.AccessibleContext.firePropertyChange(java.lang.String, java.lang.Object, java.lang.Object) , getAccessibleIcon sample code for javax.accessibility.AccessibleContext.getAccessibleIcon() definition code for javax.accessibility.AccessibleContext.getAccessibleIcon() , getAccessibleRelationSet sample code for javax.accessibility.AccessibleContext.getAccessibleRelationSet() definition code for javax.accessibility.AccessibleContext.getAccessibleRelationSet() , getAccessibleSelection sample code for javax.accessibility.AccessibleContext.getAccessibleSelection() definition code for javax.accessibility.AccessibleContext.getAccessibleSelection() , getAccessibleTable sample code for javax.accessibility.AccessibleContext.getAccessibleTable() definition code for javax.accessibility.AccessibleContext.getAccessibleTable() , getAccessibleValue sample code for javax.accessibility.AccessibleContext.getAccessibleValue() definition code for javax.accessibility.AccessibleContext.getAccessibleValue() , setAccessibleDescription sample code for javax.accessibility.AccessibleContext.setAccessibleDescription(java.lang.String) definition code for javax.accessibility.AccessibleContext.setAccessibleDescription(java.lang.String) , setAccessibleName sample code for javax.accessibility.AccessibleContext.setAccessibleName(java.lang.String) definition code for javax.accessibility.AccessibleContext.setAccessibleName(java.lang.String) , setAccessibleParent sample code for javax.accessibility.AccessibleContext.setAccessibleParent(javax.accessibility.Accessible) definition code for javax.accessibility.AccessibleContext.setAccessibleParent(javax.accessibility.Accessible)
 
Methods inherited from class java.lang.Object sample code for java.lang.Object definition code for java.lang.Object
clone sample code for java.lang.Object.clone() definition code for java.lang.Object.clone() , equals sample code for java.lang.Object.equals(java.lang.Object) definition code for java.lang.Object.equals(java.lang.Object) , finalize sample code for java.lang.Object.finalize() definition code for java.lang.Object.finalize() , getClass sample code for java.lang.Object.getClass() definition code for java.lang.Object.getClass() , hashCode sample code for java.lang.Object.hashCode() definition code for java.lang.Object.hashCode() , notify sample code for java.lang.Object.notify() definition code for java.lang.Object.notify() , notifyAll sample code for java.lang.Object.notifyAll() definition code for java.lang.Object.notifyAll() , toString sample code for java.lang.Object.toString() definition code for java.lang.Object.toString() , wait sample code for java.lang.Object.wait() definition code for java.lang.Object.wait() , wait sample code for java.lang.Object.wait(long) definition code for java.lang.Object.wait(long) , wait sample code for java.lang.Object.wait(long, int) definition code for java.lang.Object.wait(long, int)
 
Methods inherited from interface javax.accessibility.AccessibleComponent sample code for javax.accessibility.AccessibleComponent definition code for javax.accessibility.AccessibleComponent
addFocusListener sample code for javax.accessibility.AccessibleComponent.addFocusListener(java.awt.event.FocusListener) definition code for javax.accessibility.AccessibleComponent.addFocusListener(java.awt.event.FocusListener) , contains sample code for javax.accessibility.AccessibleComponent.contains(java.awt.Point) definition code for javax.accessibility.AccessibleComponent.contains(java.awt.Point) , getAccessibleAt sample code for javax.accessibility.AccessibleComponent.getAccessibleAt(java.awt.Point) definition code for javax.accessibility.AccessibleComponent.getAccessibleAt(java.awt.Point) , getBackground sample code for javax.accessibility.AccessibleComponent.getBackground() definition code for javax.accessibility.AccessibleComponent.getBackground() , getBounds sample code for javax.accessibility.AccessibleComponent.getBounds() definition code for javax.accessibility.AccessibleComponent.getBounds() , getCursor sample code for javax.accessibility.AccessibleComponent.getCursor() definition code for javax.accessibility.AccessibleComponent.getCursor() , getFont sample code for javax.accessibility.AccessibleComponent.getFont() definition code for javax.accessibility.AccessibleComponent.getFont() , getFontMetrics sample code for javax.accessibility.AccessibleComponent.getFontMetrics(java.awt.Font) definition code for javax.accessibility.AccessibleComponent.getFontMetrics(java.awt.Font) , getForeground sample code for javax.accessibility.AccessibleComponent.getForeground() definition code for javax.accessibility.AccessibleComponent.getForeground() , getLocation sample code for javax.accessibility.AccessibleComponent.getLocation() definition code for javax.accessibility.AccessibleComponent.getLocation() , getLocationOnScreen sample code for javax.accessibility.AccessibleComponent.getLocationOnScreen() definition code for javax.accessibility.AccessibleComponent.getLocationOnScreen() , getSize sample code for javax.accessibility.AccessibleComponent.getSize() definition code for javax.accessibility.AccessibleComponent.getSize() , isEnabled sample code for javax.accessibility.AccessibleComponent.isEnabled() definition code for javax.accessibility.AccessibleComponent.isEnabled() , isFocusTraversable sample code for javax.accessibility.AccessibleComponent.isFocusTraversable() definition code for javax.accessibility.AccessibleComponent.isFocusTraversable() , isShowing sample code for javax.accessibility.AccessibleComponent.isShowing() definition code for javax.accessibility.AccessibleComponent.isShowing() , isVisible sample code for javax.accessibility.AccessibleComponent.isVisible() definition code for javax.accessibility.AccessibleComponent.isVisible() , removeFocusListener sample code for javax.accessibility.AccessibleComponent.removeFocusListener(java.awt.event.FocusListener) definition code for javax.accessibility.AccessibleComponent.removeFocusListener(java.awt.event.FocusListener) , requestFocus sample code for javax.accessibility.AccessibleComponent.requestFocus() definition code for javax.accessibility.AccessibleComponent.requestFocus() , setBackground sample code for javax.accessibility.AccessibleComponent.setBackground(java.awt.Color) definition code for javax.accessibility.AccessibleComponent.setBackground(java.awt.Color) , setBounds sample code for javax.accessibility.AccessibleComponent.setBounds(java.awt.Rectangle) definition code for javax.accessibility.AccessibleComponent.setBounds(java.awt.Rectangle) , setCursor sample code for javax.accessibility.AccessibleComponent.setCursor(java.awt.Cursor) definition code for javax.accessibility.AccessibleComponent.setCursor(java.awt.Cursor) , setEnabled sample code for javax.accessibility.AccessibleComponent.setEnabled(boolean) definition code for javax.accessibility.AccessibleComponent.setEnabled(boolean) , setFont sample code for javax.accessibility.AccessibleComponent.setFont(java.awt.Font) definition code for javax.accessibility.AccessibleComponent.setFont(java.awt.Font) , setForeground sample code for javax.accessibility.AccessibleComponent.setForeground(java.awt.Color) definition code for javax.accessibility.AccessibleComponent.setForeground(java.awt.Color) , setLocation sample code for javax.accessibility.AccessibleComponent.setLocation(java.awt.Point) definition code for javax.accessibility.AccessibleComponent.setLocation(java.awt.Point) , setSize sample code for javax.accessibility.AccessibleComponent.setSize(java.awt.Dimension) definition code for javax.accessibility.AccessibleComponent.setSize(java.awt.Dimension) , setVisible sample code for javax.accessibility.AccessibleComponent.setVisible(boolean) definition code for javax.accessibility.AccessibleComponent.setVisible(boolean)
 

Constructor Detail

JTextComponent.AccessibleJTextComponent sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent() definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent()

public JTextComponent.AccessibleJTextComponent()
Constructs an AccessibleJTextComponent. Adds a listener to track caret change.

Method Detail

caretUpdate sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.caretUpdate(javax.swing.event.CaretEvent) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.caretUpdate(javax.swing.event.CaretEvent)

public void caretUpdate(CaretEvent sample code for javax.swing.event.CaretEvent definition code for javax.swing.event.CaretEvent  e)
Handles caret updates (fire appropriate property change event, which are AccessibleContext.ACCESSIBLE_CARET_PROPERTY and AccessibleContext.ACCESSIBLE_SELECTION_PROPERTY). This keeps track of the dot position internally. When the caret moves, the internal position is updated after firing the event.

Specified by:
caretUpdate sample code for javax.swing.event.CaretListener.caretUpdate(javax.swing.event.CaretEvent) definition code for javax.swing.event.CaretListener.caretUpdate(javax.swing.event.CaretEvent) in interface CaretListener sample code for javax.swing.event.CaretListener definition code for javax.swing.event.CaretListener
Parameters:
e - the CaretEvent

insertUpdate sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.insertUpdate(javax.swing.event.DocumentEvent) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.insertUpdate(javax.swing.event.DocumentEvent)

public void insertUpdate(DocumentEvent sample code for javax.swing.event.DocumentEvent definition code for javax.swing.event.DocumentEvent  e)
Handles document insert (fire appropriate property change event which is AccessibleContext.ACCESSIBLE_TEXT_PROPERTY). This tracks the changed offset via the event.

Specified by:
insertUpdate sample code for javax.swing.event.DocumentListener.insertUpdate(javax.swing.event.DocumentEvent) definition code for javax.swing.event.DocumentListener.insertUpdate(javax.swing.event.DocumentEvent) in interface DocumentListener sample code for javax.swing.event.DocumentListener definition code for javax.swing.event.DocumentListener
Parameters:
e - the DocumentEvent

removeUpdate sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.removeUpdate(javax.swing.event.DocumentEvent) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.removeUpdate(javax.swing.event.DocumentEvent)

public void removeUpdate(DocumentEvent sample code for javax.swing.event.DocumentEvent definition code for javax.swing.event.DocumentEvent  e)
Handles document remove (fire appropriate property change event, which is AccessibleContext.ACCESSIBLE_TEXT_PROPERTY). This tracks the changed offset via the event.

Specified by:
removeUpdate sample code for javax.swing.event.DocumentListener.removeUpdate(javax.swing.event.DocumentEvent) definition code for javax.swing.event.DocumentListener.removeUpdate(javax.swing.event.DocumentEvent) in interface DocumentListener sample code for javax.swing.event.DocumentListener definition code for javax.swing.event.DocumentListener
Parameters:
e - the DocumentEvent

changedUpdate sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.changedUpdate(javax.swing.event.DocumentEvent) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.changedUpdate(javax.swing.event.DocumentEvent)

public void changedUpdate(DocumentEvent sample code for javax.swing.event.DocumentEvent definition code for javax.swing.event.DocumentEvent  e)
Handles document remove (fire appropriate property change event, which is AccessibleContext.ACCESSIBLE_TEXT_PROPERTY). This tracks the changed offset via the event.

Specified by:
changedUpdate sample code for javax.swing.event.DocumentListener.changedUpdate(javax.swing.event.DocumentEvent) definition code for javax.swing.event.DocumentListener.changedUpdate(javax.swing.event.DocumentEvent) in interface DocumentListener sample code for javax.swing.event.DocumentListener definition code for javax.swing.event.DocumentListener
Parameters:
e - the DocumentEvent

getAccessibleStateSet sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleStateSet() definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleStateSet()

public AccessibleStateSet sample code for javax.accessibility.AccessibleStateSet definition code for javax.accessibility.AccessibleStateSet  getAccessibleStateSet()
Gets the state set of the JTextComponent. The AccessibleStateSet of an object is composed of a set of unique AccessibleState's. A change in the AccessibleStateSet of an object will cause a PropertyChangeEvent to be fired for the AccessibleContext.ACCESSIBLE_STATE_PROPERTY property.

Overrides:
getAccessibleStateSet sample code for javax.swing.JComponent.AccessibleJComponent.getAccessibleStateSet() definition code for javax.swing.JComponent.AccessibleJComponent.getAccessibleStateSet() in class JComponent.AccessibleJComponent sample code for javax.swing.JComponent.AccessibleJComponent definition code for javax.swing.JComponent.AccessibleJComponent
Returns:
an instance of AccessibleStateSet containing the current state set of the object
See Also:
AccessibleStateSet sample code for javax.accessibility.AccessibleStateSet definition code for javax.accessibility.AccessibleStateSet , AccessibleState sample code for javax.accessibility.AccessibleState definition code for javax.accessibility.AccessibleState , JComponent.AccessibleJComponent.addPropertyChangeListener(java.beans.PropertyChangeListener) sample code for javax.swing.JComponent.AccessibleJComponent.addPropertyChangeListener(java.beans.PropertyChangeListener) definition code for javax.swing.JComponent.AccessibleJComponent.addPropertyChangeListener(java.beans.PropertyChangeListener)

getAccessibleRole sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleRole() definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleRole()

public AccessibleRole sample code for javax.accessibility.AccessibleRole definition code for javax.accessibility.AccessibleRole  getAccessibleRole()
Gets the role of this object.

Overrides:
getAccessibleRole sample code for javax.swing.JComponent.AccessibleJComponent.getAccessibleRole() definition code for javax.swing.JComponent.AccessibleJComponent.getAccessibleRole() in class JComponent.AccessibleJComponent sample code for javax.swing.JComponent.AccessibleJComponent definition code for javax.swing.JComponent.AccessibleJComponent
Returns:
an instance of AccessibleRole describing the role of the object (AccessibleRole.TEXT)
See Also:
AccessibleRole sample code for javax.accessibility.AccessibleRole definition code for javax.accessibility.AccessibleRole

getAccessibleText sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleText() definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleText()

public AccessibleText sample code for javax.accessibility.AccessibleText definition code for javax.accessibility.AccessibleText  getAccessibleText()
Get the AccessibleText associated with this object. In the implementation of the Java Accessibility API for this class, return this object, which is responsible for implementing the AccessibleText interface on behalf of itself.

Overrides:
getAccessibleText sample code for javax.accessibility.AccessibleContext.getAccessibleText() definition code for javax.accessibility.AccessibleContext.getAccessibleText() in class AccessibleContext sample code for javax.accessibility.AccessibleContext definition code for javax.accessibility.AccessibleContext
Returns:
this object
See Also:
AccessibleText sample code for javax.accessibility.AccessibleText definition code for javax.accessibility.AccessibleText

getIndexAtPoint sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getIndexAtPoint(java.awt.Point) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getIndexAtPoint(java.awt.Point)

public int getIndexAtPoint(Point sample code for java.awt.Point definition code for java.awt.Point  p)
Given a point in local coordinates, return the zero-based index of the character under that Point. If the point is invalid, this method returns -1.

Specified by:
getIndexAtPoint sample code for javax.accessibility.AccessibleText.getIndexAtPoint(java.awt.Point) definition code for javax.accessibility.AccessibleText.getIndexAtPoint(java.awt.Point) in interface AccessibleText sample code for javax.accessibility.AccessibleText definition code for javax.accessibility.AccessibleText
Parameters:
p - the Point in local coordinates
Returns:
the zero-based index of the character under Point p.

getCharacterBounds sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getCharacterBounds(int) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getCharacterBounds(int)

public Rectangle sample code for java.awt.Rectangle definition code for java.awt.Rectangle  getCharacterBounds(int i)
Determines the bounding box of the character at the given index into the string. The bounds are returned in local coordinates. If the index is invalid a null rectangle is returned. The screen coordinates returned are "unscrolled coordinates" if the JTextComponent is contained in a JScrollPane in which case the resulting rectangle should be composed with the parent coordinates. A good algorithm to use is: Accessible a: AccessibleText at = a.getAccessibleText(); AccessibleComponent ac = a.getAccessibleComponent(); Rectangle r = at.getCharacterBounds(); Point p = ac.getLocation(); r.x += p.x; r.y += p.y; Note: the JTextComponent must have a valid size (e.g. have been added to a parent container whose ancestor container is a valid top-level window) for this method to be able to return a meaningful (non-null) value.

Specified by:
getCharacterBounds sample code for javax.accessibility.AccessibleText.getCharacterBounds(int) definition code for javax.accessibility.AccessibleText.getCharacterBounds(int) in interface AccessibleText sample code for javax.accessibility.AccessibleText definition code for javax.accessibility.AccessibleText
Parameters:
i - the index into the String >= 0
Returns:
the screen coordinates of the character's bounding box

getCharCount sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getCharCount() definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getCharCount()

public int getCharCount()
Returns the number of characters (valid indices)

Specified by:
getCharCount sample code for javax.accessibility.AccessibleText.getCharCount() definition code for javax.accessibility.AccessibleText.getCharCount() in interface AccessibleText sample code for javax.accessibility.AccessibleText definition code for javax.accessibility.AccessibleText
Returns:
the number of characters >= 0

getCaretPosition sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getCaretPosition() definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getCaretPosition()

public int getCaretPosition()
Returns the zero-based offset of the caret. Note: The character to the right of the caret will have the same index value as the offset (the caret is between two characters).

Specified by:
getCaretPosition sample code for javax.accessibility.AccessibleText.getCaretPosition() definition code for javax.accessibility.AccessibleText.getCaretPosition() in interface AccessibleText sample code for javax.accessibility.AccessibleText definition code for javax.accessibility.AccessibleText
Returns:
the zero-based offset of the caret.

getCharacterAttribute sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getCharacterAttribute(int) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getCharacterAttribute(int)

public AttributeSet sample code for javax.swing.text.AttributeSet definition code for javax.swing.text.AttributeSet  getCharacterAttribute(int i)
Returns the AttributeSet for a given character (at a given index).

Specified by:
getCharacterAttribute sample code for javax.accessibility.AccessibleText.getCharacterAttribute(int) definition code for javax.accessibility.AccessibleText.getCharacterAttribute(int) in interface AccessibleText sample code for javax.accessibility.AccessibleText definition code for javax.accessibility.AccessibleText
Parameters:
i - the zero-based index into the text
Returns:
the AttributeSet of the character

getSelectionStart sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getSelectionStart() definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getSelectionStart()

public int getSelectionStart()
Returns the start offset within the selected text. If there is no selection, but there is a caret, the start and end offsets will be the same. Return 0 if the text is empty, or the caret position if no selection.

Specified by:
getSelectionStart sample code for javax.accessibility.AccessibleText.getSelectionStart() definition code for javax.accessibility.AccessibleText.getSelectionStart() in interface AccessibleText sample code for javax.accessibility.AccessibleText definition code for javax.accessibility.AccessibleText
Returns:
the index into the text of the start of the selection >= 0

getSelectionEnd sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getSelectionEnd() definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getSelectionEnd()

public int getSelectionEnd()
Returns the end offset within the selected text. If there is no selection, but there is a caret, the start and end offsets will be the same. Return 0 if the text is empty, or the caret position if no selection.

Specified by:
getSelectionEnd sample code for javax.accessibility.AccessibleText.getSelectionEnd() definition code for javax.accessibility.AccessibleText.getSelectionEnd() in interface AccessibleText sample code for javax.accessibility.AccessibleText definition code for javax.accessibility.AccessibleText
Returns:
the index into teh text of the end of the selection >= 0

getSelectedText sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getSelectedText() definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getSelectedText()

public String sample code for java.lang.String definition code for java.lang.String  getSelectedText()
Returns the portion of the text that is selected.

Specified by:
getSelectedText sample code for javax.accessibility.AccessibleText.getSelectedText() definition code for javax.accessibility.AccessibleText.getSelectedText() in interface AccessibleText sample code for javax.accessibility.AccessibleText definition code for javax.accessibility.AccessibleText
Returns:
the text, null if no selection

getAtIndex sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAtIndex(int, int) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAtIndex(int, int)

public String sample code for java.lang.String definition code for java.lang.String  getAtIndex(int part,
                         int index)
Returns the String at a given index. Whitespace between words is treated as a word.

Specified by:
getAtIndex sample code for javax.accessibility.AccessibleText.getAtIndex(int, int) definition code for javax.accessibility.AccessibleText.getAtIndex(int, int) in interface AccessibleText sample code for javax.accessibility.AccessibleText definition code for javax.accessibility.AccessibleText
Parameters:
part - the CHARACTER, WORD, or SENTENCE to retrieve
index - an index within the text
Returns:
the letter, word, or sentence.

getAfterIndex sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAfterIndex(int, int) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAfterIndex(int, int)

public String sample code for java.lang.String definition code for java.lang.String  getAfterIndex(int part,
                            int index)
Returns the String after a given index. Whitespace between words is treated as a word.

Specified by:
getAfterIndex sample code for javax.accessibility.AccessibleText.getAfterIndex(int, int) definition code for javax.accessibility.AccessibleText.getAfterIndex(int, int) in interface AccessibleText sample code for javax.accessibility.AccessibleText definition code for javax.accessibility.AccessibleText
Parameters:
part - the CHARACTER, WORD, or SENTENCE to retrieve
index - an index within the text
Returns:
the letter, word, or sentence.

getBeforeIndex sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getBeforeIndex(int, int) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getBeforeIndex(int, int)

public String sample code for java.lang.String definition code for java.lang.String  getBeforeIndex(int part,
                             int index)
Returns the String before a given index. Whitespace between words is treated a word.

Specified by:
getBeforeIndex sample code for javax.accessibility.AccessibleText.getBeforeIndex(int, int) definition code for javax.accessibility.AccessibleText.getBeforeIndex(int, int) in interface AccessibleText sample code for javax.accessibility.AccessibleText definition code for javax.accessibility.AccessibleText
Parameters:
part - the CHARACTER, WORD, or SENTENCE to retrieve
index - an index within the text
Returns:
the letter, word, or sentence.

getAccessibleEditableText sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleEditableText() definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleEditableText()

public AccessibleEditableText sample code for javax.accessibility.AccessibleEditableText definition code for javax.accessibility.AccessibleEditableText  getAccessibleEditableText()
Returns the AccessibleEditableText interface for this text component.

Overrides:
getAccessibleEditableText sample code for javax.accessibility.AccessibleContext.getAccessibleEditableText() definition code for javax.accessibility.AccessibleContext.getAccessibleEditableText() in class AccessibleContext sample code for javax.accessibility.AccessibleContext definition code for javax.accessibility.AccessibleContext
Returns:
the AccessibleEditableText interface
See Also:
AccessibleEditableText sample code for javax.accessibility.AccessibleEditableText definition code for javax.accessibility.AccessibleEditableText

setTextContents sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.setTextContents(java.lang.String) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.setTextContents(java.lang.String)

public void setTextContents(String sample code for java.lang.String definition code for java.lang.String  s)
Sets the text contents to the specified string.

Specified by:
setTextContents sample code for javax.accessibility.AccessibleEditableText.setTextContents(java.lang.String) definition code for javax.accessibility.AccessibleEditableText.setTextContents(java.lang.String) in interface AccessibleEditableText sample code for javax.accessibility.AccessibleEditableText definition code for javax.accessibility.AccessibleEditableText
Parameters:
s - the string to set the text contents

insertTextAtIndex sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.insertTextAtIndex(int, java.lang.String) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.insertTextAtIndex(int, java.lang.String)

public void insertTextAtIndex(int index,
                              String sample code for java.lang.String definition code for java.lang.String  s)
Inserts the specified string at the given index

Specified by:
insertTextAtIndex sample code for javax.accessibility.AccessibleEditableText.insertTextAtIndex(int, java.lang.String) definition code for javax.accessibility.AccessibleEditableText.insertTextAtIndex(int, java.lang.String) in interface AccessibleEditableText sample code for javax.accessibility.AccessibleEditableText definition code for javax.accessibility.AccessibleEditableText
Parameters:
index - the index in the text where the string will be inserted
s - the string to insert in the text

getTextRange sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getTextRange(int, int) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getTextRange(int, int)

public String sample code for java.lang.String definition code for java.lang.String  getTextRange(int startIndex,
                           int endIndex)
Returns the text string between two indices.

Specified by:
getTextRange sample code for javax.accessibility.AccessibleEditableText.getTextRange(int, int) definition code for javax.accessibility.AccessibleEditableText.getTextRange(int, int) in interface AccessibleEditableText sample code for javax.accessibility.AccessibleEditableText definition code for javax.accessibility.AccessibleEditableText
Parameters:
startIndex - the starting index in the text
endIndex - the ending index in the text
Returns:
the text string between the indices

delete sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.delete(int, int) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.delete(int, int)

public void delete(int startIndex,
                   int endIndex)
Deletes the text between two indices

Specified by:
delete sample code for javax.accessibility.AccessibleEditableText.delete(int, int) definition code for javax.accessibility.AccessibleEditableText.delete(int, int) in interface AccessibleEditableText sample code for javax.accessibility.AccessibleEditableText definition code for javax.accessibility.AccessibleEditableText
Parameters:
startIndex - the starting index in the text
endIndex - the ending index in the text

cut sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.cut(int, int) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.cut(int, int)

public void cut(int startIndex,
                int endIndex)
Cuts the text between two indices into the system clipboard.

Specified by:
cut sample code for javax.accessibility.AccessibleEditableText.cut(int, int) definition code for javax.accessibility.AccessibleEditableText.cut(int, int) in interface AccessibleEditableText sample code for javax.accessibility.AccessibleEditableText definition code for javax.accessibility.AccessibleEditableText
Parameters:
startIndex - the starting index in the text
endIndex - the ending index in the text

paste sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.paste(int) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.paste(int)

public void paste(int startIndex)
Pastes the text from the system clipboard into the text starting at the specified index.

Specified by:
paste sample code for javax.accessibility.AccessibleEditableText.paste(int) definition code for javax.accessibility.AccessibleEditableText.paste(int) in interface AccessibleEditableText sample code for javax.accessibility.AccessibleEditableText definition code for javax.accessibility.AccessibleEditableText
Parameters:
startIndex - the starting index in the text

replaceText sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.replaceText(int, int, java.lang.String) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.replaceText(int, int, java.lang.String)

public void replaceText(int startIndex,
                        int endIndex,
                        String sample code for java.lang.String definition code for java.lang.String  s)
Replaces the text between two indices with the specified string.

Specified by:
replaceText sample code for javax.accessibility.AccessibleEditableText.replaceText(int, int, java.lang.String) definition code for javax.accessibility.AccessibleEditableText.replaceText(int, int, java.lang.String) in interface AccessibleEditableText sample code for javax.accessibility.AccessibleEditableText definition code for javax.accessibility.AccessibleEditableText
Parameters:
startIndex - the starting index in the text
endIndex - the ending index in the text
s - the string to replace the text between two indices

selectText sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.selectText(int, int) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.selectText(int, int)

public void selectText(int startIndex,
                       int endIndex)
Selects the text between two indices.

Specified by:
selectText sample code for javax.accessibility.AccessibleEditableText.selectText(int, int) definition code for javax.accessibility.AccessibleEditableText.selectText(int, int) in interface AccessibleEditableText sample code for javax.accessibility.AccessibleEditableText definition code for javax.accessibility.AccessibleEditableText
Parameters:
startIndex - the starting index in the text
endIndex - the ending index in the text

setAttributes sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.setAttributes(int, int, javax.swing.text.AttributeSet) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.setAttributes(int, int, javax.swing.text.AttributeSet)

public void setAttributes(int startIndex,
                          int endIndex,
                          AttributeSet sample code for javax.swing.text.AttributeSet definition code for javax.swing.text.AttributeSet  as)
Sets attributes for the text between two indices.

Specified by:
setAttributes sample code for javax.accessibility.AccessibleEditableText.setAttributes(int, int, javax.swing.text.AttributeSet) definition code for javax.accessibility.AccessibleEditableText.setAttributes(int, int, javax.swing.text.AttributeSet) in interface AccessibleEditableText sample code for javax.accessibility.AccessibleEditableText definition code for javax.accessibility.AccessibleEditableText
Parameters:
startIndex - the starting index in the text
endIndex - the ending index in the text
as - the attribute set
See Also:
AttributeSet sample code for javax.swing.text.AttributeSet definition code for javax.swing.text.AttributeSet

getAccessibleAction sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleAction() definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleAction()

public AccessibleAction sample code for javax.accessibility.AccessibleAction definition code for javax.accessibility.AccessibleAction  getAccessibleAction()
Description copied from class: AccessibleContext sample code for javax.accessibility.AccessibleContext.getAccessibleAction() definition code for javax.accessibility.AccessibleContext.getAccessibleAction()
Gets the AccessibleAction associated with this object that supports one or more actions.

Overrides:
getAccessibleAction sample code for javax.accessibility.AccessibleContext.getAccessibleAction() definition code for javax.accessibility.AccessibleContext.getAccessibleAction() in class AccessibleContext sample code for javax.accessibility.AccessibleContext definition code for javax.accessibility.AccessibleContext
Returns:
AccessibleAction if supported by object; else return null
See Also:
AccessibleAction sample code for javax.accessibility.AccessibleAction definition code for javax.accessibility.AccessibleAction

getAccessibleActionCount sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleActionCount() definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleActionCount()

public int getAccessibleActionCount()
Returns the number of accessible actions available in this object If there are more than one, the first one is considered the "default" action of the object.

Specified by:
getAccessibleActionCount sample code for javax.accessibility.AccessibleAction.getAccessibleActionCount() definition code for javax.accessibility.AccessibleAction.getAccessibleActionCount() in interface AccessibleAction sample code for javax.accessibility.AccessibleAction definition code for javax.accessibility.AccessibleAction
Returns:
the zero-based number of Actions in this object

getAccessibleActionDescription sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleActionDescription(int) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleActionDescription(int)

public String sample code for java.lang.String definition code for java.lang.String  getAccessibleActionDescription(int i)
Returns a description of the specified action of the object.

Specified by:
getAccessibleActionDescription sample code for javax.accessibility.AccessibleAction.getAccessibleActionDescription(int) definition code for javax.accessibility.AccessibleAction.getAccessibleActionDescription(int) in interface AccessibleAction sample code for javax.accessibility.AccessibleAction definition code for javax.accessibility.AccessibleAction
Parameters:
i - zero-based index of the actions
Returns:
a String description of the action
See Also:
getAccessibleActionCount() sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleActionCount() definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleActionCount()

doAccessibleAction sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.doAccessibleAction(int) definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.doAccessibleAction(int)

public boolean doAccessibleAction(int i)
Performs the specified Action on the object

Specified by:
doAccessibleAction sample code for javax.accessibility.AccessibleAction.doAccessibleAction(int) definition code for javax.accessibility.AccessibleAction.doAccessibleAction(int) in interface AccessibleAction sample code for javax.accessibility.AccessibleAction definition code for javax.accessibility.AccessibleAction
Parameters:
i - zero-based index of actions
Returns:
true if the action was performed; otherwise false.
See Also:
getAccessibleActionCount() sample code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleActionCount() definition code for javax.swing.text.JTextComponent.AccessibleJTextComponent.getAccessibleActionCount()