edu.princeton.toy
Class TCommentingAutoCompleter

java.lang.Object
  extended by edu.princeton.swing.text.IndentingAutoCompleter
      extended by edu.princeton.toy.TUncommentingAutoCompleter
          extended by edu.princeton.toy.TCommentingAutoCompleter
All Implemented Interfaces:
AutoCompleter

public class TCommentingAutoCompleter
extends TUncommentingAutoCompleter

TCommentingAutoCompleter is an subclass of TUncommentingAutoCompleter which will also automatically update or add an autocomment when the user completes or modifies a command.


Constructor Summary
TCommentingAutoCompleter()
           
 
Method Summary
 boolean interceptKeyEvent(PHighlightedTextArea comp, KeyEvent e)
          The PHighlightedTextArea will pass all key events to its auto-completer before processing the event for itself.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TCommentingAutoCompleter

public TCommentingAutoCompleter()
Method Detail

interceptKeyEvent

public boolean interceptKeyEvent(PHighlightedTextArea comp,
                                 KeyEvent e)
The PHighlightedTextArea will pass all key events to its auto-completer before processing the event for itself.

Specified by:
interceptKeyEvent in interface AutoCompleter
Overrides:
interceptKeyEvent in class TUncommentingAutoCompleter
Parameters:
comp - The component which recieved the KeyEvent.
e - The event which occurred.
Returns:
True if the component should ignore the KeyEvent (because this method already performed a special action associated with it). In either case, KeyListeners of the component will still be informed of the event.