⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 prefsframe.java

📁 一个java版本数据分析显示程序
💻 JAVA
📖 第 1 页 / 共 2 页
字号:
/*Copyright (c) 2001, 2002, 2003 Flo Ledermann <flo@subnet.at>This file is part of parvis - a parallel coordiante based data visualisationtool written in java. You find parvis and additional information on itswebsite at http://www.mediavirus.org/parvis.parvis is free software; you can redistribute it and/or modifyit under the terms of the GNU General Public License as published bythe Free Software Foundation; either version 2 of the License, or(at your option) any later version.parvis is distributed in the hope that it will be useful,but WITHOUT ANY WARRANTY; without even the implied warranty ofMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See theGNU General Public License for more details.You should have received a copy of the GNU General Public Licensealong with parvis (in the file LICENSE.txt); if not, write to the Free SoftwareFoundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA*/package org.mediavirus.parvis.gui;import javax.swing.*;import java.awt.Color;/** * * @author  flo */public class PrefsFrame extends javax.swing.JFrame {        ParallelDisplay parent;        /** Creates new form PrefsFrame */    public PrefsFrame(ParallelDisplay parent) {        this.parent = parent;                initComponents();                updatePrefs();    }        private void updatePrefs(){        binsField.setText(parent.getIntPreference("histogramBins") + "");                switch (parent.getIntPreference("histogramWidth")){            case ParallelDisplay.HISTO_TOTALREC:                totalRadio.setSelected(true);                break;            case ParallelDisplay.HISTO_BINREC:                binRadio.setSelected(true);                break;            case ParallelDisplay.HISTO_BRUSHREC:                brushedRadio.setSelected(true);                break;        }                bgColButton.setBackground(parent.getBackground());        recordColButton.setBackground(parent.getColorPreference("recordColor"));        axisColButton.setBackground(parent.getForeground());        brushColButton.setBackground(parent.getColorPreference("brushColor"));    }        /** 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.     */    private void initComponents() {//GEN-BEGIN:initComponents        java.awt.GridBagConstraints gridBagConstraints;        histoWidthGroup = new javax.swing.ButtonGroup();        colorPanel = new javax.swing.JPanel();        label1 = new javax.swing.JLabel();        bgColButton = new javax.swing.JButton();        label2 = new javax.swing.JLabel();        recordColButton = new javax.swing.JButton();        label3 = new javax.swing.JLabel();        axisColButton = new javax.swing.JButton();        label31 = new javax.swing.JLabel();        brushColButton = new javax.swing.JButton();        histogramPanel = new javax.swing.JPanel();        label32 = new javax.swing.JLabel();        binsField = new javax.swing.JTextField();        label33 = new javax.swing.JLabel();        jPanel1 = new javax.swing.JPanel();        totalRadio = new javax.swing.JRadioButton();        binRadio = new javax.swing.JRadioButton();        brushedRadio = new javax.swing.JRadioButton();        getContentPane().setLayout(new java.awt.GridBagLayout());        addWindowListener(new java.awt.event.WindowAdapter() {            public void windowClosing(java.awt.event.WindowEvent evt) {                exitForm(evt);            }        });        colorPanel.setLayout(new java.awt.GridBagLayout());        colorPanel.setBorder(new javax.swing.border.TitledBorder(new javax.swing.border.EtchedBorder(), "Colors"));        label1.setFont(new java.awt.Font("Dialog", 0, 11));        label1.setHorizontalAlignment(javax.swing.SwingConstants.TRAILING);        label1.setText("Background");        gridBagConstraints = new java.awt.GridBagConstraints();        gridBagConstraints.gridx = 0;        gridBagConstraints.gridy = 0;        gridBagConstraints.anchor = java.awt.GridBagConstraints.EAST;        gridBagConstraints.insets = new java.awt.Insets(4, 4, 2, 4);        colorPanel.add(label1, gridBagConstraints);        bgColButton.setBackground(new java.awt.Color(255, 255, 255));        bgColButton.setFont(new java.awt.Font("Dialog", 1, 3));        bgColButton.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 2));        bgColButton.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);        bgColButton.setMargin(new java.awt.Insets(0, 0, 0, 0));        bgColButton.setMaximumSize(new java.awt.Dimension(10, 10));        bgColButton.setMinimumSize(new java.awt.Dimension(10, 10));        bgColButton.setPreferredSize(new java.awt.Dimension(14, 14));        bgColButton.addActionListener(new java.awt.event.ActionListener() {            public void actionPerformed(java.awt.event.ActionEvent evt) {                colButtonActionPerformed(evt);            }        });        gridBagConstraints = new java.awt.GridBagConstraints();        gridBagConstraints.gridx = 1;        gridBagConstraints.gridy = 0;        gridBagConstraints.insets = new java.awt.Insets(4, 4, 4, 4);        colorPanel.add(bgColButton, gridBagConstraints);        label2.setFont(new java.awt.Font("Dialog", 0, 11));        label2.setHorizontalAlignment(javax.swing.SwingConstants.TRAILING);        label2.setText("Records");        gridBagConstraints = new java.awt.GridBagConstraints();        gridBagConstraints.gridx = 0;        gridBagConstraints.gridy = 1;        gridBagConstraints.anchor = java.awt.GridBagConstraints.EAST;        gridBagConstraints.insets = new java.awt.Insets(2, 4, 2, 4);        colorPanel.add(label2, gridBagConstraints);        recordColButton.setBackground(new java.awt.Color(0, 0, 0));        recordColButton.setFont(new java.awt.Font("Dialog", 1, 3));        recordColButton.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 2));        recordColButton.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);        recordColButton.setMargin(new java.awt.Insets(0, 0, 0, 0));        recordColButton.setMaximumSize(new java.awt.Dimension(10, 10));        recordColButton.setMinimumSize(new java.awt.Dimension(10, 10));        recordColButton.setPreferredSize(new java.awt.Dimension(14, 14));        recordColButton.addActionListener(new java.awt.event.ActionListener() {            public void actionPerformed(java.awt.event.ActionEvent evt) {                colButtonActionPerformed(evt);            }        });        gridBagConstraints = new java.awt.GridBagConstraints();        gridBagConstraints.gridx = 1;        gridBagConstraints.gridy = 1;        gridBagConstraints.insets = new java.awt.Insets(4, 4, 4, 4);        colorPanel.add(recordColButton, gridBagConstraints);        label3.setFont(new java.awt.Font("Dialog", 0, 11));        label3.setHorizontalAlignment(javax.swing.SwingConstants.TRAILING);        label3.setText("Axes & Labels");        gridBagConstraints = new java.awt.GridBagConstraints();        gridBagConstraints.gridx = 0;        gridBagConstraints.gridy = 2;        gridBagConstraints.insets = new java.awt.Insets(2, 4, 2, 4);        colorPanel.add(label3, gridBagConstraints);        axisColButton.setBackground(new java.awt.Color(0, 0, 0));        axisColButton.setFont(new java.awt.Font("Dialog", 1, 3));        axisColButton.setBorder(new javax.swing.border.LineBorder(new java.awt.Color(0, 0, 0), 2));        axisColButton.setHorizontalTextPosition(javax.swing.SwingConstants.CENTER);        axisColButton.setMargin(new java.awt.Insets(0, 0, 0, 0));        axisColButton.setMaximumSize(new java.awt.Dimension(10, 10));        axisColButton.setMinimumSize(new java.awt.Dimension(10, 10));        axisColButton.setPreferredSize(new java.awt.Dimension(14, 14));        axisColButton.addActionListener(new java.awt.event.ActionListener() {            public void actionPerformed(java.awt.event.ActionEvent evt) {                colButtonActionPerformed(evt);            }        });        gridBagConstraints = new java.awt.GridBagConstraints();        gridBagConstraints.gridx = 1;        gridBagConstraints.gridy = 2;        gridBagConstraints.insets = new java.awt.Insets(4, 4, 4, 4);        colorPanel.add(axisColButton, gridBagConstraints);        label31.setFont(new java.awt.Font("Dialog", 0, 11));        label31.setHorizontalAlignment(javax.swing.SwingConstants.TRAILING);        label31.setText("Default Brush");        gridBagConstraints = new java.awt.GridBagConstraints();        gridBagConstraints.gridx = 0;        gridBagConstraints.gridy = 3;        gridBagConstraints.insets = new java.awt.Insets(2, 4, 2, 4);

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -