MAJ V4.1.1

This commit is contained in:
pablo rodriguez 2022-06-12 09:39:22 +02:00
parent 4306a47afc
commit 1e0383bcd9
28 changed files with 204 additions and 75 deletions

2
aW.xml
View File

@ -3,7 +3,7 @@
<dontWrapJar>false</dontWrapJar>
<headerType>gui</headerType>
<jar>C:\Users\pabr6\git\analyseWriter\MEPTL\analyseWriter.jar</jar>
<outfile>C:\Users\pabr6\OneDrive\Documents\Second exercice avec analyseWriter - Champ auteur\analyseWriter\analyseWriter.exe</outfile>
<outfile>C:\Users\pabr6\OneDrive\Documents\Troisième exercices avec analyseWriter\analyseWriter\analyseWriter.exe</outfile>
<errTitle>Erreur</errTitle>
<cmdLine></cmdLine>
<chdir></chdir>

Binary file not shown.

8
bin/.gitignore vendored
View File

@ -1,9 +1,3 @@
/MEPTL/
/app/
/resources/
/calcul/
/analyseWriter.bmp
/analyseWriter.ico
/setting.png
/setting.svg
/settingmini.png
/MEPTL/

Binary file not shown.

Binary file not shown.

BIN
bin/analyseWriter.bmp Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 16 KiB

BIN
bin/analyseWriter.ico Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 17 KiB

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

BIN
bin/resources/setting.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

BIN
bin/setting.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 3.0 KiB

115
bin/setting.svg Normal file
View File

