本文整理了Java中javax.swing.JEditorPane.selectAll()
方法的一些代码示例,展示了JEditorPane.selectAll()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。JEditorPane.selectAll()
方法的具体详情如下:
包路径:javax.swing.JEditorPane
类名称:JEditorPane
方法名:selectAll
暂无
代码示例来源:origin: net.sf.taverna.t2.ui-activities/stringconstant-activity-ui
public void whenOpened() {
scriptTextArea.requestFocus();
if (scriptTextArea.getText().equals(StringConstantTemplateService.DEFAULT_VALUE)) {
scriptTextArea.selectAll();
}
}
代码示例来源:origin: stackoverflow.com
JEditorPane citEditorPane;
//user fills pane with MLA citations.
citEditorPane.selectAll();
citEditorPane.copy();
citEditorPane.select(0, 0);
代码示例来源:origin: org.jspresso.framework/jspresso-swing-components
/**
* {@inheritDoc}
*/
@Override
protected Transferable createTransferable(JComponent c) {
String text = detailsPane.getSelectedText();
if (text == null || text.equals("")) {
detailsPane.selectAll();
text = detailsPane.getSelectedText();
detailsPane.select(-1, -1);
}
return new StringSelection(text);
}
}
代码示例来源:origin: org.jspresso/jspresso-swing-components
/**
* {@inheritDoc}
*/
@Override
protected Transferable createTransferable(@SuppressWarnings("unused")
JComponent c) {
String text = detailsPane.getSelectedText();
if (text == null || text.equals("")) {
detailsPane.selectAll();
text = detailsPane.getSelectedText();
detailsPane.select(-1, -1);
}
return new StringSelection(text);
}
}
代码示例来源:origin: dcaoyuan/nbscala
editorPane.selectAll ();
代码示例来源:origin: net.imagej/ij
public void keyPressed(KeyEvent e) {
int keyCode = e.getKeyCode();
ij.IJ.setKeyDown(keyCode);
escapePressed = keyCode==KeyEvent.VK_ESCAPE;
if (keyCode==KeyEvent.VK_C) {
if (editorPane.getSelectedText()==null || editorPane.getSelectedText().length()==0)
editorPane.selectAll();
editorPane.copy();
editorPane.select(0,0);
} else if (keyCode==KeyEvent.VK_ENTER || keyCode==KeyEvent.VK_W || escapePressed)
dispose();
}
代码示例来源:origin: imagej/ImageJA
public void keyPressed(KeyEvent e) {
int keyCode = e.getKeyCode();
ij.IJ.setKeyDown(keyCode);
escapePressed = keyCode==KeyEvent.VK_ESCAPE;
if (keyCode==KeyEvent.VK_C) {
if (editorPane.getSelectedText()==null || editorPane.getSelectedText().length()==0)
editorPane.selectAll();
editorPane.copy();
editorPane.select(0,0);
} else if (keyCode==KeyEvent.VK_ENTER || keyCode==KeyEvent.VK_W || escapePressed)
dispose();
}
代码示例来源:origin: freeplane/freeplane
textEditor.selectAll();
内容来源于网络,如有侵权,请联系作者删除!