Révision 14
SRC/src/fr/triangle/hyperalign/gui/annot/AnnotEquiPane.java (revision 14) | ||
---|---|---|
130 | 130 |
private boolean withSizes = false; |
131 | 131 |
private JCheckBox graphSizeBox; |
132 | 132 |
private int editEquivalence; |
133 |
private JComboBox authorGraphBox; |
|
134 |
private HyperalignText author; |
|
133 | 135 |
private String level; |
134 | 136 |
private HyperalignText selectedText; |
135 | 137 |
private boolean exportOcc; |
... | ... | |
399 | 401 |
|
400 | 402 |
//GRAPH on the left |
401 | 403 |
tradManager.setGraphSizeOption(withSizes); |
402 |
graph = new EquivalenceGraph(manager); |
|
404 |
graph = new EquivalenceGraph(manager, tradManager.getCurrentGraphUrls(), tradManager.getGraphAllConceptOption(), withSizes);
|
|
403 | 405 |
graphPanel.add(graph); |
404 | 406 |
|
405 | 407 |
//TABLES on the right |
... | ... | |
509 | 511 |
private JPanel initTriPanel(Dictionary[] targetLangs){ |
510 | 512 |
JPanel triPanel = new JPanel(); |
511 | 513 |
|
514 |
//Choix dans le graphe des ?quivalences |
|
515 |
Vector<HyperalignText> textsForTargetLang = tradManager.getDictionaryAndTextForEquivalences().get(targetLang); |
|
516 |
authorGraphBox = new JComboBox(textsForTargetLang); |
|
517 |
authorGraphBox.setPreferredSize(new Dimension(100,25)); |
|
518 |
if(author!=null){ |
|
519 |
authorGraphBox.setSelectedItem(author); |
|
520 |
} |
|
521 |
authorGraphBox.addActionListener(new ActionListener(){ |
|
522 |
public void actionPerformed(ActionEvent ae){ |
|
523 |
Object o = ((JComboBox)ae.getSource()).getSelectedItem(); |
|
524 |
author = (HyperalignText)o; |
|
525 |
authorGraphBox.setSelectedItem(o); |
|
526 |
exportEquivalencesByAuthor(); |
|
527 |
initGuiWithTable(); |
|
528 |
} |
|
529 |
}); |
|
530 |
triPanel.add(authorGraphBox); |
|
531 |
|
|
512 | 532 |
///LABEL about the Equivalences |
513 | 533 |
labelOccSource = new JLabel(); |
514 | 534 |
System.out.println("AnnotEquiPane.initTriPanel() - LABEL OCC SOURCE type = "+type); |
SRC/src/fr/triangle/hyperalign/gui/DesktopPane.java (revision 14) | ||
---|---|---|
192 | 192 |
}*/ |
193 | 193 |
|
194 | 194 |
protected void reinitGraphPane(){ |
195 |
EquivalenceManager equivManager = manager.getDataManager().getEquivalenceManager(); |
|
196 |
URL[] urlsEquivalence = equivManager.getCurrentGraphUrls(); |
|
197 |
boolean withSizes = equivManager.getGraphSizeOption(); |
|
198 |
boolean withAllConcepts = equivManager.getGraphAllConceptOption(); |
|
195 | 199 |
|
196 | 200 |
//INIT |
197 | 201 |
if(graphPane==null){ |
198 |
graphPane = new EquivalenceGraph(manager); |
|
202 |
graphPane = new EquivalenceGraph(manager, urlsEquivalence, withAllConcepts, withSizes);
|
|
199 | 203 |
} |
200 | 204 |
//REINIT |
201 | 205 |
else { |
202 |
EquivalenceManager equivManager = manager.getDataManager().getEquivalenceManager(); |
|
203 |
URL[] urlsEquivalence = equivManager.getCurrentGraphUrls(); |
|
204 |
boolean withSizes = equivManager.getGraphSizeOption(); |
|
205 |
boolean withAllConcepts = equivManager.getGraphAllConceptOption(); |
|
206 | 206 |
|
207 | 207 |
graphPane.reinitPane(urlsEquivalence, withSizes, withAllConcepts); |
208 | 208 |
} |
SRC/src/fr/triangle/hyperalign/gui/graph/EquivalenceGraph.java (revision 14) | ||
---|---|---|
57 | 57 |
String level; |
58 | 58 |
JCheckBox graphSizeBox; |
59 | 59 |
|
60 |
public EquivalenceGraph(HMManager manager){ |
|
60 |
public EquivalenceGraph(HMManager manager, URL [] urlsEquivalence, boolean withAllConcepts, boolean withSizes){
|
|
61 | 61 |
this.manager = manager; |
62 | 62 |
this.res = HyperalignData.getInstance().getResourceBundle(); |
63 |
EquivalenceManager equivManager = manager.getDataManager().getEquivalenceManager(); |
|
63 |
//EquivalenceManager equivManager = manager.getDataManager().getEquivalenceManager();
|
|
64 | 64 |
graphs = new HashMap<GraphPane, Visualization>(); |
65 |
this.withSizes = equivManager.getGraphSizeOption(); |
|
66 |
this.withAllConcepts= equivManager.getGraphAllConceptOption(); |
|
67 |
this.urlsEquivalence = equivManager.getCurrentGraphUrls(); |
|
65 |
this.withSizes = withSizes;//equivManager.getGraphSizeOption();
|
|
66 |
this.withAllConcepts= withAllConcepts;//equivManager.getGraphAllConceptOption();
|
|
67 |
this.urlsEquivalence = urlsEquivalence; //equivManager.getCurrentGraphUrls();
|
|
68 | 68 |
initGui(); |
69 | 69 |
} |
70 | 70 |
|
Formats disponibles : Unified diff