@ -0,0 +1,115 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
<svg
inkscape:export-ydpi="96"
inkscape:export-xdpi="96"
inkscape:export-filename="C:\Users\pabr6\git\analyseWriter\MEPTL\icons\setting.png"
sodipodi:docname="setting.svg"
inkscape:version="1.1.2 (b8e25be833, 2022-02-05)"
id="svg8"
version="1.1"
viewBox="0 0 11.90625 11.90625"
height="45"
width="45"
xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
xmlns="http://www.w3.org/2000/svg"
xmlns:svg="http://www.w3.org/2000/svg"
xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
xmlns:cc="http://creativecommons.org/ns#"
xmlns:dc="http://purl.org/dc/elements/1.1/">
<defs
id="defs2">
<filter
inkscape:collect="always"
style="color-interpolation-filters:sRGB"
id="filter11078"
x="-0.09419507"
y="-0.096008412"
width="1.1883901"
height="1.1920168">
<feGaussianBlur
inkscape:collect="always"
stdDeviation="15.826359"
id="feGaussianBlur11080" />
</filter>
</defs>
<sodipodi:namedview
inkscape:snap-global="false"
inkscape:window-maximized="1"
inkscape:window-y="-8"
inkscape:window-x="-8"
inkscape:window-height="1009"
inkscape:window-width="1920"
inkscape:object-nodes="true"
inkscape:bbox-nodes="true"
inkscape:bbox-paths="true"
inkscape:snap-bbox="true"
inkscape:snap-page="true"
units="px"
showgrid="false"
inkscape:document-rotation="0"
inkscape:current-layer="g1030"
inkscape:document-units="mm"
inkscape:cy="21.493944"
inkscape:cx="32.240915"
inkscape:zoom="7.0717595"
inkscape:pageshadow="2"
inkscape:pageopacity="0.0"
borderopacity="1.0"
bordercolor="#666666"
pagecolor="#ffffff"
id="base"
inkscape:pagecheckerboard="0"
inkscape:object-paths="true"
inkscape:snap-intersection-paths="true" />
<metadata
id="metadata5">
<rdf:RDF>
<cc:Work
rdf:about="">
<dc:format>image/svg+xml</dc:format>
<dc:type
rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
</cc:Work>
</rdf:RDF>
</metadata>
<g
inkscape:label="Calque 2"
id="layer2"
inkscape:groupmode="layer">
<g
transform="matrix(0.12313291,0,0,0.12313291,3.8933229,-12.453772)"
id="g862"
style="fill:#0000ff">
<g
id="g1030">
<g
id="g10920"
transform="matrix(0.11376555,0,0,0.11376555,-67.474539,165.56503)">
<path
id="path11058"
style="opacity:0.447188;fill:#000000;fill-opacity:1;stroke:#000000;stroke-width:18.5286;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1;paint-order:fill markers stroke;filter:url(#filter11078);stop-color:#000000"
d="m 579.00721,-469.63855 c -9.9246,0 -17.91308,7.98851 -17.91308,17.91311 v 47.42007 c 0,3.50366 1.01252,6.75475 2.73764,9.50974 a 186.17991,176.94203 0 0 0 -40.74577,14.40356 c -0.72787,-1.01526 -1.53866,-1.99148 -2.47007,-2.89204 l -38.18304,-36.91716 c -8.30792,-8.03286 -21.4638,-7.80875 -29.49669,0.49919 l -38.37859,39.69595 c -8.03285,8.30793 -7.81391,21.46381 0.49401,29.4967 l 34.29786,33.16058 a 186.17991,176.94203 0 0 0 -22.26661,49.51449 h -46.92605 c -11.55631,0 -20.8566,9.30543 -20.8566,20.86174 v 55.2162 c 0,11.55633 9.30029,20.86176 20.8566,20.86176 h 49.27776 a 186.17991,176.94203 0 0 0 19.15844,40.79722 l -34.59633,33.44877 c -8.30792,8.03286 -8.52687,21.1836 -0.49402,29.49153 l 38.37861,39.695973 c 8.03287,8.307927 21.18876,8.532021 29.49668,0.499161 l 38.18306,-36.917154 c 0.81526,-0.78827 1.52766,-1.63888 2.18703,-2.51638 a 186.17991,176.94203 0 0 0 40.64284,14.666001 c -1.48881,2.614626 -2.3517,5.635813 -2.3517,8.871643 V 4.5673234 c -2e-5,9.9246006 7.9885,17.9131046 17.9131,17.9131046 h 60.06885 c 9.9246,0 17.91311,-7.988504 17.91311,-17.9131046 V -42.857896 c 0,-3.561659 -1.04184,-6.865234 -2.81997,-9.648684 a 186.17991,176.94203 0 0 0 43.6738,-16.79643 c 0.79782,1.17452 1.7262,2.28629 2.7891,3.314 l 38.17793,36.917157 c 8.30792,8.032861 21.46383,7.813913 29.49668,-0.494013 l 38.38376,-39.695974 c 8.03285,-8.30793 7.80878,-21.46382 -0.49916,-29.49668 l -37.92062,-36.67014 a 186.17991,176.94203 0 0 0 17.22355,-38.7903 c 0.81538,0.0959 1.63832,0.15954 2.48035,0.15954 h 53.11151 c 11.55631,0 20.86173,-9.30029 20.86176,-20.8566 v -55.22136 c -3e-5,-11.55631 -9.30545,-20.85661 -20.86176,-20.85661 h -53.11151 c -0.45423,0 -0.89627,0.0387 -1.3431,0.067 a 186.17991,176.94203 0 0 0 -18.71588,-41.66174 c 0.38809,-0.32484 0.77779,-0.64595 1.14755,-1.00344 l 38.18308,-36.91715 c 8.30792,-8.0329 8.52686,-21.18878 0.49401,-29.4967 l -38.37863,-39.696 c -8.03285,-8.30792 -21.18873,-8.53204 -29.49666,-0.49919 l -38.18307,36.91717 c -1.69003,1.63409 -3.02536,3.49091 -4.04475,5.46502 a 186.17991,176.94203 0 0 0 -42.80412,-16.24069 c 2.02071,-2.90085 3.21108,-6.42706 3.21108,-10.24563 v -47.42006 c 0,-9.92461 -7.98851,-17.91312 -17.9131,-17.91312 z m 27.39713,165.84933 a 84.952219,80.737058 0 0 1 84.95474,80.73506 84.952219,80.737058 0 0 1 -84.95474,80.73505 84.952219,80.737058 0 0 1 -84.94961,-80.73505 84.952219,80.737058 0 0 1 84.94961,-80.73506 z" />
<path
id="ellipse7810"
style="opacity:1;fill:#ac9d93;fill-opacity:1;stroke:#000000;stroke-width:18.5286;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1;paint-order:fill markers stroke;stop-color:#000000"
d="m 552.92264,-466.37633 c -9.9246,0 -17.91308,7.98851 -17.91308,17.91311 v 47.42007 c 0,3.50366 1.01252,6.75475 2.73764,9.50974 a 186.17991,176.94203 0 0 0 -40.74577,14.40356 c -0.72787,-1.01526 -1.53866,-1.99148 -2.47007,-2.89204 l -38.18304,-36.91716 c -8.30792,-8.03286 -21.4638,-7.80875 -29.49669,0.49919 l -38.37859,39.69595 c -8.03285,8.30793 -7.81391,21.46381 0.49401,29.4967 l 34.29786,33.16058 a 186.17991,176.94203 0 0 0 -22.26661,49.51449 h -46.92605 c -11.55631,0 -20.8566,9.30543 -20.8566,20.86174 v 55.2162 c 0,11.55633 9.30029,20.86176 20.8566,20.86176 h 49.27776 a 186.17991,176.94203 0 0 0 19.15844,40.79722 l -34.59633,33.448771 c -8.30792,8.032864 -8.52687,21.183605 -0.49402,29.491529 l 38.37861,39.695977 c 8.03287,8.307927 21.18876,8.532021 29.49668,0.499161 l 38.18306,-36.917158 c 0.81526,-0.788267 1.52766,-1.638878 2.18703,-2.516376 a 186.17991,176.94203 0 0 0 40.64284,14.666001 c -1.48881,2.614626 -2.3517,5.635813 -2.3517,8.871643 V 7.8295477 c -2e-5,9.9246003 7.9885,17.9131043 17.9131,17.9131043 h 60.06885 c 9.9246,0 17.91311,-7.988504 17.91311,-17.9131043 V -39.595672 c 0,-3.561659 -1.04184,-6.865234 -2.81997,-9.648684 a 186.17991,176.94203 0 0 0 43.6738,-16.796432 c 0.79782,1.17452 1.7262,2.286291 2.7891,3.314003 l 38.17793,36.917156 c 8.30792,8.032861 21.46383,7.813913 29.49668,-0.494013 l 38.38376,-39.695978 c 8.03285,-8.307927 7.80878,-21.463813 -0.49916,-29.496674 L 741.1312,-132.16644 a 186.17991,176.94203 0 0 0 17.22355,-38.7903 c 0.81538,0.0959 1.63832,0.15954 2.48035,0.15954 h 53.11151 c 11.55631,0 20.86173,-9.30029 20.86176,-20.8566 v -55.22136 c -3e-5,-11.55631 -9.30545,-20.85661 -20.86176,-20.85661 H 760.8351 c -0.45423,0 -0.89627,0.0387 -1.3431,0.067 a 186.17991,176.94203 0 0 0 -18.71588,-41.66174 c 0.38809,-0.32484 0.77779,-0.64595 1.14755,-1.00344 l 38.18308,-36.91715 c 8.30792,-8.0329 8.52686,-21.18878 0.49401,-29.4967 l -38.37863,-39.696 c -8.03285,-8.30792 -21.18873,-8.53204 -29.49666,-0.49919 l -38.18307,36.91717 c -1.69003,1.63409 -3.02536,3.49091 -4.04475,5.46502 a 186.17991,176.94203 0 0 0 -42.80412,-16.24069 c 2.02071,-2.90085 3.21108,-6.42706 3.21108,-10.24563 v -47.42006 c 0,-9.92461 -7.98851,-17.91312 -17.9131,-17.91312 z m 27.39713,165.84933 a 84.952219,80.737058 0 0 1 84.95474,80.73506 84.952219,80.737058 0 0 1 -84.95474,80.73505 84.952219,80.737058 0 0 1 -84.94961,-80.73505 84.952219,80.737058 0 0 1 84.94961,-80.73506 z" />
</g>
<g
id="g1038"
transform="matrix(0.09096832,-0.00248123,0.00248123,0.09096832,-13.389883,187.37233)"
inkscape:transform-center-x="-0.13298587"
inkscape:transform-center-y="0.069033722">
<path
id="path1034"
style="opacity:0.447188;fill:#000000;fill-opacity:1;stroke:#000000;stroke-width:18.5286;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1;paint-order:fill markers stroke;filter:url(#filter11078);stop-color:#000000"
d="m 579.00721,-469.63855 c -9.9246,0 -17.91308,7.98851 -17.91308,17.91311 v 47.42007 c 0,3.50366 1.01252,6.75475 2.73764,9.50974 a 186.17991,176.94203 0 0 0 -40.74577,14.40356 c -0.72787,-1.01526 -1.53866,-1.99148 -2.47007,-2.89204 l -38.18304,-36.91716 c -8.30792,-8.03286 -21.4638,-7.80875 -29.49669,0.49919 l -38.37859,39.69595 c -8.03285,8.30793 -7.81391,21.46381 0.49401,29.4967 l 34.29786,33.16058 a 186.17991,176.94203 0 0 0 -22.26661,49.51449 h -46.92605 c -11.55631,0 -20.8566,9.30543 -20.8566,20.86174 v 55.2162 c 0,11.55633 9.30029,20.86176 20.8566,20.86176 h 49.27776 a 186.17991,176.94203 0 0 0 19.15844,40.79722 l -34.59633,33.44877 c -8.30792,8.03286 -8.52687,21.1836 -0.49402,29.49153 l 38.37861,39.695973 c 8.03287,8.307927 21.18876,8.532021 29.49668,0.499161 l 38.18306,-36.917154 c 0.81526,-0.78827 1.52766,-1.63888 2.18703,-2.51638 a 186.17991,176.94203 0 0 0 40.64284,14.666001 c -1.48881,2.614626 -2.3517,5.635813 -2.3517,8.871643 V 4.5673234 c -2e-5,9.9246006 7.9885,17.9131046 17.9131,17.9131046 h 60.06885 c 9.9246,0 17.91311,-7.988504 17.91311,-17.9131046 V -42.857896 c 0,-3.561659 -1.04184,-6.865234 -2.81997,-9.648684 a 186.17991,176.94203 0 0 0 43.6738,-16.79643 c 0.79782,1.17452 1.7262,2.28629 2.7891,3.314 l 38.17793,36.917157 c 8.30792,8.032861 21.46383,7.813913 29.49668,-0.494013 l 38.38376,-39.695974 c 8.03285,-8.30793 7.80878,-21.46382 -0.49916,-29.49668 l -37.92062,-36.67014 a 186.17991,176.94203 0 0 0 17.22355,-38.7903 c 0.81538,0.0959 1.63832,0.15954 2.48035,0.15954 h 53.11151 c 11.55631,0 20.86173,-9.30029 20.86176,-20.8566 v -55.22136 c -3e-5,-11.55631 -9.30545,-20.85661 -20.86176,-20.85661 h -53.11151 c -0.45423,0 -0.89627,0.0387 -1.3431,0.067 a 186.17991,176.94203 0 0 0 -18.71588,-41.66174 c 0.38809,-0.32484 0.77779,-0.64595 1.14755,-1.00344 l 38.18308,-36.91715 c 8.30792,-8.0329 8.52686,-21.18878 0.49401,-29.4967 l -38.37863,-39.696 c -8.03285,-8.30792 -21.18873,-8.53204 -29.49666,-0.49919 l -38.18307,36.91717 c -1.69003,1.63409 -3.02536,3.49091 -4.04475,5.46502 a 186.17991,176.94203 0 0 0 -42.80412,-16.24069 c 2.02071,-2.90085 3.21108,-6.42706 3.21108,-10.24563 v -47.42006 c 0,-9.92461 -7.98851,-17.91312 -17.9131,-17.91312 z m 27.39713,165.84933 a 84.952219,80.737058 0 0 1 84.95474,80.73506 84.952219,80.737058 0 0 1 -84.95474,80.73505 84.952219,80.737058 0 0 1 -84.94961,-80.73505 84.952219,80.737058 0 0 1 84.94961,-80.73506 z" />
<path
id="path1036"
style="opacity:1;fill:#ac9d93;fill-opacity:1;stroke:#000000;stroke-width:18.5286;stroke-linecap:round;stroke-linejoin:round;stroke-miterlimit:4;stroke-dasharray:none;stroke-opacity:1;paint-order:fill markers stroke;stop-color:#000000"
d="m 552.92264,-466.37633 c -9.9246,0 -17.91308,7.98851 -17.91308,17.91311 v 47.42007 c 0,3.50366 1.01252,6.75475 2.73764,9.50974 a 186.17991,176.94203 0 0 0 -40.74577,14.40356 c -0.72787,-1.01526 -1.53866,-1.99148 -2.47007,-2.89204 l -38.18304,-36.91716 c -8.30792,-8.03286 -21.4638,-7.80875 -29.49669,0.49919 l -38.37859,39.69595 c -8.03285,8.30793 -7.81391,21.46381 0.49401,29.4967 l 34.29786,33.16058 a 186.17991,176.94203 0 0 0 -22.26661,49.51449 h -46.92605 c -11.55631,0 -20.8566,9.30543 -20.8566,20.86174 v 55.2162 c 0,11.55633 9.30029,20.86176 20.8566,20.86176 h 49.27776 a 186.17991,176.94203 0 0 0 19.15844,40.79722 l -34.59633,33.448771 c -8.30792,8.032864 -8.52687,21.183605 -0.49402,29.491529 l 38.37861,39.695977 c 8.03287,8.307927 21.18876,8.532021 29.49668,0.499161 l 38.18306,-36.917158 c 0.81526,-0.788267 1.52766,-1.638878 2.18703,-2.516376 a 186.17991,176.94203 0 0 0 40.64284,14.666001 c -1.48881,2.614626 -2.3517,5.635813 -2.3517,8.871643 V 7.8295477 c -2e-5,9.9246003 7.9885,17.9131043 17.9131,17.9131043 h 60.06885 c 9.9246,0 17.91311,-7.988504 17.91311,-17.9131043 V -39.595672 c 0,-3.561659 -1.04184,-6.865234 -2.81997,-9.648684 a 186.17991,176.94203 0 0 0 43.6738,-16.796432 c 0.79782,1.17452 1.7262,2.286291 2.7891,3.314003 l 38.17793,36.917156 c 8.30792,8.032861 21.46383,7.813913 29.49668,-0.494013 l 38.38376,-39.695978 c 8.03285,-8.307927 7.80878,-21.463813 -0.49916,-29.496674 L 741.1312,-132.16644 a 186.17991,176.94203 0 0 0 17.22355,-38.7903 c 0.81538,0.0959 1.63832,0.15954 2.48035,0.15954 h 53.11151 c 11.55631,0 20.86173,-9.30029 20.86176,-20.8566 v -55.22136 c -3e-5,-11.55631 -9.30545,-20.85661 -20.86176,-20.85661 H 760.8351 c -0.45423,0 -0.89627,0.0387 -1.3431,0.067 a 186.17991,176.94203 0 0 0 -18.71588,-41.66174 c 0.38809,-0.32484 0.77779,-0.64595 1.14755,-1.00344 l 38.18308,-36.91715 c 8.30792,-8.0329 8.52686,-21.18878 0.49401,-29.4967 l -38.37863,-39.696 c -8.03285,-8.30792 -21.18873,-8.53204 -29.49666,-0.49919 l -38.18307,36.91717 c -1.69003,1.63409 -3.02536,3.49091 -4.04475,5.46502 a 186.17991,176.94203 0 0 0 -42.80412,-16.24069 c 2.02071,-2.90085 3.21108,-6.42706 3.21108,-10.24563 v -47.42006 c 0,-9.92461 -7.98851,-17.91312 -17.9131,-17.91312 z m 27.39713,165.84933 a 84.952219,80.737058 0 0 1 84.95474,80.73506 84.952219,80.737058 0 0 1 -84.95474,80.73505 84.952219,80.737058 0 0 1 -84.94961,-80.73505 84.952219,80.737058 0 0 1 84.94961,-80.73506 z" />
</g>
</g>
</g>
</g>
</svg>

