ide/src/org/xnap/commons/gui/shortcut/EmacsKeyBindings.java
public static void unload() {
		JTextComponent[] jtcs = new JTextComponent[] { new JTextArea(),
				new JTextPane(), new JTextField(), new JEditorPane(), };

		for (int i = 0; i < jtcs.length; i++) {
			Keymap backup = JTextComponent.getKeymap(jtcs[i].getClass()
					.getName());

			if (backup != null) {
				Keymap current = jtcs[i].getKeymap();
				current.removeBindings();

				Action[] bound = backup.getBoundActions();
				for (int j = 0; j < bound.length; j++) {
					KeyStroke[] strokes = backup
							.getKeyStrokesForAction(bound[i]);
					for (int k = 0; k < strokes.length; k++) {
						current.addActionForKeyStroke(strokes[k], bound[j]);
					}
				}
				current.setDefaultAction(backup.getDefaultAction());
			}
		}
	}
/***
	 * Restores the original keybindings for the concrete subclasses of
	 * {@link JTextComponent}.
	 * 
	 */
Restores the original keybindings for the concrete subclasses of
JTextComponent.
Restores the original keybindings for the concrete subclasses of JTextComponent .
public static void unload() {
		JTextComponent[] jtcs = new JTextComponent[] { new JTextArea(),
				new JTextPane(), new JTextField(), new JEditorPane(), };
		for (int i = 0; i < jtcs.length; i++) {
			Keymap backup = JTextComponent.getKeymap(jtcs[i].getClass()
					.getName());
			if (backup != null) {
				Keymap current = jtcs[i].getKeymap();
				current.removeBindings();
				Action[] bound = backup.getBoundActions();
				for (int j = 0; j < bound.length; j++) {
					KeyStroke[] strokes = backup
							.getKeyStrokesForAction(bound[i]);
					for (int k = 0; k < strokes.length; k++) {
						current.addActionForKeyStroke(strokes[k], bound[j]);
					}
				}
				current.setDefaultAction(backup.getDefaultAction());
			}
		}
	}
public static void unload ( ) { JTextComponent [ ] jtcs = new JTextComponent [ ] { new JTextArea ( ) , new JTextPane ( ) , new JTextField ( ) , new JEditorPane ( ) , } ; for ( int i = 0 ; i < jtcs . length ; i ++ ) { Keymap backup = JTextComponent . getKeymap ( jtcs [ i ] . getClass ( ) . getName ( ) ) ; if ( backup != null ) { Keymap current = jtcs [ i ] . getKeymap ( ) ; current . removeBindings ( ) ; Action [ ] bound = backup . getBoundActions ( ) ; for ( int j = 0 ; j < bound . length ; j ++ ) { KeyStroke [ ] strokes = backup . getKeyStrokesForAction ( bound [ i ] ) ; for ( int k = 0 ; k < strokes . length ; k ++ ) { current . addActionForKeyStroke ( strokes [ k ] , bound [ j ] ) ; } } current . setDefaultAction ( backup . getDefaultAction ( ) ) ; } } }
Restores the original keybindings for the concrete subclasses of
 {@link JTextComponent}.
Restores the original keybindings for the concrete subclasses of { @link JTextComponent } .