MAJ (V4.3.1 : Raffraichissement de l'arbre. Ajout de traduction.)
This commit is contained in:
parent
76926779b4
commit
9b292d46e3
Binary file not shown.
Binary file not shown.
3
bin/.gitignore
vendored
3
bin/.gitignore
vendored
@ -1,4 +1 @@
|
||||
/fenetres/
|
||||
/list/
|
||||
/MEPTL/
|
||||
/evaluer/
|
||||
|
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
@ -153,7 +153,16 @@ public class HTML {
|
||||
"</table>";
|
||||
}
|
||||
|
||||
// Table pour la synthèse au début du FeedBack : Style de paragraphe, Style de page
|
||||
/**
|
||||
* Table pour la synthèse au début du FeedBack : Style de paragraphe, Style de page
|
||||
* @param titre
|
||||
* @param prop
|
||||
* @param pointstotal
|
||||
* @param pointsgagnes
|
||||
* @param coef
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
public static String TablePointsSyntheseStyle(String titre,double prop, String pointstotal, String pointsgagnes, String coef, String id ) {
|
||||
|
||||
String propRed = Integer.toHexString(255 - (int) Math.round(Math.pow(prop,3)*255));
|
||||
@ -181,18 +190,27 @@ public class HTML {
|
||||
+ "</tr>\r\n" +
|
||||
"</table>";
|
||||
|
||||
|
||||
return "<table width=\"80%\" align=\"center\" cellpadding=\"4\" cellspacing=\"0\" style=\"page-break-after: avoid\">\r\n" +
|
||||
"<col width=\"30%\"/><col width=\"20%\"/><col width=\"20%\"/><col width=\"20%\"/><col width=\"10%\"/>"
|
||||
"<col width=\"100%\"/>"
|
||||
+ "<tr valign=\"top\">"
|
||||
+ "<td width=\"20%\" style=\"border-top: 1px solid #000000; border-bottom: 1px solid #000000; border-left: 1px solid #000000; border-right: none; padding-top: 0.1cm; padding-bottom: 0.1cm; padding-left: 0.1cm; padding-right: 0cm\"><p>" +
|
||||
"<a href=\"" + id + "\"><font size=\"4\">" + titre +"</font></p></td>"
|
||||
+ "<td width=\"20%\" align=\"center\" style=\"border-top: 1px solid #000000; border-bottom: 1px solid #000000; border-left: 1px solid #000000; border-right: none; padding-top: 0.1cm; padding-bottom: 0.1cm; padding-left: 0.1cm; padding-right: 0cm\"><p>" +
|
||||
"<b><span size\"6\" style=\"color:#FFFFFF\">█ </span></b></p></td>"
|
||||
+ "<td width=\"20%\" align=\"center\" style=\"border: 1px solid #000000; padding: 0.1cm\"><p></p></td>"
|
||||
+ "<td width=\"20%\" align=\"center\" style=\"border: 1px solid #000000; padding: 0.1cm\"><p></p></td>"
|
||||
+ "<td width=\"20%\" align=\"center\" style=\"border: 1px solid #000000; padding: 0.1cm\"><p></p></td>"
|
||||
+ "<td width=\"15%\" style=\"border-top: 0px solid #000000; border-bottom: 0px solid #000000; border-left: 0px solid #000000; border-right: none; padding-top: 0.1cm; padding-bottom: 0.1cm; padding-left: 1.2cm; padding-right: 0cm\"><p>" +
|
||||
"├ <a href=\"" + id + "\"><font size=\"3\">" + titre +"</font></p></td>"
|
||||
+ "</tr>\r\n" +
|
||||
"</table>";
|
||||
|
||||
// return "<table width=\"80%\" align=\"center\" cellpadding=\"4\" cellspacing=\"0\" style=\"page-break-after: avoid\">\r\n" +
|
||||
// "<col width=\"30%\"/><col width=\"20%\"/><col width=\"20%\"/><col width=\"20%\"/><col width=\"10%\"/>"
|
||||
// + "<tr valign=\"top\">"
|
||||
// + "<td width=\"20%\" style=\"border-top: 1px solid #000000; border-bottom: 1px solid #000000; border-left: 1px solid #000000; border-right: none; padding-top: 0.1cm; padding-bottom: 0.1cm; padding-left: 0.1cm; padding-right: 0cm\"><p>" +
|
||||
// "<a href=\"" + id + "\"><font size=\"4\">" + titre +"</font></p></td>"
|
||||
// + "<td width=\"20%\" align=\"center\" style=\"border-top: 1px solid #000000; border-bottom: 1px solid #000000; border-left: 1px solid #000000; border-right: none; padding-top: 0.1cm; padding-bottom: 0.1cm; padding-left: 0.1cm; padding-right: 0cm\"><p>" +
|
||||
// "<b><span size\"6\" style=\"color:#FFFFFF\">█ </span></b></p></td>"
|
||||
// + "<td width=\"20%\" align=\"center\" style=\"border: 1px solid #000000; padding: 0.1cm\"><p></p></td>"
|
||||
// + "<td width=\"20%\" align=\"center\" style=\"border: 1px solid #000000; padding: 0.1cm\"><p></p></td>"
|
||||
// + "<td width=\"20%\" align=\"center\" style=\"border: 1px solid #000000; padding: 0.1cm\"><p></p></td>"
|
||||
// + "</tr>\r\n" +
|
||||
// "</table>";
|
||||
}
|
||||
|
||||
// Entête des tables pour les styles de paragraphe, styles de page, etc...
|
||||
@ -228,7 +246,15 @@ public class HTML {
|
||||
}
|
||||
|
||||
|
||||
// Table pour les corrects dans les styles de paragraphe, styles de page
|
||||
/**
|
||||
* Table pour les résultats corrects et incorrects **
|
||||
* @param txt1 = résultat avec le point en positif ou négatif
|
||||
* @param txt2
|
||||
* @param txt3
|
||||
* @param txt4
|
||||
* @param niveau
|
||||
* @return
|
||||
*/
|
||||
public static String Table(String txt1, String txt2, String txt3, String txt4,int niveau) {
|
||||
String color = "#AAAAAA"; //#
|
||||
if(niveau==2) color =" #dc143c";
|
||||
|
@ -113,7 +113,9 @@ public class feedbacks {
|
||||
"<font color=\"#ffffff\" size=\"6\" style=\"font-size: 26pt\">Feedback - AnalyseWriter - format ODF 1.2<br></font></h1>\r");
|
||||
}
|
||||
|
||||
//Note
|
||||
//**********
|
||||
//** Note **
|
||||
//**********
|
||||
node ouvre = nodana.retourneFirstEnfantsByName("ouverture");
|
||||
String noteFrom = ouvre.getAttributs().get("notefrom");
|
||||
node notation = nodana.retourneFirstEnfantsByName("bodyetnotation");
|
||||
@ -173,7 +175,6 @@ public class feedbacks {
|
||||
SystemeStudent=decompose[1].substring(decompose[1].lastIndexOf("$")+1, decompose[1].lastIndexOf(" "));
|
||||
}catch (Exception e) {
|
||||
System.out.println("Problème avec l'attribut producteur.");
|
||||
|
||||
}finally {
|
||||
|
||||
}
|
||||
@ -354,8 +355,9 @@ public class feedbacks {
|
||||
|
||||
|
||||
|
||||
|
||||
//footer
|
||||
//************
|
||||
//** footer **
|
||||
//************
|
||||
fichier.append("<div class=\"footer\">");
|
||||
fichier.append("<font color=\"#808080\" style=\"font-size: 10pt\"><i>analyseWriter - P. Rodriguez (université d'Artois) - Licence GPL v3.0 - analysé avec la version : " + commandes.version + " - ");
|
||||
fichier.append("Fichier d'analyse créé avec la version : " + ouvre.getAttributs().get("version") + "</i></font>");
|
||||
|
@ -8,6 +8,9 @@ import javax.swing.AbstractAction;
|
||||
import javax.swing.Action;
|
||||
import javax.swing.ImageIcon;
|
||||
import javax.swing.KeyStroke;
|
||||
import javax.swing.tree.DefaultMutableTreeNode;
|
||||
import javax.swing.tree.DefaultTreeModel;
|
||||
import javax.swing.tree.TreePath;
|
||||
|
||||
import cXML.node;
|
||||
import fenetres.create;
|
||||
@ -28,7 +31,23 @@ public class actEvalueFalse extends AbstractAction{
|
||||
node nod = (node) fenetres.create.getSelectNode().getUserObject();
|
||||
nod.evaluerFalse();
|
||||
fenetres.create.getTextNodeSelect().refreshAffichage(nod);
|
||||
fenetres.create.getTree().repaint();
|
||||
// fenetres.create.getTree().repaint();
|
||||
|
||||
|
||||
TreePath path = fenetres.create.getTree().getSelectionPath();
|
||||
|
||||
DefaultTreeModel model = (DefaultTreeModel) fenetres.create.getTree().getModel();
|
||||
DefaultMutableTreeNode root = (DefaultMutableTreeNode) model.getRoot();
|
||||
model.reload(root);
|
||||
|
||||
fenetres.create.getTree().setSelectionPath(path);
|
||||
fenetres.create.getTree().expandPath(path);
|
||||
|
||||
|
||||
fenetres.create.getTextNodeSelect().refreshAffichage(nod);
|
||||
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
@ -8,6 +8,9 @@ import javax.swing.AbstractAction;
|
||||
import javax.swing.Action;
|
||||
import javax.swing.ImageIcon;
|
||||
import javax.swing.KeyStroke;
|
||||
import javax.swing.tree.DefaultMutableTreeNode;
|
||||
import javax.swing.tree.DefaultTreeModel;
|
||||
import javax.swing.tree.TreePath;
|
||||
|
||||
import cXML.node;
|
||||
import fenetres.create;
|
||||
@ -31,8 +34,20 @@ public class actEvalueTrue extends AbstractAction{
|
||||
if(nod.getLevel()==1) {
|
||||
nod.addMenu(true);
|
||||
}
|
||||
fenetres.create.getTextNodeSelect().refreshAffichage(nod);
|
||||
fenetres.create.getTree().repaint();
|
||||
|
||||
TreePath path = fenetres.create.getTree().getSelectionPath();
|
||||
|
||||
// fenetres.create.getTextNodeSelect().refreshAffichage(nod);
|
||||
// fenetres.create.getTree().repaint();
|
||||
|
||||
|
||||
DefaultTreeModel model = (DefaultTreeModel) fenetres.create.getTree().getModel();
|
||||
DefaultMutableTreeNode root = (DefaultMutableTreeNode) model.getRoot();
|
||||
model.reload(root);
|
||||
|
||||
fenetres.create.getTree().setSelectionPath(path);
|
||||
fenetres.create.getTree().expandPath(path);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -4,6 +4,9 @@ import java.awt.event.ActionEvent;
|
||||
|
||||
import javax.swing.AbstractAction;
|
||||
import javax.swing.Action;
|
||||
import javax.swing.tree.DefaultMutableTreeNode;
|
||||
import javax.swing.tree.DefaultTreeModel;
|
||||
import javax.swing.tree.TreePath;
|
||||
|
||||
import MEPTL.commandes;
|
||||
import cXML.node;
|
||||
@ -34,6 +37,16 @@ public class actEvaluerStyleTrue extends AbstractAction{
|
||||
nodStyle.changeLesCodesEvaluateursVersCodeATraversAnalyseStyle();
|
||||
}
|
||||
|
||||
TreePath path = fenetres.create.getTree().getSelectionPath();
|
||||
|
||||
DefaultTreeModel model = (DefaultTreeModel) fenetres.create.getTree().getModel();
|
||||
DefaultMutableTreeNode root = (DefaultMutableTreeNode) model.getRoot();
|
||||
model.reload(root);
|
||||
|
||||
fenetres.create.getTree().setSelectionPath(path);
|
||||
fenetres.create.getTree().expandPath(path);
|
||||
|
||||
|
||||
fenetres.create.getTextNodeSelect().refreshAffichage(nod);
|
||||
}
|
||||
|
||||
|
@ -5,6 +5,9 @@ import java.awt.event.ActionEvent;
|
||||
import javax.swing.AbstractAction;
|
||||
import javax.swing.Action;
|
||||
import javax.swing.ImageIcon;
|
||||
import javax.swing.tree.DefaultMutableTreeNode;
|
||||
import javax.swing.tree.DefaultTreeModel;
|
||||
import javax.swing.tree.TreePath;
|
||||
|
||||
import cXML.node;
|
||||
import fenetres.create;
|
||||
@ -28,6 +31,20 @@ public class actEvaluerTousEnfantsTrue extends AbstractAction{
|
||||
nod.evaluerAllChildTrue();
|
||||
fenetres.create.getTextNodeSelect().refreshAffichage(nod);
|
||||
}
|
||||
|
||||
TreePath path = fenetres.create.getTree().getSelectionPath();
|
||||
|
||||
DefaultTreeModel model = (DefaultTreeModel) fenetres.create.getTree().getModel();
|
||||
DefaultMutableTreeNode root = (DefaultMutableTreeNode) model.getRoot();
|
||||
model.reload(root);
|
||||
|
||||
fenetres.create.getTree().setSelectionPath(path);
|
||||
fenetres.create.getTree().expandPath(path);
|
||||
|
||||
|
||||
fenetres.create.getTextNodeSelect().refreshAffichage(nod);
|
||||
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -671,6 +671,7 @@ public final class setting extends JFrame {
|
||||
btnExtraire.addActionListener(new ActionListener() {
|
||||
public void actionPerformed(ActionEvent e) {
|
||||
node nodeTransalte = commandes.sujet.retourneFirstEnfantsByName("translation");
|
||||
|
||||
JFileChooser fileChooser = new JFileChooser();
|
||||
fileChooser.setDialogTitle("Enregistrer sous...");
|
||||
File file = null;
|
||||
@ -683,7 +684,12 @@ public final class setting extends JFrame {
|
||||
File fileToSave = fileChooser.getSelectedFile();
|
||||
try {
|
||||
|
||||
Run.ecritureNodeEnXML(nodeTransalte, fileToSave.getName(), fileToSave.getPath().substring(0,fileToSave.getPath().lastIndexOf("\\")),"" );
|
||||
if(commandes.os.contains("Win")) {
|
||||
Run.ecritureNodeEnXML(nodeTransalte, fileToSave.getName(), fileToSave.getPath().substring(0,fileToSave.getPath().lastIndexOf("\\")),"setting" );
|
||||
}else {
|
||||
Run.ecritureNodeEnXML(nodeTransalte, fileToSave.getName(), fileToSave.getPath().substring(0,fileToSave.getPath().lastIndexOf("/")),"setting" );
|
||||
}
|
||||
|
||||
JOptionPane.showMessageDialog(null, "Le fichier \"" + fileToSave.getName() + ".xml\" a été renregistré.\n\nIl se trouve dans le dossier " + fileToSave.getPath());
|
||||
|
||||
} catch (IOException e1) {
|
||||
@ -700,7 +706,7 @@ public final class setting extends JFrame {
|
||||
btnAjouterVosTraductions.addActionListener(new ActionListener() {
|
||||
public void actionPerformed(ActionEvent e) {
|
||||
JFileChooser fileChooser = new JFileChooser();
|
||||
fileChooser.setDialogTitle("Charger le node translate en mémoire");
|
||||
fileChooser.setDialogTitle("Charger le node traduction en mémoire");
|
||||
|
||||
FileNameExtensionFilter filter = new FileNameExtensionFilter("Fichier d'analyse .XML", "xml");
|
||||
fileChooser.setFileFilter(filter);
|
||||
|
Loading…
x
Reference in New Issue
Block a user