Java JButton Settings getButtonPane()

Here you can find the source of getButtonPane()

Description

get Button Pane

License

Open Source License

Declaration

static JPanel getButtonPane() 

Method Source Code

//package com.java2s;
/********************************************************************************
 * Copyright (c) 2009 Regents of the University of Minnesota
 *
 * This Software was written at the Minnesota Supercomputing Institute
 * http://msi.umn.edu//from   ww w .j  a  v a 2 s . c om
 *
 * All rights reserved. The following statement of license applies
 * only to this file, and and not to the other files distributed with it
 * or derived therefrom.  This file is made available under the terms of
 * the Eclipse Public License v1.0 which accompanies this distribution,
 * and is available at http://www.eclipse.org/legal/epl-v10.html
 *
 * Contributors:
 * Minnesota Supercomputing Institute - initial API and implementation
 *******************************************************************************/

import java.awt.Component;

import javax.swing.BorderFactory;
import javax.swing.Box;
import javax.swing.BoxLayout;

import javax.swing.JPanel;

public class Main {
    static JPanel getButtonPane() {
        final JPanel buttonPane = new JPanel();
        buttonPane
                .setLayout(new BoxLayout(buttonPane, BoxLayout.LINE_AXIS));
        buttonPane.setBorder(BorderFactory
                .createEmptyBorder(10, 10, 10, 10));
        buttonPane.add(Box.createHorizontalGlue());
        buttonPane.setAlignmentX(Component.LEFT_ALIGNMENT);
        return buttonPane;
    }
}

Related

  1. getButton(Container container, String text)
  2. getButton(String displayText, ActionListener actionListener)
  3. getButtonAsLink(String text)
  4. getButtonBorderColor(Color color)
  5. getButtonColor()
  6. getButtonSelectColor()
  7. getButtonSelectedInt(ButtonGroup buttonGroup)
  8. getButtonSelectedString(ButtonGroup buttonGroup)
  9. getDefaultFatButtonMargin()