本文整理了Java中javax.swing.JTextField.setFocusTraversalKeys()
方法的一些代码示例,展示了JTextField.setFocusTraversalKeys()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。JTextField.setFocusTraversalKeys()
方法的具体详情如下:
包路径:javax.swing.JTextField
类名称:JTextField
方法名:setFocusTraversalKeys
暂无
代码示例来源:origin: org.netbeans.modules/org-netbeans-modules-swingapp
private void setupAccelField() {
acceleratorListener = new AcceleratorKeyListener(this);
// add the special listener
acceleratorText.addKeyListener(acceleratorListener);
// turn off focus keys
acceleratorText.setFocusTraversalKeys(KeyboardFocusManager.FORWARD_TRAVERSAL_KEYS, Collections.EMPTY_SET);
acceleratorText.setFocusTraversalKeys(KeyboardFocusManager.BACKWARD_TRAVERSAL_KEYS, Collections.EMPTY_SET);
}
代码示例来源:origin: org.netbeans.modules/org-netbeans-modules-apisupport-wizards
/** Creates new form ShortcutCustomizerPanel */
public ShortcutEnterPanel() {
initComponents();
bTab = new JButton();
bClear = new JButton();
loc(bTab, "CTL_Tab");
loc(bClear, "CTL_Clear");
tfShortcut.setFocusTraversalKeys(
KeyboardFocusManager.BACKWARD_TRAVERSAL_KEYS,
Collections.<AWTKeyStroke>emptySet()
);
tfShortcut.setFocusTraversalKeys(
KeyboardFocusManager.DOWN_CYCLE_TRAVERSAL_KEYS,
Collections.<AWTKeyStroke>emptySet()
);
tfShortcut.setFocusTraversalKeys(
KeyboardFocusManager.UP_CYCLE_TRAVERSAL_KEYS,
Collections.<AWTKeyStroke>emptySet()
);
tfShortcut.addKeyListener(listener);
}
代码示例来源:origin: org.gephi/directory-chooser
filenameTextField.setFocusTraversalKeys(KeyboardFocusManager.FORWARD_TRAVERSAL_KEYS, newTKeys);
代码示例来源:origin: org.scijava/ui-behaviour
textField.getDocument().addDocumentListener( autoComplete );
textField.getInputMap().put( KeyStroke.getKeyStroke( KeyEvent.VK_ENTER, 0 ), COMMIT_ACTION );
textField.setFocusTraversalKeys( KeyboardFocusManager.FORWARD_TRAVERSAL_KEYS, Collections.emptySet() );
textField.getInputMap().put( KeyStroke.getKeyStroke( KeyEvent.VK_TAB, 0 ), COMMIT_ACTION );
textField.getActionMap().put( COMMIT_ACTION, autoComplete.new CommitAction() );
代码示例来源:origin: org.scijava/ui-behaviour
textField.getInputMap().put( KeyStroke.getKeyStroke( KeyEvent.VK_ENTER, 0 ), COMMIT_ACTION );
textField.getInputMap().put( KeyStroke.getKeyStroke( ' ' ), COMMIT_ACTION );
textField.setFocusTraversalKeys( KeyboardFocusManager.FORWARD_TRAVERSAL_KEYS, Collections.emptySet() );
textField.getInputMap().put( KeyStroke.getKeyStroke( KeyEvent.VK_TAB, 0 ), COMMIT_ACTION );
textField.getActionMap().put( COMMIT_ACTION, autoComplete.new CommitAction() );
代码示例来源:origin: blurpy/kouchat
msgTF.setFocusTraversalKeys(KeyboardFocusManager.FORWARD_TRAVERSAL_KEYS,
new HashSet<AWTKeyStroke>());
内容来源于网络,如有侵权,请联系作者删除!