Search in sources :

Example 1 with JXTitledPanel

use of org.jdesktop.swingx.JXTitledPanel in project jgnash by ccavanaugh.

the class BudgetPeriodPanel method buildHeader.

private void buildHeader(final JTableHeader header) {
    periodHeader = new JXTitledPanel(model.getPeriodDescription(), header);
    periodHeader.setBorder(ShadowBorder.getCompondShadowBorder());
}
Also used : JXTitledPanel(org.jdesktop.swingx.JXTitledPanel)

Example 2 with JXTitledPanel

use of org.jdesktop.swingx.JXTitledPanel in project jgnash by ccavanaugh.

the class AccountRowHeaderPanel method getTableHeader.

JPanel getTableHeader() {
    JTableHeader header = table.getTableHeader();
    header.setReorderingAllowed(false);
    header.setResizingAllowed(false);
    JPanel panel = new JXTitledPanel("  ", header);
    panel.setBorder(ShadowBorder.getCompondShadowBorder());
    return panel;
}
Also used : JPanel(javax.swing.JPanel) JXTitledPanel(org.jdesktop.swingx.JXTitledPanel) JTableHeader(javax.swing.table.JTableHeader)

Example 3 with JXTitledPanel

use of org.jdesktop.swingx.JXTitledPanel in project jgnash by ccavanaugh.

the class AccountRowFooterPanel method buildHeader.

private static JComponent buildHeader(final JTableHeader tableHeader) {
    final JXTitledPanel panelHeader = new JXTitledPanel(ResourceUtils.getString("Title.Summary"), tableHeader);
    panelHeader.setBorder(ShadowBorder.getCompondShadowBorder());
    return panelHeader;
}
Also used : JXTitledPanel(org.jdesktop.swingx.JXTitledPanel)

Example 4 with JXTitledPanel

use of org.jdesktop.swingx.JXTitledPanel in project jgnash by ccavanaugh.

the class ReconcileDialog method buildTablePanel.

private static JPanel buildTablePanel(final String title, final JLabel label, final JTable table) {
    JPanel p = new JPanel(new BorderLayout());
    JPanel footer = new JPanel(new FlowLayout(FlowLayout.RIGHT));
    footer.setBackground(SystemColor.inactiveCaptionBorder);
    footer.add(label);
    JScrollPane pane = new JScrollPane(table);
    pane.setBorder(new EmptyBorder(0, 0, 0, 0));
    pane.setHorizontalScrollBarPolicy(ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER);
    JXTitledPanel panel = new JXTitledPanel(title, pane);
    p.add(panel, BorderLayout.CENTER);
    p.add(footer, BorderLayout.SOUTH);
    return p;
}
Also used : JScrollPane(javax.swing.JScrollPane) JPanel(javax.swing.JPanel) JXTitledPanel(org.jdesktop.swingx.JXTitledPanel) FlowLayout(java.awt.FlowLayout) BorderLayout(java.awt.BorderLayout) EmptyBorder(javax.swing.border.EmptyBorder)

Example 5 with JXTitledPanel

use of org.jdesktop.swingx.JXTitledPanel in project jgnash by ccavanaugh.

the class MainViewPanel method addView.

void addView(final Container component, final String description, final String toolTip) {
    Objects.requireNonNull(description);
    Objects.requireNonNull(component);
    JXTitledPanel p = new JXTitledPanel(toolTip, component);
    component.setName(description);
    p.setName(description);
    JButton button = new Button(component, new VerticalTextIcon(description, false));
    button.addActionListener(this);
    button.setActionCommand(description);
    button.setName(description);
    if (toolTip != null) {
        button.setToolTipText(toolTip);
    } else {
        button.setToolTipText(description);
    }
    buttonPanel.addButton(button);
    if (contentPanel.getComponentCount() == 0) {
        last = component;
    }
    contentPanel.add(p, description);
    String lastComponent = pref.get(LAST_VIEW, "");
    if (lastComponent.equals(description)) {
        cardLayout.show(contentPanel, description);
        last = component;
    }
}
Also used : JXTitledPanel(org.jdesktop.swingx.JXTitledPanel) JButton(javax.swing.JButton) JButton(javax.swing.JButton) VerticalTextIcon(jgnash.ui.components.VerticalTextIcon)

Aggregations

JXTitledPanel (org.jdesktop.swingx.JXTitledPanel)6 JPanel (javax.swing.JPanel)2 BorderLayout (java.awt.BorderLayout)1 Dimension (java.awt.Dimension)1 FlowLayout (java.awt.FlowLayout)1 Image (java.awt.Image)1 FocusAdapter (java.awt.event.FocusAdapter)1 FocusEvent (java.awt.event.FocusEvent)1 MouseAdapter (java.awt.event.MouseAdapter)1 MouseEvent (java.awt.event.MouseEvent)1 BufferedImage (java.awt.image.BufferedImage)1 JButton (javax.swing.JButton)1 JScrollPane (javax.swing.JScrollPane)1 EmptyBorder (javax.swing.border.EmptyBorder)1 JTableHeader (javax.swing.table.JTableHeader)1 VerticalTextIcon (jgnash.ui.components.VerticalTextIcon)1 JXImageView (org.jdesktop.swingx.JXImageView)1 Painter (org.jdesktop.swingx.painter.Painter)1