private JPanel wrapComponent(JComponent c) {
JPanel result = new JPanel(new GridBagLayout());
GridBagConstraints gbc = new GridBagConstraints();
gbc.gridx = 0;
gbc.gridy = 0;
gbc.anchor = GridBagConstraints.NORTHWEST;
gbc.fill = GridBagConstraints.HORIZONTAL;
gbc.gridwidth = 2;
gbc.weightx = 0.9;
gbc.insets = rightGap;
result.add(c, gbc);
c.setBackground(SystemColor.text);
gbc.weightx = 0.9;
gbc.weighty = 0.9;
gbc.gridx = 0;
gbc.gridy++;
gbc.gridwidth = 2;
gbc.fill = GridBagConstraints.BOTH;
JPanel filler = new JPanel();
filler.setBackground(SystemColor.text);
result.setBackground(SystemColor.text);
result.add(filler, gbc);
return result;
}
ReportViewComponent.java 文件源码
java
阅读 22
收藏 0
点赞 0
评论 0
项目:incubator-taverna-workbench
作者:
评论列表
文章目录