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 41 42 43 44 45 46 47 48 49 50 51 52 53
| super(new BorderLayout());
//on en aura besoin plus tard
this.table = table;
lborder = new EmptyBorder(5, 5, 5, 5);
this.setBorder(lborder);
linfoAttr = new JLabel();
linfoAttr.setBorder(lborder);
ldiscretise = (String)System.getProperty("ldattr.discretise");
this.graphic = graphic;
// on veut avoir ?gauche, le nom de l'attr, son type et le graphique
add(linfoAttr, BorderLayout.NORTH);
// Partie inféieure
southPanel = new JPanel();
southPanel.setLayout(null);
// à gauche, ldiscretise, la combo, les paramères
westPanel = new JPanel(new BorderLayout());
westPanel.add(cb, BorderLayout.NORTH);
westPanel.add(params, BorderLayout.SOUTH);
westPanel.setBorder(lborder);
// Placer westPanel sur le JPanel methGraphPanel
westPanel.setBounds(15,15,(southPanel.getWidth()-30)*2/5,(southPanel.getHeight()-30));
Border etched = BorderFactory.createLineBorder(Color.LIGHT_GRAY, 1);
westPanel.setBorder(etched);
southPanel.add(westPanel,BorderLayout.WEST);
//bouton pour affiner
affinageBouton = new JButton(System.getProperty("baffiner"));
//Le bouton est inactif, on l'activera uniquement lorsque les paramères seront suffisants
affinageBouton.setEnabled(false);
affinageBouton.addActionListener(this);
panelBouton = new JPanel();
graphicEtBouton = new JPanel(new BorderLayout());
panelBouton.add(affinageBouton);
graphicEtBouton.add(panelBouton , BorderLayout.SOUTH);
linfoGraphe = new JLabel(System.getProperty("tborder.graphique"));
graphicEtBouton.add(linfoGraphe, BorderLayout.NORTH);
// Placer graphicEtBouton
graphicEtBouton.setBounds(20+westPanel.getWidth(),15,(southPanel.getWidth()-30)*3/5,(southPanel.getHeight()-30));
graphicEtBouton.setBorder(etched);
southPanel.add(graphicEtBouton , BorderLayout.EAST);
this.add(southPanel, BorderLayout.CENTER); |
Partager