Search in sources :

Example 11 with ProportionalGridPanel

use of com.mucommander.commons.util.ui.layout.ProportionalGridPanel in project mucommander by mucommander.

the class FolderPanePanel method createGeneralPanel.

/**
 * Creates the 'general' theme.
 */
private JPanel createGeneralPanel(FontChooser chooser) {
    YBoxPanel mainPanel;
    JPanel quickSearchPanel;
    ProportionalGridPanel panel;
    JPanel wrapper;
    // Initialises the quicksearch panel.
    panel = new ProportionalGridPanel(4);
    addLabelRow(panel);
    panel.add(addColorButtons(panel, chooser, "theme_editor.quick_search.unmatched_file", ThemeData.FILE_TABLE_UNMATCHED_FOREGROUND_COLOR, ThemeData.FILE_TABLE_UNMATCHED_BACKGROUND_COLOR));
    quickSearchPanel = new JPanel(new FlowLayout(FlowLayout.LEFT));
    quickSearchPanel.add(panel);
    quickSearchPanel.setBorder(BorderFactory.createTitledBorder(Translator.get("theme_editor.quick_search")));
    // Initialises the panel.
    mainPanel = new YBoxPanel();
    mainPanel.add(chooser);
    mainPanel.addSpace(10);
    mainPanel.add(quickSearchPanel);
    // Wraps everything in a border layout.
    wrapper = new JPanel(new BorderLayout());
    wrapper.add(mainPanel, BorderLayout.NORTH);
    return wrapper;
}
Also used : YBoxPanel(com.mucommander.commons.util.ui.layout.YBoxPanel) ProportionalGridPanel(com.mucommander.commons.util.ui.layout.ProportionalGridPanel)

Aggregations

ProportionalGridPanel (com.mucommander.commons.util.ui.layout.ProportionalGridPanel)11 YBoxPanel (com.mucommander.commons.util.ui.layout.YBoxPanel)4 PreviewLabel (com.mucommander.ui.chooser.PreviewLabel)4 FlowLayout (java.awt.FlowLayout)4 JPanel (javax.swing.JPanel)4 JLabel (javax.swing.JLabel)3 FontChooser (com.mucommander.ui.chooser.FontChooser)2 PrefComboBox (com.mucommander.ui.dialog.pref.component.PrefComboBox)1 Theme (com.mucommander.ui.theme.Theme)1 Component (java.awt.Component)1 BufferedImage (java.awt.image.BufferedImage)1 ImageIcon (javax.swing.ImageIcon)1 JButton (javax.swing.JButton)1 JList (javax.swing.JList)1 BasicComboBoxRenderer (javax.swing.plaf.basic.BasicComboBoxRenderer)1