/src/slix/ced/jvm/gui/src/slix/ced/gui/MainPanel.java
http://github.com/ksuzuki/Sevenri · Java · 183 lines · 124 code · 25 blank · 34 comment · 0 complexity · 311621dc292481dcedd5b9456aa45843 MD5 · raw file
- /*
- * %! Copyright (C) 2011 Kei Suzuki All rights reserved. !%
- *
- * This file is part of Sevenri, a Clojure environment ("This Software").
- *
- * The use and distribution terms for this software are covered by the Eclipse
- * Public License version 1.0 (http://opensource.org/licenses/eclipse-1.0.php)
- * which can be found in the COPYING at the root of this distribution.
- * By using this software in any fashion, you are agreeing to be bound by the
- * terms of this license.
- * You must not remove this notice, or any other, from this software.
- */
- /*
- * To change this template, choose Tools | Templates
- * and open the template in the editor.
- */
- /*
- * MainPanel.java
- *
- * Created on Sep 8, 2010, 11:07:12 AM
- */
- package slix.ced.gui;
- /**
- *
- * @author ksuzuki
- */
- public class MainPanel extends javax.swing.JPanel {
- /** Creates new form MainPanel */
- public MainPanel() {
- initComponents();
- }
- /** This method is called from within the constructor to
- * initialize the form.
- * WARNING: Do NOT modify this code. The content of this method is
- * always regenerated by the Form Editor.
- */
- @SuppressWarnings("unchecked")
- // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
- private void initComponents() {
- splitter = new javax.swing.JSplitPane();
- scrollPane2 = new javax.swing.JScrollPane();
- ced2 = new javax.swing.JEditorPane();
- scrollPane1 = new javax.swing.JScrollPane();
- ced1 = new javax.swing.JEditorPane();
- toolBar = new javax.swing.JToolBar();
- modIndicator = new javax.swing.JLabel();
- lineNumber = new javax.swing.JFormattedTextField();
- col = new javax.swing.JLabel();
- columnNumber = new javax.swing.JLabel();
- sep = new javax.swing.JToolBar.Separator();
- findKeyword = new javax.swing.JTextField();
- setBackground(new java.awt.Color(255, 255, 255));
- setFont(new java.awt.Font("Courier", 0, 12));
- setMinimumSize(new java.awt.Dimension(320, 200));
- setPreferredSize(new java.awt.Dimension(640, 400));
- splitter.setDividerSize(6);
- splitter.setOrientation(javax.swing.JSplitPane.VERTICAL_SPLIT);
- splitter.setFont(getFont());
- splitter.setMaximumSize(new java.awt.Dimension(32767, 32767));
- splitter.setOneTouchExpandable(true);
- scrollPane2.setFont(getFont());
- scrollPane2.setMinimumSize(new java.awt.Dimension(0, 0));
- scrollPane2.setPreferredSize(new java.awt.Dimension(640, 370));
- ced2.setFont(getFont());
- ced2.setMaximumSize(new java.awt.Dimension(32767, 32767));
- ced2.setMinimumSize(new java.awt.Dimension(0, 0));
- ced2.setName("ced2"); // NOI18N
- ced2.setPreferredSize(new java.awt.Dimension(640, 370));
- scrollPane2.setViewportView(ced2);
- splitter.setLeftComponent(scrollPane2);
- scrollPane1.setFont(getFont());
- scrollPane1.setMinimumSize(new java.awt.Dimension(0, 0));
- scrollPane1.setPreferredSize(new java.awt.Dimension(640, 370));
- ced1.setFont(getFont());
- ced1.setMaximumSize(new java.awt.Dimension(32767, 32767));
- ced1.setMinimumSize(new java.awt.Dimension(0, 0));
- ced1.setName("ced1"); // NOI18N
- ced1.setPreferredSize(new java.awt.Dimension(640, 370));
- scrollPane1.setViewportView(ced1);
- splitter.setRightComponent(scrollPane1);
- toolBar.setFloatable(false);
- toolBar.setRollover(true);
- toolBar.setFont(getFont());
- toolBar.setMaximumSize(new java.awt.Dimension(32767, 32767));
- toolBar.setMinimumSize(new java.awt.Dimension(320, 30));
- toolBar.setPreferredSize(new java.awt.Dimension(640, 30));
- modIndicator.setFont(getFont());
- modIndicator.setForeground(new java.awt.Color(255, 0, 0));
- modIndicator.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
- modIndicator.setFocusTraversalKeysEnabled(false);
- modIndicator.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);
- modIndicator.setMaximumSize(new java.awt.Dimension(8, 12));
- modIndicator.setMinimumSize(new java.awt.Dimension(8, 12));
- modIndicator.setPreferredSize(new java.awt.Dimension(8, 12));
- modIndicator.setRequestFocusEnabled(false);
- modIndicator.setVerifyInputWhenFocusTarget(false);
- toolBar.add(modIndicator);
- lineNumber.setFormatterFactory(new javax.swing.text.DefaultFormatterFactory(new javax.swing.text.NumberFormatter(new java.text.DecimalFormat("#0"))));
- lineNumber.setHorizontalAlignment(javax.swing.JTextField.RIGHT);
- lineNumber.setFocusTraversalKeysEnabled(false);
- lineNumber.setFont(getFont());
- lineNumber.setMaximumSize(new java.awt.Dimension(70, 24));
- lineNumber.setMinimumSize(new java.awt.Dimension(70, 24));
- lineNumber.setPreferredSize(new java.awt.Dimension(70, 24));
- toolBar.add(lineNumber);
- col.setFont(getFont());
- col.setHorizontalAlignment(javax.swing.SwingConstants.CENTER);
- col.setText(":");
- toolBar.add(col);
- columnNumber.setFont(getFont());
- columnNumber.setHorizontalAlignment(javax.swing.SwingConstants.LEFT);
- columnNumber.setHorizontalTextPosition(javax.swing.SwingConstants.LEFT);
- columnNumber.setMaximumSize(new java.awt.Dimension(30, 12));
- columnNumber.setMinimumSize(new java.awt.Dimension(30, 12));
- columnNumber.setPreferredSize(new java.awt.Dimension(30, 12));
- toolBar.add(columnNumber);
- toolBar.add(sep);
- findKeyword.setFont(getFont());
- findKeyword.setHorizontalAlignment(javax.swing.JTextField.LEFT);
- findKeyword.setFocusTraversalKeysEnabled(false);
- findKeyword.setMaximumSize(new java.awt.Dimension(160, 24));
- findKeyword.setMinimumSize(new java.awt.Dimension(160, 24));
- findKeyword.setPreferredSize(new java.awt.Dimension(160, 24));
- toolBar.add(findKeyword);
- org.jdesktop.layout.GroupLayout layout = new org.jdesktop.layout.GroupLayout(this);
- this.setLayout(layout);
- layout.setHorizontalGroup(
- layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
- .add(toolBar, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
- .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
- .add(splitter, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 640, Short.MAX_VALUE))
- );
- layout.setVerticalGroup(
- layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
- .add(org.jdesktop.layout.GroupLayout.TRAILING, layout.createSequentialGroup()
- .addContainerGap(370, Short.MAX_VALUE)
- .add(toolBar, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE, 30, org.jdesktop.layout.GroupLayout.PREFERRED_SIZE))
- .add(layout.createParallelGroup(org.jdesktop.layout.GroupLayout.LEADING)
- .add(layout.createSequentialGroup()
- .add(splitter, org.jdesktop.layout.GroupLayout.DEFAULT_SIZE, 370, Short.MAX_VALUE)
- .add(30, 30, 30)))
- );
- }// </editor-fold>//GEN-END:initComponents
- // Variables declaration - do not modify//GEN-BEGIN:variables
- public javax.swing.JEditorPane ced1;
- public javax.swing.JEditorPane ced2;
- private javax.swing.JLabel col;
- public javax.swing.JLabel columnNumber;
- public javax.swing.JTextField findKeyword;
- public javax.swing.JFormattedTextField lineNumber;
- public javax.swing.JLabel modIndicator;
- public javax.swing.JScrollPane scrollPane1;
- public javax.swing.JScrollPane scrollPane2;
- private javax.swing.JToolBar.Separator sep;
- public javax.swing.JSplitPane splitter;
- public javax.swing.JToolBar toolBar;
- // End of variables declaration//GEN-END:variables
- }