e1,date2; int num,len1,len2,count; long time; double rightrate; char[] ch; public void actionPerformed(ActionEvent e){ // TODO Auto-generated method stub String cmd = e.mand(); date1=new Date(); if (cmd.equals("4 .退出")) { System.exit(0); } else if(cmd.equals(" 返回")) {} else { JFrame f1= new JFrame(" 英文打字游戏"); f1.setSize(350, 750); f1.setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE); Container con1 = f1.getContentPane(); panel0 = new JPanel(); panel1 = new JPanel(); panel2 = new JPanel(); panel3 = new JPanel(); panel4 = new JPanel(); tp1=new JTextPane(); tp1.setBackground(Color.pink); Font size=new Font("ad",Font.BOLD,20); tp1.setFont(size); tp1.setPreferredSize(new Dimension(300,300)); tp1.setForeground(Color.white); tp2=new JTextPane(); tp2.setBackground(Color.lightGray); tp2.setFont(size);