}
getContentPane().setLayout(new BorderLayout());
CollapsiblePanes panes = new CollapsiblePanes();
CollapsiblePane descriptionPane = new CollapsiblePane("Using Filters");
MultilineLabel label = new MultilineLabel(getDescription());
label.setBorder(BorderFactory.createEmptyBorder(8, 10, 8, 10));
descriptionPane.setContentPane(label);
try
{
descriptionPane.setCollapsed(true);
}
catch (PropertyVetoException e)
{
log.warn(e.getMessage(), e);
}
CollapsiblePane comboPane = new CollapsiblePane("Saved Filters");
comboPane.getContentPane().setLayout(new BoxLayout(comboPane.getContentPane(), BoxLayout.X_AXIS));
JPanel comboPanel = new JPanel();
comboPanel.setLayout(new BoxLayout(comboPanel, BoxLayout.X_AXIS));
comboPanel.setBorder(BorderFactory.createEmptyBorder(8, 10, 8, 10));
comboPane.setEmphasized(true);
try
{
comboPane.setCollapsed(true);
}
catch (PropertyVetoException e)
{
log.warn(e.getMessage(), e);
}
filterCombo = new JComboBox(filterHistory);
filterCombo.setEditable(false);
comboPanel.add(filterCombo);
comboPanel.add(comboFilterButton);
comboPanel.add(comboRemoveFilterButton);
comboPane.setContentPane(comboPanel);
CollapsiblePane fieldPane = new CollapsiblePane("New Filter");
JPanel fieldPanel = new JPanel();
fieldPane.setEmphasized(true);
fieldPanel.setLayout(new BoxLayout(fieldPanel, BoxLayout.X_AXIS));
fieldPanel.setBorder(BorderFactory.createEmptyBorder(8, 10, 8, 10));
fieldPanel.add(filterField);
fieldPanel.add(textFilterButton);
fieldPanel.add(textSaveFilterButton);
fieldPane.setContentPane(fieldPanel);
panes.add(fieldPane);
panes.add(comboPane);
panes.add(descriptionPane);