summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--Master/texmf-dist/doc/latex/profmaquette/ProfMaquette-doc.pdfbin288578 -> 288571 bytes
-rw-r--r--Master/texmf-dist/doc/latex/profmaquette/ProfMaquette-doc.zipbin103215 -> 103315 bytes
-rw-r--r--Master/texmf-dist/tex/latex/profmaquette/ProfMaquette.sty127
3 files changed, 78 insertions, 49 deletions
diff --git a/Master/texmf-dist/doc/latex/profmaquette/ProfMaquette-doc.pdf b/Master/texmf-dist/doc/latex/profmaquette/ProfMaquette-doc.pdf
index dbd1708aafd..552ebfe62c4 100644
--- a/Master/texmf-dist/doc/latex/profmaquette/ProfMaquette-doc.pdf
+++ b/Master/texmf-dist/doc/latex/profmaquette/ProfMaquette-doc.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/profmaquette/ProfMaquette-doc.zip b/Master/texmf-dist/doc/latex/profmaquette/ProfMaquette-doc.zip
index 1a6d59ad430..baedcd57bbf 100644
--- a/Master/texmf-dist/doc/latex/profmaquette/ProfMaquette-doc.zip
+++ b/Master/texmf-dist/doc/latex/profmaquette/ProfMaquette-doc.zip
Binary files differ
diff --git a/Master/texmf-dist/tex/latex/profmaquette/ProfMaquette.sty b/Master/texmf-dist/tex/latex/profmaquette/ProfMaquette.sty
index 62f7313ca35..9d2e501a04f 100644
--- a/Master/texmf-dist/tex/latex/profmaquette/ProfMaquette.sty
+++ b/Master/texmf-dist/tex/latex/profmaquette/ProfMaquette.sty
@@ -2,9 +2,9 @@
% licence : Released under the LaTeX Project Public License v1.3c
% or later, see http://www.latex-project.org/lppl.txtf
\NeedsTeXFormat{LaTeX2e}%
-\def\filedate{2024/04/13}%
+\def\filedate{2024/04/25}%
\let\PfMfiledate\filedate%
-\def\fileversion{0.91}%
+\def\fileversion{0.92}%
\let\PfMfileversion\fileversion%
\ProvidesPackage{ProfMaquette}[\filedate\space v\fileversion\space Maquettage de documents]%
@@ -40,7 +40,7 @@
\makeatother
%définition des clés
\RequirePackage{simplekv}%
-\setKVdefault[Boulot]{Dys=false,Taille=14,Cours=false,Base=false,BaseHTML=false,CAN=false,Fiche=false,DM=false,DS=false,IE=false,Kholle=false,RecapBrevet=false,PdT=false,Parcours=false,Contrat=false,FdR=false,ParcoursPerso=false,OlympiadesAPMEP=false,CorrigeSeul=false,CorrigeApres=false,CorrigeFin=false,CorrigeAll=false,Brevet=false,BaremeComplet=false,BaremeGlobal=false,CorrectionColonnes=false,Epaisseur=0pt,VersSolution=false,Small=false,Footnotesize=false,Scriptsize=false,AllDirect=false,AllPouce=false}%Les deux derniers pour essayer de mettre tous les exercices d'un même fichier en mode Reponse, en mode Indice. Pas implanté, pas testé
+\setKVdefault[Boulot]{Dys=false,Taille=14,Cours=false,Base=false,BaseHTML=false,CAN=false,Fiche=false,DM=false,DS=false,IE=false,Kholle=false,RecapBrevet=false,PdT=false,Parcours=false,Contrat=false,FdR=false,ParcoursPerso=false,OlympiadesAPMEP=false,CorrigeInverse=false,CorrigeSeul=false,CorrigeApres=false,CorrigeFin=false,CorrigeAll=false,Brevet=false,BaremeComplet=false,BaremeGlobal=false,CorrectionColonnes=false,Epaisseur=0pt,VersSolution=false,Small=false,Footnotesize=false,Scriptsize=false,AllDirect=false,AllPouce=false}%Les deux derniers pour essayer de mettre tous les exercices d'un même fichier en mode Reponse, en mode Indice. Pas implanté, pas testé
\defKV[Boulot]{Colonnes=\setKV[Boulot]{CorrectionColonnes}}%
\setKVdefault[Cours]{Couleur=Crimson,Theme=Trace écrite,NomExercice=Exercice}%
\setKVdefault[DM]{Numero=1,Date=\today,Classe={},Niveau=3,Code=\jobname}%
@@ -85,12 +85,28 @@
\IfNoValueTF{#1}{\PfMDotfill}{\makebox[#1]{\PfMDotfill}}%
}%
%
-\NewDocumentCommand\PfMLignespointilles{m}{%
- \xintifboolexpr{\fpeval{#1}>1}{%
- \xintFor* ##1 in {\xintSeq {1}{\fpeval{#1}}}\do{%
- \PfMpointilles\par%
- }%
- }{}%
+\NewDocumentCommand\PfMNbLignesRestantes{}{%
+ \edef\measurepage{\dimexpr\pagegoal-\pagetotal\relax}%
+ \xdef\PfMResteLignes{\fpeval{trunc((\the\measurepage)/(\baselineskip),0)}}%
+}%
+
+\NewDocumentCommand\PfMLignesFinales{}{%
+ \PfMNbLignesRestantes%
+ \xintFor* ##1 in {\xintSeq {1}{\PfMResteLignes}}\do{%
+ \PfMpointilles\par%
+ }%
+}%
+
+\NewDocumentCommand\PfMLignespointilles{sm}{%
+ \IfBooleanTF{#1}{%
+ \par\PfMLignesFinales%
+ }{%
+ \xintifboolexpr{\fpeval{#2}>1}{%
+ \xintFor* ##1 in {\xintSeq {1}{#2}}\do{%
+ \PfMpointilles\par%
+ }%
+ }{}%
+ }%
}%
% Definition de longueurs
\newlength\PfMLargeurSchemaParcours%
@@ -143,6 +159,8 @@
\newcounter{Nbcolonnes}
+\newbox\PfMSauvegardeBox%
+
\newif\ifPfMDeuxColonnes
\newif\ifPfMRectoVerso
\makeatletter
@@ -2278,6 +2296,8 @@
\fi%
}%
+\newbox\PfMBoxSauvegarde%
+
\NewDocumentEnvironment{exerciceFiche}{so+b}{%
\setcounter{PfMAlea}{0}%
\setcounter{PfMNbLogo}{1}%
@@ -2298,6 +2318,8 @@
\refstepcounter{PfMSection}%
\PfMChoixCorrection%
\refstepcounter{PfMExo}%
+ % \setbox\PfMBoxSauvegarde{#3\unskip\unpenalty\unpenalty}
+% \setbox\PfMBoxSauvegarde=\vbox{#3}
\ifboolKV[Boulot]{CorrigeSeul}{}{%
\PfMChoixTitreSolution%
\PfMChoixHideItemSolution%
@@ -3373,47 +3395,54 @@
}{%
\ifboolKV[Boulot]{CAN}{%
\setKV[CAN]{#2}%
- \ifboolKV[Boulot]{CorrigeSeul}{}{\TikzCAN}%
+ %\ifboolKV[Boulot]{CorrigeSeul}{}{\TikzCAN}%
\PfMChangerTailleCorrection%
- \setcounter{PfMCNNumQ}{0}%
- \setlength{\PfMLargeurQuestion}{\useKV[CAN]{CoefQ}\linewidth}\setlength{\PfMLargeurReponse}{\useKV[CAN]{CoefR}\linewidth}\setlength{\PfMLargeurJury}{\useKV[CAN]{CoefJ}\linewidth}%
- \let\exercice\ExoCANWrite\let\endexercice\endExoCANWrite%
- \AddToHook{env/exercice/begin}{\setcounter{PfMAlea}{0}}%
- \AddToHook{env/Maquette/end}{%
- \xdef\PfMCANTotalExo{\thePfMExo}%
- \ifboolKV[Boulot]{CorrigeSeul}{}{
- \setcounter{PfMExo}{0}%
- \renewcommand{\arraystretch}{2}%
- \begin{longtable}{|c|m{\PfMLargeurQuestion}|>{\centering\arraybackslash}m{\PfMLargeurReponse}|m{\PfMLargeurJury}|}%
- \hhline{~---}%
- \multicolumn{1}{c|}{}&\cellcolor{gray!15}\centering Question&\cellcolor{gray!15}\centering Réponse&\cellcolor{gray!15}\centering\arraybackslash Jury\\%
- \hline%
- \endhead%
- \xintFor* ##1 in {\xintSeq{1}{\PfMCANTotalExo}}\do{%
- \refstepcounter{PfMCNNumQ}\ttfamily{\thePfMCNNumQ}\label{TestCAN-\thePfMCNNumQ}&\Complement{}\stepcounter{PfMExo}\setcounter{PfMAlea}{0}\input{\jobname-Ex##1.can}&\CNReponse&\\
- \hline%
- }%
- \end{longtable}%
- \renewcommand{\arraystretch}{1}%
- }%
- }%
- \ifboolKV[Boulot]{CorrigeFin}{%
- \AddToHook{env/Maquette/after}[Correction]{%
- \PfMPrepareCorrection{#1}%
-% \useKVdefault[Boulot]%
-% \setKV[Boulot]{#1}%
-% \if@Dyslexie
-% \setKV[Boulot]{Dys}
-% \fi
-% \PfMBasculeDys%
-% \setlength{\columnseprule}{\useKV[Boulot]{Epaisseur}}%
- \TikzCANCor{#2}%
-% \ifboolKV[Boulot]{CorrectionColonnes}{\begin{multicols}{\useKV[Boulot]{Colonnes}}}{}%
-% \PfMAffichageCorrige%
-% \ifboolKV[Boulot]{CorrectionColonnes}{\end{multicols}}{}%
- \PfMAffichageCorrectionColonnes%
- }%
- }{}%
+ \setcounter{PfMCNNumQ}{0}%
+ \setlength{\PfMLargeurQuestion}{\useKV[CAN]{CoefQ}\linewidth}\setlength{\PfMLargeurReponse}{\useKV[CAN]{CoefR}\linewidth}\setlength{\PfMLargeurJury}{\useKV[CAN]{CoefJ}\linewidth}%
+ \let\exercice\ExoCANWrite\let\endexercice\endExoCANWrite%
+ \AddToHook{env/exercice/begin}{\setcounter{PfMAlea}{0}}%
+ \AddToHook{env/Maquette/end}{%
+ \xdef\PfMCANTotalExo{\thePfMExo}%
+ \setbox\PfMSauvegardeBox\vbox{%
+ \setcounter{PfMExo}{0}%
+ \renewcommand{\arraystretch}{2}%
+ \begin{longtable}{|c|m{\PfMLargeurQuestion}|>{\centering\arraybackslash}m{\PfMLargeurReponse}|m{\PfMLargeurJury}|}%
+ \hhline{~---}%
+ \multicolumn{1}{c|}{}&\cellcolor{gray!15}\centering Question&\cellcolor{gray!15}\centering Réponse&\cellcolor{gray!15}\centering\arraybackslash Jury\\%
+ \hline%
+ \endhead%
+ \xintFor* ##1 in {\xintSeq{1}{\PfMCANTotalExo}}\do{%
+ \refstepcounter{PfMCNNumQ}\ttfamily{\thePfMCNNumQ}\label{TestCAN-\thePfMCNNumQ}&\Complement{}\stepcounter{PfMExo}\setcounter{PfMAlea}{0}\input{\jobname-Ex##1.can}&\CNReponse&\\
+ \hline%
+ }%
+ \end{longtable}%
+ \renewcommand{\arraystretch}{1}%
+ }
+ \ifboolKV[Boulot]{CorrigeInverse}{%
+ \PfMPrepareCorrection{#1}%
+ \TikzCANCor{#2}%
+ \PfMAffichageCorrectionColonnes%
+ \clearpage
+ \TikzCAN%
+ \usebox{\PfMSauvegardeBox}%
+ }{%
+ \TikzCAN%
+ \usebox{\PfMSauvegardeBox}%
+ \ifboolKV[Boulot]{CorrigeFin}{\ifboolKV[Boulot]{CorrigeInverse}{}{\clearpage
+ \PfMPrepareCorrection{#1}%
+ \TikzCANCor{#2}%
+ \PfMAffichageCorrectionColonnes%
+ }
+ }{}
+ }
+ }%
+% \ifboolKV[Boulot]{CorrigeFin}{%
+% \AddToHook{env/Maquette/after}[Correction]{%
+% \PfMPrepareCorrection{#1}%
+% \TikzCANCor{#2}%
+% \PfMAffichageCorrectionColonnes%
+% }%
+% }{}%
}{%
\ifboolKV[Boulot]{FdR}{%
\ifboolKV[Boulot]{CorrigeSeul}{}{%