2 * Copyright (C) 2010, mshio <mshio@users.sourceforge.jp>
4 * This program is free software: you can redistribute it and/or
5 * modify it under the terms of the GNU General Public License
6 * as published by the Free Software Foundation; either version 2
7 * of the License, or any later version.
9 * This program is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
14 * You should have received a copy of the GNU General Public License
15 * along with this program. If not, see <http://www.gnu.org/licenses/>.
17 * Require JDK 1.5 (or later)
19 package jp.sourceforge.sawarabifonts.chartool;
21 import java.awt.BorderLayout;
23 import javax.swing.JPanel;
24 import javax.swing.SwingUtilities;
25 import javax.swing.border.EmptyBorder;
27 class MainPanel extends JPanel {
28 private static final long serialVersionUID = 7520947148504510083L;
30 public MainPanel(Main m) {
31 GuiController c = new GuiController(m);
32 final SearchPanel sp = new SearchPanel(c);
33 PropertyPanel pp = new PropertyPanel(c);
34 GlyphViewer gv = new GlyphViewer(c);
36 EmptyBorder b = new EmptyBorder(10, 10, 10, 10);
38 this.setLayout(new BorderLayout());
40 JPanel p = new JPanel();
41 EmptyBorder e = new EmptyBorder(0, 10, 0, 0);
43 p.setLayout(new BorderLayout());
44 p.add(sp, BorderLayout.NORTH);
45 p.add(pp, BorderLayout.CENTER);
46 this.add(p, BorderLayout.CENTER);
48 this.add(gv, BorderLayout.WEST);
50 SwingUtilities.invokeLater(new Runnable() {
51 public void run() { sp.setFocus(); }