| java.lang.Object org.gjt.sp.jedit.input.AbstractInputHandler org.gjt.sp.jedit.gui.InputHandler
All known Subclasses: org.gjt.sp.jedit.gui.DefaultInputHandler,
InputHandler | abstract public class InputHandler extends AbstractInputHandler (Code) | | An input handler converts the user's key strokes into concrete actions.
It also takes care of macro recording and action repetition.
This class provides all the necessary support code for an input
handler, but doesn't actually do any key binding logic. It is up
to the implementations of this class to do so.
author: Slava Pestov version: $Id: InputHandler.java 10775 2007-09-30 20:52:43Z kpouer $ See Also: org.gjt.sp.jedit.gui.DefaultInputHandler |
InputHandler | public InputHandler(View view)(Code) | | Creates a new input handler.
Parameters: view - The view |
addKeyBinding | abstract public void addKeyBinding(String keyBinding, String action)(Code) | | Adds a key binding to this input handler.
Parameters: keyBinding - The key binding (the format of this isinput-handler specific) Parameters: action - The action |
addKeyBinding | abstract public void addKeyBinding(String keyBinding, EditAction action)(Code) | | Adds a key binding to this input handler.
Parameters: keyBinding - The key binding (the format of this isinput-handler specific) Parameters: action - The action |
getLastAction | public EditAction getLastAction()(Code) | | Returns the last executed action.
since: jEdit 2.5pre5 |
getRepeatCount | public int getRepeatCount()(Code) | | Returns the number of times the next action will be repeated.
|
handleKey | final public boolean handleKey(KeyEventTranslator.Key keyStroke)(Code) | | Handles a keystroke.
Parameters: keyStroke - The key stroke. true if the input could be handled. since: jEdit 4.2pre5 |
invokeAction | public void invokeAction(String action)(Code) | | Invokes the specified action, repeating and recording it as
necessary.
Parameters: action - The action since: jEdit 4.2pre1 |
invokeAction | public void invokeAction(EditAction action)(Code) | | Invokes the specified action, repeating and recording it as
necessary.
Parameters: action - The action |
invokeLastAction | public void invokeLastAction()(Code) | | |
invokeReadNextChar | protected void invokeReadNextChar(char ch)(Code) | | |
processKeyEvent | public void processKeyEvent(KeyEvent evt, int from, boolean global)(Code) | | Forwards key events directly to the input handler.
This is slightly faster than using a KeyListener
because some Swing overhead is avoided.
since: 4.3pre7 |
readNextChar | public void readNextChar(String msg, String code)(Code) | | Invokes the specified BeanShell code, replacing __char__ in the
code with the next input character.
Parameters: msg - The prompt to display in the status bar Parameters: code - The code since: jEdit 3.2pre2 |
removeAllKeyBindings | abstract public void removeAllKeyBindings()(Code) | | Removes all key bindings from this input handler.
|
removeKeyBinding | abstract public void removeKeyBinding(String keyBinding)(Code) | | Removes a key binding from this input handler.
Parameters: keyBinding - The key binding |
setRepeatCount | public void setRepeatCount(int repeatCount)(Code) | | Sets the number of times the next action will be repeated.
Parameters: repeatCount - The repeat count |
userInput | protected void userInput(char ch)(Code) | | |
|
|