After

Width:  |  Height:  |  Size: 14 KiB

BIN
bin/settingmini.png Normal file

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.4 KiB

View File

@ -294,7 +294,10 @@ public class ecritureSujet {
return noPourPlacerEvaluer;
}
/**
* Ajoute les attribut d'analyseWriter par défaut
* @param no
*/
private static void nextNodesEnfants(ArrayList<node> no) {
for(int k=0 ; k < no.size(); k++) {
if(no.get(k)!=null) {

View File

@ -498,7 +498,8 @@ public class meptl {
/**
* Lecture du fichier Writer des étudiants et fournir tous les nodes de la lecture dans un node nommé "fichier".
* Lecture du fichier Writer des étudiants et fournir tous les nodes de la lecture dans un node nommé "fichier".<br>
* Permet aussi de créer un fichier d'analyse à partir d'un fichier ODF.<br>
* @param nod Le node Writer de l'étudiant.
* @param a Objet de la class Run package cXML
* @param i Index de l'étudiant dans la liste EC de l'objet a.
@ -515,23 +516,22 @@ public class meptl {
// ajoute les créateurs ou éditeur dans les nodes dc:creator ou meta:initial-creator
// Pour permettre l'analyse avec les attributs evalNameCreator ou evalNameInitialCreator
if(!commandes.ecritCode) {
if(nodmeta.retourneEnfantsByNameExist("dc:creator")) {
if(a.getLectDossiers().getEC().getListeNomDossier().get(i)!=null) {
nodmeta.retourneFirstEnfantsByName("dc:creator").getAttributs().put("creator", a.getLectDossiers().getEC().getListeNomDossier().get(i));
}else {
nodmeta.retourneFirstEnfantsByName("dc:creator").getAttributs().put("creator", "null");
}
}
if(nodmeta.retourneEnfantsByNameExist("meta:initial-creator")) {
if(a.getLectDossiers().getEC().getListeNomDossier().get(i)!=null) {
nodmeta.retourneFirstEnfantsByName("meta:initial-creator").getAttributs().put("initial-creator", a.getLectDossiers().getEC().getListeNomDossier().get(i));
}else {
nodmeta.retourneFirstEnfantsByName("meta:initial-creator").getAttributs().put("initial-creator", "null");
}
if(nodmeta.retourneEnfantsByNameExist("dc:creator")) {
if(a.getLectDossiers().getEC().getListeNomDossier().get(i)!=null) {
nodmeta.retourneFirstEnfantsByName("dc:creator").getAttributs().put("creator", a.getLectDossiers().getEC().getListeNomDossier().get(i));
}else {
nodmeta.retourneFirstEnfantsByName("dc:creator").getAttributs().put("creator", "null");
}
}
if(nodmeta.retourneEnfantsByNameExist("meta:initial-creator")) {
if(a.getLectDossiers().getEC().getListeNomDossier().get(i)!=null) {
nodmeta.retourneFirstEnfantsByName("meta:initial-creator").getAttributs().put("initial-creator", a.getLectDossiers().getEC().getListeNomDossier().get(i));
}else {
nodmeta.retourneFirstEnfantsByName("meta:initial-creator").getAttributs().put("initial-creator", "null");
}
}
node nodstyle = new node();
@ -575,12 +575,13 @@ public class meptl {
node nodsequence = new node();
nodsequence.setNomElt("sequences");
nodsequence.addNode(a.retourneNames(nodbody, "text:sequence-decl"));
// le node des frames : renomme les nodes style:style avec le nom de draw:name exemple style:styledraw:name
// si une draw:text-box contenant un attribut fo:min-height alors ajoute dans darw:farme l'attribut svg:height
node nodframe = new node();
nodframe.setNomElt("frames");
nodframe.addNode(a.retourneNames(nodbody, "draw:frame"));
nodframe.addNode(a.retourneNames(nodbody, "draw:frame")); //Problème place des doublons dans la liste des nodes
for(int j = 0 ; j < nodframe.getNodes().size(); j++) {
node nodframestyle = a.retourneFirstNodeByNameAttributValue(nodstyle, "style:style", "style:name", nodframe.getNodes().get(j).getAttributs().get("draw:style-name"));
String nomObjet = nodframe.getNodes().get(j).getAttributs().get("draw:name");
@ -593,6 +594,7 @@ public class meptl {
nodframe.getNodes().get(j).getAttributs().put("svg:height", a.retourneName(nodframe.getNodes().get(j), "draw:text-box", "fo:min-height").getAttributs().get("fo:min-height"));
}
}
// le node section
node nodsection = new node();
@ -1927,7 +1929,7 @@ public class meptl {
if(nodeStudent!=null) {
retour = evaluNameCreator(retour,nodeStudent, nodeStudent.getContenu().get(0), sujet.getAttributs().get("evalNameCreator"),"Editeur");
}else {
retour = evaluNameCreator(retour,null, "Editeur inconnu", sujet.getAttributs().get("evalNameCreator"),"Editeur");
retour = evaluNameCreator(retour,null, "Pas trouvé le champ auteur", sujet.getAttributs().get("evalNameCreator"),"Editeur");
}
}

View File

@ -10,6 +10,7 @@ import java.util.stream.Collectors;
import javax.swing.JEditorPane;
import MEPTL.commandes;
import MEPTL.outils;
import cXML.node;
import calcul.calculIntervalleBaremeABCDE;
import calcul.calculNotesProgression;
@ -49,15 +50,31 @@ public class afficheText extends JEditorPane {
sb.append("<p class=\"p1\">Parent = " + nodeParent.getNomElt() + "</p><br>");
sb.append("<hr><br><h1>Nom du node : " + nod.getNomElt() + "</h1><br><hr>");
//sous titre pour identifier les éléments
if(nod.getNomElt().equals("style:style")) {
sb.append("<h2>Nom du style : " + nod.getAttributs().get("style:name")+ "</h2><br>");
}
if(nod.getNomElt().equals("draw:frame")) {
sb.append("<h2>Nom du frame : " + outils.withoutCodeAndPointPourRechercheContenuExact(nod.getAttributs().get("draw:name"))+ "</h2><br>");
}
if(nod.getNomElt().equals("style:master-page")) {
sb.append("<h2>Nom du style de page : " + nod.getAttributs().get("style:display-name")+ "</h2><br>");
}
if(nod.getNomElt().equals("page")) {
sb.append("<h2>Numero absolue de la page : " + outils.withoutCodeAndPointPourRechercheContenuExact(nod.getAttributs().get("numeroabsolue"))
+ " - Numerotation de la page : " + outils.withoutCodeAndPointPourRechercheContenuExact(nod.getAttributs().get("numero"))+ "</h2><br>");
}
if(nod.getAttributs().get("evaluer")!=null) if(nod.getAttributs().get("evaluer").equalsIgnoreCase("true")) {
sb.append("<p><img src="+afficheText.class.getResource("/resources/evalwriter.png").toString()+"> Ce node est évalué.</p>");
}
if(nod.getAttributs().size()>0) {
if(nod.getAttributs().size()==1) sb.append("<br><h4><u>L'ATTRIBUT DU NODE</u></h4>");
if(nod.getAttributs().size()>1) sb.append("<br><h4><u>LES ATTRIBUTS DU NODE</u></h4>");

View File

@ -2302,30 +2302,33 @@ public class create extends JFrame {
if (chooser.showOpenDialog(null) == JFileChooser.APPROVE_OPTION) {
System.out.println("getCurrentDirectory(): " + chooser.getCurrentDirectory());
System.out.println("getSelectedFile() : " + chooser.getSelectedFile().getAbsolutePath());
commandes.path = chooser.getCurrentDirectory().getAbsolutePath();
commandes.PathFilenameAnalysis = chooser.getSelectedFile().getAbsolutePath();
commandes.PathFilenameAnalysis = chooser.getCurrentDirectory().getAbsolutePath();
String cheminVersFichier = chooser.getSelectedFile().getAbsolutePath();
commandes.nameSujet = chooser.getSelectedFile().getName();
Run b = null;
try {
b = new Run(commandes.PathFilenameAnalysis);
node nodSujet = Run.XMLContent(b.getLectDossiers().getEC().getListeContentWriter().get(0));
b = new Run(cheminVersFichier);
commandes.sujet = Run.XMLContent(b.getLectDossiers().getEC().getListeContentWriter().get(0));
commandes.sujet = meptl.LectureFichierEtudiantSousFormeDeNode(commandes.sujet,b,0);
commandes.sujet.getAttributs().put("analysis_filename","sujet.xml");
commandes.sujet = ecritureSujet.nodePourEcritureSujet(commandes.sujet,b,0);
commandes.sujet.supprimeTousLesNodesEnfantWithThisName("text:change-start");
commandes.sujet.supprimeTousLesNodesEnfantWithThisName("text:change-end");
commandes.sujetSauvegarde = commandes.sujet.clone();
nodSujet = meptl.LectureFichierEtudiantSousFormeDeNode(nodSujet,b,0);
nodSujet.getAttributs().put("analysis_filename","sujet.xml");
commandes.sujet = ecritureSujet.nodePourEcritureSujet(nodSujet,b,0);
new verificationFichierAnalyse();
if(commandes.fichierAnalyseValide) {
constructionTree();
textNodeSelect.afficheChargementFichierAnalyse();
textNodeSelect.afficheChargementFichierAnalyse();
}else {
textNodeSelect.setText("<h1>Le fichier n'est pas valise</h1>");
}
@ -2336,7 +2339,6 @@ public class create extends JFrame {
} else {
textNodeSelect.refreshAffichage(null);
// refeshNodeSelected();
}
@ -2379,13 +2381,14 @@ public class create extends JFrame {
Run.parentAndLevel(commandes.sujet, commandes.sujet, 0);
DefaultMutableTreeNode node0 = null;
DefaultMutableTreeNode node1 = null;
DefaultMutableTreeNode node2 = null;
DefaultMutableTreeNode node3 = null;
DefaultMutableTreeNode node4 = null;
DefaultMutableTreeNode node5 = null;
DefaultMutableTreeNode node6 = null;
try {
Run.ecritureNodeEnXML(commandes.sujet, "test", commandes.PathFilenameAnalysis, "");
} catch (IOException e) {
e.printStackTrace();
}
DefaultMutableTreeNode root = null;
commandes.tree.getSelectionModel().setSelectionMode(TreeSelectionModel.SINGLE_TREE_SELECTION);
commandes.tree.setExpandsSelectedPaths(true);
@ -2396,34 +2399,10 @@ public class create extends JFrame {
if(commandes.sujet.getNomElt().equals("fichier")) {
node0 = new DefaultMutableTreeNode(commandes.sujet.getNomElt(),true);
if(commandes.sujet!=null) for(int i = 0 ; i < commandes.sujet.getNodes().size(); i++) {
node1 = new DefaultMutableTreeNode(commandes.sujet.getNodes().get(i));
if(commandes.sujet.getNodes().get(i)!=null) for(int j = 0 ; j < commandes.sujet.getNodes().get(i).getNodes().size();j++) {
node2 = new DefaultMutableTreeNode(commandes.sujet.getNodes().get(i).getNodes().get(j));
if(commandes.sujet.getNodes().get(i).getNodes().get(j)!=null) for(int k = 0 ; k<commandes.sujet.getNodes().get(i).getNodes().get(j).getNodes().size(); k++){
node3 = new DefaultMutableTreeNode(commandes.sujet.getNodes().get(i).getNodes().get(j).getNodes().get(k));
if(commandes.sujet.getNodes().get(i).getNodes().get(j).getNodes().get(k)!=null) for(int l = 0 ; l<commandes.sujet.getNodes().get(i).getNodes().get(j).getNodes().get(k).getNodes().size(); l++){
node4 = new DefaultMutableTreeNode(commandes.sujet.getNodes().get(i).getNodes().get(j).getNodes().get(k).getNodes().get(l));
if(commandes.sujet.getNodes().get(i).getNodes().get(j).getNodes().get(k).getNodes().get(l)!=null) for(int m = 0 ; m<commandes.sujet.getNodes().get(i).getNodes().get(j).getNodes().get(k).getNodes().get(l).getNodes().size(); m++){
node5 = new DefaultMutableTreeNode(commandes.sujet.getNodes().get(i).getNodes().get(j).getNodes().get(k).getNodes().get(l).getNodes().get(m));
if(commandes.sujet.getNodes().get(i).getNodes().get(j).getNodes().get(k).getNodes().get(l).getNodes().get(m)!=null) for(int n = 0 ; n<commandes.sujet.getNodes().get(i).getNodes().get(j).getNodes().get(k).getNodes().get(l).getNodes().get(m).getNodes().size(); n++){
node6 = new DefaultMutableTreeNode(commandes.sujet.getNodes().get(i).getNodes().get(j).getNodes().get(k).getNodes().get(l).getNodes().get(m).getNodes().get(n));
node5.add(node6);
}
node4.add(node5);
}
node3.add(node4);
}
node2.add(node3);
}
node1.add(node2);
}
node0.add(node1);
}
root = new DefaultMutableTreeNode(commandes.sujet.getNomElt(),true);
root = addNodeMutable(commandes.sujet, root);
}
commandes.tree = new JTree(node0);
commandes.tree = new JTree(root);
DefaultTreeCellRenderer cellRenderer = (DefaultTreeCellRenderer) commandes.tree.getCellRenderer();
@ -2442,10 +2421,27 @@ public class create extends JFrame {
tree.setCellRenderer(cellRenderer);
tree.setModel(commandes.tree.getModel()) ;
}
/**
* Permet la construction du tree.
* @param nod
* @param parent
* @return
*/
private DefaultMutableTreeNode addNodeMutable(node nod, DefaultMutableTreeNode parent) {
if(nod!=null) {
DefaultMutableTreeNode node1 = null;
for(int i = 0 ; i < nod.getNodes().size(); i++) {
node1 = new DefaultMutableTreeNode(nod.getNodes().get(i));
addNodeMutable(nod.getNodes().get(i), node1);
parent.add(node1);
}
}
return parent;
}
/**

View File

@ -1,6 +1,5 @@
package app;
import java.awt.EventQueue;
import javax.swing.JFrame;
import javax.swing.JPanel;
@ -19,7 +18,6 @@ import javax.swing.JButton;
import javax.swing.JComboBox;
import javax.swing.DefaultComboBoxModel;
import java.awt.event.ActionListener;
import java.text.DecimalFormat;
import java.awt.event.ActionEvent;
import net.miginfocom.swing.MigLayout;
import java.awt.Toolkit;

View File

@ -27,6 +27,8 @@ public class listeAttributsAnalyseWriter {
if(attribut.equals("evalNameInitialCreator")) return true;
if(attribut.equals("recherche_anchor-page-number")) return true;
if(attribut.equals("recherche_contenu_plus_proche_voisin")) return true;
if(attribut.equals("numero")) return true;
if(attribut.equals("numeroabsolue")) return true;
return false;
}

View File

@ -11,6 +11,8 @@ public listeNodeAnalyseWriter() {
if(nameNode.equals("fichier")) return true;
if(nameNode.equals("style:paragraph")) return true;
if(nameNode.equals("section")) return true;
if(nameNode.equals("page")) return true;
if(nameNode.equals("structurepage")) return true;
if(nameNode.equals("setting")) return true;
return false;