From ddde12b29639ebea17904e9d56fc6e3729f1fc48 Mon Sep 17 00:00:00 2001 From: amwaterhouse Date: Mon, 21 Mar 2005 18:50:05 +0000 Subject: [PATCH] altered layout --- src/jalview/jbgui/GSliderPanel.java | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) diff --git a/src/jalview/jbgui/GSliderPanel.java b/src/jalview/jbgui/GSliderPanel.java index 402fb6e..77911b4 100755 --- a/src/jalview/jbgui/GSliderPanel.java +++ b/src/jalview/jbgui/GSliderPanel.java @@ -17,7 +17,7 @@ public class GSliderPanel extends JPanel protected JButton undoButton = new JButton(); FlowLayout flowLayout1 = new FlowLayout(); protected JCheckBox allGroupsCheck = new JCheckBox(); - FlowLayout flowLayout2 = new FlowLayout(); + BorderLayout borderLayout1 = new BorderLayout(); public GSliderPanel() { @@ -36,12 +36,12 @@ public class GSliderPanel extends JPanel slider.setMajorTickSpacing(10); slider.setMinorTickSpacing(1); slider.setPaintTicks(true); - slider.setBackground(new Color(177, 177, 217)); + slider.setBackground(Color.white); slider.setFont(new java.awt.Font("Verdana", 0, 11)); - slider.setOpaque(false); + slider.setDoubleBuffered(true); valueField.setFont(new java.awt.Font("Verdana", 0, 11)); valueField.setMinimumSize(new Dimension(6, 14)); - valueField.setPreferredSize(new Dimension(50, 21)); + valueField.setPreferredSize(new Dimension(50, 12)); valueField.setText(""); valueField.setHorizontalAlignment(SwingConstants.CENTER); valueField.addActionListener(new java.awt.event.ActionListener() @@ -55,7 +55,7 @@ public class GSliderPanel extends JPanel label.setOpaque(false); label.setHorizontalAlignment(SwingConstants.CENTER); label.setText("set this label text"); - jPanel1.setLayout(flowLayout2); + jPanel1.setLayout(borderLayout1); gridLayout1.setRows(2); jPanel2.setLayout(flowLayout1); applyButton.setFont(new java.awt.Font("Verdana", 0, 11)); @@ -90,7 +90,7 @@ public class GSliderPanel extends JPanel allGroupsCheck_actionPerformed(e); } }); - this.setBackground(new Color(177, 177, 217)); + this.setBackground(Color.white); this.setPreferredSize(new Dimension(415, 84)); jPanel2.setOpaque(false); jPanel1.setOpaque(false); @@ -98,9 +98,9 @@ public class GSliderPanel extends JPanel jPanel2.add(label, null); jPanel2.add(applyButton, null); jPanel2.add(undoButton, null);this.add(jPanel1, null); - jPanel1.add(slider, null); - jPanel1.add(valueField, null); - jPanel1.add(allGroupsCheck, null); + jPanel1.add(slider, BorderLayout.WEST); + jPanel1.add(valueField, BorderLayout.CENTER); + jPanel1.add(allGroupsCheck, BorderLayout.EAST); } -- 1.7.10.2