MAJ V4.4.2 (amélioration de la méthode evalPlacement : ajoute le texte

paragraphe vide lorsque le contenu du paragraphe est empty)
This commit is contained in:
pablo rodriguez 2023-01-18 08:25:08 +01:00
parent a7fefbd018
commit 8d5d894ed6
6 changed files with 9 additions and 7 deletions

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -2673,12 +2673,11 @@ public class meptl {
if(LeStyleDefaut!=null) {
node styleparagraphproperties = LeStyleDefaut.retourneFirstEnfantsByName("style:paragraph-properties");
if(styleparagraphproperties!=null) {
if(styleparagraphproperties.getAttributs().get("fo:margin-bottom")==null) LeStyleDefaut.getAttributs().put("fo:margin-bottom", "0");
if(styleparagraphproperties.getAttributs().get("fo:margin-left")==null) LeStyleDefaut.getAttributs().put("fo:margin-left", "0");
if(styleparagraphproperties.getAttributs().get("fo:margin-right")==null) LeStyleDefaut.getAttributs().put("fo:margin-right", "0");
if(styleparagraphproperties.getAttributs().get("fo:margin-right")==null) LeStyleDefaut.getAttributs().put("fo:margin-right", "0");
if(styleparagraphproperties.getAttributs().get("fo:margin-top")==null) LeStyleDefaut.getAttributs().put("fo:margin-top", "0");
if(styleparagraphproperties.getAttributs().get("fo:text-indent")==null) LeStyleDefaut.getAttributs().put("fo:text-indent", "0");
if(styleparagraphproperties.getAttributs().get("fo:margin-bottom")==null) styleparagraphproperties.getAttributs().put("fo:margin-bottom", "0");
if(styleparagraphproperties.getAttributs().get("fo:margin-left")==null) styleparagraphproperties.getAttributs().put("fo:margin-left", "0");
if(styleparagraphproperties.getAttributs().get("fo:margin-right")==null) styleparagraphproperties.getAttributs().put("fo:margin-right", "0");
if(styleparagraphproperties.getAttributs().get("fo:margin-top")==null) styleparagraphproperties.getAttributs().put("fo:margin-top", "0");
if(styleparagraphproperties.getAttributs().get("fo:text-indent")==null) styleparagraphproperties.getAttributs().put("fo:text-indent", "0");
}
}

View File

@ -661,7 +661,10 @@ public class evaluationAttribut {
if(nodeStudentfereAvant==null) nodeStudentfereAvant = new node();
String A = nodeSujetfrereAvant.retourneLesContenusEnfants("");
String B = nodeStudentfereAvant.retourneLesContenusEnfants("");
if(A.isEmpty() && B.isEmpty()) calcul++;
if(A.isEmpty()) A = "Paragraphe vide";
if(B.isEmpty()) B = "Paragraphe vide";
if(!A.isEmpty() && !B.isEmpty()) if(cXML.StringSimilarity.similarity(A, B)>0.92) calcul++;
if(calcul==1) {