-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathReviewInterface.java
More file actions
40 lines (40 loc) · 2.01 KB
/
ReviewInterface.java
File metadata and controls
40 lines (40 loc) · 2.01 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
/*
* package userinterface; import javax.swing.*; import java.awt.*; import
* java.awt.event.*; public class ReviewInterface extends JPanel{
*
* JPanel labelPanel = new JPanel(); JPanel foldablePanel=new JPanel(); JPanel
* mainPanel = new JPanel(); String fileDate =new String("17.AUG.16"); int
* index=0; public ReviewInterface() {
*
* //MainFrame.singleWords=separateWords(MainFrame.wordGroup);
* labelPanel.setBounds(0, 0, 288, 600); //foldablePanel.setBounds(0, 0, 288,
* 600); mainPanel.setBounds(288, 0, 864, 600); mainPanel.setLayout(null);
* labelPanel.setBackground(MainFrame.secondBackgroundColor); //
* foldablePanel.setBackground(MainFrame.secondBackgroundColor);
* mainPanel.setBackground(MainFrame.mainBackgroundColor); JButton
* labelListSwitch=UserInterface.createButton
* (fileDate,0,450,180,30,MainFrame.secondBackgroundColor,new
* Color(155,155,155,255)); //�����Ǹ��ǵ����б��� mainPanel.add(labelListSwitch);
* JButton j1=new JButton("J1"); JButton j2=new JButton("J2");
* j1.setSize(50,50); j2.setSize(50,50); labelPanel.add(j1); labelPanel.add(j2);
* //labelPanel.add(foldablePanel); add(labelPanel); add(mainPanel);
* setBounds(0, 0, 1152, 600); setLayout(null); }
*
* private String[] separateWords(String group) {
*
* String[] singleWords =new String[100]; int index=0; int beginPoint=0; int
* endPoint=0; endPoint=group.indexOf(124,beginPoint);//124��Ӧ�ķ�����"|"
* while(endPoint!=-1) {
* singleWords[index]=group.substring(beginPoint,endPoint);
* beginPoint=++endPoint; index++; endPoint=group.indexOf(124,beginPoint);
*
* } this.index=index; return singleWords;
*
* } private void setLabel(String[] s) { int i=0; JButton[] labelWords = new
* JButton[100]; while(i<index) { labelWords[i]=new JButton(singleWords[i]);
* labelWords[i].setFont(MainFrame.labelButtonFont);
* labelWords[i].setSize(50,50); labelWords[i].setForeground(Color.BLACK);
* foldablePanel.add(labelWords[i]); i++;
*
* } } }
*/