javax.swing.JButton.getMinimumSize()方法的使用及代码示例

x33g5p2x  于2022-01-21 转载在 其他  
字(4.3k)|赞(0)|评价(0)|浏览(142)

本文整理了Java中javax.swing.JButton.getMinimumSize()方法的一些代码示例,展示了JButton.getMinimumSize()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。JButton.getMinimumSize()方法的具体详情如下:
包路径:javax.swing.JButton
类名称:JButton
方法名:getMinimumSize

JButton.getMinimumSize介绍

暂无

代码示例

代码示例来源:origin: kiegroup/optaplanner

solvePanel.add(solveButton, "solveAction");
solvePanel.add(terminateSolvingEarlyButton, "terminateSolvingEarlyAction");
solveButton.setMinimumSize(terminateSolvingEarlyButton.getMinimumSize());
solveButton.setPreferredSize(terminateSolvingEarlyButton.getPreferredSize());

代码示例来源:origin: org.japura/japura-gui

@Override
public Dimension getMinimumSize() {
 if (isMinimumSizeSet()) {
  return super.getMinimumSize();
 }
 return calculatePreferredSize();
}

代码示例来源:origin: org.activecomponents.jadex/jadex-commons-gui

bok.setMinimumSize(bcancel.getMinimumSize());
bok.setPreferredSize(bcancel.getPreferredSize());
ps.add(bcancel, new GridBagConstraints(1,0,1,1,0,0,GridBagConstraints.SOUTHEAST, GridBagConstraints.BOTH, new Insets(2,2,2,2), 0, 0));

代码示例来源:origin: com.jtattoo/JTattoo

buttonMinSize = leftButton.getMinimumSize();

代码示例来源:origin: net.sourceforge.jadex/jadex-tools-base-swing

Dimension md = cancel.getMinimumSize();
Dimension pd = cancel.getPreferredSize();
ok.setMinimumSize(md);

代码示例来源:origin: khuxtable/seaglass

buttonMinSize = leftButton.getMinimumSize();

代码示例来源:origin: com.l2fprod.common/l2fprod-common-directorychooser

private void updateView(JFileChooser chooser) {
 if (chooser.getApproveButtonText() != null) {
  approveButton.setText(chooser.getApproveButtonText());
  approveButton.setMnemonic(chooser.getApproveButtonMnemonic());
 } else {
  if (JFileChooser.OPEN_DIALOG == chooser.getDialogType()) {
   approveButton.setText(openButtonText);
   approveButton.setToolTipText(openButtonToolTipText);
   approveButton.setMnemonic(openButtonMnemonic);
  } else {
   approveButton.setText(saveButtonText);
   approveButton.setToolTipText(saveButtonToolTipText);
   approveButton.setMnemonic(saveButtonMnemonic);
  }
 }
 cancelButton.setText(cancelButtonText);
 cancelButton.setMnemonic(cancelButtonMnemonic);
 newFolderButton.setText(newFolderText);
 newFolderButton.setToolTipText(newFolderToolTipText);
 newFolderButton.setVisible(((JDirectoryChooser)chooser).isShowingCreateDirectory());
 buttonPanel.setVisible(chooser.getControlButtonsAreShown());
 // ensure approve/cancel buttons have the same width
 approveButton.setPreferredSize(null);
 cancelButton.setPreferredSize(null);
 Dimension preferredSize = approveButton.getMinimumSize();
 preferredSize = new Dimension(Math.max(preferredSize.width, cancelButton
  .getPreferredSize().width), preferredSize.height);
 approveButton.setPreferredSize(preferredSize);
 cancelButton.setPreferredSize(preferredSize);    
}

代码示例来源:origin: net.sf.squirrel-sql.thirdparty-non-maven/openide

public void doLayout() {
  Insets ins = getInsets();
  Dimension bttn = btn.getMinimumSize();
  Dimension lbll = lbl.getPreferredSize();
  
  int height = Math.max (bttn.height, lbll.height);
  int right = getWidth() - (ins.right + bttn.width);
  
  
  btn.setBounds (right, ins.top, 
    bttn.width, height);
  
  lbl.setBounds (ins.left, ins.top, right, height);
  
  jsc.setBounds (ins.left, height, getWidth() - (ins.left + ins.right), 
    getHeight() - height);
}

代码示例来源:origin: net.sf.squirrel-sql.thirdpary-non-maven/openide

public void doLayout() {
  Insets ins = getInsets();
  Dimension bttn = btn.getMinimumSize();
  Dimension lbll = lbl.getPreferredSize();
  
  int height = Math.max (bttn.height, lbll.height);
  int right = getWidth() - (ins.right + bttn.width);
  
  
  btn.setBounds (right, ins.top, 
    bttn.width, height);
  
  lbl.setBounds (ins.left, ins.top, right, height);
  
  jsc.setBounds (ins.left, height, getWidth() - (ins.left + ins.right), 
    getHeight() - height);
}

代码示例来源:origin: eu.mihosoft.vrl/vrl

button.getMinimumSize().height));

代码示例来源:origin: eu.mihosoft.vrl/vrl

button.getMinimumSize().height));

代码示例来源:origin: eu.mihosoft.vrl/vrl

button.getMinimumSize().height));

代码示例来源:origin: eu.mihosoft.vrl/vrl

button.getMinimumSize().height));

代码示例来源:origin: eu.mihosoft.vrl/vrl

button.getMinimumSize().height));

代码示例来源:origin: eu.mihosoft.vrl/vrl

button.getMinimumSize().height));

代码示例来源:origin: eu.mihosoft.vrl/vrl

button.getMinimumSize().height));

代码示例来源:origin: eu.mihosoft.vrl/vrl

button.getMinimumSize().height));

代码示例来源:origin: eu.mihosoft.vrl/vrl

button.getMinimumSize().height));

代码示例来源:origin: eu.mihosoft.vrl/vrl

button.getMinimumSize().height));

代码示例来源:origin: eu.mihosoft.vrl/vrl

button.getMinimumSize().height));

相关文章

JButton类方法