Skip navigation links
oracle.javatools.editor
Class BasicEditorKit.EmacsKillTypeAction
java.lang.Object
javax.swing.AbstractAction
javax.swing.text.TextAction
oracle.javatools.editor.BasicAction
oracle.javatools.editor.EmacsAction
oracle.javatools.editor.EmacsWriteAction
oracle.javatools.editor.BasicEditorKit.EmacsKillTypeAction
- All Implemented Interfaces:
- java.awt.event.ActionListener, java.io.Serializable, java.lang.Cloneable, java.util.EventListener, javax.swing.Action
- Direct Known Subclasses:
- BasicEditorKit.EmacsAppendNextKillAction, BasicEditorKit.EmacsBackwardKillWordAction, BasicEditorKit.EmacsKillLineAction, BasicEditorKit.EmacsKillRegionAction, BasicEditorKit.EmacsKillWordAction
- Enclosing class:
- BasicEditorKit
-
public abstract static class BasicEditorKit.EmacsKillTypeAction
- extends EmacsWriteAction
The EmacsKillTypeAction
is a base action for all Emacs kill-type action implementations. It implements the functionality for tracking whether the last action was a kill, if focus has left the editor, or if navigation occurred via the mouse.
- See Also:
- Serialized Form
Fields inherited from class javax.swing.AbstractAction |
changeSupport, enabled |
Fields inherited from interface javax.swing.Action |
ACCELERATOR_KEY, ACTION_COMMAND_KEY, DEFAULT, DISPLAYED_MNEMONIC_INDEX_KEY, LARGE_ICON_KEY, LONG_DESCRIPTION, MNEMONIC_KEY, NAME, SELECTED_KEY, SHORT_DESCRIPTION, SMALL_ICON |
Methods inherited from class oracle.javatools.editor.EmacsAction |
addKillRing, appendKillRing, getClipboardText, getMark, getSystemClipboard, popKillRing, prependKillRing, removeMark, setClipboardText, setMark, setSystemClipboard, showEndBufferMessage, showMarkNotSetMessage, showMarkSetMessage, showNextKillAppendMessage, showPreviousNotYankMessage, showReadOnlyMessage, yankKillRing |
Methods inherited from class oracle.javatools.editor.BasicAction |
actionPerformed, beep, buildIndent, getFontHeight, getIndentSizeProperty, 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 |
BasicEditorKit.EmacsKillTypeAction
public BasicEditorKit.EmacsKillTypeAction(java.lang.String actionName)
- Constructs this object with the appropriate action name.
killPerformed
protected abstract boolean killPerformed(java.awt.event.ActionEvent event,
BasicEditorPane editor,
BasicDocument document,
boolean lastActionWasKill)
- The kill operation to perform when this action is triggered. Kill implementations should override this instead of actionPerformed. This should return true if the kill operation was performed (i.e., not end of buffer), false otherwise.
-
- Parameters:
event
- the action event
editor
- the editor his action was invoked in
document
- the document associated with the editor
lastActionWasKill
- whether the previous action was a kill
- Returns:
- true if kill was performed, false otherwise
actionPerformed
public final void actionPerformed(java.awt.event.ActionEvent event,
BasicEditorPane editor,
BasicDocument document)
- The operation to perform when this action is triggered.
-
- Specified by:
actionPerformed
in class EmacsAction
-
- Parameters:
event
- the action event
editor
- the editor his action was invoked in
document
- the document associated with the editor
Skip navigation links
Copyright © 1997, 2012, Oracle. All rights reserved.