本文整理汇总了Java中javax.swing.plaf.metal.MetalIconFactory.getFileChooserNewFolderIcon方法的典型用法代码示例。如果您正苦于以下问题:Java MetalIconFactory.getFileChooserNewFolderIcon方法的具体用法?Java MetalIconFactory.getFileChooserNewFolderIcon怎么用?Java MetalIconFactory.getFileChooserNewFolderIcon使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类javax.swing.plaf.metal.MetalIconFactory
的用法示例。
在下文中一共展示了MetalIconFactory.getFileChooserNewFolderIcon方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: createPanel6
import javax.swing.plaf.metal.MetalIconFactory; //导入方法依赖的package包/类
/**
* This panel contains combo boxes with a custom renderer.
*
* @return A panel.
*/
private JPanel createPanel6()
{
JPanel panel = new JPanel(new BorderLayout());
this.comboState6 = new JCheckBox("Enabled", true);
this.comboState6.setActionCommand("COMBO_STATE6");
this.comboState6.addActionListener(this);
panel.add(this.comboState6, BorderLayout.EAST);
JPanel controlPanel = new JPanel();
controlPanel.setBorder(BorderFactory.createTitledBorder("Custom Renderer: "));
this.combo11 = new JComboBox(new Object[] {
MetalIconFactory.getFileChooserHomeFolderIcon(),
MetalIconFactory.getFileChooserNewFolderIcon()});
this.combo11.setPreferredSize(new Dimension(100, 30));
this.combo11.setRenderer(new CustomCellRenderer());
this.combo12 = new JComboBox(new Object[] {
MetalIconFactory.getFileChooserHomeFolderIcon(),
MetalIconFactory.getFileChooserNewFolderIcon()});
this.combo12.setPreferredSize(new Dimension(100, 30));
this.combo12.setRenderer(new CustomCellRenderer());
this.combo12.setEditable(true);
controlPanel.add(combo11);
controlPanel.add(combo12);
panel.add(controlPanel);
return panel;
}
示例2: createPanel6
import javax.swing.plaf.metal.MetalIconFactory; //导入方法依赖的package包/类
/**
* This panel contains combo boxes with a custom renderer.
*
* @return A panel.
*/
private JPanel createPanel6()
{
JPanel panel = new JPanel(new BorderLayout());
this.comboState6 = new JCheckBox("Enabled", true);
this.comboState6.setActionCommand("COMBO_STATE6");
this.comboState6.addActionListener(this);
panel.add(this.comboState6, BorderLayout.EAST);
JPanel controlPanel = new JPanel();
controlPanel.setBorder(BorderFactory.createTitledBorder("Custom Renderer: "));
this.combo11 = new JComboBox(new Object[] {
MetalIconFactory.getFileChooserHomeFolderIcon(),
MetalIconFactory.getFileChooserNewFolderIcon()});
this.combo11.setPreferredSize(new Dimension(100, 30));
this.combo11.setRenderer(new CustomCellRenderer());
this.combo12 = new JComboBox(new Object[] {
MetalIconFactory.getFileChooserHomeFolderIcon(),
MetalIconFactory.getFileChooserNewFolderIcon()});
this.combo12.setPreferredSize(new Dimension(100, 30));
this.combo12.setRenderer(new CustomCellRenderer());
this.combo12.setEditable(true);
controlPanel.add(combo11);
controlPanel.add(combo12);
panel.add(controlPanel);
return panel;
}