Package javax.swing.border

Examples of javax.swing.border.MatteBorder


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

        visibleTitleLabel = new JLabel("Visible", SwingConstants.CENTER);
        visibleTitleLabel.setBorder(new MatteBorder(1, 1, 1, 0, Color.BLACK));
        roiTitleLabel = new JLabel("ROI", SwingConstants.CENTER);
        roiTitleLabel.setBorder(new MatteBorder(1, 1, 1, 0, Color.BLACK));
        startTitleLabel = new JLabel("Start", SwingConstants.CENTER);
        startTitleLabel.setBorder(new MatteBorder(1, 1, 1, 0, Color.BLACK));
        endTitleLabel = new JLabel("End", SwingConstants.CENTER);
        endTitleLabel.setBorder(new MatteBorder(1, 1, 1, 0, Color.BLACK));
        labelTitleLabel = new JLabel("Label", SwingConstants.CENTER);
        labelTitleLabel.setBorder(new MatteBorder(1, 1, 1, 1, Color.BLACK));

        roiValuesLabel = new JLabel("Rois Values", SwingConstants.CENTER);
        roiValuesLabel.setBorder(new MatteBorder(1, 1, 1, 1, Color.BLACK));

        if (XIA_DEVICE.equals(deviceTypeName)) {
            roiChannelTitleLabel = new JLabel("Channel to set: ");
            roiChannelTitleLabel.setFont(CHANNEL_TITLE_FONT);
            roiChannelLabel = new JLabel();
View Full Code Here


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

        visibleTitleLabel = new JLabel("Visible", SwingConstants.CENTER);
        visibleTitleLabel.setBorder(new MatteBorder(1, 1, 1, 0, Color.BLACK));
        roiTitleLabel = new JLabel("ROI", SwingConstants.CENTER);
        roiTitleLabel.setBorder(new MatteBorder(1, 1, 1, 0, Color.BLACK));
        startTitleLabel = new JLabel("Start", SwingConstants.CENTER);
        startTitleLabel.setBorder(new MatteBorder(1, 1, 1, 0, Color.BLACK));
        endTitleLabel = new JLabel("End", SwingConstants.CENTER);
        endTitleLabel.setBorder(new MatteBorder(1, 1, 1, 0, Color.BLACK));
        labelTitleLabel = new JLabel("Label", SwingConstants.CENTER);
        labelTitleLabel.setBorder(new MatteBorder(1, 1, 1, 1, Color.BLACK));

        roiValuesLabel = new JLabel("Rois Values", SwingConstants.CENTER);
        roiValuesLabel.setBorder(new MatteBorder(1, 1, 1, 1, Color.BLACK));

        if (XIA_DEVICE.equals(deviceTypeName)) {
            roiChannelTitleLabel = new JLabel("Channel to set: ");
            roiChannelTitleLabel.setFont(CHANNEL_TITLE_FONT);
            roiChannelLabel = new JLabel();
View Full Code Here

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

        visibleTitleLabel = new JLabel("Visible", SwingConstants.CENTER);
        visibleTitleLabel.setBorder(new MatteBorder(1, 1, 1, 0, Color.BLACK));
        roiTitleLabel = new JLabel("ROI", SwingConstants.CENTER);
        roiTitleLabel.setBorder(new MatteBorder(1, 1, 1, 0, Color.BLACK));
        startTitleLabel = new JLabel("Start", SwingConstants.CENTER);
        startTitleLabel.setBorder(new MatteBorder(1, 1, 1, 0, Color.BLACK));
        endTitleLabel = new JLabel("End", SwingConstants.CENTER);
        endTitleLabel.setBorder(new MatteBorder(1, 1, 1, 0, Color.BLACK));
        labelTitleLabel = new JLabel("Label", SwingConstants.CENTER);
        labelTitleLabel.setBorder(new MatteBorder(1, 1, 1, 1, Color.BLACK));

        roiValuesLabel = new JLabel("Rois Values", SwingConstants.CENTER);
        roiValuesLabel.setBorder(new MatteBorder(1, 1, 1, 1, Color.BLACK));

        if (XIA_DEVICE.equals(deviceTypeName)) {
            roiChannelTitleLabel = new JLabel("Channel to set: ");
            roiChannelTitleLabel.setFont(CHANNEL_TITLE_FONT);
            roiChannelLabel = new JLabel();
View Full Code Here

            color2Constraints.gridy = 0;
            color2Constraints.weightx = 0.5;
            color2Constraints.weighty = 1;
            colorPanel.add(color1Panel, color1Constraints);
            colorPanel.add(color2Panel, color2Constraints);
            color1Panel.setBorder(new MatteBorder(0, 1, 0, 0, Color.BLACK));
            color2Panel.setBorder(new MatteBorder(0, 1, 0, 1, Color.BLACK));

            JPanel selectionPanel = new JPanel();
            JLabel selection1Label = new JLabel("Compare color", SwingConstants.RIGHT);
            ColorCombo selection1Combo = new ColorCombo(color1Panel);
            JLabel selection2Label = new JLabel("with color", SwingConstants.RIGHT);
View Full Code Here

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

        visibleTitleLabel = new JLabel("Visible", SwingConstants.CENTER);
        visibleTitleLabel.setBorder(new MatteBorder(1, 1, 1, 0, Color.BLACK));
        roiTitleLabel = new JLabel("ROI", SwingConstants.CENTER);
        roiTitleLabel.setBorder(new MatteBorder(1, 1, 1, 0, Color.BLACK));
        startTitleLabel = new JLabel("Start", SwingConstants.CENTER);
        startTitleLabel.setBorder(new MatteBorder(1, 1, 1, 0, Color.BLACK));
        endTitleLabel = new JLabel("End", SwingConstants.CENTER);
        endTitleLabel.setBorder(new MatteBorder(1, 1, 1, 0, Color.BLACK));
        labelTitleLabel = new JLabel("Label", SwingConstants.CENTER);
        labelTitleLabel.setBorder(new MatteBorder(1, 1, 1, 1, Color.BLACK));

        roiValuesLabel = new JLabel("Rois Values", SwingConstants.CENTER);
        roiValuesLabel.setBorder(new MatteBorder(1, 1, 1, 1, Color.BLACK));

        if (XIA_DEVICE.equals(deviceTypeName)) {
            roiChannelTitleLabel = new JLabel("Channel to set: ");
            roiChannelTitleLabel.setFont(CHANNEL_TITLE_FONT);
            roiChannelLabel = new JLabel();
View Full Code Here

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

        visibleTitleLabel = new JLabel("Visible", SwingConstants.CENTER);
        visibleTitleLabel.setBorder(new MatteBorder(1, 1, 1, 0, Color.BLACK));
        roiTitleLabel = new JLabel("ROI", SwingConstants.CENTER);
        roiTitleLabel.setBorder(new MatteBorder(1, 1, 1, 0, Color.BLACK));
        startTitleLabel = new JLabel("Start", SwingConstants.CENTER);
        startTitleLabel.setBorder(new MatteBorder(1, 1, 1, 0, Color.BLACK));
        endTitleLabel = new JLabel("End", SwingConstants.CENTER);
        endTitleLabel.setBorder(new MatteBorder(1, 1, 1, 0, Color.BLACK));
        labelTitleLabel = new JLabel("Label", SwingConstants.CENTER);
        labelTitleLabel.setBorder(new MatteBorder(1, 1, 1, 1, Color.BLACK));

        roiValuesLabel = new JLabel("Rois Values", SwingConstants.CENTER);
        roiValuesLabel.setBorder(new MatteBorder(1, 1, 1, 1, Color.BLACK));

        if (XIA_DEVICE.equals(deviceTypeName)) {
            roiChannelTitleLabel = new JLabel("Channel to set: ");
            roiChannelTitleLabel.setFont(CHANNEL_TITLE_FONT);
            roiChannelLabel = new JLabel();
View Full Code Here

        Icon icon = new ImageIcon(new BufferedImage(20, 20, BufferedImage.TYPE_BYTE_GRAY));
        int top = 100;
        int left = 200;
        int right = 300;
        int bottom = 400;
        MatteBorder border = BorderFactory.createMatteBorder(top, left, bottom, right, icon);
        Insets insets = border.getBorderInsets(null);
        assertEquals(insets, new Insets(top, left, bottom, right));
        icon = new ImageIcon(new BufferedImage(30, 40, BufferedImage.TYPE_4BYTE_ABGR));
        top = 200;
        left = 300;
        right = 200;
        bottom = 300;
        border = BorderFactory.createMatteBorder(top, left, bottom, right, icon);
        Insets insets2 = border.getBorderInsets(null);
        assertEquals(insets2, new Insets(top, left, bottom, right));
    }
View Full Code Here

        Color color = Color.RED;
        int top = 100;
        int left = 200;
        int right = 300;
        int bottom = 400;
        MatteBorder border = BorderFactory.createMatteBorder(top, left, bottom, right, color);
        Insets insets = border.getBorderInsets(null);
        assertEquals(insets, new Insets(top, left, bottom, right));
        color = Color.YELLOW;
        top = 200;
        left = 300;
        right = 200;
        bottom = 300;
        border = BorderFactory.createMatteBorder(top, left, bottom, right, color);
        Insets insets2 = border.getBorderInsets(null);
        assertEquals(insets2, new Insets(top, left, bottom, right));
    }
View Full Code Here

*
* @author Sergey A. Malenkov
*/
final class javax_swing_border_MatteBorder_PersistenceDelegate extends PersistenceDelegate {
    protected Expression instantiate(Object oldInstance, Encoder out) {
        MatteBorder border = (MatteBorder) oldInstance;
        Insets insets = border.getBorderInsets();
        Object object = border.getTileIcon();
        if (object == null) {
            object = border.getMatteColor();
        }
        Object[] args = new Object[] {
                insets.top,
                insets.left,
                insets.bottom,
                insets.right,
                object,
        };
        return new Expression(border, border.getClass(), "new", args);
    }
View Full Code Here

  class ColorComboRenderer1 extends JPanel implements ListCellRenderer {
    protected Color m_c = Color.black;

    public ColorComboRenderer1() {
      super();
      setBorder(new CompoundBorder(new MatteBorder(2, 10, 2, 10,
          Color.white), new LineBorder(Color.black)));
    }
View Full Code Here

TOP

Related Classes of javax.swing.border.MatteBorder

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.