javax.swing.JTree.getBorder()方法的使用及代码示例

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

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

JTree.getBorder介绍

暂无

代码示例

代码示例来源:origin: net.java.abeille/abeille

/**
   * Resets the default borders.
   */
  private static void resetDefaultBorders() {
    m_default_borders.clear();
    m_default_borders.put(JButton.class, getDefaultBorder("Button.border"));
    m_default_borders.put(JComboBox.class, getDefaultBorder("ComboBox.border"));
    m_default_borders.put(JLabel.class, new JLabel().getBorder());
    m_default_borders.put(JList.class, getDefaultBorder("List.border"));
    m_default_borders.put(JSpinner.class, getDefaultBorder("Spinner.border"));
    m_default_borders.put(JTable.class, new JTable().getBorder());
    m_default_borders.put(JTextArea.class, getDefaultBorder("TextArea.border"));
    m_default_borders.put(JTextField.class, getDefaultBorder("TextField.border"));
    m_default_borders.put(JTree.class, new JTree().getBorder());
    m_default_borders.put(JScrollPane.class, new JScrollPane().getBorder());

    m_default_borders.put(JCheckBox.class, new javax.swing.border.EmptyBorder(1, 0, 1, 2));
    m_default_borders.put(JRadioButton.class, new javax.swing.border.EmptyBorder(1, 0, 1, 2));

    /**
     * JCheckBox and JRadioButton have overriden borders because their
     * default borders have a horizontal offset that produces a rather
     * unpleasant looking GUI.
     */
  }
}

代码示例来源:origin: notzippy/JALOPY2-MAIN

_tree.setBorder(
  BorderFactory.createCompoundBorder(
    _tree.getBorder(), BorderFactory.createEmptyBorder(5, 0, 5, 5)));

相关文章

JTree类方法