Package fr.soleil.comete.swing

Examples of fr.soleil.comete.swing.Button


        setLayout(new GridBagLayout());
        final TitledBorder titledBorder = new TitledBorder("Custom parameters");
        titledBorder.setTitleFont(new Font("Arial", Font.ITALIC, 15));
        setBorder(titledBorder);

        Button addButton = new Button();
        addButton.setText("+");

        GridBagConstraints addButtonGridBagConstraints = new GridBagConstraints();
        addButtonGridBagConstraints.gridx = 0;
        addButtonGridBagConstraints.gridy = GridBagConstraints.RELATIVE;
        addButtonGridBagConstraints.fill = GridBagConstraints.NONE;
        addButtonGridBagConstraints.anchor = GridBagConstraints.CENTER;
        addButtonGridBagConstraints.gridwidth = 3;

        this.add(addButton, addButtonGridBagConstraints);

        addButton.setEnabled(isEnabled);

        addButton.addButtonListener(new IButtonListener() {

            @Override
            public void actionPerformed(EventObject arg0) {
                final JDialog dialog = new JDialog(JOptionPane.getRootFrame(), "Add custom parameter", true);
View Full Code Here


        TextField textField = new CustomTextField(entry, this, actor);

        textField.setEnabled(isEnabled);

        Button deleteButton = new Button();
        deleteButton.setIcon(Utilities.ICONS.getIcon("flyscan.delete"));
        deleteButton.setOpaque(false);
        deleteButton.setContentAreaFilled(false);
        deleteButton.setBorderPainted(false);

        deleteButton.setEnabled(isEnabled);
        deleteButton.addButtonListener(new IButtonListener() {

            @Override
            public void actionPerformed(EventObject arg0) {

                Component[] components = getCustomParameterComponents(entry);
View Full Code Here

        okConstraints.gridx = 0;
        okConstraints.gridy = 2;
        okConstraints.anchor = GridBagConstraints.CENTER;
        okConstraints.insets = new Insets(5, 5, 5, 5);

        okButton = new Button("OK");
        add(okButton, okConstraints);

        okButton.addMouseListener(new MouseAdapter() {

            @Override
View Full Code Here

        this.add(scrollbox, indexesGridBagConstraints);

        JPanel addPanel = new JPanel();
        addPanel.setLayout(new GridBagLayout());

        addButton = new Button();
        addButton.setText("+");
        addButton.setMargin(CometeUtils.getzInset());

        removeButton = new Button();
        removeButton.setText("- ");
        removeButton.setMargin(CometeUtils.getzInset());

        removeButton.setEnabled(trajectory.getPoints().size() > 1);
View Full Code Here

        }

        JPanel addPanel = new JPanel();
        addPanel.setLayout(new GridBagLayout());

        addButton = new Button();
        addButton.setText("+");

        removeButton = new Button();
        removeButton.setText("-");

        removeButton.setEnabled(isEnabled() && this.intervals.size() > 1);

        addButton.addButtonListener(new IButtonListener() {
View Full Code Here

        // Status
        statusArea = new TextArea();
        statusArea.setBorder(BorderFactory.createTitledBorder("Status"));

        // Start
        startButton = new Button();
        // Stop
        stopButton = new Button();

        // excitationEnergy
        // Label
        excitationEnergyLabel = new JLabel();
        excitationEnergyLabel.setText("Excitation Energy");
View Full Code Here

        JPanel addPanel = new JPanel();
        addPanel.setLayout(new GridBagLayout());

        addButton.setText("+");

        removeButton = new Button();
        removeButton.setText("-");

        addButton.setEnabled(this.comboBoxes.size() < this.possibleValues.size());
        removeButton.setEnabled(this.comboBoxes.size() > 1);
View Full Code Here

        openButtonViewer.setText("OpenDataSource");
        currentLabel = new JLabel("Current:");
        currentLabel.setFont(new Font("Default", Font.BOLD, 15));
        currentViewer = generateLabel();
        currentViewer.setCometeFont(FontTool.getCometeFont(new Font("Default", Font.BOLD, 15)));
        closeButtonViewer = new Button();
        closeButtonViewer.setText("CloseDataSource");

        GridBagConstraints inputLabelConstraints = new GridBagConstraints();
        inputLabelConstraints.fill = GridBagConstraints.NONE;
        inputLabelConstraints.gridx = 0;
View Full Code Here

                    if (isEnabled()) {
                        super.actionPerformed(event);
                    }
                };
            };
            startCommandViewer = new Button() {
                private static final long serialVersionUID = -679641383339305170L;

                @Override
                public void actionPerformed(ActionEvent event) {
                    super.actionPerformed(event);
                    readDataSpectrumButton.actionPerformed(null);
                }
            };
        }
        else {
            startCommandViewer = new Button();
        }
        startCommandViewer.setText("Start");

        ((JButton) startCommandViewer).setIcon(new ImageIcon(getClass().getResource(
                "/org/tango-project/tango-icon-theme/22x22/actions/media-playback-start.png")));
        stopCommandViewer = new Button("Abort");
        ((JButton) stopCommandViewer).setIcon(new ImageIcon(getClass().getResource(
                "/org/tango-project/tango-icon-theme/22x22/actions/media-playback-stop.png")));
        clearDataCommandViewer = new Button();
        clearDataCommandViewer.setText("Clear Data");
        ((JButton) clearDataCommandViewer).setIcon(new ImageIcon(getClass().getResource(
                "/org/tango-project/tango-icon-theme/22x22/places/user-trash.png")));

        GridBagConstraints startConstraints2 = new GridBagConstraints();
View Full Code Here

        openButtonViewer.setText("OpenDataSource");
        currentLabel = new JLabel("Current:");
        currentLabel.setFont(new Font("Default", Font.BOLD, 15));
        currentViewer = generateLabel();
        currentViewer.setCometeFont(FontTool.getCometeFont(new Font("Default", Font.BOLD, 15)));
        closeButtonViewer = new Button();
        closeButtonViewer.setText("CloseDataSource");

        GridBagConstraints inputLabelConstraints = new GridBagConstraints();
        inputLabelConstraints.fill = GridBagConstraints.NONE;
        inputLabelConstraints.gridx = 0;
View Full Code Here

TOP

Related Classes of fr.soleil.comete.swing.Button

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.