本文整理汇总了Java中javax.swing.JButton.setHideActionText方法的典型用法代码示例。如果您正苦于以下问题:Java JButton.setHideActionText方法的具体用法?Java JButton.setHideActionText怎么用?Java JButton.setHideActionText使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类javax.swing.JButton
的用法示例。
在下文中一共展示了JButton.setHideActionText方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: getApplicationToolbar
import javax.swing.JButton; //导入方法依赖的package包/类
private ProfilerToolbar getApplicationToolbar() {
if (applicationToolbar == null) {
applicationToolbar = ProfilerToolbar.create(true);
applicationToolbar.addSpace(2);
applicationToolbar.addSeparator();
applicationToolbar.addSpace(5);
JLabel apLabel = new GrayLabel(Bundle.ProfilerWindow_application());
applicationToolbar.add(apLabel);
applicationToolbar.addSpace(2);
JButton apThreadDumpButton = new JButton(TakeThreadDumpAction.getInstance());
apThreadDumpButton.setHideActionText(true);
// apThreadDumpButton.setText(Bundle.ProfilerWindow_threadDump());
applicationToolbar.add(apThreadDumpButton);
applicationToolbar.addSpace(3);
JButton apHeapDumpButton = new JButton(HeapDumpAction.getInstance());
apHeapDumpButton.setHideActionText(true);
// apHeapDumpButton.setText(Bundle.ProfilerWindow_heapDump());
applicationToolbar.add(apHeapDumpButton);
applicationToolbar.addSpace(3);
JButton apGCButton = new JButton(RunGCAction.getInstance());
apGCButton.setHideActionText(true);
// apGCButton.setText(Bundle.ProfilerWindow_gc());
applicationToolbar.add(apGCButton);
}
return applicationToolbar;
}
示例2: PopuleBarra
import javax.swing.JButton; //导入方法依赖的package包/类
public void PopuleBarra(JComponent obj) {
ButtonGroup buttons = new ButtonGroup();
Barra = obj;
Acao ac = new Acao(editor, "?", "Controler.interface.BarraLateral.Nothing.img", "Controler.interface.BarraLateral.Nothing.Texto", null);
JToggleButton btn = arrume(new JToggleButton(ac));
buttons.add(btn);
obj.add(btn);
btn.setSelected(true);
ac.IDX = -1;
this.BtnNothing = btn;
int i = 0;
for (ConfigAcao ca : Lista) {
if (ca.tipo == TipoConfigAcao.tpBotoes || ca.tipo == TipoConfigAcao.tpAny) {
ac = new Acao(editor, ca.texto, ca.ico, ca.descricao, ca.command);
ac.IDX = i++;
btn = arrume(new JToggleButton(ac));
buttons.add(btn);
//obj.add(btn);
listaBotoes.put(ca.command, btn);
}
}
menuComandos c = menuComandos.cmdDel;
String str = "Controler.comandos." + c.toString().substring(3).toLowerCase();
ac = new Acao(editor, Editor.fromConfiguracao.getValor(str + ".descricao"), str + ".img", str + ".descricao", c.toString());
ListaDeAcoesEditaveis.add(ac);
ac.normal = false;
JButton btn2 = new JButton(ac);
btn2.setHideActionText(true);
btn2.setFocusable(false);
btn2.setPreferredSize(new Dimension(40, 40));
obj.add(btn2);
LayoutManager la = obj.getLayout();
if (la instanceof GridLayout) {
((GridLayout) la).setRows(i + 2);
}
}