本文整理了Java中javax.swing.JEditorPane.getInputMap()
方法的一些代码示例,展示了JEditorPane.getInputMap()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。JEditorPane.getInputMap()
方法的具体详情如下:
包路径:javax.swing.JEditorPane
类名称:JEditorPane
方法名:getInputMap
暂无
代码示例来源:origin: de.sciss/jsyntaxpane
@Override
public void deinstall(JEditorPane editorPane) {
List<SyntaxComponent> l = editorComponents.get(editorPane);
for (SyntaxComponent c : editorComponents.get(editorPane)) {
c.deinstall(editorPane);
}
editorComponents.clear();
editorPane.getInputMap().clear();
editorPane.getActionMap().clear();
}
代码示例来源:origin: com.github.vlsi.mxgraph/jgraphx
InputMap editorInputMap = editorPane.getInputMap();
InputMap textInputMap = textArea.getInputMap();
代码示例来源:origin: org.tinyjee.jgraphx/jgraphx
InputMap editorInputMap = editorPane.getInputMap();
InputMap textInputMap = textArea.getInputMap();
代码示例来源:origin: io.ultreia.java4all.jaxx/jaxx-widgets-extra
static protected void addUndoRedoSupport(JEditorPane editor) {
UndoManager undo = (UndoManager) editor.getClientProperty(UNDO_MANAGER);
if (undo == null) {
undo = new UndoManager();
editor.putClientProperty(UNDO_MANAGER, undo);
Action undoAction = new UndoAction(undo);
KeyStroke key = KeyStroke.getKeyStroke(KeyEvent.VK_Z,
Event.CTRL_MASK);
editor.getInputMap().put(key, "undo");
editor.getActionMap().put("undo", undoAction);
Action redoAction = new RedoAction(undo);
key = KeyStroke.getKeyStroke(KeyEvent.VK_Z, KeyEvent.CTRL_MASK
+ KeyEvent.SHIFT_DOWN_MASK);
editor.getInputMap().put(key, "redo");
editor.getActionMap().put("redo", redoAction);
}
Document doc = editor.getDocument();
doc.addUndoableEditListener(undo);
}
代码示例来源:origin: org.nuiton/nuiton-widgets
static protected void addUndoRedoSupport(JEditorPane editor) {
UndoManager undo = (UndoManager) editor.getClientProperty(UNDO_MANAGER);
if (undo == null) {
undo = new UndoManager();
editor.putClientProperty(UNDO_MANAGER, undo);
Action undoAction = new UndoAction(undo);
KeyStroke key = KeyStroke.getKeyStroke(KeyEvent.VK_Z,
Event.CTRL_MASK);
editor.getInputMap().put(key, "undo");
editor.getActionMap().put("undo", undoAction);
Action redoAction = new RedoAction(undo);
key = KeyStroke.getKeyStroke(KeyEvent.VK_Z, KeyEvent.CTRL_MASK
+ KeyEvent.SHIFT_DOWN_MASK);
editor.getInputMap().put(key, "redo");
editor.getActionMap().put("redo", redoAction);
}
Document doc = editor.getDocument();
doc.addUndoableEditListener(undo);
}
代码示例来源:origin: com.github.vlsi.mxgraph/jgraphx
editorEnterActionMapKey = editorPane.getInputMap().get(enterKeystroke);
textEnterActionMapKey = editorPane.getInputMap().get(enterKeystroke);
代码示例来源:origin: org.tinyjee.jgraphx/jgraphx
editorEnterActionMapKey = editorPane.getInputMap().get(enterKeystroke);
textEnterActionMapKey = editorPane.getInputMap().get(enterKeystroke);
代码示例来源:origin: de.sciss/syntaxpane
@Override
public void deinstall(JEditorPane editorPane) {
for (SyntaxComponent c : editorComponents.get(editorPane)) {
c.deinstall(editorPane);
}
editorComponents.clear();
editorPane.getInputMap().clear();
ActionMap m = editorPane.getActionMap();
for (Object key : editorPane.getActionMap().keys()) {
Action a = m.get(key);
if (a instanceof SyntaxAction) {
((SyntaxAction) a).deinstall(editorPane);
}
}
m.clear();
}
代码示例来源:origin: freeplane/freeplane
textArea.getInputMap().put(KeyStroke.getKeyStroke(KeyEvent.VK_ENTER, KeyEvent.ALT_MASK, false), dialogCloser);
textArea.getActionMap().put(dialogCloser, dialogCloser);
代码示例来源:origin: eu.mihosoft.vrl/vrl
InputMap keyMap = editor.getInputMap();
代码示例来源:origin: de.sciss/jsyntaxpane
imap.setParent(editorPane.getInputMap());
ActionMap amap = new ActionMap();
amap.setParent(editorPane.getActionMap());
代码示例来源:origin: de.sciss/syntaxpane
imap.setParent(editorPane.getInputMap());
ActionMap amap = new ActionMap();
amap.setParent(editorPane.getActionMap());
代码示例来源:origin: freeplane/freeplane
textfield.setEditorKit(kit);
final InputMap inputMap = textfield.getInputMap();
final ActionMap actionMap = textfield.getActionMap();
actionMap.put(DefaultEditorKit.pasteAction, pasteAction);
内容来源于网络,如有侵权,请联系作者删除!