2 * Jalview - A Sequence Alignment Editor and Viewer (Version 2.7)
3 * Copyright (C) 2011 J Procter, AM Waterhouse, J Engelhardt, LM Lui, G Barton, M Clamp, S Searle
5 * This file is part of Jalview.
7 * Jalview is free software: you can redistribute it and/or
8 * modify it under the terms of the GNU General Public License
9 * as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version.
11 * Jalview is distributed in the hope that it will be useful, but
12 * WITHOUT ANY WARRANTY; without even the implied warranty
13 * of MERCHANTABILITY or FITNESS FOR A PARTICULAR
14 * PURPOSE. See the GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License along with Jalview. If not, see <http://www.gnu.org/licenses/>.
18 package jalview.jbgui;
22 import javax.swing.border.*;
24 public class GAlignmentPanel extends JPanel
26 protected JPanel sequenceHolderPanel = new JPanel();
28 protected JScrollBar vscroll = new JScrollBar();
30 protected JScrollBar hscroll = new JScrollBar();
32 protected JPanel seqPanelHolder = new JPanel();
34 BorderLayout borderLayout1 = new BorderLayout();
36 BorderLayout borderLayout3 = new BorderLayout();
38 protected JPanel scalePanelHolder = new JPanel();
40 protected JPanel idPanelHolder = new JPanel();
42 BorderLayout borderLayout5 = new BorderLayout();
44 protected JPanel idSpaceFillerPanel1 = new JPanel();
46 public JPanel annotationSpaceFillerHolder = new JPanel();
48 BorderLayout borderLayout6 = new BorderLayout();
50 ButtonGroup buttonGroup1 = new ButtonGroup();
52 BorderLayout borderLayout7 = new BorderLayout();
54 JPanel hscrollHolder = new JPanel();
56 BorderLayout borderLayout10 = new BorderLayout();
58 protected JPanel hscrollFillerPanel = new JPanel();
60 BorderLayout borderLayout11 = new BorderLayout();
62 public JScrollPane annotationScroller = new JScrollPane();
66 BorderLayout borderLayout4 = new BorderLayout();
68 public GAlignmentPanel()
79 private void jbInit() throws Exception
81 border1 = BorderFactory.createLineBorder(Color.gray, 1);
82 idPanelHolder.setBorder(null);
83 idPanelHolder.setPreferredSize(new Dimension(70, 10));
84 this.setLayout(borderLayout7);
86 .setMaximumSize(new Dimension(2147483647, 2147483647));
87 sequenceHolderPanel.setMinimumSize(new Dimension(150, 150));
88 sequenceHolderPanel.setPreferredSize(new Dimension(150, 150));
89 sequenceHolderPanel.setLayout(borderLayout3);
90 seqPanelHolder.setLayout(borderLayout1);
91 scalePanelHolder.setBackground(Color.white);
92 scalePanelHolder.setMinimumSize(new Dimension(10, 80));
93 scalePanelHolder.setPreferredSize(new Dimension(10, 30));
94 scalePanelHolder.setLayout(borderLayout6);
95 idPanelHolder.setLayout(borderLayout5);
96 idSpaceFillerPanel1.setBackground(Color.white);
97 idSpaceFillerPanel1.setPreferredSize(new Dimension(10, 30));
98 idSpaceFillerPanel1.setLayout(borderLayout11);
99 annotationSpaceFillerHolder.setBackground(Color.white);
100 annotationSpaceFillerHolder.setPreferredSize(new Dimension(10, 80));
101 annotationSpaceFillerHolder.setLayout(borderLayout4);
102 hscroll.setOrientation(JScrollBar.HORIZONTAL);
103 hscrollHolder.setLayout(borderLayout10);
104 hscrollFillerPanel.setBackground(Color.white);
105 hscrollFillerPanel.setPreferredSize(new Dimension(70, 10));
106 hscrollHolder.setBackground(Color.white);
107 annotationScroller.setBorder(null);
108 annotationScroller.setPreferredSize(new Dimension(10, 80));
109 this.setPreferredSize(new Dimension(220, 166));
111 sequenceHolderPanel.add(scalePanelHolder, BorderLayout.NORTH);
112 sequenceHolderPanel.add(seqPanelHolder, BorderLayout.CENTER);
113 seqPanelHolder.add(vscroll, BorderLayout.EAST);
114 sequenceHolderPanel.add(annotationScroller, BorderLayout.SOUTH);
116 // jPanel3.add(secondaryPanelHolder, BorderLayout.SOUTH);
117 this.add(idPanelHolder, BorderLayout.WEST);
118 idPanelHolder.add(idSpaceFillerPanel1, BorderLayout.NORTH);
119 idPanelHolder.add(annotationSpaceFillerHolder, BorderLayout.SOUTH);
120 this.add(hscrollHolder, BorderLayout.SOUTH);
121 hscrollHolder.add(hscroll, BorderLayout.CENTER);
122 hscrollHolder.add(hscrollFillerPanel, BorderLayout.WEST);
123 this.add(sequenceHolderPanel, BorderLayout.CENTER);