oracle.javatools.editor
Class BasicEditorKit.PreviousWordAction
java.lang.Object
javax.swing.AbstractAction
javax.swing.text.TextAction
oracle.javatools.editor.BasicAction
oracle.javatools.editor.BasicEditorKit.NavigateAction
oracle.javatools.editor.BasicEditorKit.PreviousWordAction
- All Implemented Interfaces:
- javax.swing.Action, java.awt.event.ActionListener, java.lang.Cloneable, java.util.EventListener, java.io.Serializable
- Enclosing class:
- BasicEditorKit
- public static class BasicEditorKit.PreviousWordAction
- extends BasicEditorKit.NavigateAction
The PreviousWordAction
implementation of the action
for moving the caret to the previous occurrence of a word start
or end, possibly extending the selection.
- See Also:
- Serialized Form
Field Summary |
static int |
TO_BOTH
Constant to delete to start or end of a word, whichever occurs first. |
static int |
TO_END
Constant to delete to end of a word. |
static int |
TO_START
Constant to delete to start of a word. |
Fields inherited from class javax.swing.AbstractAction |
changeSupport, enabled |
Fields inherited from interface javax.swing.Action |
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SHORT_DESCRIPTION, SMALL_ICON |
Constructor Summary |
BasicEditorKit.PreviousWordAction(java.lang.String actionName,
int wordBehavior,
boolean performSelect)
Constructs this object with the appropriate action name. |
Methods inherited from class oracle.javatools.editor.BasicAction |
actionPerformed, beep, buildIndent, getFontHeight, getLastAction, getMagicCaretPosition, getName, getSmartIndentProvider, getSpaces, getTab, getTabs, getTabSizeProperty, getUseAutoIndentProperty, getUseTabsProperty, getVisibleRect, isEditable, setMagicCaretPosition, showMessage, skipLeadingIndent |
Methods inherited from class javax.swing.text.TextAction |
augmentList, getFocusedComponent, getTextComponent |
Methods inherited from class javax.swing.AbstractAction |
addPropertyChangeListener, clone, firePropertyChange, getKeys, getPropertyChangeListeners, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled |
Methods inherited from class java.lang.Object |
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
TO_START
public static final int TO_START
- Constant to delete to start of a word.
- See Also:
- Constant Field Values
TO_END
public static final int TO_END
- Constant to delete to end of a word.
- See Also:
- Constant Field Values
TO_BOTH
public static final int TO_BOTH
- Constant to delete to start or end of a word, whichever occurs first.
- See Also:
- Constant Field Values
BasicEditorKit.PreviousWordAction
public BasicEditorKit.PreviousWordAction(java.lang.String actionName,
int wordBehavior,
boolean performSelect)
- Constructs this object with the appropriate action name.
- Parameters:
actionName
- the name of the navigation actionwordBehavior
- move the caret to the next word start or endperformSelect
- true to perform selection while navigating
navigatePerformed
protected void navigatePerformed(java.awt.event.ActionEvent event,
BasicEditorPane editor,
BasicDocument document)
- The navigation to perform when this action is triggered.
- Specified by:
navigatePerformed
in class BasicEditorKit.NavigateAction
- Parameters:
event
- the action eventeditor
- the editor his action was invoked indocument
- the document associated with the editor
Copyright © 1997, 2004, Oracle. All rights reserved.