javax.swing.JLayeredPane.setSize()方法的使用及代码示例

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

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

JLayeredPane.setSize介绍

暂无

代码示例

代码示例来源:origin: magefree/mage

@Override
  public void componentResized(ComponentEvent e) {
    int width = ((JComponent) e.getSource()).getWidth();
    int height = ((JComponent) e.getSource()).getHeight();
    jLayeredBackgroundPane.setSize(width, height);
    jSplitPane0.setSize(width, height);
    if (height < storedHeight) {
      pnlBattlefield.setSize(0, 200);
    }
    storedHeight = height;
    sizeToScreen();
    if (!initialized) {
      String state = PreferencesDialog.getCachedValue(PreferencesDialog.KEY_BIG_CARD_TOGGLED, null);
      if (state != null && state.equals("down")) {
        jSplitPane0.setDividerLocation(1.0);
      }
      initialized = true;
    }
  }
});

代码示例来源:origin: magefree/mage

/**
 * This method initializes this
 * 
 * @return void
 */
private void initialize() {
  int w = getDlgParams().rect.width;
  int h = getDlgParams().rect.height;
  jLayeredPane = new JLayeredPane();
  add(jLayeredPane);
  jLayeredPane.setSize(w, h);
  jLayeredPane.setVisible(true);
  jLayeredPane.setOpaque(false);
  jTitle = new CustomLabel();
  jTitle.setBounds(new Rectangle(5, 3, w, 16));
  jTitle.setFont(new Font("Dialog", Font.BOLD, 14));
  jTitle.setText("Current stack: ");
  this.setLayout(null);
  jLayeredPane.setLayout(null);
  jLayeredPane.add(jTitle, null);
  //jLayeredPane.add(jTitle2, null);
  jLayeredPane.add(getJButtonAccept(), null);
  jLayeredPane.add(getJButtonResponse(), null);
  makeTransparent(jLayeredPane);
}

代码示例来源:origin: magefree/mage

jLayeredBackgroundPane.setSize(1024, 768);
this.add(jLayeredBackgroundPane);
jLayeredBackgroundPane.add(jSplitPane0, JLayeredPane.DEFAULT_LAYER);

代码示例来源:origin: apache/batik

p.setSize(600, 425);
getContentPane().add(p);

代码示例来源:origin: fr.avianey.apache-xmlgraphics/batik

p.setSize(600, 425);
getContentPane().add(p);

相关文章