com.borland.primetime.editor
Class EditorActions.TabKeyAction

java.lang.Object
  |
  +--javax.swing.AbstractAction
        |
        +--com.borland.primetime.editor.EditorAction
              |
              +--com.borland.primetime.editor.EditorActions.TabKeyAction
All Implemented Interfaces:
javax.swing.Action, java.awt.event.ActionListener, java.lang.Cloneable, java.util.EventListener, java.io.Serializable
Enclosing class:
EditorActions

public static class EditorActions.TabKeyAction
extends EditorAction

Does one of the following:

  1. If EditorManager.isSmartTabs is true, places enough spaces on the the line to line up the next character typed with the next non-whitespace character on the previous non-blank line. If there is a selection, it is simply moved with the spaces.

    For example, if the caret was at position '1' in the code snippet below, it would end up at position '2'.

    
           boolean enableAdvancedNuclearHydrodyneDrive = false;
           boolean enableWarpCore                      = true;
           boolean enableFusionGun 1                   2
         
  2. Move to the next 'indent size' position.
  3. If there is a multi line selection, indent the selected block.
After determining what to indent and how far to indent, indent by adding a combination of tabs and spaces if there is only whitespace to the left of the caret, or only spaces.

See Also:
Serialized Form

Inner classes inherited from class com.borland.primetime.editor.EditorAction
EditorAction.SubKeymapAction
 
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
EditorActions.TabKeyAction(java.lang.String nm)
           
 
Method Summary
 void actionPerformed(java.awt.event.ActionEvent e)
           
 
Methods inherited from class com.borland.primetime.editor.EditorAction
getEditorTarget, getFocusedEditor, setFocusedEditor
 
Methods inherited from class javax.swing.AbstractAction
addPropertyChangeListener, clone, firePropertyChange, getKeys, getValue, isEnabled, putValue, removePropertyChangeListener, setEnabled
 
Methods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EditorActions.TabKeyAction

public EditorActions.TabKeyAction(java.lang.String nm)
Method Detail

actionPerformed

public void actionPerformed(java.awt.event.ActionEvent e)
Overrides:
actionPerformed in class javax.swing.AbstractAction