summaryrefslogtreecommitdiff
path: root/macros/latex
diff options
context:
space:
mode:
authorNorbert Preining <norbert@preining.info>2024-03-12 03:00:58 +0000
committerNorbert Preining <norbert@preining.info>2024-03-12 03:00:58 +0000
commitd297b9ceca6496ab2982347e29bb4db2be6261ad (patch)
tree3ee6e6b38f47ae1f7b20dbd5e5a453f17cb3fe14 /macros/latex
parentd0e99dfc632984d24851f9160409ef583a011f48 (diff)
CTAN sync 202403120300
Diffstat (limited to 'macros/latex')
-rw-r--r--macros/latex/contrib/denisbdoc/denisbdoc.dtx87
-rw-r--r--macros/latex/contrib/knowledge/README.md4
-rw-r--r--macros/latex/contrib/knowledge/knowledge-code.dtx17
-rw-r--r--macros/latex/contrib/knowledge/knowledge.pdfbin771140 -> 802176 bytes
-rw-r--r--macros/latex/contrib/knowledge/knowledge.tex363
-rw-r--r--macros/latex/contrib/mathtools/empheq.ins94
-rw-r--r--macros/latex/contrib/mathtools/empheq.pdfbin330511 -> 330685 bytes
-rw-r--r--macros/latex/contrib/mathtools/mathtools.dtx110
-rw-r--r--macros/latex/contrib/mathtools/mathtools.ins4
-rw-r--r--macros/latex/contrib/mathtools/mathtools.pdfbin503979 -> 506537 bytes
-rw-r--r--macros/latex/contrib/mathtools/mhsetup.ins93
-rw-r--r--macros/latex/contrib/mathtools/mhsetup.pdfbin256987 -> 256933 bytes
-rw-r--r--macros/latex/contrib/mathtools/test.pdfbin3812 -> 0 bytes
-rw-r--r--macros/latex/contrib/nwejm/README.md2
-rw-r--r--macros/latex/contrib/nwejm/doc/english/nwejm-en.pdfbin324653 -> 318860 bytes
-rw-r--r--macros/latex/contrib/nwejm/doc/english/nwejm-en.tex4
-rw-r--r--macros/latex/contrib/nwejm/doc/examples/article-in-dutch.pdfbin199039 -> 199291 bytes
-rw-r--r--macros/latex/contrib/nwejm/doc/examples/article-in-english.pdfbin194867 -> 194934 bytes
-rw-r--r--macros/latex/contrib/nwejm/doc/examples/article-in-french.pdfbin251488 -> 251770 bytes
-rw-r--r--macros/latex/contrib/nwejm/doc/examples/article-in-german.pdfbin202196 -> 202304 bytes
-rw-r--r--macros/latex/contrib/nwejm/doc/examples/issue.pdfbin397932 -> 397932 bytes
-rw-r--r--macros/latex/contrib/nwejm/doc/french/nwejm-fr.pdfbin345097 -> 339633 bytes
-rw-r--r--macros/latex/contrib/nwejm/doc/french/nwejm-fr.tex15
-rw-r--r--macros/latex/contrib/nwejm/source/nwejm.dtx64
-rw-r--r--macros/latex/contrib/robust-externalize/robust-externalize.pdfbin1630257 -> 1653583 bytes
-rw-r--r--macros/latex/contrib/robust-externalize/robust-externalize.sty54
-rw-r--r--macros/latex/contrib/robust-externalize/robust-externalize.tex31
-rw-r--r--macros/latex/contrib/starray/README.md9
-rw-r--r--macros/latex/contrib/starray/doc/starray.pdfbin273009 -> 273444 bytes
-rw-r--r--macros/latex/contrib/starray/doc/starray.tex6
-rw-r--r--macros/latex/contrib/starray/latex/starray.sty250
-rw-r--r--macros/latex/contrib/ufrgscca/README.md8
-rw-r--r--macros/latex/contrib/ufrgscca/doc/ufrgscca.pdfbin593730 -> 593583 bytes
-rw-r--r--macros/latex/contrib/ufrgscca/doc/ufrgscca.tex2
-rw-r--r--macros/latex/contrib/ufrgscca/latex/ufrgscca-abnt.sty10
-rw-r--r--macros/latex/contrib/ufrgscca/latex/ufrgscca-base-en.def2
-rw-r--r--macros/latex/contrib/ufrgscca/latex/ufrgscca-base-ptBR.def2
-rw-r--r--macros/latex/contrib/ufrgscca/latex/ufrgscca-coord.sty88
-rw-r--r--macros/latex/contrib/ufrgscca/latex/ufrgscca-core.sty38
-rw-r--r--macros/latex/contrib/ufrgscca/latex/ufrgscca-cover-ptBR.tex2
-rw-r--r--macros/latex/contrib/ufrgscca/latex/ufrgscca-cover.sty10
-rw-r--r--macros/latex/contrib/ufrgscca/latex/ufrgscca-curr.sty110
-rw-r--r--macros/latex/contrib/ufrgscca/latex/ufrgscca-forms.sty10
-rw-r--r--macros/latex/contrib/ufrgscca/latex/ufrgscca-forms.tex83
-rw-r--r--macros/latex/contrib/ufrgscca/latex/ufrgscca-lists.sty10
-rw-r--r--macros/latex/contrib/ufrgscca/latex/ufrgscca-ppc.sty87
-rw-r--r--macros/latex/contrib/ufrgscca/latex/ufrgscca-terms-en.tex2
-rw-r--r--macros/latex/contrib/ufrgscca/latex/ufrgscca-terms-ptBR.tex2
-rw-r--r--macros/latex/contrib/ufrgscca/latex/ufrgscca.cls18
49 files changed, 912 insertions, 779 deletions
diff --git a/macros/latex/contrib/denisbdoc/denisbdoc.dtx b/macros/latex/contrib/denisbdoc/denisbdoc.dtx
index 2a6d7d057b..8159146490 100644
--- a/macros/latex/contrib/denisbdoc/denisbdoc.dtx
+++ b/macros/latex/contrib/denisbdoc/denisbdoc.dtx
@@ -41,7 +41,7 @@ This package is currently not documented.
% This field contains the version of the package.
% The value is optional.
% The value is restricted to 32 characters.
-\version{0.9.4 2022-06-13}
+\version{0.9.5 2024-03-10}
% -------------------------------------------------------------------------
% This field contains the name of the author(s).
% The value is optional.
@@ -156,7 +156,7 @@ A personal dirty package for documenting packages.
\preamble
-----------------------------------------------------------------------------
denisbdoc --- A personal dirty package for documenting personal classes,
- version 0.9.4
+ version 0.9.5
Maintained by Denis Bitouzé
E-mail: denis.bitouze@univ-littoral.fr
@@ -259,6 +259,7 @@ This work consists of the file denisbdoc.dtx
%\changes{v0.9.2}{2021-10-13}{Further CTAN version}
%\changes{v0.9.3}{2021-12-01}{Further CTAN version}
%\changes{v0.9.4}{2022-06-13}{Further CTAN version}
+%\changes{v0.9.5}{2024-03-10}{Further CTAN version}
%
%\begin{abstract}
% ...
@@ -329,7 +330,7 @@ This work consists of the file denisbdoc.dtx
%
% The usual preliminaries.
% \begin{macrocode}
-\ProvidesExplPackage {denisbdoc} {2022-06-13} {0.9.4}
+\ProvidesExplPackage {denisbdoc} {2024-03-10} {0.9.5}
{A personal package for documenting packages}
% \end{macrocode}
%
@@ -2024,37 +2025,63 @@ This work consists of the file denisbdoc.dtx
\_@@_subdirectory_filetree: {}
}
%
-\cs_new_protected:Nn \_@@_mandatory:
-{
- \hyperref[sec-comm-oblig]{%
- \textcolor{red!75!black}{
- % \sys_if_engine_pdftex:TF
- % {
- % % \string!
- % \ding{52}
- % }{
+\AddToHook{begindocument/end}{%
+ \cs_new_protected:Nn \_@@_arrow:
+ {
+ {\fontfamily{pzd}\fontencoding{U}\fontseries{m}\fontshape{n}\selectfont\char213}
+ }
+ \ltx@ifpackageloaded{realscripts}{%
+ \@ifundefined{up}{
+ \cs_new_protected:Npn \_@@_deal_with_superiors:n #1
+ {
+ \fakesuperscript{#1}
+ }
+ }{
+ \cs_new_protected:Npn \_@@_deal_with_superiors:n #1
+ {
+ \up*{#1}
+ }
+ }
+ }{
+ \cs_new_protected:Npn \_@@_deal_with_superiors:n #1
+ {
+ \textsuperscript{#1}
+ }
+ }
+ \cs_new_protected:Nn \_@@_mandatory:
+ {
+ \hyperref[sec-comm-oblig]{%
+ \textcolor{red!75!black}{
\faLock
- % \ding{52}
- % }%
+ }
+ \ifnum\getpagerefnumber{sec-comm-oblig}=\thepage%
+ \else%
+ \_@@_deal_with_superiors:n{\_@@_arrow:{}\,\kvtcb@text@pageshort\,\pageref*{sec-comm-oblig}}%
+ \fi%
+ }%
+ }
+ \RenewDocumentCommand\tcb@ref@doc{msm}{%
+ \hyperref[#1:#3]{\texttt{\ref*{#1:#3}}%
+ \IfBooleanTF{#2}{}{%
+ \ifnum\getpagerefnumber{#1:#3}=\thepage\relax%
+ \else%
+ \_@@_deal_with_superiors:n{\_@@_arrow:{}%
+ \,\kvtcb@text@pageshort\,\pageref*{#1:#3}}%
+ \fi}}%
+ }
+ \cs_new_protected:Nn \_@@_mandatory_no_link:
+ {
+ \textcolor{red!75!black}{
+ \faLock
}
- \ifnum\getpagerefnumber{sec-comm-oblig}=\thepage%
- \else%
- \textsuperscript{\ding{213}\,\kvtcb@text@pageshort\,\pageref*{sec-comm-oblig}}%
- \fi%
- }%
-}
-\cs_new_protected:Nn \_@@_mandatory_no_link:
-{
- \textcolor{red!75!black}{
- \faLock
}
+ \NewDocumentCommand{\mandatory}{ s }
+ {
+ \IfBooleanTF {#1}
+ { \_@@_mandatory_no_link: {} }
+ { \_@@_mandatory: {} }
+ }%
}
-\NewDocumentCommand{\mandatory}{ s }
-{
- \IfBooleanTF {#1}
- { \_@@_mandatory_no_link: {} }
- { \_@@_mandatory: {} }
-}%
%
\NewDocumentCommand{\unixtldirectory}{}
{
diff --git a/macros/latex/contrib/knowledge/README.md b/macros/latex/contrib/knowledge/README.md
index 07b55368a0..a03e55834a 100644
--- a/macros/latex/contrib/knowledge/README.md
+++ b/macros/latex/contrib/knowledge/README.md
@@ -3,8 +3,8 @@ This directory contains the package
name: knowledge
license: LaTeX Project Public License version 1.2 or above
- version: v1.28
- date: 2022/02/12
+ version: v1.29
+ date: 2024/03/10
author: Thomas Colcombet
mail: thomas.colcombet@irif.fr
web: https://ctan.org/pkg/knowledge
diff --git a/macros/latex/contrib/knowledge/knowledge-code.dtx b/macros/latex/contrib/knowledge/knowledge-code.dtx
index 2f6a4f0a12..6bc619c558 100644
--- a/macros/latex/contrib/knowledge/knowledge-code.dtx
+++ b/macros/latex/contrib/knowledge/knowledge-code.dtx
@@ -23,7 +23,7 @@
%
% \iffalse
%<head>\usepackage{expl3}
-%<head>\ProvidesExplPackage{knowledge}{2022/02/12}{1.28}{}
+%<head>\ProvidesExplPackage{knowledge}{2024/03/10}{1.29}{}
%<*driver>
\def\knowledgecode{active}
\input{knowledge.tex}
@@ -61,6 +61,7 @@
% \changes{1.26}{2021/12/20}{enhanced math+other functionalities+extra options} %
% \changes{1.27}{2022/01/12}{doc changes} %
% \changes{1.28}{2022/02/12}{imakeidx support} %
+% \changes{1.29}{2024/03/10}{typographic bug corrected} %
% \GetFileInfo{knowledge.sty} %
% \DoNotIndex{}
%
@@ -80,8 +81,8 @@ This directory contains the package
name: knowledge
license: LaTeX Project Public License version 1.2 or above
- version: v1.28
- date: 2022/02/12
+ version: v1.29
+ date: 2024/03/10
author: Thomas Colcombet
mail: thomas.colcombet@irif.fr
web: https://ctan.org/pkg/knowledge
@@ -604,7 +605,7 @@ This directory contains the package
\KnowledgeConfigureTrigger{ fix~hyperref~twocolumn }
{\knowledgeFixHyperrefTwocolumn}
\KnowledgeConfigureTrigger{ notion }
- {\KnowledgeConfigureNotion{notion}
+ {\KnowledgeConfigureNotion[blue]{notion}
\knowledge_directives_require_aci_package:nn{notion}{hyperref}
\knowledgesetvariant\kl{suggestion=notion}
\knowledgesetvariant\intro{suggestion=notion}
@@ -3777,7 +3778,7 @@ This directory contains the package
\knowledgevariantmodifier{\phantomintro*\kl}{\phantomintro}
\knowledgevariantmodifier{\phantomkl*\kl}{\phantomkl}
-\knowledgedirective{automatic~in~command}{notion}
+\knowledgedirective{automatic~in~command}{notion,also~now}
% \end{macrocode}
% \begin{macrocode}
@@ -3787,11 +3788,8 @@ This directory contains the package
\cs_new:Nn\knowledge_inner_command:
{knowledge_cmdkl \int_to_arabic:n\knowledge_inner_modifier_count_int :n}
-
\NewDocumentCommand\withkl{mm}{
\int_gincr:N\knowledge_inner_modifier_count_int
- \group_begin:
- \group_end:
\cs_gset:cpx
{\knowledge_inner_command:}
{\exp_not:N\cs_gset:Npn
@@ -3799,7 +3797,7 @@ This directory contains the package
{\knowledge_inner_modifer_re_tl\knowledge_kl_modifiers_tl\exp_not:n{#1}}
\knowledge_kl_modifiers_tl\exp_not:n{#1}}
\knowledge_kl_modifiers_reset:
- #2{}{}
+ #2
\int_gdecr:N\knowledge_inner_modifier_count_int
}
@@ -3831,7 +3829,6 @@ This directory contains the package
\exp_args:Nc\NewDocumentCommand{knowledge\cs_to_str:N#1}{}
{\knowledge_knowledgified_newcommand:NNwn#1}
}{
- %\tl_show:n{Unknown~#1~in~\KnowledgifyNewcommand}
\use:x{\exp_not:N\NewDocumentCommand
\exp_not:c{knowledge\cs_to_str:N#1}
{}
diff --git a/macros/latex/contrib/knowledge/knowledge.pdf b/macros/latex/contrib/knowledge/knowledge.pdf
index 2e7e53daac..a4a481ddb0 100644
--- a/macros/latex/contrib/knowledge/knowledge.pdf
+++ b/macros/latex/contrib/knowledge/knowledge.pdf
Binary files differ
diff --git a/macros/latex/contrib/knowledge/knowledge.tex b/macros/latex/contrib/knowledge/knowledge.tex
index a821315e1b..8d0c1102aa 100644
--- a/macros/latex/contrib/knowledge/knowledge.tex
+++ b/macros/latex/contrib/knowledge/knowledge.tex
@@ -7,6 +7,7 @@
\usepackage{hyperref}
\usepackage{cleveref}
%\usepackage{complexity}
+\usepackage{marginfix}
\usepackage[quotation,scope,silent]{knowledge}
\knowledgeconfigure{visible anchor points=false}
\knowledgeconfigure{notion,diagnose line=false}
@@ -58,7 +59,7 @@
\textmenu{\hyperref[section:doc]{doc}} ---
\textmenu{\hyperref[section:faq]{FAQ}} ---
\textmenu{\hyperref[section:resources]{resources}} ---
- \ifcodeTF{\textmenu{\hyperref[section:code]{code}} ---}{}
+ \ifcodeTF{\textmenu{\hyperref[section:code]{CODE}} ---}{}
\end{tabular}%
}}}
}
@@ -136,8 +137,10 @@
PDF string={\detokenize{#1}}
}
-\knowledgestyle{cs}{wrap=\Robustdisplay,typewriter,up,md,color=NavyBlue}
-\knowledgestyle{cs unknown}{wrap=\Robustdisplay,typewriter,up,md,color=black}
+%\knowledgestyle{cs}{wrap=\Robustdisplay,typewriter,up,md,color=NavyBlue}
+%\knowledgestyle{cs unknown}{wrap=\Robustdisplay,typewriter,up,md,color=black}
+\knowledgestyle{cs}{wrap=\detokenize,typewriter,up,md,color=NavyBlue}
+\knowledgestyle{cs unknown}{wrap=\detokenize,typewriter,up,md,color=black}
\knowledgenewvariant\csintro
{namespace=cs,
@@ -593,7 +596,7 @@
\fbox{\usebox{\fminipagebox}}%
\kern\dimexpr-\fboxsep-\fboxrule\relax}\par\kern#2\relax}
- \newenvironment{code}[1][12.4cm]
+ \newenvironment{CODE}[1][12.4cm]
{\par
\noindent
\cminipage{#1}%
@@ -787,6 +790,7 @@ I have seen Till Tantau who explained me how to test whether a material is displ
\item[2021-12-27] Bug correction for corner shape, and doc update (thanks to Rémi Morvan).
\item[2022-01-12] Minor changes. Removing dead link for the webpage. V1.27
\item[2022-02-12] Adding support of "imakeidx@@package" and the directive "index name=" (request and code change by Maximilian Keßler). V1.28
+\item[2024-03-10] Correcting typographic bug of \cs\withkl\ and \cs\cmdkl\ when in combination with e.g. \cs\mathrel\ (suggested by Rémi Morvan). V1.29
\end{compactdesc}
\normalsize
%\restoregeometry
@@ -831,20 +835,20 @@ using either:
\marginpar{\begin{hint}
You may use other options like \kl(option){xcolor} for allowing debugging with colors (for undefined knowledges).
\end{hint}}
-\begin{code}[8cm]
+\begin{CODE}[8cm]
\cs{\usepackage}["hyperref@@package",\kl(option){quotation}]\{"knowledge@@package"\}
-\end{code}
+\end{CODE}
\noindent or equivalently:
-\begin{code}[8cm]
+\begin{CODE}[8cm]
\cs\usepackage\{\kl(package){hyperref}\}\\
\cs\usepackage[\kl(option){quotation}\footnote{If you want to use the \kl{"..."} notation.}]\{"knowledge@@package"\}
-\end{code}
+\end{CODE}
Then, in the preamble (or in an external file), one uses commands of the form either:
-\begin{code}
+\begin{CODE}
\cs\knowledge\{\kl{url=}\{https://en.wikipedia.org/wiki/LaTeX\}\}\par
\qquad\kl{|}\quad latex
-\end{code}
+\end{CODE}
This configures the text `\texttt{latex}' to be associated with the sole directive \kl{url=},
which means an hyperreference to this address.
@@ -858,13 +862,13 @@ Hence:
In fact, it is good practice to use many \cs{\kl} commands or \kl{"..."} notations while writing a text,
and only resolve these questions at the end (see also the \kl{diagnose file}).
\end{hint}}
-\begin{code}[10cm]
+\begin{CODE}[10cm]
This package has been written for use in \cs\kl\{latex\}.
-\end{code}\noindent
+\end{CODE}\noindent
or, if the \kl(option){quotation} option is activated,
-\begin{code}[10cm]
+\begin{CODE}[10cm]
This package has been written for use in \kl{"}latex\kl{"}.
-\end{code}\noindent
+\end{CODE}\noindent
yields
\knowledge{urllatex}{url=https://en.wikipedia.org/wiki/LaTeX,color=black}
\begin{PDFoutput}
@@ -875,11 +879,11 @@ This package has been written for use in \kl[urllatex]{latex}.
But in fact, I would like `\texttt{latex}' to also be properly typeset \LaTeX{}, and in \textcolor{gray}{gray}.
This requires to load the package with the \kl(option){xcolor} option (for being able to use colors, obviously), or by loading the package "xcolor@@package" before, and then modify the \cs{\knowledge} command using
extra "directives":
-\begin{code}%[10.9cm]
+\begin{CODE}%[10.9cm]
\cs\knowledge\{\kl{url=}\{https://en.wikipedia.org/wiki/LaTeX\},\par
\qquad~\qquad\kl{text=}\cs\LaTeX,~\kl{color=}gray\}\par
\qquad\kl{|}\quad latex
-\end{code}
+\end{CODE}
\noindent
yields with the same text
\knowledge{urllatexgray}{url=https://en.wikipedia.org/wiki/LaTeX, color=gray, text=\LaTeX}
@@ -900,20 +904,20 @@ the result is that the text `\textit{text}' is displayed, but urls, colors, etc
Another more systematic way to do it is to declare synonyms.
This obtained by adding the corresponding lines:
- \begin{code}[4.35cm]
+ \begin{CODE}[4.35cm]
\cs{\knowledge}\{"url="\dots\}\\
\indent~\vbar~Donald Ervin Knuth\\
\indent~\vbar~Donald Knuth\\
\indent~\vbar~D. Knuth\\
\indent~\vbar~Knuth
- \end{code}
+ \end{CODE}
\noindent would allow
\begin{center}
\smallcode{\cs\kl\{Knuth\}}~~~as well as~~~\smallcode{\cs\kl\{Donald Knuth\}},\\
or simply \smallcode{\kl"Knuth\kl"}~~~as well as~~~\smallcode{\kl"Donald Knuth\kl"} and so on
\end{center} to all point to the same web address.
It is even more convenient to use it for nouns that are sometimes in plural form or at the beginning of a sentence. There is also a scoping feature that helps distinguishing the same names in a different context. For instance:
-\begin{code}[12.4cm]
+\begin{CODE}[12.4cm]
\cs\knowledge\{\kl{url=}https://en.wikipedia.org/wiki/Group\_(mathematics)\}
\qquad\indent~~~\vbar~~group\\
\qquad\indent~~~\vbar~~groups\\
@@ -924,13 +928,13 @@ It is even more convenient to use it for nouns that are sometimes in plural form
\qquad\indent~~~\vbar~~morphism@GROUP\\
\qquad\indent~~~\vbar~~morphisms@GROUP\\
\qquad\indent~~~\vbar~~Morphisms@GROUP
-\end{code}
+\end{CODE}
\end{variation}
\noindent
makes it possible to use the notions in many contexts:
-\begin{code}
+\begin{CODE}
\kl"Groups\kl" form a category when equipped with \kl"group morphisms\kl". Consider now some \kl"morphism@@GROUP\kl" \$\cs\alpha\$ ...
-\end{code}
+\end{CODE}
In the above code all quoted parts send the reader to the same wikipedia page about groups.
Note in particular that \smallcode{\kl"morphism@@GROUP\kl"} simply displays `morphism' at compilation.
The \smallcode{GROUP} part is a "scope".
@@ -952,9 +956,9 @@ However, I do not want it to be a hassle when writing.
A solution is as follows. First load the "knowledge@@package" package in the preamble:
-\begin{code}[11cm]
+\begin{CODE}[11cm]
\cs\usepackage[\kl(option){xcolor},\kl(option){hyperref},\kl(option){notion},\kl(option){quotation}]\{"knowledge@@package"\}
-\end{code}
+\end{CODE}
\noindent with suitable options: \kl(option){hyperref} for links,
\kl(option){xcolor} for colors (if required, but always advised), "quotation@@option" for using the "quotation notation" and \kl(option){notion} for automatic configuration of the "notion" "directive".
@@ -964,15 +968,15 @@ Then write the document using \cs{\intro} (or \kl{""...""} if \kl(option){quotat
\marginpar{\begin{hint} Using an \cs{\AP} command is strongly advised,
and allows to control more precisely where the target of hyperreferences is: at the beginning of a paragraph is better than the beginning of the section several pages before...\end{hint}}
\cs{\kl} (or \kl{"..."} if \kl(option){quotation} is activated) when it is used. For instance:
-\begin{code}[12cm]
+\begin{CODE}[12cm]
\cs\AP{}
A \cs\intro\{semigroup\} is an ordered pair \verb|$(S,\cdot)$| in which \verb|$S$| is a set and \verb|$\cdot$| is an
associative binary operator over~\verb|$S$|. A \cs\intro\{semigroup morphism\} is "[...]"\\
"[...]"\\
Consider a \cs\kl\{semigroup morphism\} between \cs\kl\{semigroups\} \verb|$S$| and \verb|$T$|. "[...]"
-\end{code}
+\end{CODE}
\noindent or when the "quotation notation" is activated:
-\begin{code}[12cm]
+\begin{CODE}[12cm]
\cs\AP{}
A \kl{""}semigroup\kl{""} is an ordered pair \verb|$(S,\cdot)$| in which \verb|$S$| is a set and \verb|$\cdot$| is an
associative binary operator over~\verb|$S$|.
@@ -980,7 +984,7 @@ associative binary operator over~\verb|$S$|.
A \kl{""}semigroup morphism\kl{""} is "[...]"\\
"[...]"\\
Consider a \kl"semigroup morphism\kl" between \kl"semigroups\kl" \verb|$S$| and \verb|$T$|. "[...]"
-\end{code}
+\end{CODE}
This yields
\knowledgeconfigure{visible anchor points=true}%
@@ -1006,13 +1010,13 @@ which means that the strings `\texttt{semigroup}', `\texttt{semigroups}' and `\
\AP
To solve this, let us copy these four lines in the preamble\footnote{It is good practice to use a separate file, something like `paper-knowledge.tex'.}, replacing ignore by the \kl{notion} \kl{directive} and separating it into two blocks. We obtain:
-\begin{code}[6.7cm]
+\begin{CODE}[6.7cm]
\cs\knowledge\{\kl{notion}\}\\
\indent~~~\klbn|~~semigroup\\
\indent~~~\klbn|~~semigroups\\
\cs\knowledge\{\kl{notion}\}\\
\indent~~~\klbn|~~semigroup morphism
-\end{code}
+\end{CODE}
\noindent
This informally means that `\texttt{semigroup}' and `\texttt{semigroups}' are two strings that represent the same notion, and that
`\texttt{semigroup morphism}' is a different one.
@@ -1035,7 +1039,7 @@ location of the red corner depicting the presence of the \cs{\AP}-command before
If now one adds the option \kl{electronic} while loading the package, then the red corners disappear as well as the undefined knowledges which become black. When using the option \kl{paper}, the links are still there, but all texts are in black.
A more complete example would look as follows:
-\begin{code}[6.7cm]
+\begin{CODE}[6.7cm]
\cs\knowledge\{\kl{notion}\}\\
\indent~~~\klbn|~~semigroup\\
\indent~~~\klbn|~~semigroups\\
@@ -1045,7 +1049,7 @@ A more complete example would look as follows:
\indent~~~\klbn|~~semigroup morphisms\\
\indent~~~\klbn|~~morphism@SG\\
\indent~~~\klbn|~~morphisms@SG
-\end{code}\noindent
+\end{CODE}\noindent
The most interesting part consists of the two last lines. These define `\texttt{morphism}' and `\texttt{morphisms}' to represent the same notion as `\texttt{semigroup morphism}' when in the scope `\texttt{SG}' (a convenient abbreviation chosen by the writer for meaning `semigroup'). This is particularly useful for separating morphisms of semigroups from, say, ring morphisms.
Now, using \smallcode{Take a \cs\kl\{morphism\} ...} would yield an unknown knowledge. However,
\smallcode{Take a \cs\kl(SG)\{morphism\} ...} or \smallcode{Take a \kl"morphism@@SG\kl" ...} would yield
@@ -1065,9 +1069,9 @@ These \kl(ex1)[semigroup]{algebraic objects} "[...]"
The term is properly linked to the definition of semigroups.
Another possibility is to refer to the location of the definition, using commands \cs\kref, \cs\kpageref, and even better their improvements \cs\kcref, \cs\kCref, etc (when using the "cleveref@@option" package). For instance,
-\begin{code}
+\begin{CODE}
\kl"Semigroups\kl" are introduced in \cs\kCref\{semigroup\},\\ Page~\cs\kpageref\{semigroup\}.
-\end{code}
+\end{CODE}
\noindent yields:
\begin{PDFoutput}[10cm]
\kl(ex1)[semigroups]{Semigroups} are introduced in \kCref(ex1){semigroups},
@@ -1077,7 +1081,7 @@ Finally, in particular for large documents, it is good to have an "index". For t
one should load the package "makeidx@@package" before "knowledge@@package".
Then use it normally: putting \cs{\makeindex} in the preamble and \cs{\printindex} at the end of the document.
Finally, the \cs{knowledge} commands are adapted in a straightforward manner:
-\begin{code}[10.7cm]
+\begin{CODE}[10.7cm]
\cs\knowledge\{\kl{notion},"index="semigroup\}\\
\indent~~~\klbn|~~semigroup\\
\indent~~~\klbn|~~semigroups\\
@@ -1087,7 +1091,7 @@ Finally, the \cs{knowledge} commands are adapted in a straightforward manner:
\indent~~~\klbn|~~semigroup morphisms\\
\indent~~~\klbn|~~morphism@SG\\
\indent~~~\klbn|~~morphisms@SG
-\end{code}\noindent
+\end{CODE}\noindent
Now, the index (after running \texttt{makeindex}) contains all entries and references to the use of semigroups and semigroup morphisms.
See \kCref(option){makeidx} for more details on making an index.
@@ -1102,13 +1106,13 @@ See \kCref(option){makeidx} for more details on making an index.
\label{subsection:mathematics scenario}
The examples above show various techniques for using \kl{knowledges} for enhancing the information associated to terms. In fact, these techniques are not incompatible with mathematics. Some special syntax is even offered:
-\begin{code}[12.6cm]
+\begin{CODE}[12.6cm]
\cs\knowledgenewrobustcmd\cs\closure[1]\{\cs\cmdkl\{\cs\langle\}\#1\cs\cmdkl\{\cs\rangle\}\}\}\\
"[...]"\\
The closure of~\$X\$ under product is denoted~\$\cs\intro*\cs\closure\{X\}\$.\\
"[...]"\\
Consider now \$\cs\closure\{\cs\{a,b,c\cs\}\}\$.
-\end{code}\noindent
+\end{CODE}\noindent
\noindent
would yield:
\begin{PDFoutput}[8cm]
@@ -1126,7 +1130,7 @@ Even better, I would like to be able to have variables hyperlinking to the place
attached to a particular context. This is particularly true when typesetting mathematics: a variable is meaningful inside a statement, and inside the proof of the statement. Furthermore, the same variable name may reappear elsewhere with a different meaning.
The following code gives an idea of what is possible using \kl{scoping}:
-\begin{code}
+\begin{CODE}
\cs\knowledgeconfigureenvironment\{theorem,lemma,proof\}\{\}\par\noindent
"[...]"\par\noindent
\cs\begin\{lemma\}\cs\label\{theorem:main\}\par\noindent
@@ -1140,7 +1144,7 @@ Here \$\cs\kl\ n\$ is an undefined knowledge.\par\noindent
~~~~\cs\knowledgeimport\{theorem:main\}\par\noindent
~~~~Inside the proof, \$\cs\kl\ n\$ is hyperlinked to the theorem...\par\noindent
\cs\end\{proof\}
-\end{code}
+\end{CODE}
More on \kl{scoping} can be found in Section~\ref{subsection:scoping}.
The use of "variants of \cs{\kl}" is also useful for typesetting mathematics. It allows for instance, to implicitly execute the \cs{\knowledge} command at the same time of the introduction. See~\ref{subsubsection:variants} for more detail.
@@ -1189,15 +1193,15 @@ or &\smallcode{\cs\usepackage[\kl{composition}]\{"knowledge@@package"\}}
&\smallcode{\cs\def\cs\knowledgepackagemode\texttt\{\kl{paper}\texttt\}}
\end{tabular}\\
The idea is that this can be used in automatic compilation scripts. For instance, using in a terminal:
-\begin{code}[12cm]
+\begin{CODE}[12cm]
\smallcode{\texttt{pdflatex} \quotesymbol\cs\def\cs\knowledgepackagemode%
\texttt\{\kl{electronic}\texttt\}\cs\input\texttt\{file.tex\texttt\}\quotesymbol}
-\end{code}
+\end{CODE}
\noindent would result in compiling `\texttt{file.tex}' using "knowledge@@package" in
"electronic mode".
The following primitives are available to the user for "writing mode"-sensitive configuration:
-\begin{code}[11.4cm]
+\begin{CODE}[11.4cm]
\AP
\csintro\IfKnowledgePaperModeTF\texttt\{true code\texttt\}\texttt\{false code\texttt\}\\
\AP
@@ -1210,7 +1214,7 @@ The following primitives are available to the user for "writing mode"-sensitive
\csintro{\IfKnowledgeCompositionModeTF}\texttt\{true code\texttt\}\texttt\{false code\texttt\}\\
\AP
\csintro{\ ifKnowledgeCompositionMode} true code [\cs{\ else} false code] \cs{\ fi}
-\end{code}
+\end{CODE}
\subsubsection{Automatic loading of other packages}
@@ -1222,14 +1226,14 @@ For the moment, the packages that are concerned are \kl(option){hyperref},
For activating these functionalities, it is sufficient, either to load the package \emph{before} the "knowledge@@package" package, or to name it explicitly as an "option@package option" for "knowledge@@package".
Loading separately the package is convenient for setting options for it. For instance,
a typical preamble may look like:
-\begin{code}[7cm]
+\begin{CODE}[7cm]
\cs\documentclass\{article\}\\
%\cs\usepackage[utf8]\{inputenc\}\\
%\cs\usepackage[T1]\{fontenc\}\\
\cs\usepackage[svgnames]\{\kl(package){xcolor}\}\\
\cs\usepackage[\texttt{draft}]\{\kl(package){hyperref}\}\\
\cs\usepackage[\kl(package){makeidx}]\{"knowledge@@package"\}
-\end{code}\noindent
+\end{CODE}\noindent
Such a sequence will activate the "knowledge@@package" package using the features related to \kl(package){xcolor} configured with \texttt{svgnames} option, to \kl(package){hyperref} configured with \texttt{draft} option, and to \kl(package){makeidx} with its standard configuration.
@@ -1324,13 +1328,13 @@ The second one is the ""`\vbar'-notation""\footnote{%
Detecting the end of the line requires to change the catcode of the end of line character; this is
not robust for being used in an argument or a macro.
}:
-\begin{code}[10cm]
+\begin{CODE}[10cm]
\csreintro\knowledge\{\kl[\knowledge directives]{directives}\}\\
\indent~~~~\klbn|~\kl[\knowledge knowledge name]{knowledge name}@\kl[\knowledge optional scope]{optional scope}\\
\indent~~~~\klbn|~\kl[\knowledge synonyms]{synonym 1}@\kl[\knowledge optional scope]{optional scope}\\
\indent~~~~\klbn|~\kl[\knowledge synonyms]{synonym 2}@\kl[\knowledge optional scope]{optional scope}\\
\indent~~~~~~~~$\cdots$
-\end{code}
+\end{CODE}
\AP
The \intro[\knowledge knowledge name]{knowledge name} as well as the \intro[\knowledge synonyms]{synonyms} are plain text strings describing the knowledge. It may contain any combination of symbols, including accents or special characters as long as it well bracketted.
This string will be used to fetch the \kl{knowledge}. Note (and this is a standard \kl{tex} behavior) that several consecutive spaces is the same as one or a line feed.
@@ -1424,12 +1428,12 @@ yield the corresponding standard \TeX{} spacing features in math mode,
This directive is often bypassed by the use of the \kl[\knowledge optional argument]{optional argument} of \cs{\knowledge} defining synonyms or the \kl{synonym} directive.
\itemAP[\intro{synonym}] defines the knowledge as a link to the previously defined knowledge (in fact, the most recently defined that was not using \kl{synonym}). For instance
-\begin{code}[11cm]
+\begin{CODE}[11cm]
\cs\knowledge\{Leslie Lamport\}\\
\indent~~~~~\{\kl{ref=}\{https://fr.wikipedia.org/wiki/Leslie\_Lamport\}\}\\
\cs\knowledge\{L. Lamport\}\{\kl{synonym}\}\\
\cs\knowledge\{Lamport\}\{\kl{synonym}\}
-\end{code}
+\end{CODE}
\noindent
results in the two subsequent \kl{knowledge names} to point to the first one.
\itemAP[\intro{style=}\textmd{\{knowledge style\}}] will adopt the styling option of the \kl{knowledge style}. Surrounding braces can be omitted if there are no commas.
@@ -1480,7 +1484,7 @@ sequence of directives are used. \intro{Macro directives} are here for simplifyi
After execution of the command, `name' becomes a \kl[\knowledge directives]{directive}
usable in \cs{\knowledge} commands, that amounts to execute the comma separated list `directives'. The newly created \kl[\knowledge directives]{directive} may receive a value, that is accessible as \texttt{\#1} in `directives'. By default, it does not allow the redefinition of a directive. This can be forced using the optional \texttt*. The `optional parameter' gives
a default value. For instance:
-\begin{code}
+\begin{CODE}
\cs\knowledgedirective\{highlight\}[brown]\{\kl{color=}\{\#1\},\kl{emphasize},\kl{md}\}\\{}
"[...]"\\{}
\cs\knowledge\{notion A\}\{highlight\}\\
@@ -1489,7 +1493,7 @@ a default value. For instance:
\cs\knowledge\{important notion D\}\{highlight=red\}\\{}
"[...]"\\
We shall now see \cs\kl\{notion A\}, \cs\kl\{notion B\}, \cs\kl\{notion C\}, as well as the \cs\kl\{important notion D\}.
-\end{code}
+\end{CODE}
\noindent
yields
\begin{PDFoutput}
@@ -1583,7 +1587,7 @@ notations for the \cs{\kl} and \cs{\intro} macros. Possible syntaxes are as foll
\itemAP[\smallcode{\klqn"text\klqn"}]\phantomintro{"..."}%
uses the "knowledge" pointed to by `text'. Equivalent to~\texttt{\cs\kl\{text\}}.
\itemAP[\smallcode{\klqn"text\klqn@knowledge\klqn"}]\phantomintro{"...@..."}%
- uses the "knowledge" pointed to by `knowledge to display `text'. Equivalent to~\texttt{\cs\kl[knowledge]\{text\}}.
+ uses the "knowledge" pointed to by `knowledge' to display `text'. Equivalent to~\texttt{\cs\kl[knowledge]\{text\}}.
\itemAP[\smallcode{\klqn"text\klqn{@@}scope\klqn"}]\phantomintro{"...@@..."}%
uses the "knowledge" pointed to by `text' in "scope" `scope' to display `text'. Equivalent to~\texttt{\cs\kl(scope)\{text\}}.
\itemAP[\smallcode{\klqn"text\klqn@knowledge\klqn@scope\klqn"}]\phantomintro{"...@...@..."}%
@@ -1611,9 +1615,9 @@ It can also be activated while loading the package.
\AP It is sometimes the case that some packages do use the quote symbol, usually in some environment
(this is the case of the "tikzcd@@env" environment). The "knowledge@@package" package can be configured to deactivate always the "quotation notation" when entering the environment. This is obtained using the "configuration option" ""protect quotation="" followed by a list of environments to be protected:
-\begin{code}[12cm]
+\begin{CODE}[12cm]
\cs\knowledgeconfigure\{"protect quotation="\{env1,env2,\dots\}\}
-\end{code}
+\end{CODE}
Note that the braces surrounding the list of environments can be omitted if the list contains only one item.
There are nevertheless some situations in which one would prefer to use the original \cs{\kl} notation:
@@ -1625,7 +1629,8 @@ There are nevertheless some situations in which one would prefer to use the orig
-\subsubsection{\kl{Variants of \cs{\kl}}}
+\subsubsection{Variants}
+
Several variants of the \cs\kl-command are defined by default. The syntax for their use is the same (including "scopes", \dots).
The following variants are linked to the "autoref" directive:
\begin{itemize}
@@ -1640,7 +1645,7 @@ The following variants are linked to the "autoref" directive:
following the semantics of the corresponding functions in the "cleveref@@package" package (see \kCref*"cleveref@@option").
\end{itemize}
-\subsubsection{Defining your own \kl{variants of \cs{\kl}}}
+\subsubsection{Defining your own variants}
\label{subsubsection:variants}
\phantomintro{variant of \cs{\kl}}%
It may happen for several reasons that we may want to define new variants of the \cs{\kl} macros, that essentially perform the same task, but are configured differently. Typical examples may be:
@@ -1690,7 +1695,7 @@ in which the ""stared sequence@@variant"" is of the form `\cs{variant1}*\cs{vari
This sequence is declared to reduce to \cs{\variant}.
For instance, \smallcode{\cs{\knowledgevariantmodifier}\{\cs{\intro*}\cs\kl\}\cs\intro} declares `\cs{\intro}*\cs{\kl}' to reduce to `\cs{\intro}'.
-\subsubsection{Examples of \kl{variants of \cs{\kl}}}
+\subsubsection{Examples of \kl{variants}}
The best way for introducing new variants is to look at examples. We provide two of them now.
the first one is the configuration of the \cs{\kl} and \cs{\intro} commands as defined in the "package@knowledge@package".
@@ -1698,7 +1703,7 @@ The second one is the code used in this documentation for displaying macros, def
and \cs{\csintro}.
\paragraph{The configuration of \cs{\kl} and \cs{\intro}} It is also interesting to see this code since it gives more ideas on how to modify the standard behaviour of these commands correctly.
-\begin{code}
+\begin{CODE}
\cs\knowledgestyle\{autoref link\}\{"autoref link"\}\par
\cs\knowledgestyle\{autoref target\}\{"autoref target"\}\par
\cs\knowledgestyle\{invisible\}\{"invisible"\}\par
@@ -1717,7 +1722,7 @@ and \cs{\csintro}.
~~~~"style directive=@@variant" "intro style@intro style="\par
\}\par
\cs\knowledgevariantmodifier\{\cs{\intro*}\cs\kl\}\cs\intro
-\end{code}
+\end{CODE}
Note that \cs{\reintro} and \cs{\phantomintro} are defined using similar code.
\paragraph{Displaying control sequences}
@@ -1734,7 +1739,7 @@ following semantics:
then \smallcode{\cs\cs\{\cs[\ucommand]\command\}} simply displays \cs[\ucommand]\command\ in black,
\item no \cs{\knowledge} command is necessary, and no warning is issued if a command is unknown.
\end{itemize}
-\begin{code}
+\begin{CODE}
\cs\knowledgestyle\{cs\}\par
~~~~\{"detokenize","remove space","typewriter","up","md","color="NavyBlue\}\par
\cs\knowledgestyle\{cs unknown\}\par
@@ -1761,7 +1766,7 @@ following semantics:
\}\par
\cs\knowledgevariantmodifier\{\cs{\intro*}\cs\cs\}\cs\csintro\par
\cs\knowledgevariantmodifier\{\cs\csintro*\cs\cs\}\cs\csintro\par
-\end{code}
+\end{CODE}
Several things can be noted about this code:
\begin{asparaitem}
\item the "directives" "detokenize" and "remove space" prevent the execution of the argument, and instead display its name, this is important since the argument is a control sequence,
@@ -1801,34 +1806,34 @@ the "quotation notation":
It works also for \cs{\intro} and with double quotes.
Another option is to import the scope locally, using:
-\begin{code}[10cm]
+\begin{CODE}[10cm]
\cs\knowledgeimport\{\textit{scope name 1,scope name 2,}\dots\}
-\end{code}
+\end{CODE}
After this command, the knowledges will be searched automatically in the imported scopes.
The import stops at the end of the current scoping environment.
\paragraph{Attaching knowledge to a given scope}
This can be done directly using the "scope=" "directive", for instance in:
-\begin{code}[12cm]
+\begin{CODE}[12cm]
\cs\knowledge\{knowledge\}\{"scope="\textit{scope name},\textit{directives}\}
-\end{code}
+\end{CODE}
\noindent
or, this is obtained usint the "`\vbar'-notation" using `\klbn@'~:
- \begin{code}[8cm]
+ \begin{CODE}[8cm]
\cs\knowledge\{\textit{directives}\}\\
\indent~~~\klbn|~~knowledge\klbn@\textit{scope name 1}\\
\indent~~~\klbn|~~synonym\klbn@\textit{scope name 2}\\
\indent~~~$\vdots$~~~~~~~~~~~~$\vdots$
- \end{code}
+ \end{CODE}
\AP
The other possibility is to define a knowledge inside a "scope@@env" environment:
-\begin{code}[8cm]
+\begin{CODE}[8cm]
\cs\begin\{"scope@@env"\}\cs\label\{label\}\\
\indent\quad\cs\knowledge\{knowledge 1\}\{\textit{directives}\}\\
\indent\qquad$\vdots$\\
\cs\end\{"scope@@env"\}
-\end{code}
+\end{CODE}
\noindent
In such a code, the knowledge defined is automatically visible in the environment,
and from outside, using the scope name \texttt{label}. Indeed, the \cs{\label} is overloaded for doing automatically a \cs{\knowledgescope} command.
@@ -1839,17 +1844,17 @@ In fact, it is possible to do even more: other environments can be defined to be
\subsubsection{Scoping by examples}
""Explicit scoping"" consists in attaching a precise scope name to a "knowledge" using the "scope=" "directive":
-\begin{code}
+\begin{CODE}
\cs\knowledge\{thing\}\{"scope="s1,"color="red\}\\
\cs\knowledge\{thing\}\{"scope="s2,"color="green\}\\
\\
Here, \klqn"thing\klqn" and \cs\kl\{thing\} are unknown.\\
But \klqn"thing\klqn{@@}s1\klqn" and \cs\kl(s1)\{thing\} are in red,\\
and \klqn"thing\klqn{@@}s2\klqn" and \cs\kl(s2)\{thing\} are in green.
-\end{code}
+\end{CODE}
The "`\vbar'-notation" can also be used for "explicit scoping".
This is convenient, in particular for having synonyms in different scopes:
-\begin{code}
+\begin{CODE}
\cs\knowledge\{"color="red\}\\
\indent~~\klbn|~~abelian group\\
\indent~~\klbn|~~abelian groups\\
@@ -1863,11 +1868,11 @@ and correspond to \klqn"abelian groups\klqn".\\
\cs\begin\{"scope@@env"\}\cs\knowledgeimport\{abelian\}\\
\indent~~All \klqn"groups\klqn" here are abelian.\\
\cs\end\{"scope@@env"\}
-\end{code}
+\end{CODE}
"Scopes" can also be attached to areas in the code. It is convenient to use the usual \cs{\label} command to name them (though, in practive, two different naming spaces are used).
-\begin{code}
+\begin{CODE}
\textcolor{gray}{\% We declare first in the preamble the environments that can have}\\
\textcolor{gray}{\% knowledges attached to them.}\\
\cs\knowledgeconfigureenvironment\{theorem,lemma,proof\}\{\}\\
@@ -1883,7 +1888,7 @@ But \kl{"}rabbits\kl[quotation notation]{@@}theorem:main\kl{"} point to Theorem
\cs\begin\{proof\}\cs\knowledgeimport\{theorem:main\}\\
\indent~~ Now, \kl"rabbit\kl" is hyperlinked to Theorem~\cs\ref\{theorem:main\}.
\cs\end\{proof\}
-\end{code}
+\end{CODE}
\subsubsection{What is the structure of \kl{scopes} in a document}
@@ -1891,13 +1896,13 @@ To start with, one needs to understand what are the possible \kl{scopes}. Scopes
\begin{itemize}
\itemAP By default, all the body of the document belongs to a \kl{scope} called `\texttt{document}'.
The user can open new scopes using the \intro(env){scope} environment:
- \begin{code}[10cm]
+ \begin{CODE}[10cm]
\cs\begin\{\kl(env){scope}\}\par
~~\cs\knowledge\{local notion\}\{\kl{color=}green\}\par
~~Here is a \cs\kl\{local notion\} that appears in green.\par
\cs\end\{\kl(env){scope}\}\\
But here the \cs\kl\{local notion\} is undefined.
- \end{code}
+ \end{CODE}
Note that scoping is independent from the grouping mechanism of \LaTeX.
\AP The user can also declare environments such as \texttt{lemma}, \texttt{theorem},
@@ -1915,7 +1920,7 @@ In general, when a \cs{\knowledge} command is used, the system tries to figure o
\item This default behavior can be modified using the \kl{scope=} directive. The \kl{scope=} directive can be followed with a scope level, such as `section', `subsection', 'chapter' or `itemize' (in particular in combination with the \kl{scope option}), that will be looked for in the current context and will receive the \kl{knowledge}. The \kl[\knowledge directives]{directive} can also be followed by a label name, and the active scope at the moment of this label will be used.
The following code (that requires the "scope option" for being functional) should be self explanatory:
- \begin{code}[11.5cm]
+ \begin{CODE}[11.5cm]
\cs\section\{First section\}\par\noindent
\cs\label\{section:first\}\par\noindent
\cs\knowledge\{one\}\{\kl{scope=}section,\kl{color=}green\}\par\noindent
@@ -1930,14 +1935,14 @@ The following code (that requires the "scope option" for being functional) shoul
Here neither \cs\kl\{one\} nor \cs\kl\{two\} is defined.
However, I can still use them using \cs\kl(section:first)\{one\} and \cs\kl(some label)\{two\}
(or \kl"one@@section:first\kl" and \kl"two@@some label\kl", or using the \cs{\knowledgeimport}\{section:first\}).
- \end{code}
+ \end{CODE}
\end{itemize}
\subsubsection{Naming "scopes": the \cs{\knowledgeimport}, \cs{\knowledgescope} and \cs{label} commands
}
It is often the case in a text, that one has to locally break the nesting structure of a document, and refer to a object local in an environment. For instance, a comment may refer to a variables/concept that has been locally used in the proof. The "knowledge@@package" provides suitable mechanisms for complex referencing of scopes. Let us explain this through an example:
-\begin{code}
+\begin{CODE}
\textcolor{gray}{\% We declare first in the preamble the environments that use knowledge.}\\
\cs\knowledgeconfigureenvironment\{definition\}\{knowledge=attracts\}\par\indent
"[...]"\\
@@ -1946,7 +1951,7 @@ It is often the case in a text, that one has to locally break the nesting struct
\indent~~\cs\knowledge\{something\}\{notion\}\\
\indent~~Here, \cs\intro\{something\} is a notion internal to the definition.
\cs\end\{definition\}
-\end{code}
+\end{CODE}
Note here that what is important is the location of the \cs\knowledge\ command, irrespective of the location ofthe \cs\intro\ command.
\AP The \cs\label\ command is used to name the "scope". In fact, the real command is
@@ -1966,7 +1971,7 @@ The result is that the \kl{knowledges} in the \kl{scope} identified by the label
accessible until the closure of the current \kl{scope}.
For instance:
-\begin{code}[9cm]
+\begin{CODE}[9cm]
\cs\knowledgeconfigureenvironment\{theorem,proof\}\{\}\par\indent
"[...]"\par\indent
\cs\begin\{theorem\}\cs\label\{theorem:1\}\par\noindent
@@ -1980,7 +1985,7 @@ Here \$\cs\kl\verb|\alpha|\$ is unknown.\par\noindent
~~\cs\knowledgeimport\{theorem:1\}\par\noindent
~~But now \$\cs\kl\verb|\alpha|\$ points to its definition.\par\noindent
\cs\end\{proof\}
-\end{code}
+\end{CODE}
@@ -1994,10 +1999,10 @@ Here \$\cs\kl\verb|\alpha|\$ is unknown.\par\noindent
\smallcode{\csintro\knowledgeconfigureenvironment\{environments\}\{"scope directives"\}}
\end{center}
For instance:
-\begin{code}[12cm]
+\begin{CODE}[12cm]
\cs\knowledgeconfigureenvironment \{lemma,theorem,fact,proof\}\par
~~~~~~~~\{knowledge=attracts\}
-\end{code}
+\end{CODE}
\noindent
will induce the corresponding environments to have internal knowledges.
@@ -2095,13 +2100,13 @@ Exporting means outputting in the \kl{export file} some code that it is sufficie
When this file is used, using for instance an \cs{\input} command, or simply copied and paste in another document, then the knowledge `Pythagorean theorem'
becomes available, and points to the proper file.
Hence in another document, we can use:
-\begin{code}
+\begin{CODE}
\cs\knowledgeimport\{lesson1\}
-\end{code}
+\end{CODE}
that would make immediately available all the knowledge attached to \kl{scope} `lesson1'. Another possibility if this should be linked only once is to use it directly in the text:
-\begin{code}
+\begin{CODE}
-\end{code}
+\end{CODE}
It is useful to be able to 1) export some of the knowledges defined in a document, and 2) import them in another document. For the moment this feature is not coded.
\kl{to be done}
@@ -2145,17 +2150,17 @@ the options of the "xcolor@@package" package
\label{subsection:hyperref option}
\subsubsubsection{Activating the \kl{hyperref option}}
-
-The \intro{hyperref option} loads the \intro(package){hyperref}
-and triggers a certain number of link-related features.
-This is done either by the command:
-\marginpar{%
+ \marginpar{%
\begin{hint}
The "hyperref@@package" surrounds by default links by boxes that are graphically heavy
(this are visible in some viewers, and not in some others): this is automatically deactivated when loading
- the "knowledge@@package" package. Such automatic behavior can ba avoided using the \kl{no patch}
+ the "knowledge@@package" package. Such automatic behaviour can be avoided using the \kl{no patch}
option at loading.
\end{hint}}
+The \intro{hyperref option} loads the \intro(package){hyperref}
+and triggers a certain number of link-related features.
+This is done either by the command:
+
%
\begin{center}
\smallcode{%
@@ -2213,7 +2218,7 @@ A typical use looks as follows:
executed twice, once in the \kl{table of contents}, and once in the
document itself.
\end{hint}}
-\begin{code}
+\begin{CODE}
\cs\knowledge\{house\}[Houses\vbar houses]\{\kl{autoref}\}\\~
"[...]"\\
\cs\begin\{document\}\\~
@@ -2224,7 +2229,7 @@ In this document, we will see the very important notion of \kl{"}houses\kl{"}.\\
Let us define a \kl{""}house\kl{""} to be a building that functions as a home.\\~
"[...]"\\
\cs\end\{document\}
-\end{code}\noindent
+\end{CODE}\noindent
yields
\begin{PDFoutput}
\knowledge{house}[Houses| houses]{autoref}%
@@ -2239,7 +2244,7 @@ Let us define a \intro{house} to be a building that functions as a home.
\AP
The variant \csintro{\intro*} makes the next \cs{\kl} command behave like \cs{\intro}. This is useful in particular in math mode:
-\begin{code}
+\begin{CODE}
\cs\newcommand\kl[@token]\monoid\{\cs\kl[\kl[@token]\monoid]\{\cs\mathcal M\}\}\\
\cs\knowledge\kl[@token]\monoid\{autoref\}\\~
"[...]"\\
@@ -2247,7 +2252,7 @@ The variant \csintro{\intro*} makes the next \cs{\kl} command behave like \cs{\i
Let now \$\cs{\intro*}\kl[@token]\monoid\$ be a monoid.\\~
"[...]"\\
Remember now who is \$\kl[@token]\monoid\$.
-\end{code}
+\end{CODE}
%
\marginpar{\begin{hint} This does not work in \kl{align*} and similar environments.
Section~\ref{section:amsmath questions} gives some solutions. \end{hint}}
@@ -2297,9 +2302,9 @@ there are new directives:
\end{description}
See the use of \cs{\knowledgesetvariant} for examples of configuration.
%Hence:
-%\begin{code}
+%\begin{CODE}
%%test
-%\end{code}
+%\end{CODE}
\subsubsubsection{The \kl{autorefhere} \kl[\knowledge directives]{directive}}
@@ -2340,7 +2345,7 @@ We offer here new commands for helping using this feature:
Usually putting an \cs{\AP} (a standard command of the "hyperref@@package") at the beginning of every paragraph, and replacing \cs{\item} by \cs{\itemAP} in itemize-like environments is most of the time good and safe option.
For instance:
-\begin{code}[12.5cm]
+\begin{CODE}[12.5cm]
\cs\AP\\
In order to describe what is a \cs\kl\{monoid\}, let us us first define
a \cs\intro\{product\} to be an associative binary operator,
@@ -2351,7 +2356,7 @@ and a \cs\intro\{unit\} to be "[...]"
\cs\itemAP[A \cs\intro\{semigroup\}] is a set equipped with a \cs\kl\{product\}.\\
\cs\itemAP[A \cs\intro\{monoid\}] is a \cs\kl\{semigroup\} that has a \cs\kl\{unit\}.\\
\cs\end\{description\}
-\end{code}
+\end{CODE}
\noindent
yields
\begin{PDFoutput}[10cm]
@@ -2423,22 +2428,22 @@ The following \kl[\knowledge directives]{directives} are to be used:
\itemAP[\intro{index key=}] takes as argument the \kl{index key}: a text that is used for identifying the \kl{index entry} (usually an accent free version of it). You can use `!' in it, as long as it does not clash with "index=" in order to avoid clashes.
\itemAP[\intro{index parent key=}] makes the \kl{index entry} be a subentry of the given \kl{main index entry} (a replacement of `!'). Once more, it should not clash with "index=" and "index key=".
\itemAP[\intro{index style=}] is followed by a token (without the scape character) that will be used for displaying the number (e.g. "index style="\texttt{textbf}). Usually, this is to be used in order to typeset in a particular manner the knowledges in the index when introduced. Thus, by default, the \cs{\intro}, \cs{\reintro} and \cs{\phantomintro} command use the command \csintro{\knowledgeIntroIndexStyle}. Hence, you can use for instance:
-\begin{code}[8cm]
+\begin{CODE}[8cm]
\cs\def\cs\knowledgeIntroIndexStyle\#1\{\cs\fbox\{\#1\}\}
-\end{code}
+\end{CODE}
\itemAP[\intro{index name=}] requires to activate "imakeidx@@option", and allows to choose the index name in case of multiple indexes.
\end{description}
\AP
The "directive" ""no index"", deactivates the index feature for a knowledge. This is meant to be used in a "style".
For instance
-\begin{code}
+\begin{CODE}
\cs\knowledgedirective\{standard\}\par\noindent~~~~~
\{"autoref","style="standard,"intro style="intro standard\}\\
\cs\knowledgestyle\{standard\}\{"no index"\}\\
\cs\knowledgestyle\{intro standard\}\{"emphasize"\}\\
\cs\knowledge\{test\}\{standard,"index=" test\}
-\end{code}\noindent
+\end{CODE}\noindent
result in that the introductions of `test' will be gathered in the index, but not the other uses.
\subsubsection{The \kl{cleveref option}}
@@ -2450,10 +2455,10 @@ The \intro(option){cleveref} option loads the "cleveref@@package" package and gi
These commands are variants of \cs\kl\ and hence are subject to the same syntax.
For instance,
-\begin{code}
+\begin{CODE}
\kl{"}Anchor points\kl{"} have been described in~\cs\kCref\{anchor point\},\\
Page \cs\kpageref\{anchor point\}.
-\end{code}\noindent
+\end{CODE}\noindent
would typeset as
\begin{PDFoutput}[10cm]
"Anchor points" have been introduced in~\kCref{anchor point}, Page \kpageref{anchor point}.
@@ -2489,21 +2494,21 @@ In the subsequent sections, some more explanations are given covering the case o
\paragraph*{The use through an example}\AP
Let us define the $\intro*\floor{x}$ command representing the
floor rounding of~$x$, and use it in $\floor{1.5}$. This is achieved by first defining a macro \cs\floor\ (for instance in the preamble):
-\begin{code}
+\begin{CODE}
\cs\knowledgenewrobustcmd\cs\floor[1]\{\cs\cmdkl\{\cs\lfloor\}\#1\cs\cmdkl\{\cs\rfloor\}\}
-\end{code}\noindent
+\end{CODE}\noindent
and then use it in a natural way:
-\begin{code}
+\begin{CODE}
\cs\AP\ Let us define the \$\cs\intro*\cs\floor\ x\$ command representing the floor rounding of \$x\$,
and use it in \$\cs\floor\{1.5\}\$.
-\end{code}\noindent
+\end{CODE}\noindent
There, we used a special command, \cs\knowledgenewrobustcmd, which is similar to the \cs\newrobustcmd\footnote{It has the same syntax as \cs\newcommand\ and should always be used instead as far as a good reason for not to do it is given.}
and at the same time introduces a "knowledge" for the macro name (defined using the directive "automatic in command").
It sets the contexts such that \cs\cmdkl\ implements the code for using this "knowledge". It is somehow similar to:
-\begin{code}
+\begin{CODE}
\cs\newrobustcmd\cs\floor[1]\{\cs\kl[\cs\floor]\{\cs\lfloor\}\#1\cs\kl[\cs\floor]\{\cs\rfloor\}\}\\
\cs\knowledge\{\cs\floor\}\{"automatic in command"\}
-\end{code}\noindent
+\end{CODE}\noindent
but is shorter to write and also corrects some bugs of this direct implementation\footnote{For instance, with this wrong implementation,
\smallcode{\cs\intro*\cs\floor\ x} would display in \cs\intro\ aspect the `\cs\lfloor'\ symbol but not the `\cs\rfloor' one.}.
@@ -2523,11 +2528,11 @@ The behavior of these commands is identical to the original ones, and furthemore
\AP
The commands
\begin{quote}
- \csintro\knowledgerenewcommand,\\
- \csintro\knowledgenewrobustcmd, and \\
- \csintro\knowledgenewcommand\footnote{You should always prefer \cs\knowledgenewrobustcmd\ instead. It is just here for completeness.},
+ \csintro\knowledgenewrobustcmd, [
+ \csintro\knowledgerenewcommand, and \\
+ \csintro\knowledgenewcommand\footnote{These commands are here for completeness. You should always prefer \cs\knowledgenewrobustcmd\ instead, in particular to avoid problems in sectioning commands.}],
\end{quote}
-correspond to \cs\newcommand, \cs\renewcommand, and \cs\newrobustcmd\ (from "etoolbox@@package") respectively.
+correspond to \cs\newrobustcmd (from "etoolbox@@package") , \cs\newcommand, \cs\renewcommand respectively.
\AP
The commands
\begin{quote}
@@ -2588,20 +2593,20 @@ gets to be evaluated as
An example of use of this technique is if we want "knowledges" aware of the parameters of a macro.
Imagine that you use the norms $1$ and $2$ of a function:
-\begin{code}
+\begin{CODE}
\cs\newrobustcmd\cs\norm[2]\par
~~~~\{\cs\withkl\{\cs\kl[\cs\norm\{\#1\}]\}\{\cs\cmdkl\{\cs\|\}\#2\cs\cmdkl\{\cs\|\}\_\{\cs\cmdkl\{\#1\}\}\}\}\\
\cs\knowledge\{\cs\norm\{1\}\}\{notion\}\\
\cs\knowledge\{\cs\norm\{2\}\}\{notion\}
-\end{code}\noindent
+\end{CODE}\noindent
Now, the norm $1$ and the norm $2$ can be defined in different places since "knowledge" is specific to each case.
-\begin{code}
+\begin{CODE}
\cs\AP\ The norm~\$1\$ of a function~\$f\$ is denoted \$\cs\intro*\cs\norm1f\$.\\
"[...]"\\
\cs\AP\ The norm~\$2\$ of a function~\$f\$ is denoted \$\cs\intro*\cs\norm2f\$.\\
"[...]"\\
Here, \$\cs\norm 1g\$ and \$\cs\norm2h\$ link to the proper place, while\\\$\cs\norm3g\$ is an undefined knowledge.
-\end{code}
+\end{CODE}
\subsubsection{Defining macros for math: the "mathcommand@@package" package}
@@ -2620,27 +2625,27 @@ We shall use it in the advanced examples below. It allows:
\item to define/redefine commands to be used in math mode only. This allows for instance to use the macro \cs\c\ for producing as usual a cedilla in text mode, and at the same time some variable $\mathbf c$ in math mode. This is achieved using for instance:
\smallcode{\cs\renewmathcommand\cs\c\{\cs\mathbf\{c\}\}}.
\item When redefining a command, it automatically stores the original command \cs\macro\ as \cs\LaTeXmacro. So for instance, if one wants to introduce the constant~$\pi$ in a document and have it linked, one can use:
- \begin{code}
+ \begin{CODE}
\cs\renewmathcommand\cs\pi\{\cs\kl[\cs\pi]\{\cs\LaTeXpi\}\}\\
\cs\knowledge\cs\pi\{notion\}\\
"[...]"\\
\cs\AP\ Let \$\cs{\intro*}\cs\pi=3.1415\$.\\
"[...]"\\
Now \$\cs\pi\$ points to the above sentence.
- \end{code}
+ \end{CODE}
This code works because a different name \cs\LaTeXpi\ stores the original macro. Using~\cs\pi\ instead would yield an infinite loop.
Even better is to use the knowledge-aware version:
- \begin{code}
+ \begin{CODE}
\cs\knowledgerenewmathcommand\cs\pi\{\cs\cmdkl\{\cs\LaTeXpi\}\}
- \end{code}
+ \end{CODE}
\item The package also gives access to the exponents and indices as well as primes that follow a command (see the documentation).
\item It also has some facilities for disabling \LaTeX\ commands and provide suggestions of replacement (useful for remembering the macros and working with colleagues).
\item Finally, it offers some commodity for redefining many variables in one command.
E.g. for defining \cs\calA, \cs\calB,\dots to be shortcuts for \smallcode{\cs\cal\{A\}}, \smallcode{\cs\cal\{B\}}, \dots:
- \begin{code}
+ \begin{CODE}
\cs\LoopCommands\{ABCDEFGHIJKLMNOPQRSTUVWXYZ\}[cal\#1]\par
~~~~\quad\{\cs\newmathcommand\#2\{\cs\cal\{\#1\}\}\}
- \end{code}
+ \end{CODE}
\end{itemize}
\subsubsection{Mathematical objects that are singly introduced}
@@ -2661,24 +2666,24 @@ Five points have to be kept in mind:
\item The surrounding typography may be broken when using the command \cs{\kl}, or \cs\cmdkl\ (if someone knows how to solve that, please contact me). Commands such as \cs\mathrel\ should be used to recover it.
\end{itemize}
These five points are illustrated in the following code:
-\begin{code}
+\begin{CODE}
\cs\knowledgenewrobustcmd\cs\comp\{\cs\mathrel\{\cs\cmdkl\{\cs\circ\}\}\}\\
"[...]"\\
\cs\AP\ Composition is denoted \$\cs{\intro*}\cs\comp\$.\\
"[...]"\\
Now, each use of \$\cs\comp\$ points to its introduction.
-\end{code}
+\end{CODE}
Two variation may be comfortable to use.
\paragraph{Disabling commands}
When writing a paper, in particular with coauthors, one may be tempted to not always use the macros designed for each case.
For helping to remember the macro, one can use instead (using the "mathcommand@@package" package):
-\begin{code}
+\begin{CODE}
\csintro\disablecommand\cs\circ\\
\csintro\suggestcommand\cs\circ\{Use instead \cs\comp\ for function composition.\}\\
\cs\knowledgenewrobustcmd\cs\comp\{\cs\cmdkl\{\cs\LaTeXcirc\}\}\\
-\end{code}
+\end{CODE}
\noindent The result is that if one uses \cs\circ\ in the code, an error will be issued, and \cs\comp\ will be suggested as a replacement.
Note that more than one suggestions can be attached to the macro (if several macros use the symbol~\cs\comp\ with different meanings). Note also that in the definition of \cs\comp, \cs\LaTeXcirc\ is used instead of~\cs\circ. Indeed, \cs\circ\ has been deactivated,
but~\cs\LaTeXcirc\ gives access to its original meaning.
@@ -2686,13 +2691,13 @@ but~\cs\LaTeXcirc\ gives access to its original meaning.
\paragraph{Redefining the original \TeX\ macro}
Another situation is that one would like to use the \cs\circ\ control sequence for accessing our function instead of \cs\comp\ (simply because this is more convenient and easy to remember, and we know in advance that no confusion may arise).
In this case, the "mathcommand@@package" package can also be of some help:
-\begin{code}
+\begin{CODE}
\cs\knowledgerenewmathcommand\cs\circ\{\cs\mathrel\{\cs\cmdkl\{\cs\LaTeXcirc\}\}\}\\
"[...]"\\
\cs\AP\ Let \$g\cs{\intro*}\cs\circ\ f\$ denote the composition of functions.\\
"[...]"\\
Now, each use of \$\cs\circ\$ points to its introduction.
-\end{code}
+\end{CODE}
\noindent
The effect of \cs\knowledgerenewmathcommand\ is that it sets~\cs\LaTeXcirc\ to have the same effect as the original \cs\circ\ command,
and then redefines~\cs\circ.
@@ -2705,9 +2710,9 @@ This section is not yet written.
We enter now a more advanced situation. We want to track all the variables in a mathematic document...
the first thing to do is to give access to the "knowledge@@package" package to the scope of the document.
The easiest way to do that is to declare in the preamble what are the environments that we want to use.
-\begin{code}
+\begin{CODE}
\cs\knowledgeconfigureenvironment\{theorem,lemma,proof\}\{\}\par\noindent
-\end{code}}
+\end{CODE}}
The "knowledge@@package" package offers several tools for dealing with mathematics. It is mostly still experimental.
@@ -2741,7 +2746,7 @@ The behavior of the "notion" directive is to activate "autoref", and to configur
\end{itemize}
A typical document using notion could start by the following commands:
-\begin{code}
+\begin{CODE}
\cs\documentclass\{article\}\\
\cs\usepackage\{\kl(package){xcolor}\}\\
\cs\usepackage\{\kl(package){hyperref}\}\\
@@ -2749,7 +2754,7 @@ A typical document using notion could start by the following commands:
\cs\knowledgeconfigure\{"notion@@option"\}\\
"[...]"\\
\cs\knowledge\{some text\}\{notion\}
-\end{code}\noindent
+\end{CODE}\noindent
Then the paper is displayed in a colorful way.
@@ -2792,7 +2797,7 @@ The notation \kl{"..."} does not have this issue.
\paragraph{The use of \cs{\kl} does not work in (e.g.) the table of content.} When the \kl{knowledge name} contains expandable macros, or accentuated letters, then these are not copied in the table of content as the exact same text, but are expanded/translated. Thus, when the table of content is displayed, the \cs{\kl} command complains of not knowing the \kl{knowledge}. For instance\footnote{with \texttt{\cs\usepackage[utf8]\{inputenc\}} and, for instance \texttt{\cs\usepackage[T1]\{fontenc\}} for the accents.}:
\begin{center}
-\begin{code}[11cm]
+\begin{CODE}[11cm]
\cs\newcommand\robustdisplay\Ltwo\{\cs\ensuremath\{L\^{}2\}\}\\
\cs\knowledge\{\robustdisplay\Ltwo-space\}[\robustdisplay\Ltwo-spaces]\{autoref\}\\
\cs\knowledge\{\'etale topology\}[\'Etale topology]\par
@@ -2805,29 +2810,29 @@ The notation \kl{"..."} does not have this issue.
\cs\section\{On the \cs\kl\{\'etale topology\}\}\\
{"[...]"}\\
\cs\end\{document\}
-\end{code}\end{center}\noindent
+\end{CODE}\end{center}\noindent
will result in that both \kl{knowledges} are considered unknown in the table of contents.
For the first one, this is due to the expansion of~\cs\Ltwo. For the second, this is due to an implicit translation of the accentuated letter into an internal sequence of commands (for instance `\'e' is translated into the internal sequence `\verb|\IeC {\'e}|'). Some solutions are as follows:
\begin{itemize}
\item Make the macros non-expandable, for instance using \cs{\newrobustcmd} (of the \kl(package){etoolbox} package) or \cs{\NewDocumentCommand} (of the \kl(package){xparse} package, with a different handling of arguments) instead of \cs{\newcommand}. Hence:
-\begin{code}
+\begin{CODE}
\cs\newrobustcmd\robustdisplay\Ltwo\{\cs\ensuremath\{L\^{}2\}\}
-\end{code}\noindent
+\end{CODE}\noindent
solves the first problem.
\item Using an equivalent text that does not have the problem:
- \begin{code}
+ \begin{CODE}
\cs\knowledge\{$\backslash$'etale topology\}\{\kl{link=}\'etale topology\}\\
{"[...]"}\\
\cs\section\{On the \cs\kl\{$\backslash$'etale topology\}\}
- \end{code}
+ \end{CODE}
\item Both problems can be solved using synonyms/links that have no problem. For instance:
- \begin{code}
+ \begin{CODE}
\cs\knowledge\{Ltwo-space\}\{\kl{link=}\robustdisplay\Ltwo-space\}\\
\cs\knowledge\{etale topology\}\{\kl{link=}\'etale topology\}\\
{"[...]"}\\
\cs\section\{On \cs\kl[Ltwo-space]\{\robustdisplay\Ltwo-spaces\}\}\\
\cs\section\{On the \cs\kl[etale topology]\{étale topology\}\}
- \end{code}
+ \end{CODE}
\item Other solutions? None so far. I am trying to systematize the treatment of these problems.
\end{itemize}
@@ -2837,13 +2842,13 @@ Do not use \cs{\intro} in titles, but rather \cs{\reintro}. If you want the sect
\begin{center}
\begin{tabular}{ccc}
%\hline
-\begin{code}[5.5cm]
+\begin{CODE}[5.5cm]
\cs\section\{On \cs\intro\{topology\}\}\\
-\end{code}&&
-\begin{code}[5.9cm]
+\end{CODE}&&
+\begin{CODE}[5.9cm]
\cs\section\{On \cs{\reintro}\{topology\}\}\\
\cs{\phantomintro}\{topology\}
-\end{code}\\
+\end{CODE}\\
\textit{Problematic code}&&
\textit{A solution}
\end{tabular}
@@ -2861,18 +2866,18 @@ active when you do so, and
\end{itemize}
This can be done either explicitly using before each figure:
-\begin{code}[8.5cm]
+\begin{CODE}[8.5cm]
\cs\knowledgeconfigure\{"quotation@@option"=false\}
-\end{code}
+\end{CODE}
\noindent
and after the figure:
-\begin{code}[7cm]
+\begin{CODE}[7cm]
\cs\knowledgeconfigure\{"quotation@@option"\}
-\end{code}
+\end{CODE}
Another possibility is to force some environment to deactivate systematically the "quotation notation" when used. For instance
-\begin{code}[10cm]
+\begin{CODE}[10cm]
\cs\knowledgeconfigure\{"protect quotation="\{"tikzcd@@env"\}\}
-\end{code}\noindent
+\end{CODE}\noindent
will deactivate the "quotation notation" in all the "tikzcd@@env" environments.
\subsection{Problems with \kl(package){amsmath}}
@@ -2886,18 +2891,18 @@ the incriminated environment using \cs\phantomsection, and then use \cs{\reintro
\begin{center}
\begin{tabular}{ccc}
does not work&&works\\
- \begin{code}[5cm]
+ \begin{CODE}[5cm]
\cs\begin\{\kl{align*}\}\\
\cs{\intro*}\texttt{\robustdisplay{\SomeCommand}}\\
\cs\end\{\kl{align*}\}\\
- \end{code}
+ \end{CODE}
&&
- \begin{code}[5cm]
+ \begin{CODE}[5cm]
\cs\phantomintro\texttt{\robustdisplay{\SomeCommand}}\\
\cs\begin\{\kl{align*}\}\\
\cs\reintro*\texttt{\robustdisplay{\SomeCommand}}\\
\cs\end\{\kl{align*}\}
- \end{code}
+ \end{CODE}
\end{tabular}
\end{center}
@@ -2912,19 +2917,19 @@ This happens in particular wen used in combination with the "complexity@@package
The problem has to be resolved by hand. The two following solutions are quick hacks:
\begin{center}
\begin{tabular}{ccc}
-\begin{code}[5.2cm]
+\begin{CODE}[5.2cm]
\cs\usepackage\{\kl(package){complexity}\}\\
\cs\let\cs\compAP\robustdisplay\AP\\
\cs\let\robustdisplay\AP\cs\undefined\\
\cs\usepackage"[...]"\{"knowledge@@package"\}
-\end{code}
+\end{CODE}
&&
-\begin{code}[5.2cm]
+\begin{CODE}[5.2cm]
\cs\usepackage"[...]"\{"knowledge@@package"\}\\
\cs\let\cs\kAP\robustdisplay\AP\\
\cs\let\robustdisplay\AP\cs\undefined\\
\cs\usepackage\{\kl(package){complexity}\}
-\end{code}\\
+\end{CODE}\\
for using \texttt{\robustdisplay\AP}from "knowledge@@package",
&& for using \texttt{\robustdisplay\AP}from "complexity@@package",\\
and \cs\compAP\ for "complexity@@package",
@@ -2940,7 +2945,7 @@ It may happen that some hyperlinks generated by "knowledge@@package" are not bro
at the end of lines. This is an issue with the \kl(package){hyperref} package. This happens in particular for files compiled by the "arXiv" system while the file on the local computer was not having any problem. A workaround is to use the \kl{breaklinks} option of \kl(package){hyperref}. If you need this for "arXiv", then you also have to force the use of \cs\pdflatex\ (because the \kl{breaklinks} option does not work if compiled via the ancestral sequence TEX$\rightarrow$DVI$\rightarrow$PS$\rightarrow$PDF). This can be obtained by adding \smallcode{\cs\pdfoutput=1} within the five first lines of the preamble.
The preamble thus looks like:
-\begin{code}[9cm]
+\begin{CODE}[9cm]
\cs\documentclass\{"[...]"\}\par\noindent
\cs\pdfoutput=1\par\noindent
"[...]"\par\noindent
@@ -2948,13 +2953,13 @@ The preamble thus looks like:
"[...]"\par\noindent
\cs\usepackage\{\kl(package){knowledge}\}\par\noindent
"[...]"\par\noindent
-\end{code}
+\end{CODE}
\subsection{Display errors in pdf output, in particular "arXiv"}
Again, try in the preamble:
-\begin{code}[9cm]
+\begin{CODE}[9cm]
\cs\pdfoutput=1
-\end{code}
+\end{CODE}
\subsubsection{Red boxes around links}
@@ -2964,21 +2969,21 @@ unless the "no patch" option is used when loading the package. When the "no patc
\subsubsection{Incorrect color for links in "paper mode" (e.g. red in with \kl(package){acmart})}
Some classes, like \kl(package){acmart}, change the default color of the hyperlinks of \kl(package){hyperref}. Since "knowledge@@package" does not apply any color to the links in "paper mode", this unexpected color appears. The black color of the "paper mode" can be forced by using:
-\begin{code}
+\begin{CODE}
\cs\IfKnowledgePaperMode\\
\cs\knowledgestyle\{"kl@@style"\}\{"color="black\}\\
\cs\knowledgestyle\{"notion@@style"\}\{"color="black\}\\
\cs{\ fi}
-\end{code}
+\end{CODE}
\subsubsection{Unexepected color in margin paragraph}
This is a problem of the combination of the package "xcolor@@package" with \cs\marginpar: when a colored text gets to be broken into separated lines and the \cs\marginpar\ be inserted at this place, the colors leaks in to the margin text.
It is independent of "knowledge@@package", but is more likely to occur when colors are often used.
A correction is to force going the use of color black whenever inside a \cs\marginpar. For instance:
-\begin{code}
+\begin{CODE}
\cs\let\cs\LaTeXmarginpar\cs\marginpar\\
\cs\def\cs\marginpar\#1\{\cs\LaTeXmarginpar\{\cs\textcolor\{black\}\{\#1\}\}\}
-\end{code}
+\end{CODE}
\subsection{Problems with scope}
@@ -2989,22 +2994,22 @@ The "scope option" of the package triggers some analysis of the code, and restra
However, this is what does the environment "thebibliography@@env", yielding a scoping error.
A simple hack to treat this situation:
-\begin{code}[6cm]
+\begin{CODE}[6cm]
\cs\let\cs\section\cs\SUPERsection\\
\cs\begin\{"thebibliography@@env"\}\\
\cs\bibitem\dots\\
{}"[...]"\\
\cs\end\{"thebibliography@@env"\}\\
\cs\let\cs\section\cs\NEWsection
-\end{code}
+\end{CODE}
The result is to revert to the original version of the macro \smallcode{\cs\section}, which does not make any structural test, and then reactivate the modified version of the command.
Another solution is to reconfigure the environment "thebibliography@@env" using in the preamble:
-\begin{code}
+\begin{CODE}
\cs\ScopeConfigure\{"thebibliography@@env"\}\par
\hspace{3cm}\{push code=\cs\let\cs\section\cs\SUPERsection,\par
\hspace{3cm}~pop code=\cs\let\cs\section\cs\NEWsection\}
-\end{code}
+\end{CODE}
\subsection{Editors}
@@ -3096,7 +3101,6 @@ If other kind of problems occur, report them to \texttt{thomas.colcombet@irif.fr
\item[\kl{italic=}] displays in italic
\item[\kl{fbox}] Surround the text with a box.
\item[\kl{md}] Removes boldface typesetting.
-\item[\kl{notion}]
%\item[\kl{import=}] (\kl{not implemented})
\item[\kl{index=}] Chooses the text to be displayed in the \kl{index=}.
\item[\kl{index key=}] the key used to choose the place in the \kl{index}.
@@ -3111,6 +3115,7 @@ If other kind of problems occur, report them to \texttt{thomas.colcombet@irif.fr
\item[\kl{lowercase}] Put all letters of the output in lowercase.
\item[\kl{mathord}, \kl{mathop}, \kl{mathbin}, \kl{mathrel}, \kl{mathopen}, \kl{mathclose}, \kl{mathpunct}] Selects a spacing behaviour in math mode.
\item[\kl{no index}] avoids the indexing of the term.
+\item[\kl{notion}] automatic configuration for displaying and autoreferencing.
\item[\kl{protect link}] Disables the hyperlinks inside the link.
\item[\kl{ref=}] Links to a label inside the document.
\item[\kl{scope=}] Choose the \kl{scope} of the definition.
diff --git a/macros/latex/contrib/mathtools/empheq.ins b/macros/latex/contrib/mathtools/empheq.ins
deleted file mode 100644
index 265efeb2bb..0000000000
--- a/macros/latex/contrib/mathtools/empheq.ins
+++ /dev/null
@@ -1,94 +0,0 @@
-%%
-%% This is file `empheq.ins',
-%% generated with the docstrip utility.
-%%
-%% The original source files were:
-%%
-%% empheq.dtx (with options: `install')
-%%
-%% This is a generated file.
-%%
-%% Copyright (C) 2002-2007 by Morten Hoegholm
-%% Copyright (C) 2012-2019 by Lars Madsen
-%% Copyright (C) 2020- by Lars Madsen, The LaTeX3 Project
-%%
-%%
-%% This work may be distributed and/or modified under the
-%% conditions of the LaTeX Project Public License, either
-%% version 1.3 of this license or (at your option) any later
-%% version. The latest version of this license is in
-%% http://www.latex-project.org/lppl.txt
-%% and version 1.3 or later is part of all distributions of
-%% LaTeX version 2005/12/01 or later.
-%%
-%% This work has the LPPL maintenance status "maintained".
-%%
-%% This Current Maintainer of this work is
-%% Lars Madsen, The LaTeX3 Project
-%%
-%% This work consists of the main source file empheq.dtx
-%% and the derived files
-%% empheq.sty, empheq.pdf, empheq.ins, empheq.drv.
-%%
-\input docstrip.tex
-\Msg{************************************************************************}
-\Msg{* Installation}
-\Msg{* Package: empheq 2020/03/24 v2.16 empheq}
-\Msg{************************************************************************}
-
-\keepsilent
-\askforoverwritefalse
-
-\preamble
-
-This is a generated file.
-
-Copyright (C) 2002-2007 by Morten Hoegholm
-Copyright (C) 2012-2019 by Lars Madsen
-Copyright (C) 2020- by Lars Madsen, The LaTeX3 Project
-
-This work may be distributed and/or modified under the
-conditions of the LaTeX Project Public License, either
-version 1.3 of this license or (at your option) any later
-version. The latest version of this license is in
- http://www.latex-project.org/lppl.txt
-and version 1.3 or later is part of all distributions of
-LaTeX version 2005/12/01 or later.
-
-This work has the LPPL maintenance status "maintained".
-
-This Current Maintainer of this work is
-Lars Madsen, The LaTeX3 Project
-
-This work consists of the main source file empheq.dtx
-and the derived files
- empheq.sty, empheq.pdf, empheq.ins, empheq.drv.
-
-\endpreamble
-
-\generate{%
- \file{empheq.ins}{\from{empheq.dtx}{install}}%
- \file{empheq.drv}{\from{empheq.dtx}{driver}}%
- \usedir{tex/latex/mh}%
- \file{empheq.sty}{\from{empheq.dtx}{package}}%
-}
-
-\obeyspaces
-\Msg{************************************************************************}
-\Msg{*}
-\Msg{* To finish the installation you have to move the following}
-\Msg{* file into a directory searched by TeX:}
-\Msg{*}
-\Msg{* empheq.sty}
-\Msg{*}
-\Msg{* To produce the documentation run the file `empheq.drv'}
-\Msg{* through LaTeX.}
-\Msg{*}
-\Msg{* Happy TeXing!}
-\Msg{*}
-\Msg{************************************************************************}
-
-\endbatchfile
-\endinput
-%%
-%% End of file `empheq.ins'.
diff --git a/macros/latex/contrib/mathtools/empheq.pdf b/macros/latex/contrib/mathtools/empheq.pdf
index d7f91d3071..e3e75f26f8 100644
--- a/macros/latex/contrib/mathtools/empheq.pdf
+++ b/macros/latex/contrib/mathtools/empheq.pdf
Binary files differ
diff --git a/macros/latex/contrib/mathtools/mathtools.dtx b/macros/latex/contrib/mathtools/mathtools.dtx
index 28526b0a88..db726b51b5 100644
--- a/macros/latex/contrib/mathtools/mathtools.dtx
+++ b/macros/latex/contrib/mathtools/mathtools.dtx
@@ -69,7 +69,7 @@
\input docstrip.tex
\Msg{************************************************************************}
\Msg{* Installation}
-\Msg{* Package: mathtools 2022/06/29 v1.29}
+\Msg{* Package: mathtools 2024/03/11 v1.30}
\Msg{************************************************************************}
\keepsilent
@@ -133,7 +133,7 @@ and the derived files
%<*driver>
\NeedsTeXFormat{LaTeX2e}
\ProvidesFile{mathtools.drv}%
- [2022/06/29 v1.29 mathematical typesetting tools]
+ [2024/03/11 v1.30 mathematical typesetting tools]
\documentclass{ltxdoc}
\IfFileExists{fourier.sty}{\usepackage{fourier}}{}
@@ -333,7 +333,7 @@ colorlinks,
%
% \GetFileInfo{mathtools.drv}
%
-% \CheckSum{3740}
+% \CheckSum{3772}
%
% \title{The \pkg{mathtools} package\thanks{This file has version number
% \fileversion, last revised \filedate.}}
@@ -1056,7 +1056,7 @@ colorlinks,
% \usepackage[overload,ntheorem]{empheq}
% \end{verbatim}
% before loading \pkg{ntheorem}. But the \texttt{overload} option of
-% course disables things like \cs{intertext} and \cs{shotintertext}.
+% course disables things like \cs{intertext} and \cs{shortintertext}.
%
% The other thing to try is to drop the \texttt{overload} option
% and use \env{empheq} on the very last expression, as in
@@ -1118,6 +1118,21 @@ colorlinks,
% \[
% A \xLeftarrow[under]{over} B
% \]
+% \textbf{Caveat for \cs{xmapsto}:} Whenever \pkg{unicode-math} is
+% used, the macro \cs{xmapsto} will not work correctly (a random 7
+% appears). This is due to how we define \cs{xmapsto}: the symbol
+% »\,$\mapstochar{}$\,« (via \cs{mapstochar}, setup in the \LaTeX{}
+% kernel) and extensible \cs{rightarrow}. The symbol behind
+% \cs{mapstochar} is not defined in unicode, and thus is not
+% available in the unicode math fonts.\footnote{The symbol
+% $\mapsto$ \emph{is} in unicode and \pkg{unicode-math} maps
+% \cs{mapsto} onto this symbol in the unicode math font. Whereas
+% without \pkg{unicode-math}, \cs{mapsto} is a symbol constructed
+% by combining \cs{mapstochar} and \cs{rightarrow}. On the other
+% hand \textsf{lualatex} \emph{does} have some special macros to
+% create extensible arrows, but \emph{none} of these can write above
+% \emph{and} below at the same time. So for now we leave this
+% unresolved.}
% \begin{codesyntax}
% \SpecialUsageIndex{\xrightharpoondown}
% \cs{xrightharpoondown}\oarg{sub}\marg{sup}\texttt{~~~~}
@@ -1170,6 +1185,24 @@ colorlinks,
% A & \xlongrightarrow[b]{a} B & A & \xlongleftarrow[b]{a} B \\
% A & \xlongrightarrow[below]{above} B & A & \xlongleftarrow[below]{above} B \\
% \end{align*}
+% \begin{codesyntax}
+% \SpecialUsageIndex{\xLongrightarrow}
+% \cs{xLongrightarrow}\oarg{sub}\marg{sup}\texttt{~~~~}
+% \SpecialUsageIndex{\xLongleftarrow}
+% \cs{xLongleftarrow}\oarg{sub}\marg{sup}\texttt{~~~~}
+% \end{codesyntax}
+% \FeatureRequest{quarkQuark {\footnotesize (issue \#51)}}{added 2024}%
+% Similar to \cs{xRight/Leftarrow} but based on the \emph{long}
+% versions. For short arguments it stays the same length as the
+% \cs{long...} base arrow.
+% \begin{align*}
+% A & \xLongrightarrow B & A & \Longleftarrow B \\
+% A & \xLongrightarrow[b]{a} B & A & \xLongleftarrow[b]{a} B \\
+% A & \xLongrightarrow[below]{above} B & A & \xLongleftarrow[below]{above} B \\
+% \end{align*}
+
+%
+%
%
% \subsubsection{Braces and brackets}
%
@@ -2019,15 +2052,26 @@ colorlinks,
% \]
% \end{itemize}
%
+% \paragraph{A note on the delimiters.} Whenever the manual scalings
+% are used we internally convert them into their \cs{...l} and
+% \cs{...r} variants. Therefore if you define your own manual
+% scalers, remember to also have -l and -r variants.
+% \\
+% \emph{New from version 1.30.} You can now use »\verb|.|« (dot)
+% as an empty delimiter, for macros what only have a delimiter on one
+% side.\footnote{The syntax is borrowed from
+% \cs{left.}\cs{frac\{1\}\{2\}}\cs{right}\cs{rvert} where the dot marks an empty
+% delimiter. }
+%
% \begin{codesyntax}
% \SpecialUsageIndex{\DeclarePairedDelimiterX}
% \cs{DeclarePairedDelimiterX}\marg{cmd}\oarg{num args}\marg{left_delim}\marg{right_delim}\marg{body}\\
% \cs{delimsize}
% \end{codesyntax}
% Sometimes one might want to have the capabilities of
-% \cs{DeclarePairedDelimiter}, but also want a macro the takes more
-% than one argument and specify plus being able to specify the body
-% of the generated macro.
+% \cs{DeclarePairedDelimiter}, but also want a macro which takes more
+% than one argument plus being able to specify the body of the
+% generated macro.
%
% \cs{DeclarePairedDelimiterX} extends the features of
% \cs{DeclarePairedDelimiter} such that the user will get a macro
@@ -2183,8 +2227,8 @@ colorlinks,
% the \marg{pre code} and \marg{post code} it is identical to
% \cs{DeclarePairedDelimiterX}. It should be interpreted as
% \begin{center}
-% \marg{pre code} \marg{left_delim} \marg{body}
-% \marg{right_delim} \marg{post code}
+% \marg{pre code} \marg{left_delim} \marg{right_delim}
+% \marg{post code} \marg{body}
% \end{center}
%
%
@@ -2261,7 +2305,7 @@ colorlinks,
% The default values for the call backs correspond to
% \begin{verbatim}
% star: \mathopen{}\mathclose\bgroup #1#2\aftergroup\egroup #3
-% nostarnonscaled: \mathopen#1#2\mathclose#3
+% nostarnonscaled: \ifx.#1\else\mathopen#1\fi#2\ifx.#3\else\mathclose#3\fi
% nostarscaled: \mathopen{#1}#2\mathclose{#3}
% \end{verbatim}
% The two \texttt{nostar...} versions look the same, but they are
@@ -2768,7 +2812,7 @@ colorlinks,
% \SpecialUsageIndex{\splitdfrac}\cs{splitdfrac}\marg{start line}\marg{continuation}
% \end{codesyntax}
% \cttPosting{Michael J.~Downes}{2001/12/06}
-% These commands provide split fractions e.g., multiline fractions:
+% These commands provide split fractions, e.g., multiline fractions:
% \begin{verbatim}
% \[
% a=\frac{
@@ -3094,7 +3138,7 @@ colorlinks,
% \begin{macrocode}
%<*package>
\ProvidesPackage{mathtools}%
- [2022/06/29 v1.29 mathematical typesetting tools]
+ [2024/03/11 v1.30 mathematical typesetting tools]
% \end{macrocode}
% \changes{v1.10}{2011/02/12}{Might as well make sure that we need the
% latest version of \texttt{mhsetup}}
@@ -3292,10 +3336,11 @@ colorlinks,
% commands similar to \cs{tagform@} only this will give us tag form
% \emph{types}. The actual code is very similar to the one in
% \pkg{amsmath}.
+% \changes{v1.30}{2024/01/19}{Add group so \#2 (the inner format) does not leak}
% \begin{macrocode}
\def\MT_define_tagform:nwnn #1[#2]#3#4{
\@namedef{MT_tagform_#1:n}##1
- {\maketag@@@{#3\ignorespaces#2{##1}\unskip\@@italiccorr#4}}
+ {\maketag@@@{#3\ignorespaces{#2{##1}}\unskip\@@italiccorr#4}}
}
% \end{macrocode}
% \end{macro}
@@ -3789,8 +3834,31 @@ colorlinks,
\arrowfill@{\mapstochar\relbar}\relbar\rightarrow}
% \end{macrocode}
% \end{macro}
-% \end{macro}
+% \end{macro}
+% 2024 (v1.30): Added \verb+\xLongrightarrow+ and \verb+\xLongleftarrow+. Code by muzimuchi on GitHub. I added extra spaces like for |\xRightarrow| above.
+% \begin{macro}{\MT_Longrightarrow_fill:}
+% \begin{macro}{\MT_Longleftarrow_fill:}
+% \begin{macro}{\xLongrightarrow}
+% \begin{macro}{\xLongleftarrow}
+% \begin{macrocode}
+\def\MT_Longrightarrow_fill:{%
+ \arrowfill@\Relbar\Relbar\Longrightarrow}
+\def\MT_Longleftarrow_fill:{%
+ \arrowfill@\Longleftarrow\Relbar\Relbar}
+
+\providecommand*\xLongrightarrow[2][]{%
+ \ext@arrow 0359\MT_Longrightarrow_fill:{#1\ }{#2\ }}
+\providecommand*\xLongleftarrow[2][]{%
+ \ext@arrow 3095\MT_Longleftarrow_fill:{\ #1}{\ #2}}
+
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+% \end{macro}
+%
% \subsection{Underbrackets etc.}
+%
% \begin{macro}{\underbracket}
% \begin{macro}{\MT_underbracket_I:w}
% \begin{macro}{\MT_underbracket_II:w}
@@ -3981,6 +4049,13 @@ colorlinks,
}
}
% \end{macrocode}
+%
+% \changes{v1.30}{2022/11/15}{Forgot to define a default
+% \cs{MT\_active\_colon_false:}, who would run centercolon=false
+% before it being true?}
+% \begin{macrocode}
+\def\MT_active_colon_false:{}
+% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
@@ -4596,8 +4671,13 @@ colorlinks,
\@namedef{MT_delim_\MH_cs_to_str:N #1 _nostarscaled_wrapper:nnn}##1##2##3{
\mathopen{##1}##2\mathclose{##3}
}
+% \end{macrocode}
+% \changes{v1.30}{2024/01/18}{Changed the nostarnonscaled to support the empty scaler (dot).}
+% If we want to support the empty scaler (dot) we need a test in the non-scaled case, otherwise a dot would be left in the output.
+% Test sugggested by David Carlisle.
+% \begin{macrocode}
\@namedef{MT_delim_\MH_cs_to_str:N #1 _nostarnonscaled_wrapper:nnn}##1##2##3{
- \mathopen##1##2\mathclose##3
+ \ifx.##1\else\mathopen##1\fi##2\ifx.##3\else\mathclose##3\fi
}
}
diff --git a/macros/latex/contrib/mathtools/mathtools.ins b/macros/latex/contrib/mathtools/mathtools.ins
index f13c6c01a5..a8df08bca3 100644
--- a/macros/latex/contrib/mathtools/mathtools.ins
+++ b/macros/latex/contrib/mathtools/mathtools.ins
@@ -12,6 +12,7 @@
%% Copyright (C) 2012-2019 by Lars Madsen
%% Copyright (C) 2020- by Lars Madsen, the LaTeX3 project
%%
+%%
%% This work may be distributed and/or modified under the
%% conditions of the LaTeX Project Public License, either
%% version 1.3c of this license or (at your option) any later
@@ -32,7 +33,7 @@
\input docstrip.tex
\Msg{************************************************************************}
\Msg{* Installation}
-\Msg{* Package: mathtools 2022/02/07 v1.28a}
+\Msg{* Package: mathtools 2024/03/11 v1.30}
\Msg{************************************************************************}
\keepsilent
@@ -88,6 +89,7 @@ and the derived files
\Msg{************************************************************************}
\endbatchfile
+
\endinput
%%
%% End of file `mathtools.ins'.
diff --git a/macros/latex/contrib/mathtools/mathtools.pdf b/macros/latex/contrib/mathtools/mathtools.pdf
index b47de74277..9921854b8b 100644
--- a/macros/latex/contrib/mathtools/mathtools.pdf
+++ b/macros/latex/contrib/mathtools/mathtools.pdf
Binary files differ
diff --git a/macros/latex/contrib/mathtools/mhsetup.ins b/macros/latex/contrib/mathtools/mhsetup.ins
deleted file mode 100644
index 4ba3ce8d64..0000000000
--- a/macros/latex/contrib/mathtools/mhsetup.ins
+++ /dev/null
@@ -1,93 +0,0 @@
-%%
-%% This is file `mhsetup.ins',
-%% generated with the docstrip utility.
-%%
-%% The original source files were:
-%%
-%% mhsetup.dtx (with options: `install')
-%%
-%% This is a generated file.
-%%
-%% Copyright (C) 2002-2007,2010 by Morten Hoegholm
-%% Copyright (C) 2017-2019 by Lars Madsen
-%% Copyright (C) 2020- by Lars Madsen, The LaTeX3 team
-%%
-%% This work may be distributed and/or modified under the
-%% conditions of the LaTeX Project Public License, either
-%% version 1.3 of this license or (at your option) any later
-%% version. The latest version of this license is in
-%% http://www.latex-project.org/lppl.txt
-%% and version 1.3 or later is part of all distributions of
-%% LaTeX version 2005/12/01 or later.
-%%
-%% This work has the LPPL maintenance status "maintained".
-%%
-%% This Current Maintainer of this work is Lars Madsen
-%% <daleif@math.au.dk>, The LaTeX3 team https://github.com/latex3/mathtools
-%%
-%% This work consists of the main source file mhsetup.dtx
-%% and the derived files
-%% mhsetup.sty, mhsetup.pdf, mhsetup.ins, mhsetup.drv.
-%%
-\input docstrip.tex
-\Msg{************************************************************************}
-\Msg{* Installation}
-\Msg{* Package: mhsetup 2021/03/18 v1.4 mhsetup}
-\Msg{************************************************************************}
-
-\keepsilent
-\askforoverwritefalse
-
-\preamble
-
-This is a generated file.
-
-Copyright (C) 2002-2007,2010 by Morten Hoegholm
-Copyright (C) 2017-2019 by Lars Madsen
-Copyright (C) 2020- by Lars Madsen, The LaTeX3 team
-
-This work may be distributed and/or modified under the
-conditions of the LaTeX Project Public License, either
-version 1.3c of this license or (at your option) any later
-version. The latest version of this license is in
- http://www.latex-project.org/lppl.txt
-and version 1.3c or later is part of all distributions of
-LaTeX version 2008/05/04 or later.
-
-This work has the LPPL maintenance status "maintained".
-
-This Current Maintainer of this work is Lars Madsen
-<daleif@math.au.dk>, The LaTeX3 team https://github.com/latex3/mathtools
-
-This work consists of the main source file mhsetup.dtx
-and the derived files
- mhsetup.sty, mhsetup.pdf, mhsetup.ins, mhsetup.drv.
-
-\endpreamble
-
-\generate{%
- \file{mhsetup.ins}{\from{mhsetup.dtx}{install}}%
- \file{mhsetup.drv}{\from{mhsetup.dtx}{driver}}%
- \usedir{tex/latex/mh}%
- \file{mhsetup.sty}{\from{mhsetup.dtx}{package}}%
-}
-
-\obeyspaces
-\Msg{************************************************************************}
-\Msg{*}
-\Msg{* To finish the installation you have to move the following}
-\Msg{* file into a directory searched by TeX:}
-\Msg{*}
-\Msg{* mhsetup.sty}
-\Msg{*}
-\Msg{* To produce the documentation run the file `mhsetup.drv'}
-\Msg{* through LaTeX.}
-\Msg{*}
-\Msg{* Happy TeXing!}
-\Msg{*}
-\Msg{************************************************************************}
-
-\endbatchfile
-\endinput
-%%
-%% End of file `mhsetup.ins'.
diff --git a/macros/latex/contrib/mathtools/mhsetup.pdf b/macros/latex/contrib/mathtools/mhsetup.pdf
index a3a4faccf9..2be52b31ab 100644
--- a/macros/latex/contrib/mathtools/mhsetup.pdf
+++ b/macros/latex/contrib/mathtools/mhsetup.pdf
Binary files differ
diff --git a/macros/latex/contrib/mathtools/test.pdf b/macros/latex/contrib/mathtools/test.pdf
deleted file mode 100644
index a82f6e29ba..0000000000
--- a/macros/latex/contrib/mathtools/test.pdf
+++ /dev/null
Binary files differ
diff --git a/macros/latex/contrib/nwejm/README.md b/macros/latex/contrib/nwejm/README.md
index 51b2bfc391..d61c3674a2 100644
--- a/macros/latex/contrib/nwejm/README.md
+++ b/macros/latex/contrib/nwejm/README.md
@@ -8,7 +8,7 @@ new journal “North-Western European Journal of Mathematics”.
Release
-------
-2022-09-21 v1.0.5
+2024-02-08 v1.0.6
Development
-----------
diff --git a/macros/latex/contrib/nwejm/doc/english/nwejm-en.pdf b/macros/latex/contrib/nwejm/doc/english/nwejm-en.pdf
index b6723ddf7d..ff0487f25c 100644
--- a/macros/latex/contrib/nwejm/doc/english/nwejm-en.pdf
+++ b/macros/latex/contrib/nwejm/doc/english/nwejm-en.pdf
Binary files differ
diff --git a/macros/latex/contrib/nwejm/doc/english/nwejm-en.tex b/macros/latex/contrib/nwejm/doc/english/nwejm-en.tex
index 57e382120f..9c6f0a214c 100644
--- a/macros/latex/contrib/nwejm/doc/english/nwejm-en.tex
+++ b/macros/latex/contrib/nwejm/doc/english/nwejm-en.tex
@@ -9,8 +9,8 @@
\documentclass[english,nolocaltoc]{nwejmart}
%
-\DTMsavedate{release-date}{2022-09-21}
-\newcommand{\releaseversion}{1.0.5}
+\DTMsavedate{release-date}{2024-02-08}
+\newcommand{\releaseversion}{1.0.6}
%
\usepackage[nwejm]{denisbdoc}
\usepackage{tabulary}
diff --git a/macros/latex/contrib/nwejm/doc/examples/article-in-dutch.pdf b/macros/latex/contrib/nwejm/doc/examples/article-in-dutch.pdf
index cc2aa090f7..93f7b52ce2 100644
--- a/macros/latex/contrib/nwejm/doc/examples/article-in-dutch.pdf
+++ b/macros/latex/contrib/nwejm/doc/examples/article-in-dutch.pdf
Binary files differ
diff --git a/macros/latex/contrib/nwejm/doc/examples/article-in-english.pdf b/macros/latex/contrib/nwejm/doc/examples/article-in-english.pdf
index 9d486cc520..e494f1446a 100644
--- a/macros/latex/contrib/nwejm/doc/examples/article-in-english.pdf
+++ b/macros/latex/contrib/nwejm/doc/examples/article-in-english.pdf
Binary files differ
diff --git a/macros/latex/contrib/nwejm/doc/examples/article-in-french.pdf b/macros/latex/contrib/nwejm/doc/examples/article-in-french.pdf
index 83cbf7c07b..d96142e528 100644
--- a/macros/latex/contrib/nwejm/doc/examples/article-in-french.pdf
+++ b/macros/latex/contrib/nwejm/doc/examples/article-in-french.pdf
Binary files differ
diff --git a/macros/latex/contrib/nwejm/doc/examples/article-in-german.pdf b/macros/latex/contrib/nwejm/doc/examples/article-in-german.pdf
index 50ae92ace9..c387c8e46a 100644
--- a/macros/latex/contrib/nwejm/doc/examples/article-in-german.pdf
+++ b/macros/latex/contrib/nwejm/doc/examples/article-in-german.pdf
Binary files differ
diff --git a/macros/latex/contrib/nwejm/doc/examples/issue.pdf b/macros/latex/contrib/nwejm/doc/examples/issue.pdf
index cfedc3e940..269480c9b8 100644
--- a/macros/latex/contrib/nwejm/doc/examples/issue.pdf
+++ b/macros/latex/contrib/nwejm/doc/examples/issue.pdf
Binary files differ
diff --git a/macros/latex/contrib/nwejm/doc/french/nwejm-fr.pdf b/macros/latex/contrib/nwejm/doc/french/nwejm-fr.pdf
index 2f80d2cac4..0935c8c4a7 100644
--- a/macros/latex/contrib/nwejm/doc/french/nwejm-fr.pdf
+++ b/macros/latex/contrib/nwejm/doc/french/nwejm-fr.pdf
Binary files differ
diff --git a/macros/latex/contrib/nwejm/doc/french/nwejm-fr.tex b/macros/latex/contrib/nwejm/doc/french/nwejm-fr.tex
index 6923a6d8cb..891c0d0ef7 100644
--- a/macros/latex/contrib/nwejm/doc/french/nwejm-fr.tex
+++ b/macros/latex/contrib/nwejm/doc/french/nwejm-fr.tex
@@ -9,8 +9,8 @@
%
\documentclass[french,nolocaltoc]{nwejmart}
%
-\DTMsavedate{release-date}{2022-09-21}
-\newcommand{\releaseversion}{1.0.5}
+\DTMsavedate{release-date}{2024-02-08}
+\newcommand{\releaseversion}{1.0.6}
%
\usepackage[nwejm]{denisbdoc}
\usepackage{tabulary}
@@ -37,6 +37,17 @@
^^^^27e9% Right-Pointing Angle Bracket
^^00}
\lst@RestoreCatcodes
+
+\NewDocumentCommand{\myarrow}{}{{\fontfamily{pzd}\fontencoding{U}\fontseries{m}\fontshape{n}\selectfont\char213}}
+\RenewDocumentCommand\tcb@ref@doc{msm}{%
+ \hyperref[#1:#3]{\texttt{\ref*{#1:#3}}%
+ \IfBooleanTF{#2}{}{%
+ \ifnum\getpagerefnumber{#1:#3}=\thepage\relax%
+ \else%
+ \up*{\myarrow%
+ \,\kvtcb@text@pageshort\,\pageref*{#1:#3}}%
+ \fi}}%
+}
\makeatother
%
\indexsetup{level=\section*,toclevel=section,noclearpage}
diff --git a/macros/latex/contrib/nwejm/source/nwejm.dtx b/macros/latex/contrib/nwejm/source/nwejm.dtx
index 73840d7333..f5efe4c4f1 100644
--- a/macros/latex/contrib/nwejm/source/nwejm.dtx
+++ b/macros/latex/contrib/nwejm/source/nwejm.dtx
@@ -27,7 +27,7 @@
% This field contains the version of the package.
% The value is optional.
% The value is restricted to 32 characters.
-\version{1.0.5 2022-09-21}
+\version{1.0.6 2024-02-08}
% -------------------------------------------------------------------------
% This field contains the name of the author(s).
% The value is optional.
@@ -144,6 +144,13 @@ This update consists only in a logo file renamed as requested by Karl Berry.
% \end{macrocode}
# [Unreleased]
+# [1.0.6] - 2024-02-08
+
+## Fixed
+- (First) Page numbers could be not the same in whole issue and in standalone
+ articles.
+- Minor tweaks in the code.
+
# [1.0.5] - 2022-09-21
## Fixed
@@ -292,7 +299,7 @@ new journal “North-Western European Journal of Mathematics”.
Release
-------
-2022-09-21 v1.0.5
+2024-02-08 v1.0.6
Development
-----------
@@ -323,7 +330,7 @@ https://github.com/dbitouze/nwejm.
\input l3docstrip.tex
\Msg{********************************************************}
\Msg{* Installation}
-\Msg{* Class: nwejm 2022-09-21 v1.0.5}
+\Msg{* Class: nwejm 2024-02-08 v1.0.6}
\Msg{* for the journal}
\Msg{* "North-Western European Journal of Mathematics" (DB)}
\Msg{********************************************************}
@@ -340,7 +347,7 @@ License:| Released under the LaTeX Project Public License v1.3c or later
\endpreamble
\postamble
-Copyright (C) 2015-2022 by Denis Bitouze <denis.bitouze@univ-littoral.fr>
+Copyright (C) 2015-2024 by Denis Bitouze <denis.bitouze@univ-littoral.fr>
This work may be distributed and/or modified under the
conditions of the LaTeX Project Public License (LPPL), either
@@ -561,14 +568,6 @@ Running "make install" installs the files in the local TeX tree.
% commands.
%
% \begin{itemize}
-% \item A generic document command parser:
-% \begin{macrocode}
-\RequirePackage{xparse}
-% \end{macrocode}
-% \item \LaTeXe{} option processing using \LaTeX3 keys:
-% \begin{macrocode}
-\RequirePackage{l3keys2e}
-% \end{macrocode}
% % \item Sorting lists (since \Pkg{l3sort} is about to move from `experimental'
% % to `stable' status, the \File{l3sort.sty} will be removed soonish):
% % \begin{macrocode}
@@ -607,8 +606,8 @@ Running "make install" installs the files in the local TeX tree.
\ProvidesExplClass
%<class> {nwejm}
%<class-article> {nwejmart}
- {2022-09-21}
- {1.0.5}
+ {2024-02-08}
+ {1.0.6}
{
Class for the journal "North-Western European Journal of Mathematics".
}
@@ -685,6 +684,12 @@ Running "make install" installs the files in the local TeX tree.
%<class-article> current~ article.}%
% \end{macrocode}
%
+% In order to automatically fix the first page number each of the articles, we
+% define a related integer.
+% \begin{macrocode}
+\int_new:N \l_@@_first_page_number_int%
+% \end{macrocode}
+%
% \begin{macrocode}
%</class|class-article>
% \end{macrocode}
@@ -830,7 +835,7 @@ Running "make install" installs the files in the local TeX tree.
% \end{macrocode}
%
% \begin{macrocode}
-\ProcessKeysOptions { nwejm }
+\ProcessKeyOptions [nwejm]
% \end{macrocode}
%
% \subsection{Class loading}
@@ -904,6 +909,12 @@ Running "make install" installs the files in the local TeX tree.
\RequirePackage[l2tabu,orthodox]{nag}
% \end{macrocode}
%
+% \item Extension to \Pkg{amsmath}: correct various bugs/defeciencies in amsmath
+% and useful tools for mathematical typesetting:
+% \begin{macrocode}
+\RequirePackage{mathtools}
+% \end{macrocode}
+%
% \item In case of \hologo{pdfTeX} engine, we enforce \pkg{fontenc} to be
% loaded with its \docAuxKey*{T1} option. Otherwise \pkg{fontspec},
% convenient for both \hologo{XeLaTeX} and \hologo{LuaLaTeX}, is loaded by the
@@ -926,7 +937,7 @@ Running "make install" installs the files in the local TeX tree.
%
% \item Unicode mathematics support for \hologo{XeTeX} and \hologo{LuaTeX}:
% \begin{macrocode}
- \RequirePackage{unicode-math}
+ \RequirePackage[warnings-off={mathtools-colon,mathtools-overbracket}]{unicode-math}
% \end{macrocode}
%
% \item OTF version of the Kp-fonts for both roman and sans-serif font, but
@@ -1013,12 +1024,6 @@ Running "make install" installs the files in the local TeX tree.
\RequirePackage{booktabs}
% \end{macrocode}
%
-% \item Extension to \Pkg{amsmath}: correct various bugs/defeciencies in amsmath
-% and useful tools for mathematical typesetting:
-% \begin{macrocode}
-\RequirePackage{mathtools}
-% \end{macrocode}
-%
% \item Extensions to theorem environments:
% \begin{macrocode}
\RequirePackage[amsmath,thmmarks,fleqn]{ntheorem}
@@ -1149,6 +1154,11 @@ Running "make install" installs the files in the local TeX tree.
\RequirePackage{babel}%
% \end{macrocode}
%
+% \item :
+% \begin{macrocode}
+\RequirePackage{listings}%
+% \end{macrocode}
+%
% \item Intelligent page references:
% \begin{macrocode}
\RequirePackage{varioref}
@@ -1325,7 +1335,7 @@ Running "make install" installs the files in the local TeX tree.
% \end{macrocode}
% For the field editor.
% \begin{macrocode}
-\tl_const:Nn \c_@@_field_editor_string_tl {Field~Editor}
+\tl_const:Nn \c_@@_field_editor_string_tl {Fields~Editor}
% \end{macrocode}
% For the editorial secretariat.
% \begin{macrocode}
@@ -3186,11 +3196,11 @@ Running "make install" installs the files in the local TeX tree.
%<class-article>\file_if_exist:nTF { \c_@@_main_file_name_tl.aux }
%<class-article>{
%<class-article> \externaldocument[@@-]{\c_@@_main_file_name_tl}
-%<class-article> \cs_generate_variant:Nn \int_set:Nn { Nx }
-%<class-article> \int_set:Nx \l_tmpa_int {\number\numexpr\getpagerefnumber{@@-\currfilebase}}
-%<class-article> \int_compare:nNnTF {\l_tmpa_int} > {0}
+%<class-article> \cs_generate_variant:Nn \int_set:Nn { Ne }
+%<class-article> \int_set:Ne \l_@@_first_page_number_int {\number\numexpr\getpagerefnumber{@@-\currfilebase}}
+%<class-article> \int_compare:nNnTF {\l_@@_first_page_number_int} > {0}
%<class-article> {
-%<class-article> \AddToHook{begindocument/end}{\setcounter{page}{\l_tmpa_int}}
+%<class-article> \AddToHook{begindocument/end}{\setcounter{page}{\l_@@_first_page_number_int}}
%<class-article> }{
%<class-article> \msg_error:nn{nwejmart}{Something~wrong~with~page~numbers}
%<class-article> }
diff --git a/macros/latex/contrib/robust-externalize/robust-externalize.pdf b/macros/latex/contrib/robust-externalize/robust-externalize.pdf
index 4eca1dad3f..60be5cb58b 100644
--- a/macros/latex/contrib/robust-externalize/robust-externalize.pdf
+++ b/macros/latex/contrib/robust-externalize/robust-externalize.pdf
Binary files differ
diff --git a/macros/latex/contrib/robust-externalize/robust-externalize.sty b/macros/latex/contrib/robust-externalize/robust-externalize.sty
index 488cbb7c8f..fa9500e82d 100644
--- a/macros/latex/contrib/robust-externalize/robust-externalize.sty
+++ b/macros/latex/contrib/robust-externalize/robust-externalize.sty
@@ -1,4 +1,4 @@
-\ProvidesPackage{robust-externalize}[2.6 Cache anything (tikz, latex, python) in a robust, efficient and pure way.]
+\ProvidesPackage{robust-externalize}[2.7 Cache anything (tikz, latex, python) in a robust, efficient and pure way.]
% todo:
% change order argument replace from list, it is hard to read this way
@@ -653,7 +653,7 @@ if __name__ == '__main__':
\NewDocumentCommand{\robExtShowPlaceholder}{sm}{
\cs_if_exist:cTF {l__robExt_placeholder_#2_str} {
- \message{Placeholder ~ #2 ~ contains:^^J~ \use:c{l__robExt_placeholder_#2_str}}
+ \message{Placeholder ~ #2 ~ contains:^^J \use:c{l__robExt_placeholder_#2_str}}
}{
\message{Placeholder ~ #2 ~ does ~ not ~ exist.}
}
@@ -932,6 +932,18 @@ if __name__ == '__main__':
}
\let\addBeforePlaceholderNoImport\robExtAddBeforePlaceholderNoImport
+\ExplSyntaxOff
+
+% except inside setplaceholderfromcode, we want to modify by default the main content orig placeholder
+\def\robExtCurrentPlaceholderName{__ROBEXT_MAIN_CONTENT_ORIG__}
+
+\pgfqkeys{/robExt}{
+ defaultPlaceholderFromCodeStyle/.style={
+ remove leading spaces,
+ },
+}
+
+\ExplSyntaxOn
% Usage:
% \begin{placeholderFromCode}{HELPERFUNCTION}
@@ -940,8 +952,8 @@ if __name__ == '__main__':
% \end{placeholderFromCode}
% HELPERFUNCTION will contain at the end "def ..."
% This environment cannot be placed inside any other macro/align/...
-\NewDocumentEnvironment{RobExtPlaceholderFromCode}{sm}{%
- \checkIfPlaceholderNameIsLegal{#2}%
+\NewDocumentEnvironment{RobExtPlaceholderFromCode}{sO{defaultPlaceholderFromCodeStyle}m}{%
+ \checkIfPlaceholderNameIsLegal{#3}%
% % debug part
% \str_set:Nn \l_test_str {#1}
% \show\l_test_str
@@ -960,14 +972,17 @@ if __name__ == '__main__':
\ior_str_map_inline:Nn \g__robExt_read_ior {%
\str_gput_right:Nx \l__robExt_tmp_str {\tl_to_str:n{##1}^^J}%
}%
- \str_set_eq:cN {l__robExt_placeholder_#2_str} \l__robExt_tmp_str%
+ \str_set_eq:cN {l__robExt_placeholder_#3_str} \l__robExt_tmp_str%
+ %% We apply the style, useful for instance to remove indentation
+ \def\robExtCurrentPlaceholderName{#3}%
+ \pgfqkeys{/robExt}{#2}%
\IfBooleanTF {#1} {} {
- \robExtAddPlaceholderToList{#2}
+ \robExtAddPlaceholderToList{#3}
%% Otherwise they will be lost when the environment ends
\robExtKeepaftergroup{l__robExt_placeholder_group_main_seq}%
- }
+ }%
%% for other variable
- \robExtKeepaftergroup{l__robExt_placeholder_#2_str}%
+ \robExtKeepaftergroup{l__robExt_placeholder_#3_str}%
}%
\let\PlaceholderFromCode\RobExtPlaceholderFromCode
\let\endPlaceholderFromCode\endRobExtPlaceholderFromCode
@@ -1050,7 +1065,7 @@ if __name__ == '__main__':
%% \end{PlaceholderPathFromCode}
%% This will copy "some code" in the cache, and set MYLIBPATH to the name of the file in the cache like
%% MYLIBPATH = robExt-abc.py
-\NewDocumentEnvironment{RobExtPlaceholderPathFromCode}{sO{}m}{
+\NewDocumentEnvironment{RobExtPlaceholderPathFromCode}{sO{}O{defaultPlaceholderFromCodeStyle}m}{
\XSIMfilewritestart*{\jobnameNoQuotes-robExt-tmp-file-you-can-remove.tmp}
}{
\XSIMfilewritestop
@@ -1068,13 +1083,16 @@ if __name__ == '__main__':
\iow_now:NV \g__robExt_write_iow \l__robExt_tmp_contain_file_str
\iow_close:N \g__robExt_write_iow
%% sets the template name to the relative path to the file
- \str_set:cx { l__robExt_placeholder_#3_str } {\robExtPrefixFilename\l__robExt_tmp_filename_no_prefix_str}
+ \str_set:cx { l__robExt_placeholder_#4_str } {\robExtPrefixFilename\l__robExt_tmp_filename_no_prefix_str}
+ %% We apply the style, useful for instance to remove indentation
+ \def\robExtCurrentPlaceholderName{#4}%
+ \pgfqkeys{/robExt}{#3}%
\IfBooleanTF {#1} {} {
- \robExtAddPlaceholderToList{#3}
+ \robExtAddPlaceholderToList{#4}
\robExtKeepaftergroup{l__robExt_placeholder_group_main_seq}
}
%% Otherwise they will be lost when the environment ends
- \robExtKeepaftergroup{l__robExt_placeholder_#3_str}
+ \robExtKeepaftergroup{l__robExt_placeholder_#4_str}
}
\let\PlaceholderPathFromCode\RobExtPlaceholderPathFromCode
\let\endPlaceholderPathFromCode\endRobExtPlaceholderPathFromCode
@@ -2618,7 +2636,7 @@ if __name__ == '__main__':
remove placeholders/.style={
remove placeholder/.list={#1},
},
- set main content/.style={
+ set main content/.style={
set placeholder={__ROBEXT_MAIN_CONTENT_ORIG__}{#1}
},
copy placeholder/.code 2 args={\robExtCopyPlaceholder{#1}{#2}},
@@ -2661,19 +2679,19 @@ if __name__ == '__main__':
placeholder replace in place eval/.code n args={3}{\robExtPlaceholderReplaceInplaceEval{#1}{#2}{#3}},
placeholder prepend all lines/.code 2 args={\robExtPlaceholderPrependAllLines{#1}{#2}},
prepend all lines/.style={
- placeholder prepend all lines={__ROBEXT_MAIN_CONTENT_ORIG__}{#1},
+ placeholder prepend all lines={\robExtCurrentPlaceholderName}{#1},
},
placeholder remove spaces until/.code 2 args={\robExtPlaceholderRemoveSpacesUntil{#1}{#2}},
remove spaces until/.style={
- placeholder remove spaces until={__ROBEXT_MAIN_CONTENT_ORIG__}{#1},
+ placeholder remove spaces until={\robExtCurrentPlaceholderName}{#1},
},
placeholder strictly remove spaces until/.code 2 args={\robExtPlaceholderRemoveSpacesUntil{#1}[0]{#2}},
strictly remove spaces until/.style={
- placeholder remove spaces until nospace={__ROBEXT_MAIN_CONTENT_ORIG__}{#1},
+ placeholder remove spaces until nospace={\robExtCurrentPlaceholderName}{#1},
},
placeholder remove leading spaces/.code={\robExtPlaceholderRemoveLeadingSpaces{#1}},
- remove leading spaces/.code={\robExtPlaceholderRemoveLeadingSpaces{__ROBEXT_MAIN_CONTENT_ORIG__}},
- remove leading spaces if not disabled/.code={\ifdefined\robExtDoNotRemoveLeadingSpaces\else\robExtPlaceholderRemoveLeadingSpaces{__ROBEXT_MAIN_CONTENT_ORIG__}\fi},
+ remove leading spaces/.code={\robExtPlaceholderRemoveLeadingSpaces{\robExtCurrentPlaceholderName}},
+ remove leading spaces if not disabled/.code={\ifdefined\robExtDoNotRemoveLeadingSpaces\else\robExtPlaceholderRemoveLeadingSpaces{\robExtCurrentPlaceholderName}\fi},
do not remove leading spaces/.code={\def\robExtDoNotRemoveLeadingSpaces{}},
% Interface to set template
set template/.style={
diff --git a/macros/latex/contrib/robust-externalize/robust-externalize.tex b/macros/latex/contrib/robust-externalize/robust-externalize.tex
index 93d7f664e0..be0c689b61 100644
--- a/macros/latex/contrib/robust-externalize/robust-externalize.tex
+++ b/macros/latex/contrib/robust-externalize/robust-externalize.tex
@@ -105,7 +105,7 @@
{\Large\bfseries Cache anything (\tikzname, tikz-cd, python…),\\in a robust, efficient and pure way.}
\vspace{1em}
- {Léo Colisson \quad Version 2.6}\\[3mm]
+ {Léo Colisson \quad Version 2.7}\\[3mm]
{\href{https://github.com/leo-colisson/robust-externalize}{\texttt{github.com/leo-colisson/robust-externalize}}}
\end{center}
@@ -1711,8 +1711,8 @@ This is contrary to |\getPlaceholder| that is not expandable, so if you do want
\begin{pgfmanualentry}
- \extractenvironement{PlaceholderFromCode}\opt{*}\marg{name placeholder}\@@
- \extractenvironement{SetPlaceholderCode}\opt{*}\marg{name placeholder}\@@
+ \extractenvironement{PlaceholderFromCode}\opt{*}\opt{\oarg{style}}\marg{name placeholder}\@@
+ \extractenvironement{SetPlaceholderCode}\opt{*}\opt{\oarg{style}}\marg{name placeholder}\@@
\pgfmanualbody
These two (aliased) environments are useful to set a verbatim value to a given placeholder: the advantage is that you can put inside any code, including \LaTeX{} comments, the downside is that you cannot use it inside macros and some environments (so you typically define it before the macros and call it inside).
@@ -1758,6 +1758,27 @@ def my_function(b): # this is a python code
}
Note that of course, you can define a placeholder before a macro and call it inside (explaining how we can generate this documentation).
+You can use the optional style (only after 2.7; note that it defaults to |defaultPlaceholderFromCodeStyle|, which contains by default |remove leading spaces|) to apply some operations on the style. This way, by default, it will remove any leading indentation, allowing you, for instance, to indent your python code based on the surrounding LaTeX environment):
+\begin{codeAndResult}
+\begin{PlaceholderFromCode}{__TMP_MAIN_CONTENT__}
+ # See, you can indent this code with two spaces without disturbing python (that expects no indentation)
+ import matplotlib.pyplot as plt
+ year = [2014, 2015, 2016, 2017, 2018, 2019]
+ tutorial_count = [39, 117, 111, 110, 67, 29]
+ plt.plot(year, tutorial_count, color="#6c3376", linewidth=3)
+ plt.xlabel('Year')
+ plt.ylabel('Number of futurestud.io Tutorials')
+ plt.savefig("__ROBEXT_OUTPUT_PDF__")
+\end{PlaceholderFromCode}
+
+\fbox{\begin{CacheMeNoContent}
+ python,
+ set includegraphics options={width=.8\linewidth},
+ set main content={__TMP_MAIN_CONTENT__},
+\end{CacheMeNoContent}}
+\end{codeAndResult}
+
+
Note that the star and no import version does NOT import the placeholder it the main group (unless you try to optimize the compilation time you should not need it, but see \cref{sec:importSystem} for details).
\end{pgfmanualentry}
@@ -4911,6 +4932,10 @@ Options > Configure TeXstudio > Editor > Replace tabs in text with spaces
\section{Changelog}
\begin{itemize}
+\item v2.7:
+ \begin{itemize}
+ \item apply |remove leading spaces| by default also in |placeholderFromCode| and |PlaceholderPathFromCode|, and allow the user to customize the style. This produces a very minor backward incompatibility as it might disturb code where all lines start with a space.
+ \end{itemize}
\item v2.6:
\begin{itemize}
\item Added |\lenToCmNoUnit|
diff --git a/macros/latex/contrib/starray/README.md b/macros/latex/contrib/starray/README.md
index 42e5c77afc..4da1c376a0 100644
--- a/macros/latex/contrib/starray/README.md
+++ b/macros/latex/contrib/starray/README.md
@@ -42,7 +42,7 @@ Please do not use the issue page for generic help on how to use the package.
* git: https://github.com/alceu-frigeri/starray
-------------
-Copyright 2023 by Alceu Frigeri
+Copyright 2023-present by Alceu Frigeri
This work may be distributed and/or modified under the
conditions of
@@ -72,7 +72,12 @@ The Current Maintainer of this work is Alceu Frigeri
-------------
## Changelog
-* Version 1.5 (this)
+* Version 1.6 (this)
+ - removing all V-expansion of property/sequence lists to avoid further issues with l3kernel
+ issues: #6, https://github.com/latex3/latex3/issues/1460 and https://github.com/latex3/latex3/issues/1466
+ - Remarks: code is operational but needs further cleanup!
+
+* Version 1.5
- added \starray_term_syntax:nNN variant and friends (\starray_parsed_ ... :NN ) the _parsed_ ones being expandable
* Version 1.4
diff --git a/macros/latex/contrib/starray/doc/starray.pdf b/macros/latex/contrib/starray/doc/starray.pdf
index cf5a4f2d70..75af49bf47 100644
--- a/macros/latex/contrib/starray/doc/starray.pdf
+++ b/macros/latex/contrib/starray/doc/starray.pdf
Binary files differ
diff --git a/macros/latex/contrib/starray/doc/starray.tex b/macros/latex/contrib/starray/doc/starray.tex
index 258b533417..0668574cec 100644
--- a/macros/latex/contrib/starray/doc/starray.tex
+++ b/macros/latex/contrib/starray/doc/starray.tex
@@ -2,7 +2,7 @@
% !TEX ext = --interaction=nonstopmode --enable-etex
% !BIB program = none
%%%==============================================================================
-%% Copyright 2023 by Alceu Frigeri
+%% Copyright 2023-present by Alceu Frigeri
%%
%% This work may be distributed and/or modified under the conditions of
%%
@@ -15,7 +15,7 @@
%%
%% The Current Maintainer of this work is Alceu Frigeri
%%
-%% This is version {1.5} {2023/11/28}
+%% This is version {1.6} {2024/03/10}
%%
%% The list of files that compose this work can be found in the README.md file at
%% https://ctan.org/pkg/starray
@@ -67,7 +67,7 @@ The current implementation, albeit also complex, tries to reach a balance betwee
\end{tsremark}
-\section{Class Options}\label{pack:options}
+\section{Package Options}\label{pack:options}
The package options (\tsobj[key]{key}\,=\tsobj[value]{value}) are:
\begin{describelist}{option}
\describe{prefix}{(default: \tsobj[value]{\detokenize{l__starray_}} ). Set the \tsobj[key]{prefix} used when declaring the property lists associated with any \tsobj[pkg]{starray}.}
diff --git a/macros/latex/contrib/starray/latex/starray.sty b/macros/latex/contrib/starray/latex/starray.sty
index 376302469b..73e07868aa 100644
--- a/macros/latex/contrib/starray/latex/starray.sty
+++ b/macros/latex/contrib/starray/latex/starray.sty
@@ -1,5 +1,5 @@
%%%==============================================================================
-%% Copyright 2023 by Alceu Frigeri
+%% Copyright 2023-present by Alceu Frigeri
%%
%% This work may be distributed and/or modified under the conditions of
%%
@@ -12,7 +12,7 @@
%%
%% The Current Maintainer of this work is Alceu Frigeri
%%
-%% This is version {1.5} {2023/11/28}
+%% This is version {1.6} {2024/03/10}
%%
%% The list of files that compose this work can be found in the README.md file at
%% https://ctan.org/pkg/starray
@@ -24,8 +24,8 @@
\ProvidesExplPackage
{starray}
- {2023/11/28}
- {1.5}
+ {2024/03/10}
+ {1.6}
{A structured array/hash of properties}
%%%%%%%
@@ -38,24 +38,16 @@
{
name .code:n = {starray} ,
prefix .code:n = {starray} ,
- date .code:n = {2023/11/28},
- version .code:n = {1.5} ,
+ date .code:n = {2024/03/10},
+ version .code:n = {1.6} ,
description .code:n = {A~structured~array/hash~of~properties}
}
-\cs_if_exist:NF \__codedesc_pkg_info:nn
+\cs_if_exist:NF \PkgInfo
{
- \cs_new_protected:Npn \__codedesc_pkg_info:nn #1#2
- { \keys_set:nn {#1 / pkg info}{#2} }
- }
-\cs_if_exist:NF \PkgInfo
- { \NewDocumentCommand \PkgInfo {mm} { \keys_set:nn {#1 / pkg info}{#2} } }
-\cs_if_exist:NF \PkgDescription
- {
+ \NewDocumentCommand \PkgInfo {mm} { \keys_set:nn {#1 / pkg info}{#2} }
\NewDocumentCommand \PkgDescription {m}
- {
- \noindent Package~ \textbf{\PkgInfo{#1}{name}}~Version:~\PkgInfo{#1}{version}~ -~ \PkgInfo{#1}{date}\par \emph{\PkgInfo{#1}{description}}~\par
- }
- }
+ { \noindent Package~ \textbf{\PkgInfo{#1}{name}}~Version:~\PkgInfo{#1}{version}~ -~ \PkgInfo{#1}{date}\par \emph{\PkgInfo{#1}{description}}~\par }
+ }
%%%%%%%
%%% End of cut-n-paste
%%%%%%%
@@ -159,7 +151,7 @@
\cs_generate_variant:Nn \prop_get:NnN { cnc , cec }
-\prg_generate_conditional_variant:Nnn \prop_get:NnN { Nec } { F , T , TF}
+\prg_generate_conditional_variant:Nnn \prop_get:NnN { Nec , cec , ceN , cnN } { F , T , TF}
\prg_generate_conditional_variant:Nnn \seq_if_in:Nn {ce} {TF}
\prg_generate_conditional_variant:Nnn \prop_if_in:Nn {ce} {TF}
@@ -506,15 +498,12 @@
{ iter }
{ \use:c {\l__starray_prefix_tl #2 _iter_int} }
- \prop_gput:cnV
- { \l__starray_prefix_tl #2 _base_prop }
- { idx_hash }
- \c_empty_prop
- \prop_gput:cnV
- { \l__starray_prefix_tl #2 _base_prop }
- { iter_hash }
- \c_empty_prop
+ %% V-less : new
+ \prop_new:c {\l__starray_prefix_tl #2 _base_idxhash_prop}
+
+ %% V-less : new iterhash
+ \prop_new:c {\l__starray_prefix_tl #2 _base_iterhash_prop}
}
\cs_generate_variant:Nn \__starray_base_new:nn { ee }
@@ -540,10 +529,11 @@
\prop_clear:N \l_tmpa_prop
- \prop_gput:cnV { \l__starray_prefix_tl #1 _def_prop } {@st_seq} \c_empty_seq
-
- \prop_gput:cnV
- { \l__starray_prefix_tl #1 _def_prop} {def} \l_tmpa_prop
+ %% V-less : new st_seq => defstkeys_seq
+ \seq_new:c { \l__starray_prefix_tl #1 _defstkeys_seq }
+
+ %% V-less : This shall be the new defkey's holder {def}
+ \prop_new:c {\l__starray_prefix_tl #1 _defkeys_prop}
}
@@ -627,9 +617,12 @@
% needs protection.
\cs_new_protected:Npn \__starray_def_prop:nnn #1#2#3
{
- \prop_get:cnN {\l__starray_prefix_tl #1 _def_prop} {def} \l_tmpa_prop
- \prop_put:Nnn \l_tmpa_prop {#2} {#3}
- \prop_gput:cnV {\l__starray_prefix_tl #1 _def_prop} {def} \l_tmpa_prop
+% \prop_get:cnN {\l__starray_prefix_tl #1 _def_prop} {def} \l_tmpa_prop
+% \prop_put:Nnn \l_tmpa_prop {#2} {#3}
+% \prop_gput:cnV {\l__starray_prefix_tl #1 _def_prop} {def} \l_tmpa_prop
+
+ %% V-less : This shall be the new key's holder {def}
+ \prop_gput:cnn {\l__starray_prefix_tl #1 _defkeys_prop} {#2} {#3}
}
@@ -676,15 +669,15 @@
% needs protection because of \seq_if...
\cs_new_protected:Npn \__starray_def_struct:nn #1#2
{
- \prop_get:cnN {\l__starray_prefix_tl #1 _def_prop} {@st_seq} \l_tmpa_seq
- \seq_if_in:NnF \l_tmpa_seq {#2}
+ %% V-less : new st_seq... can be optimized by direct reference (no tmpa)
+ \seq_if_in:cnF {\l__starray_prefix_tl #1 _defstkeys_seq} {#2}
{
- \seq_put_right:Nn \l_tmpa_seq {#2}
-
- \prop_gput:cnV {\l__starray_prefix_tl #1 _def_prop} {@st_seq} \l_tmpa_seq
+ %% V-less : new st_seq
+ \seq_gput_right:cn {\l__starray_prefix_tl #1 _defstkeys_seq} {#2}
\__starray_new:e { #1 . #2}
}
+
}
\cs_generate_variant:Nn \__starray_def_struct:nn {ne}
@@ -717,10 +710,11 @@
{\l__starray_prefix_tl #2 _base_prop}
{def_ref}
\l_tmpa_tl
- \prop_get:cec
- {\l__starray_prefix_tl \l_tmpa_tl _def_prop}
- {@st_seq}
- {l__starray_tmp A_seq}
+
+ %% V-less : new st_seq
+ \seq_set_eq:cc {l__starray_tmp A_seq}{\l__starray_prefix_tl \l_tmpa_tl _defstkeys_seq}
+
+ %% V-less : can't be optimized. _fix_terms_ will change _defstkeys_seq
\seq_map_tokens:cn
{l__starray_tmp A_seq}
{\__starray_fix_terms_seq_aux:nnnn {#1}{#2}{#4}}
@@ -730,16 +724,17 @@
\cs_new_protected:Npn \__starray_fix_terms:nn #1#2
{
\group_begin:
- \prop_get:cnc
- {\l__starray_prefix_tl #2 _base_prop}
- {idx_hash}
- {l__starray_tmp A_prop}
+ %% V-less : and replaced by
+ \prop_set_eq:cc {l__starray_tmp A_prop} {\l__starray_prefix_tl #2 _base_idxhash_prop}
+
+ %% V-less : can be improved by direct reference.
\prop_if_empty:cF {l__starray_tmp A_prop}
{
\prop_map_tokens:cn
{l__starray_tmp A_prop}
{\__starray_fix_terms_seq:nnnn {#1}{#2}}
}
+
\group_end:
}
@@ -921,33 +916,29 @@
{\prop_item:cn {\l__starray_prefix_tl #1 _base_prop} {iter} }
{\prop_item:cn {\l__starray_prefix_tl #1 _base_prop} {cnt} }
-
- % idx_hash Update.
- \prop_get:cnN {\l__starray_prefix_tl #1 _base_prop} {idx_hash} \l_tmpa_prop
- \prop_get:cnN {\l__starray_prefix_tl #1 _base_prop} {iter_hash} \l_tmpb_prop
-
- \prop_put:Nee \l_tmpa_prop
+ %% V-less : new
+ \prop_put:cee {\l__starray_prefix_tl #1 _base_idxhash_prop}
{ \int_use:N \prop_item:cn {\l__starray_prefix_tl #1 _base_prop} {cnt} }
{ \int_to_Alph:e { \prop_item:cn {\l__starray_prefix_tl #1 _base_prop} {cnt} } }
- \prop_put:Nee \l_tmpb_prop
+ %% V-less : new iterhash
+ \prop_put:cee {\l__starray_prefix_tl #1 _base_iterhash_prop}
{ \int_use:N \prop_item:cn {\l__starray_prefix_tl #1 _base_prop} {cnt} }
{ \int_use:N \prop_item:cn {\l__starray_prefix_tl #1 _base_prop} {cnt} }
-
+
\tl_if_blank:nF {#2}
{
- \prop_put:Nee \l_tmpa_prop
+ %% V-less : new
+ \prop_put:cee {\l__starray_prefix_tl #1 _base_idxhash_prop}
{ #2 }
{ \int_to_Alph:e { \prop_item:cn {\l__starray_prefix_tl #1 _base_prop} {cnt} } }
- \prop_put:Nee \l_tmpb_prop
+
+ %% V-less : new iter_hash
+ \prop_put:cee {\l__starray_prefix_tl #1 _base_iterhash_prop}
{ #2 }
{ \int_use:N \prop_item:cn {\l__starray_prefix_tl #1 _base_prop} {cnt} }
}
- \prop_gput:cnV {\l__starray_prefix_tl #1 _base_prop} {idx_hash} \l_tmpa_prop
-
- \prop_gput:cnV {\l__starray_prefix_tl #1 _base_prop} {iter_hash} \l_tmpb_prop
-
% creating the 'new property list' (aka. term)
\tl_set:Ne \l_tmpa_tl
{ \int_to_Alph:e { \prop_item:cn {\l__starray_prefix_tl #1 _base_prop} {cnt} } }
@@ -957,19 +948,17 @@
\prop_get:cnN {\l__starray_prefix_tl #1 _base_prop} {def_ref} \l_tmpb_tl
- \prop_get:cnN {\l__starray_prefix_tl \l_tmpb_tl _def_prop} {def} \l_tmpa_prop
-
- \prop_gset_eq:cN { \l__starray_prefix_tl #1 _ \l_tmpa_tl _term_prop } \l_tmpa_prop
-
- \prop_get:cnN {\l__starray_prefix_tl \l_tmpb_tl _def_prop} {@st_seq} \l_tmpa_seq
+ %% V-less : replacing above
+ \prop_gset_eq:cc { \l__starray_prefix_tl #1 _ \l_tmpa_tl _term_prop } {\l__starray_prefix_tl \l_tmpb_tl _defkeys_prop}
% map over 'all sub-starrays parts of def_ref -> st_seq (those starting with a dot, @st_seq)
- \seq_map_tokens:Nn
- \l_tmpa_seq
+ \seq_map_tokens:cn
+ {\l__starray_prefix_tl \l_tmpb_tl _defstkeys_seq}
{
\__starray_sub_base_new:nnn
{ \l_tmpb_tl }{ #1 _ \l_tmpa_tl }
}
+
}
@@ -1051,9 +1040,9 @@
\cs_new_protected:Npn \__starray_set_sub_iter:nnn #1#2#3
{
- \prop_get:cnN {\l__starray_prefix_tl #2#3 _base_prop} {idx_hash} \l_tmpa_prop
- \prop_get:NecT \l_tmpa_prop
+ %% V-less : to be replaced by
+ \prop_get:cecT {\l__starray_prefix_tl #2#3 _base_idxhash_prop}
{ \int_use:N \prop_item:cn {\l__starray_prefix_tl #2#3 _base_prop} {iter} }
{ l__starray_tmp #1 A_tl }
{
@@ -1061,12 +1050,11 @@
{\l__starray_prefix_tl #2#3 _base_prop}
{def_ref}
\l_tmpa_tl
-
- \prop_get:cnc
- { \l__starray_prefix_tl \l_tmpa_tl _def_prop }
- { @st_seq }
- {l__starray_tmp #1 A_seq }
-
+
+ %% V-less : new st_seq
+ \seq_set_eq:cc {l__starray_tmp #1 A_seq }{ \l__starray_prefix_tl \l_tmpa_tl _defstkeys_seq }
+
+ %% V-less : could it be optimized? direct reference to defstkeys !?
\seq_if_empty:cF {l__starray_tmp #1 A_seq }
{
\seq_map_variable:cNn
@@ -1098,8 +1086,8 @@
%%%%%%%%%%%%%%%
\prg_new_protected_conditional:Npnn \__starray_set_iter_from_hash:nn #1#2 {T , F, TF}
{
- \prop_get:cnN {\l__starray_prefix_tl #1 _base_prop} {iter_hash} \l_tmpa_prop
- \prop_get:NnNTF \l_tmpa_prop {#2} \l_tmpa_tl
+% %% V-less : replacing ... iter_hash
+ \prop_get:cnNTF {\l__starray_prefix_tl #1 _base_iterhash_prop} {#2} \l_tmpa_tl
{
\int_gset:Nn
{ \prop_item:cn {\l__starray_prefix_tl #1 _base_prop} {iter} }
@@ -1635,6 +1623,21 @@
}
+\prg_new_protected_conditional:Npnn \starray_get_unique_id:nN #1#2 {T, F, TF}
+ {
+ \__starray_parser:nnTF {\c__starray_idx_ending_bool}{#1}
+ {
+ \tl_set:Ne
+ #2
+ { \l__starray_parsed_ref_tl }
+ \prg_return_true:
+ }
+ {
+ \seq_clear:N \l__starray_msg_seq
+ \prg_return_false:
+ } % returns nothing by default
+ }
+
@@ -1819,17 +1822,16 @@
{def_ref}
{l__starray_tmp #1 _def_prop}
- \prop_get:cnc
- {\l__starray_prefix_tl \tl_use:c {l__starray_tmp #1 _def_prop} _def_prop}
- {@st_seq}
- {l__starray_tmp #1 _seq}
-
+
+ %% V-less : new st_seq
+ \seq_set_eq:cc {l__starray_tmp #1 _seq}{\l__starray_prefix_tl \tl_use:c {l__starray_tmp #1 _def_prop} _defstkeys_seq}
+
+ %% V-less : could it be optimized? direct reference to defstkeys !?
\seq_if_in:cnTF {l__starray_tmp #1 _seq}{#4}
{
- \prop_get:cnc
- { \l__starray_prefix_tl #3 .#4 _base_prop }
- { idx_hash }
- { l__starray_tmp #1 _hash_prop }
+ %% V-less : replacing above
+ \prop_set_eq:cc { l__starray_tmp #1 _hash_prop } { \l__starray_prefix_tl #3 .#4 _base_idxhash_prop }
+
\prop_get:cnc
{ \l__starray_prefix_tl #3 .#4 _base_prop }
{ iter }
@@ -1872,18 +1874,19 @@
{def_ref}
{l__starray_tmp #1 _def_prop}
- \prop_get:cnc
- {\l__starray_prefix_tl \tl_use:c {l__starray_tmp #1 _def_prop} _def_prop}
- {@st_seq}
- {l__starray_tmp #1 _seq}
+ %% V-less : new st_seq
+ \seq_set_eq:cc {l__starray_tmp #1 _seq}{\l__starray_prefix_tl \tl_use:c {l__starray_tmp #1 _def_prop} _defstkeys_seq}
+
+ %% V-less : could it be optimized? direct reference to defstkeys !?
\seq_if_in:ceTF
{ l__starray_tmp #1 _seq } { \tl_use:c{l__starray_tmp #1 :B_tl} }
{
- \prop_get:cnc
- { \l__starray_prefix_tl #3. \tl_use:c{l__starray_tmp #1 :B_tl} _base_prop }
- { idx_hash }
- { l__starray_tmp #1 _hash_prop }
+ %% V-less : could it be optimized? direct reference !?
+ \prop_set_eq:cc
+ { l__starray_tmp #1 _hash_prop }
+ { \l__starray_prefix_tl #3. \tl_use:c{l__starray_tmp #1 :B_tl} _base_idxhash_prop }
+
\tl_set:ce
{ l__starray_tmp #1 _idx_tl }
{
@@ -2083,17 +2086,17 @@
% if #2 is empty, test if #1 is valid, return true/false
\prg_new_protected_conditional:Npnn \__starray_if_valid_idx:nn #1#2 {T, F, TF}
{
- \prop_get:cnN {\l__starray_prefix_tl \l__starray_parsed_ref_tl _base_prop} {idx_hash} \l_tmpa_prop
-
\tl_if_blank:nTF {#2}
{
- \tl_put_right:Ne \l__starray_parsed_ref_tl
- { _ \prop_item:Ne \l_tmpa_prop {#1} }
+ \prop_get:ceNF {\l__starray_prefix_tl \l__starray_parsed_ref_tl _base_idxhash_prop} {#1} \l_tmpa_tl
+ { \tl_set:Nn \l_tmpa_tl {} }
}
{
- \tl_put_right:Ne \l__starray_parsed_ref_tl
- { _ \prop_item:Ne \l_tmpa_prop {#2} }
+ \prop_get:ceNF {\l__starray_prefix_tl \l__starray_parsed_ref_tl _base_idxhash_prop} {#2} \l_tmpa_tl
+ { \tl_set:Nn \l_tmpa_tl {} }
}
+ \tl_put_right:Ne \l__starray_parsed_ref_tl { _ \l_tmpa_tl }
+
\prop_if_exist:cTF { \l__starray_prefix_tl \l__starray_parsed_ref_tl _term_prop }
{\prg_return_true:}
@@ -2333,25 +2336,18 @@
\tl_to_str:n {{#3} ~ struct}
\use:nn { ~ } { ~ } =>
}
-
- \prop_get:cnc
- {\l__starray_prefix_tl #2#3 _def_prop}
- {def}
- {l__starray_tmp A _def_prop}
-
- \prop_get:cnc
- { \l__starray_prefix_tl #2#3 _def_prop }
- { @st_seq }
- {l__starray_tmp A _seq }
-
+
+ %% V-less : direct reference to _defkeys
\prop_map_tokens:cn
- {l__starray_tmp A _def_prop}
+ {\l__starray_prefix_tl #2#3 _defkeys_prop}
{\__starray_show_def_item:nnn {#1}}
-
- \seq_if_empty:cF { l__starray_tmp A _seq }
+
+
+ %% V-less : direct reference to _defstkeys
+ \seq_if_empty:cF { \l__starray_prefix_tl #2#3 _defstkeys_seq}
{
\seq_map_tokens:cn
- { l__starray_tmp A _seq }
+ { \l__starray_prefix_tl #2#3 _defstkeys_seq}
{ \__starray_show_def:nnn { #1 \use:nnn { ~ } { ~ } { ~ }} { #2#3. } }
}
\group_end:
@@ -2421,19 +2417,17 @@
{ \l__starray_prefix_tl #2 #3 _base_prop }
{ def_ref }
\l_tmpa_tl
-
- \prop_get:cnc
- { \l__starray_prefix_tl \l_tmpa_tl _def_prop }
- { @st_seq }
- {l__starray_tmp A _seq }
-
- \seq_if_empty:cTF { l__starray_tmp A _seq }
+
+ %% V-less : this can be optimized: direct reference to defstkeys_seq
+ \seq_if_empty:cTF { \l__starray_prefix_tl \l_tmpa_tl _defstkeys_seq }
{}
{
\seq_map_tokens:cn
- { l__starray_tmp A _seq }
+ { \l__starray_prefix_tl \l_tmpa_tl _defstkeys_seq }
{ \__starray_show_terms:nen { #1 \use:nnn { ~ } { ~ } { ~ }} { #2 #3_#5. } }
}
+
+
\group_end:
}
@@ -2442,13 +2436,9 @@
\cs_new_protected:Npn \__starray_show_terms:nnn #1#2#3
{
\group_begin:
- \prop_get:cnc
- {\l__starray_prefix_tl #2 #3 _base_prop}
- {idx_hash}
- {l__starray_tmp A _idx_prop}
-
+ %% V-less : direct reference
\prop_map_tokens:cn
- {l__starray_tmp A _idx_prop}
+ {\l__starray_prefix_tl #2 #3 _base_idxhash_prop}
{\__starray_show_term_item:nnnnn {#1}{#2}{#3}}
\group_end:
}
diff --git a/macros/latex/contrib/ufrgscca/README.md b/macros/latex/contrib/ufrgscca/README.md
index dc63bf969a..7de453521e 100644
--- a/macros/latex/contrib/ufrgscca/README.md
+++ b/macros/latex/contrib/ufrgscca/README.md
@@ -107,7 +107,13 @@ The Current Maintainer of this work is Alceu Frigeri
## Changelog
-* Version 2.6 (this)
+* Version 2.7 (this)
+ - fixing issue https://github.com/alceu-frigeri/ufrgscca/issues/1
+ - removing all V-expansion of property/sequence lists to avoid further issues with l3kernel
+ issues: https://github.com/alceu-frigeri/starray/issues/6, https://github.com/latex3/latex3/issues/1460 and https://github.com/latex3/latex3/issues/1466
+ - Remarks: code is operational but needs further cleanup!
+
+* Version 2.6
- Added other's case (student fate) for record keeping.
- Report adjustments (other's case).
diff --git a/macros/latex/contrib/ufrgscca/doc/ufrgscca.pdf b/macros/latex/contrib/ufrgscca/doc/ufrgscca.pdf
index b5c3f0418b..91e81cb140 100644
--- a/macros/latex/contrib/ufrgscca/doc/ufrgscca.pdf
+++ b/macros/latex/contrib/ufrgscca/doc/ufrgscca.pdf
Binary files differ
diff --git a/macros/latex/contrib/ufrgscca/doc/ufrgscca.tex b/macros/latex/contrib/ufrgscca/doc/ufrgscca.tex
index 3ce27a7913..9905684720 100644
--- a/macros/latex/contrib/ufrgscca/doc/ufrgscca.tex
+++ b/macros/latex/contrib/ufrgscca/doc/ufrgscca.tex
@@ -15,7 +15,7 @@
%%
%% The Current Maintainer of this work is Alceu Frigeri
%%
-%% This is version {2.6} {2024/02/29}
+%% This is version {2.7} {2024/03/10}
%%
%% The list of files that compose this work can be found in the README.md file at
%% https://ctan.org/pkg/ufrgscca
diff --git a/macros/latex/contrib/ufrgscca/latex/ufrgscca-abnt.sty b/macros/latex/contrib/ufrgscca/latex/ufrgscca-abnt.sty
index 6e008fe159..fcb7856e39 100644
--- a/macros/latex/contrib/ufrgscca/latex/ufrgscca-abnt.sty
+++ b/macros/latex/contrib/ufrgscca/latex/ufrgscca-abnt.sty
@@ -12,7 +12,7 @@
%%
%% The Current Maintainer of this work is Alceu Frigeri
%%
-%% This is version {2.6} {2024/02/29}
+%% This is version {2.7} {2024/03/10}
%%
%% The list of files that compose this work can be found in the README.md file at
%% https://ctan.org/pkg/ufrgscca
@@ -27,8 +27,8 @@
\ProvidesExplPackage
{ufrgscca-abnt}
- {2024/02/29}
- {2.6}
+ {2024/03/10}
+ {2.7}
{UFRGS/CCA ABNT layout}
@@ -42,8 +42,8 @@
{
name .code:n = {ufrgscca-abnt} ,
prefix .code:n = {ufrgscca} ,
- date .code:n = {2024/02/29},
- version .code:n = {2.6} ,
+ date .code:n = {2024/03/10},
+ version .code:n = {2.7} ,
description .code:n = {UFRGS/CCA~ abnt~layout}
}
\cs_if_exist:NF \PkgInfo
diff --git a/macros/latex/contrib/ufrgscca/latex/ufrgscca-base-en.def b/macros/latex/contrib/ufrgscca/latex/ufrgscca-base-en.def
index 3af375f915..3b3fca1df7 100644
--- a/macros/latex/contrib/ufrgscca/latex/ufrgscca-base-en.def
+++ b/macros/latex/contrib/ufrgscca/latex/ufrgscca-base-en.def
@@ -12,7 +12,7 @@
%%
%% The Current Maintainer of this work is Alceu Frigeri
%%
-%% This is version {2.6} {2024/02/29}
+%% This is version {2.7} {2024/03/10}
%%
%% The list of files that compose this work can be found in the README.md file at
%% https://ctan.org/pkg/ufrgscca
diff --git a/macros/latex/contrib/ufrgscca/latex/ufrgscca-base-ptBR.def b/macros/latex/contrib/ufrgscca/latex/ufrgscca-base-ptBR.def
index 7aba05c370..a3a71fe6bb 100644
--- a/macros/latex/contrib/ufrgscca/latex/ufrgscca-base-ptBR.def
+++ b/macros/latex/contrib/ufrgscca/latex/ufrgscca-base-ptBR.def
@@ -12,7 +12,7 @@
%%
%% The Current Maintainer of this work is Alceu Frigeri
%%
-%% This is version {2.6} {2024/02/29}
+%% This is version {2.7} {2024/03/10}
%%
%% The list of files that compose this work can be found in the README.md file at
%% https://ctan.org/pkg/ufrgscca
diff --git a/macros/latex/contrib/ufrgscca/latex/ufrgscca-coord.sty b/macros/latex/contrib/ufrgscca/latex/ufrgscca-coord.sty
index e03a338b2f..c258ab8b34 100644
--- a/macros/latex/contrib/ufrgscca/latex/ufrgscca-coord.sty
+++ b/macros/latex/contrib/ufrgscca/latex/ufrgscca-coord.sty
@@ -12,7 +12,7 @@
%%
%% The Current Maintainer of this work is Alceu Frigeri
%%
-%% This is version {2.6} {2024/02/29}
+%% This is version {2.7} {2024/03/10}
%%
%% The list of files that compose this work can be found in the README.md file at
%% https://ctan.org/pkg/ufrgscca
@@ -27,8 +27,8 @@
\ProvidesExplPackage
{ufrgscca-coord}
- {2024/02/29}
- {2.6}
+ {2024/03/10}
+ {2.7}
{UFRGS/CCA coord commands}
@@ -42,8 +42,8 @@
{
name .code:n = {ufrgscca-coord} ,
prefix .code:n = {ufrgscca} ,
- date .code:n = {2024/02/29},
- version .code:n = {2.6} ,
+ date .code:n = {2024/03/10},
+ version .code:n = {2.7} ,
description .code:n = {UFRGS/CCA~ coordination~ report~ commands}
}
\cs_if_exist:NF \PkgInfo
@@ -58,6 +58,17 @@
+%%%%%%%
+%%%
+%%% V-less : Blocks of code affected:
+%%% Coord (checklist) 'kind of easy'
+%%% curr (all!) 'to be seen how'
+%%% ppc (all!) 'to be seen how'
+%%%
+%%%%%%%
+
+
+
\cs_generate_variant:Nn \tl_set:Nn {Ne}
@@ -656,7 +667,13 @@
\NewDocumentCommand{\tcreports}{O{}m}{
{
-
+ \seq_map_inline:cn {l__ufrgscca_#2_list_seq}
+ {
+ \starray_set_iter_from_hash:nn {student}{##1}
+ \emptytermifnone{student.advisor}
+ \emptytermifnone[3]{student.reviewer}[\starray_gset_prop:nnn {student}{flag-null}{\c_true_bool}]
+ \emptytermifnone{student.altreviewer}
+ }
\__ufrgscca_set_reports:n {#1}
\bool_if:cF {l__ufrgscca_#2_classified_bool}
{ \sortstudentlist{#2} }
@@ -776,18 +793,27 @@
\prop_new:N \l__ufrgscca_checkB_prop
\prop_new:N \l__ufrgscca_checkref_prop
-\NewDocumentCommand{\checkdef}{mmm}{
- \starray_get_prop:nnN {activity}{chkmarked}\l__ufrgscca_check_prop
- \prop_gput:Nnn \l__ufrgscca_check_prop {#1}{\__ufrgscca_checkedbox:~\ #3}
- \starray_gset_prop:nnV {activity}{chkmarked}\l__ufrgscca_check_prop
+\tl_new:N \l__ufrgscca_chkID_tl
+\tl_new:N \l__ufrgscca_chkIDa_tl
+\tl_new:N \l__ufrgscca_chkIDb_tl
- \starray_get_prop:nnN {activity}{chkunmarked}\l__ufrgscca_check_prop
- \prop_gput:Nnn \l__ufrgscca_check_prop {#1}{\__ufrgscca_uncheckedbox:~\ #3}
- \starray_gset_prop:nnV {activity}{chkunmarked}\l__ufrgscca_check_prop
+\NewDocumentCommand{\checkdef}{mmm}{
+% \starray_get_prop:nnN {activity}{chkmarked}\l__ufrgscca_check_prop
+% \prop_gput:Nnn \l__ufrgscca_check_prop {#1}{\__ufrgscca_checkedbox:~\ #3}
+% \starray_gset_prop:nnV {activity}{chkmarked}\l__ufrgscca_check_prop
+%
+% \starray_get_prop:nnN {activity}{chkunmarked}\l__ufrgscca_check_prop
+% \prop_gput:Nnn \l__ufrgscca_check_prop {#1}{\__ufrgscca_uncheckedbox:~\ #3}
+% \starray_gset_prop:nnV {activity}{chkunmarked}\l__ufrgscca_check_prop
+%
+% \starray_get_prop:nnN {activity}{chkref}\l__ufrgscca_check_prop
+% \prop_gput:Nnn \l__ufrgscca_check_prop {#2}{#1}
+% \starray_gset_prop:nnV {activity}{chkref}\l__ufrgscca_check_prop
- \starray_get_prop:nnN {activity}{chkref}\l__ufrgscca_check_prop
- \prop_gput:Nnn \l__ufrgscca_check_prop {#2}{#1}
- \starray_gset_prop:nnV {activity}{chkref}\l__ufrgscca_check_prop
+ \starray_get_prop:nnN {activity}{chkID}\l__ufrgscca_chkID_tl
+ \prop_gput:cnn {l__ufrgscca_ \l__ufrgscca_chkID_tl _chkmarked_prop} {#1}{\__ufrgscca_checkedbox:~\ #3}
+ \prop_gput:cnn {l__ufrgscca_ \l__ufrgscca_chkID_tl _chkunmarked_prop} {#1}{\__ufrgscca_uncheckedbox:~\ #3}
+ \prop_gput:cnn {l__ufrgscca_ \l__ufrgscca_chkID_tl _chkref_prop} {#2}{#1}
}
\cs_generate_variant:Nn \prop_gput:Nnn {Nee}
@@ -798,9 +824,16 @@
\NewDocumentCommand{\checklist}{O{}m}{
\tl_if_blank:nF {#1}
{ \starray_set_iter_from_hash:nn {activity}{#1} }
- \starray_get_prop:nnN {student}{checklist}\l__ufrgscca_check_prop
- \starray_get_prop:nnN {activity}{chkmarked}\l__ufrgscca_checkB_prop
- \starray_get_prop:nnN {activity}{chkref}\l__ufrgscca_checkref_prop
+% \starray_get_prop:nnN {student}{checklist}\l__ufrgscca_check_prop
+% \starray_get_prop:nnN {activity}{chkmarked}\l__ufrgscca_checkB_prop
+% \starray_get_prop:nnN {activity}{chkref}\l__ufrgscca_checkref_prop
+ %% V-less : checklists as hash_.... prop
+ \starray_get_prop:nnN {student} {chkID} \l__ufrgscca_chkIDa_tl
+ \starray_get_prop:nnN {activity} {chkID} \l__ufrgscca_chkIDb_tl
+ \prop_set_eq:Nc \l__ufrgscca_check_prop {l__ufrgscca_ \l__ufrgscca_chkIDa_tl _checklist_prop}
+ \prop_set_eq:Nc \l__ufrgscca_checkB_prop {l__ufrgscca_ \l__ufrgscca_chkIDb_tl _chkmarked_prop}
+ \prop_set_eq:Nc \l__ufrgscca_checkref_prop {l__ufrgscca_ \l__ufrgscca_chkIDb_tl _chkref_prop}
+
\clist_map_inline:nn {#2}
{
\prop_get:NnNT \l__ufrgscca_checkref_prop {##1} \l__ufrgscca_checkref_tl
@@ -809,7 +842,9 @@
\prop_gput:Nee \l__ufrgscca_check_prop {\l__ufrgscca_checkref_tl} {\l__ufrgscca_checkB_tl}
}
}
- \starray_gset_prop:nnV {student}{checklist}{\l__ufrgscca_check_prop}
+% \starray_gset_prop:nnV {student}{checklist}{\l__ufrgscca_check_prop}
+ %% V-less : could be improved, direct reference
+ \prop_set_eq:cN {l__ufrgscca_ \l__ufrgscca_chkIDa_tl _checklist_prop} \l__ufrgscca_check_prop
}
\prop_new:N \l__ufrgscca_check_list_prop
@@ -819,8 +854,17 @@
\cs_new_protected:Npn \__ufrgscca_checktable_lines:nn #1#2 {
- \starray_get_prop:nnN {activity} {chkunmarked} \l__ufrgscca_checkA_prop
- \starray_get_prop:nnN {student}{checklist}\l__ufrgscca_check_prop
+% \starray_get_prop:nnN {activity} {chkunmarked} \l__ufrgscca_checkA_prop
+% \starray_get_prop:nnN {student} {checklist} \l__ufrgscca_check_prop
+
+ %% V-less : checklists as hash_.... prop
+ \starray_get_prop:nnN {student} {chkID} \l__ufrgscca_chkIDa_tl
+ \starray_get_prop:nnN {activity} {chkID} \l__ufrgscca_chkIDb_tl
+ \prop_set_eq:Nc \l__ufrgscca_check_prop {l__ufrgscca_ \l__ufrgscca_chkIDa_tl _checklist_prop}
+ \prop_set_eq:Nc \l__ufrgscca_checkA_prop {l__ufrgscca_ \l__ufrgscca_chkIDb_tl _chkunmarked_prop}
+
+% \prop_show:N \l__ufrgscca_check_prop
+% \prop_show:c {l__ufrgscca_ \l__ufrgscca_chkIDa_tl _checklist_prop}
\prop_map_inline:Nn \l__ufrgscca_check_prop
{ \prop_gput:Nnn \l__ufrgscca_checkA_prop {##1}{##2} }
diff --git a/macros/latex/contrib/ufrgscca/latex/ufrgscca-core.sty b/macros/latex/contrib/ufrgscca/latex/ufrgscca-core.sty
index 7a7f360279..f250c0d27c 100644
--- a/macros/latex/contrib/ufrgscca/latex/ufrgscca-core.sty
+++ b/macros/latex/contrib/ufrgscca/latex/ufrgscca-core.sty
@@ -12,7 +12,7 @@
%%
%% The Current Maintainer of this work is Alceu Frigeri
%%
-%% This is version {2.6} {2024/02/29}
+%% This is version {2.7} {2024/03/10}
%%
%% The list of files that compose this work can be found in the README.md file at
%% https://ctan.org/pkg/ufrgscca
@@ -27,8 +27,8 @@
\ProvidesExplPackage
{ufrgscca-core}
- {2024/02/29}
- {2.6}
+ {2024/03/10}
+ {2.7}
{UFRGS/CCA core commands}
@@ -42,8 +42,8 @@
{
name .code:n = {ufrgscca-core} ,
prefix .code:n = {ufrgscca} ,
- date .code:n = {2024/02/29},
- version .code:n = {2.6} ,
+ date .code:n = {2024/03/10},
+ version .code:n = {2.7} ,
description .code:n = {UFRGS/CCA~core~commands/data}
}
\cs_if_exist:NF \PkgInfo
@@ -116,6 +116,7 @@
carticle = ao(à) ,
Carticle = Ao(À) ,
remarks = ,
+ chkID = , %%% 'unique ID' for checklist
checklist = , %%% This shall be a property list of check items
brief = \BlankLines{6} ,
reason = \BlankLines{6} ,
@@ -267,17 +268,31 @@
week = {-semana-} ,
event = {-Descrição-} ,
} ,
+ chkID = , %%% 'unique ID' for checklists
chkmarked = , %%% This shall be a prop list of marked itens
chkunmarked = , %%% This shall be a prop list of unmarked itens
chkref = , %%% This shall be a prop list of ref itens
}
+%% workaround (V-less)
+%% => \starray_get_uniqueID {starray-ref} ....
+%% (might just be parser construct...) and use it to define a unique prop name.
+
+\tl_new:N \l__ufrgscca_tmpID_tl
\NewDocumentCommand{\NewActivity}{m} {
\starray_new_term:nn {activity}{#1}
\starray_new_term:nn {activity.coord}{}
- \starray_gset_prop:nnV {activity}{chkmarked}\c_empty_prop
- \starray_gset_prop:nnV {activity}{chkunmarked}\c_empty_prop
- \starray_gset_prop:nnV {activity}{chkref}\c_empty_prop
+ \starray_get_unique_id:nNTF {activity} \l__ufrgscca_tmpID_tl
+ {}
+ {}
+ \starray_gset_prop:nnV {activity}{chkID} \l__ufrgscca_tmpID_tl
+ \prop_new:c {l__ufrgscca_ \l__ufrgscca_tmpID_tl _chkmarked_prop}
+ \prop_new:c {l__ufrgscca_ \l__ufrgscca_tmpID_tl _chkunmarked_prop}
+ \prop_new:c {l__ufrgscca_ \l__ufrgscca_tmpID_tl _chkref_prop}
+% \prop_show:c {l__ufrgscca_ \l__ufrgscca_tmpID_tl _chkmarked_prop}
+% \starray_gset_prop:nnV {activity}{chkmarked}\c_empty_prop
+% \starray_gset_prop:nnV {activity}{chkunmarked}\c_empty_prop
+% \starray_gset_prop:nnV {activity}{chkref}\c_empty_prop
}
@@ -381,7 +396,12 @@
name = {#3~ #2} ,
}
\__ufrgscca_setgender:nn {student}{#4}
- \starray_gset_prop:nnV {student}{checklist}\c_empty_prop
+ \starray_get_unique_id:nNTF {student}\l__ufrgscca_tmpID_tl
+ {}
+ {}
+ \starray_gset_prop:nnV {student}{chkID} \l__ufrgscca_tmpID_tl
+ \prop_new:c {l__ufrgscca_ \l__ufrgscca_tmpID_tl _checklist_prop}
+ %\starray_gset_prop:nnV {student}{checklist}\c_empty_prop
}%
%
\NewDocumentCommand{\eDataSet}{m}{
diff --git a/macros/latex/contrib/ufrgscca/latex/ufrgscca-cover-ptBR.tex b/macros/latex/contrib/ufrgscca/latex/ufrgscca-cover-ptBR.tex
index e73a06aef2..b88c90d7b5 100644
--- a/macros/latex/contrib/ufrgscca/latex/ufrgscca-cover-ptBR.tex
+++ b/macros/latex/contrib/ufrgscca/latex/ufrgscca-cover-ptBR.tex
@@ -12,7 +12,7 @@
%%
%% The Current Maintainer of this work is Alceu Frigeri
%%
-%% This is version {2.6} {2024/02/29}
+%% This is version {2.7} {2024/03/10}
%%
%% The list of files that compose this work can be found in the README.md file at
%% https://ctan.org/pkg/ufrgscca
diff --git a/macros/latex/contrib/ufrgscca/latex/ufrgscca-cover.sty b/macros/latex/contrib/ufrgscca/latex/ufrgscca-cover.sty
index 0231265c6e..e4f32e9687 100644
--- a/macros/latex/contrib/ufrgscca/latex/ufrgscca-cover.sty
+++ b/macros/latex/contrib/ufrgscca/latex/ufrgscca-cover.sty
@@ -12,7 +12,7 @@
%%
%% The Current Maintainer of this work is Alceu Frigeri
%%
-%% This is version {2.6} {2024/02/29}
+%% This is version {2.7} {2024/03/10}
%%
%% The list of files that compose this work can be found in the README.md file at
%% https://ctan.org/pkg/ufrgscca
@@ -27,8 +27,8 @@
\ProvidesExplPackage
{ufrgscca-cover}
- {2024/02/29}
- {2.6}
+ {2024/03/10}
+ {2.7}
{UFRGS/CCA cover commands}
@@ -42,8 +42,8 @@
{
name .code:n = {ufrgscca-cover} ,
prefix .code:n = {ufrgscca} ,
- date .code:n = {2024/02/29},
- version .code:n = {2.6} ,
+ date .code:n = {2024/03/10},
+ version .code:n = {2.7} ,
description .code:n = {UFRGS/CCA~ cover~pages}
}
\cs_if_exist:NF \PkgInfo
diff --git a/macros/latex/contrib/ufrgscca/latex/ufrgscca-curr.sty b/macros/latex/contrib/ufrgscca/latex/ufrgscca-curr.sty
index afcdb1aabe..892d0f0e51 100644
--- a/macros/latex/contrib/ufrgscca/latex/ufrgscca-curr.sty
+++ b/macros/latex/contrib/ufrgscca/latex/ufrgscca-curr.sty
@@ -12,7 +12,7 @@
%%
%% The Current Maintainer of this work is Alceu Frigeri
%%
-%% This is version {2.6} {2024/02/29}
+%% This is version {2.7} {2024/03/10}
%%
%% The list of files that compose this work can be found in the README.md file at
%% https://ctan.org/pkg/ufrgscca
@@ -27,8 +27,8 @@
\ProvidesExplPackage
{ufrgscca-curr}
- {2024/02/29}
- {2.6}
+ {2024/03/10}
+ {2.7}
{UFRGS/CCA curricula commands}
%%%%%%%
@@ -41,8 +41,8 @@
{
name .code:n = {ufrgscca-curr} ,
prefix .code:n = {ufrgscca} ,
- date .code:n = {2024/02/29},
- version .code:n = {2.6} ,
+ date .code:n = {2024/03/10},
+ version .code:n = {2.7} ,
description .code:n = {UFRGS/CCA~ curricula~ commands}
}
\cs_if_exist:NF \PkgInfo
@@ -56,6 +56,18 @@
%%%%%%%
+%%%%%%%
+%%%
+%%% V-less nightmare TO BE DONE!
+%%% => convert all V referenced sequences into 'starray sub structures'
+%%% less efficient, but 'portable' and V-safe.
+%%%
+%%% => Alternative approach: convert a _seq into a clist then store it into starray (argh! double damm)
+%%% => or just use ..._clist instead of _seq (replacing all _seq that are stored in starrays by a _clist)
+%%%
+%%%%%%%
+
+
\starray_new:n {topics}
\starray_new:n {classes}
\starray_new:n {curricula}
@@ -65,7 +77,7 @@
self = ,
name = ,
color = ,
- class lst = , %list (sequence) of classes
+ uniqueID = , % to replace class list (V-less)
}
\starray_def_from_keyval:nn {classes}
@@ -76,9 +88,7 @@
summary = ,
topic = ,
remark = ,
- bib seq = ,
- bib basic seq = ,
- bib compl seq = ,
+ uniqueID = , % to replace the many V sequences (bib)
ref . struct = {
curr = ,
sem = ,
@@ -184,8 +194,13 @@
name = {#3} ,
color = {#1} ,
}
-% \seq_clear:N \l_tmpa_seq
- \starray_set_prop:nnV {topics}{class lst} \c_empty_seq
+ %% V-less : replacing / new seq
+ \starray_get_unique_id:nNTF {topics}\l__ufrgscca_uniqueID_tmpa_tl
+ {}
+ {\tl_set:Nn \l__ufrgscca_uniqueID_tmpa_tl {}}
+ \starray_set_prop:nnV {topics}{uniqueID} \l__ufrgscca_uniqueID_tmpa_tl
+ \seq_new:c {l__ufrgscca_curr_ \l__ufrgscca_uniqueID_tmpa_tl _seq}
+
}
\tl_new:N \l__ufrgscca_default_topic_tl
@@ -203,16 +218,22 @@
name = {#4} ,
topic = {#1} ,
}
-% \seq_clear:N \l_tmpa_seq
- \starray_set_prop:nnV {classes}{bib seq} \c_empty_seq
- \starray_set_prop:nnV {classes}{bib basic seq} \c_empty_seq
- \starray_set_prop:nnV {classes}{bib compl seq} \c_empty_seq
+ %% V-less : new
+ \starray_get_unique_id:nNTF {classes}\l__ufrgscca_uniqueID_tmpb_tl
+ {}
+ {\tl_set:Nn \l__ufrgscca_uniqueID_tmpb_tl {}}
+ \starray_set_prop:nnV {classes}{uniqueID} \l__ufrgscca_uniqueID_tmpb_tl
+ \seq_new:c {l__ufrgscca_curr_ \l__ufrgscca_uniqueID_tmpb_tl _bib _seq}
+ \seq_new:c {l__ufrgscca_curr_ \l__ufrgscca_uniqueID_tmpb_tl _bib basic _seq}
+ \seq_new:c {l__ufrgscca_curr_ \l__ufrgscca_uniqueID_tmpb_tl _bib compl _seq}
+
\starray_set_iter_from_hash:nn {topics}{#1}
- \starray_get_prop:nnN {topics}{class lst} \l_tmpa_seq
- \seq_put_right:Nn \l_tmpa_seq{#2}
- \starray_set_prop:nnV {topics}{class lst} \l_tmpa_seq
+ %% V-less : new seq
+ \starray_get_prop:nnN {topics}{uniqueID} \l__ufrgscca_uniqueID_tmpa_tl
+ \seq_put_right:cn {l__ufrgscca_curr_ \l__ufrgscca_uniqueID_tmpa_tl _seq} {#2}
}
+
\NewDocumentCommand{\csummary}{m}
{
\starray_set_prop:nnn {classes}{summary}{#1}
@@ -226,31 +247,30 @@
\NewDocumentCommand{\bibdef}{O{main}m}
{
+ %% V-less
+ \starray_get_prop:nnN {classes}{uniqueID} \l__ufrgscca_uniqueID_tmpb_tl
+
\str_case:nnF {#1}
{
{main}
{
- \starray_get_prop:nnN {classes}{bib seq} \l_tmpa_seq
- \seq_put_right:Nn \l_tmpa_seq {#2}
- \starray_set_prop:nnV {classes}{bib seq} \l_tmpa_seq
+ %% V-less
+ \seq_gput_right:cn {l__ufrgscca_curr_ \l__ufrgscca_uniqueID_tmpb_tl _bib _seq} {#2}
}
{basic}%{ \starray_get_prop:nnN {classes}{bib basic seq} \l_tmpa_seq }
{
- \starray_get_prop:nnN {classes}{bib basic seq} \l_tmpa_seq
- \seq_put_right:Nn \l_tmpa_seq {#2}
- \starray_set_prop:nnV {classes}{bib basic seq} \l_tmpa_seq
+ %% V-less
+ \seq_gput_right:cn {l__ufrgscca_curr_ \l__ufrgscca_uniqueID_tmpb_tl _bib basic _seq} {#2}
}
{compl}%{ \starray_get_prop:nnN {classes}{bib compl seq} \l_tmpa_seq }
{
- \starray_get_prop:nnN {classes}{bib compl seq} \l_tmpa_seq
- \seq_put_right:Nn \l_tmpa_seq {#2}
- \starray_set_prop:nnV {classes}{bib compl seq} \l_tmpa_seq
+ %% V-less
+ \seq_gput_right:cn {l__ufrgscca_curr_ \l__ufrgscca_uniqueID_tmpb_tl _bib compl _seq} {#2}
}
}
{
- \starray_get_prop:nnN {classes}{bib seq} \l_tmpa_seq
- \seq_put_right:Nn \l_tmpa_seq {#2}
- \starray_set_prop:nnV {classes}{bib seq} \l_tmpa_seq
+ %% V-less
+ \seq_put_right:cn {l__ufrgscca_curr_ \l__ufrgscca_uniqueID_tmpb_tl _bib _seq} {#2}
}
}
@@ -382,38 +402,36 @@
\starray_get_prop:nnN {classes}{summary} \l__ufrgscca_tmp_summary_tl
\use:e { & & & & & \exp_not:N \smaller \l__ufrgscca_tmp_summary_tl\\*}
+
+ %% V-less
+ \starray_get_prop:nnN {classes}{uniqueID} \l_tmpa_tl
+ \tl_gset:Ne \l__ufrgscca_uniqueID_tmpb_tl {\l_tmpa_tl}
%% bibliography I
- \starray_get_prop:nnN {classes}{bib seq} \l__ufrgscca_tmp_bib_seq
- \seq_gset_eq:NN \l__ufrgscca_tmp_bibB_seq \l__ufrgscca_tmp_bib_seq
- \seq_if_empty:NF \l__ufrgscca_tmp_bibB_seq
- {
+ \seq_if_empty:cF {l__ufrgscca_curr_ \l__ufrgscca_uniqueID_tmpb_tl _bib _seq}
+ {
& & & & \multicolumn{2}{J{11cm}}{\smaller\scshape Bibliografia~ Básica~ Essencial}\\*
- \seq_map_inline:Nn \l__ufrgscca_tmp_bibB_seq
+ \seq_map_inline:cn {l__ufrgscca_curr_ \l__ufrgscca_uniqueID_tmpb_tl _bib _seq}
{
& & & & & \smaller\textopenbullet ~\ ~ ##1\\
}
}
%% bibliography II
- \starray_get_prop:nnN {classes}{bib basic seq} \l__ufrgscca_tmp_bib_seq
- \seq_gset_eq:NN \l__ufrgscca_tmp_bibB_seq \l__ufrgscca_tmp_bib_seq
- \seq_if_empty:NF \l__ufrgscca_tmp_bibB_seq
+ \seq_if_empty:cF {l__ufrgscca_curr_ \l__ufrgscca_uniqueID_tmpb_tl _bib basic _seq}
{
& & & & \multicolumn{2}{J{11cm}}{\smaller\scshape Bibliografia~ Básica}\\*
- \seq_map_inline:Nn \l__ufrgscca_tmp_bibB_seq
+ \seq_map_inline:cn {l__ufrgscca_curr_ \l__ufrgscca_uniqueID_tmpb_tl _bib basic _seq}
{
& & & & & \smaller\textopenbullet ~\ ~ ##1\\
}
}
%% bibliography III
- \starray_get_prop:nnN {classes}{bib compl seq} \l__ufrgscca_tmp_bib_seq
- \seq_gset_eq:NN \l__ufrgscca_tmp_bibB_seq \l__ufrgscca_tmp_bib_seq
- \seq_if_empty:NF \l__ufrgscca_tmp_bibB_seq
+ \seq_if_empty:cF {l__ufrgscca_curr_ \l__ufrgscca_uniqueID_tmpb_tl _bib compl _seq}
{
& & & & \multicolumn{2}{J{11cm}}{\smaller\scshape Bibliografia~ Complementar}\\*
- \seq_map_inline:Nn \l__ufrgscca_tmp_bibB_seq
+ \seq_map_inline:cn {l__ufrgscca_curr_ \l__ufrgscca_uniqueID_tmpb_tl _bib compl _seq}
{
& & & & & \smaller\textopenbullet ~\ ~ ##1\\
}
@@ -445,8 +463,10 @@
\tl_set:Nn \l__ufrgscca_tmp_color_tl {black}
}
\use:e { & \exp_not:N \multicolumn{2}{J{11cm}}{\exp_not:N \textcolor{\l__ufrgscca_tmp_color_tl}{\exp_not:N \textbf{\l__ufrgscca_tmp_name_tl} }}}\\\hline
- \starray_get_prop:nnN {topics}{class lst} \l__ufrgscca_tmp_classlst_seq
- \seq_map_inline:Nn \l__ufrgscca_tmp_classlst_seq
+
+ %% V-less : to be replaced
+ \starray_get_prop:nnN {topics}{uniqueID} \l__ufrgscca_uniqueID_tmpa_tl
+ \seq_map_inline:cn {l__ufrgscca_curr_ \l__ufrgscca_uniqueID_tmpa_tl _seq}
{
\starray_set_iter_from_hash:nn {classes}{##1}
\starray_get_prop:nnN {classes}{name} \l__ufrgscca_tmp_name_tl
diff --git a/macros/latex/contrib/ufrgscca/latex/ufrgscca-forms.sty b/macros/latex/contrib/ufrgscca/latex/ufrgscca-forms.sty
index 7d7916ba0f..1406013d02 100644
--- a/macros/latex/contrib/ufrgscca/latex/ufrgscca-forms.sty
+++ b/macros/latex/contrib/ufrgscca/latex/ufrgscca-forms.sty
@@ -12,7 +12,7 @@
%%
%% The Current Maintainer of this work is Alceu Frigeri
%%
-%% This is version {2.6} {2024/02/29}
+%% This is version {2.7} {2024/03/10}
%%
%% The list of files that compose this work can be found in the README.md file at
%% https://ctan.org/pkg/ufrgscca
@@ -27,8 +27,8 @@
\ProvidesExplPackage
{ufrgscca-forms}
- {2024/02/29}
- {2.6}
+ {2024/03/10}
+ {2.7}
{UFRGS/CCA forms commands}
@@ -42,8 +42,8 @@
{
name .code:n = {ufrgscca-forms} ,
prefix .code:n = {ufrgscca} ,
- date .code:n = {2024/02/29},
- version .code:n = {2.6} ,
+ date .code:n = {2024/03/10},
+ version .code:n = {2.7} ,
description .code:n = {UFRGS/CCA~ forms~commands}
}
\cs_if_exist:NF \PkgInfo
diff --git a/macros/latex/contrib/ufrgscca/latex/ufrgscca-forms.tex b/macros/latex/contrib/ufrgscca/latex/ufrgscca-forms.tex
index 8e225d5edf..d4cb25ac4d 100644
--- a/macros/latex/contrib/ufrgscca/latex/ufrgscca-forms.tex
+++ b/macros/latex/contrib/ufrgscca/latex/ufrgscca-forms.tex
@@ -12,7 +12,7 @@
%%
%% The Current Maintainer of this work is Alceu Frigeri
%%
-%% This is version {2.6} {2024/02/29}
+%% This is version {2.7} {2024/03/10}
%%
%% The list of files that compose this work can be found in the README.md file at
%% https://ctan.org/pkg/ufrgscca
@@ -23,6 +23,19 @@
%% CCA stands for "Control and Automation Engineering Course" (Portuguese acronym)
%%%==============================================================================
+\ExplSyntaxOn
+ \tl_new:N \tmpTabA
+ \tl_new:N \tmpTabB
+ \tl_new:N \tmpTabC
+ \tl_new:N \tmpTabD
+ \tl_new:N \tmpTabE
+ \tl_new:N \tmpTabEx
+ \tl_new:N \tmpTabF
+ \tl_new:N \tmpTabG
+ \tl_new:N \tmpTabMult
+ \tl_new:N \tmpTabAll
+\ExplSyntaxOff
+
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
@@ -881,7 +894,9 @@ A nota (variando de zero a dez) atribuída por cada membro da banca examinadora
{%%
\footnotesize%
\begin{center}%
- \begin{tabular}{p{\UseConst{report.tabA*}}@{\ }p{\UseConst{report.tabB*}}@{\ }c}%\hline%
+ \GetConst{report.tabA*}{\tmpTabA}
+ \GetConst{report.tabB*}{\tmpTabB}
+ \begin{tabular}{p{\tmpTabA}@{\ }p{\tmpTabB}@{\ }c}%\hline%
& \UseLabel{board} \\\hline%
\IfBooleanTF{#1}
{
@@ -906,14 +921,16 @@ A nota (variando de zero a dez) atribuída por cada membro da banca examinadora
{\footnotesize%
\begin{center}%
\resizebox{\textwidth}{!}{%
+ \GetConst{report.tabA}{\tmpTabA}
+ \GetConst{report.tabB}{\tmpTabB}
\IfBooleanTF{#1}
{%
- \begin{tabular}{p{\UseConst{report.tabA}}@{\ }p{\UseConst{report.tabB}}@{\ }c@{\ }c@{\ }c@{\ }p{0pt}@{}c@{\ }c}
+ \begin{tabular}{p{\tmpTabA}@{\ }p{\tmpTabB}@{\ }c@{\ }c@{\ }c@{\ }p{0pt}@{}c@{\ }c}
\HeaderLine{II}
\studentLine*
}
{%
- \begin{tabular}{p{\UseConst{report.tabA}}@{\ }p{\UseConst{report.tabB}}@{\ }c@{\ }c@{\ }c@{\ }c@{\ }c@{\ }c}
+ \begin{tabular}{p{\tmpTabA}@{\ }p{\tmpTabB}@{\ }c@{\ }c@{\ }c@{\ }c@{\ }c@{\ }c}
\HeaderLine{I}
\studentLine
}%
@@ -1080,6 +1097,14 @@ A nota (variando de zero a dez) atribuída por cada membro da banca examinadora
\cs_new_protected:Npn \reportBody #1#2
{
+ \GetConst{report.tabA}{\tmpTabA}
+ \GetConst{report.tabB}{\tmpTabB}
+ \GetConst{report.tabC}{\tmpTabC}
+ \GetConst{report.tabD}{\tmpTabD}
+ \GetConst{report.tabE}{\tmpTabE}
+ \GetConst{report.tabEx}{\tmpTabEx}
+ \GetConst{report.tabF}{\tmpTabF}
+ \GetConst{report.tabG}{\tmpTabG}
\str_case:nn {#1}
{
{I}
@@ -1087,14 +1112,14 @@ A nota (variando de zero a dez) atribuída por cada membro da banca examinadora
\ActivitySelect{tccI}
\begin{longtable}
{
- p{\UseConst{report.tabA}}@{\ }
- p{\UseConst{report.tabB}}@{\ }
- p{\UseConst{report.tabC}}@{\ }
- p{\UseConst{report.tabD}}@{\ }
- p{\UseConst{report.tabE}}@{\ }
- p{\UseConst{report.tabEx}}@{\ }
- p{\UseConst{report.tabF}}@{\ }
- p{\UseConst{report.tabG}}
+ p{\tmpTabA}@{\ }
+ p{\tmpTabB}@{\ }
+ p{\tmpTabC}@{\ }
+ p{\tmpTabD}@{\ }
+ p{\tmpTabE}@{\ }
+ p{\tmpTabEx}@{\ }
+ p{\tmpTabF}@{\ }
+ p{\tmpTabG}
}
}
{II}
@@ -1102,25 +1127,26 @@ A nota (variando de zero a dez) atribuída por cada membro da banca examinadora
\ActivitySelect{tccII}
\begin{longtable}
{
- p{\UseConst{report.tabA}}@{\ }
- p{\UseConst{report.tabB}}@{\ }
- p{\UseConst{report.tabC}}@{\ }
- p{\UseConst{report.tabD}}@{\ }
- p{\UseConst{report.tabE}}@{\ }
+ p{\tmpTabA}@{\ }
+ p{\tmpTabB}@{\ }
+ p{\tmpTabC}@{\ }
+ p{\tmpTabD}@{\ }
+ p{\tmpTabE}@{\ }
p{0pt}@{}
- p{\UseConst{report.tabF}}@{\ }
- p{\UseConst{report.tabG}}
+ p{\tmpTabF}@{\ }
+ p{\tmpTabG}
}
}
}
\HeaderLine{#1}
+ \GetConst{report.tabMult.#1}{\tmpTabMult}
\seq_map_inline:Nn \l__ufrgscca_baselist_graded_seq
{
\studentselect{##1}
% \__ufrgscca_student_emptyfields_if_none:
\__ufrgscca_emptyterm_if_none:nnn {3}{student.reviewer}{}
#2\\\hline
- \studentExtLine{7}{\UseConst{report.tabMult.#1}}\\\hline
+ \studentExtLine{7}{\tmpTabMult}\\\hline
\bool_if:nT {\l__ufrgscca_checklist_bool}
{
\multicolumn{7}{l}
@@ -1132,17 +1158,17 @@ A nota (variando de zero a dez) atribuída por cada membro da banca examinadora
}
}
\__ufrgscca_miss_case:nnnnn
- {7} {report.tabMult.#1}
+ {7} {\tmpTabMult}
{\l__ufrgscca_baselist_ff_seq}
{Desistentes~ com~ conceito~FF~ (2o ~ semestre)}
{red}
\__ufrgscca_miss_case:nnnnn
- {7} {report.tabMult.#1}
+ {7} {\tmpTabMult}
{\l__ufrgscca_baselist_dismiss_seq}
{Desistentes~ sem~ conceito~ (1o ~ semestre)}
{magenta}
\__ufrgscca_miss_case:nnnnn
- {7} {report.tabMult.#1}
+ {7} {\tmpTabMult}
{\l__ufrgscca_baselist_other_seq}
{Outros~ (não~ matriculados)}
{teal}
@@ -1161,7 +1187,7 @@ A nota (variando de zero a dez) atribuída por cada membro da banca examinadora
\__ufrgscca_emptyterm_if_none:nnn {3}{student.reviewer}{}
&\\*
\multicolumn{#1}{l}{\textbf{\color{#5}\DataFields{student}{name}}}\\*
- \studentExtLine{#1}{\UseConst{#2}}\\*
+ \studentExtLine{#1}{#2}\\*
\multicolumn{#1}{l}{\studentCoadvLabelCase}\\ \hline
}
}
@@ -1230,7 +1256,12 @@ A nota (variando de zero a dez) atribuída por cada membro da banca examinadora
%%%
\SetForm{boards}{opening}{ %
{\footnotesize
- \begin{longtable}{p{\UseConst{board.tabA}}p{\UseConst{board.tabB}}p{\UseConst{board.tabC}}p{\UseConst{board.tabD}}}%
+ \GetConst{board.tabA}{\tmpTabA}
+ \GetConst{board.tabB}{\tmpTabB}
+ \GetConst{board.tabC}{\tmpTabC}
+ \GetConst{board.tabD}{\tmpTabD}
+ \GetConst{board.tabAll}{\tmpTabAll}
+ \begin{longtable}{p{\tmpTabA}p{\tmpTabB}p{\tmpTabC}p{\tmpTabD}}%
%\multicolumn{4}{c}{\UseTerm{board.title}}\\\hline
\hline
\tl_gclear:N \l__ufrgscca_daytmpa_tl
@@ -1260,7 +1291,7 @@ A nota (variando de zero a dez) atribuída por cada membro da banca examinadora
&& \DataFields{student.reviewer[2]}{name} \\*
&& \DataFields{student.reviewer[3]}{name} \\*
&& ({\DataFields{student.altreviewer[1]}{name}}) \\*
- \multicolumn{4}{p{\UseConst{board.tabAll}}}
+ \multicolumn{4}{p{\tmpTabAll}}
{\textsc{Título:}\ \emph{\DataFields{student}{worktitle}}}\\\hline
}
\end{longtable}
diff --git a/macros/latex/contrib/ufrgscca/latex/ufrgscca-lists.sty b/macros/latex/contrib/ufrgscca/latex/ufrgscca-lists.sty
index 600d25e920..ab15881f3f 100644
--- a/macros/latex/contrib/ufrgscca/latex/ufrgscca-lists.sty
+++ b/macros/latex/contrib/ufrgscca/latex/ufrgscca-lists.sty
@@ -12,7 +12,7 @@
%%
%% The Current Maintainer of this work is Alceu Frigeri
%%
-%% This is version {2.6} {2024/02/29}
+%% This is version {2.7} {2024/03/10}
%%
%% The list of files that compose this work can be found in the README.md file at
%% https://ctan.org/pkg/ufrgscca
@@ -27,8 +27,8 @@
\ProvidesExplPackage
{ufrgscca-lists}
- {2024/02/29}
- {2.6}
+ {2024/03/10}
+ {2.7}
{UFRGS/CCA auxiliary lists commands}
@@ -42,8 +42,8 @@
{
name .code:n = {ufrgscca-lists} ,
prefix .code:n = {ufrgscca} ,
- date .code:n = {2024/02/29} ,
- version .code:n = {2.6} ,
+ date .code:n = {2024/03/10} ,
+ version .code:n = {2.7} ,
description .code:n = {UFRGS/CCA~Auxiliary~ lists~ commands}
}
\cs_if_exist:NF \PkgInfo
diff --git a/macros/latex/contrib/ufrgscca/latex/ufrgscca-ppc.sty b/macros/latex/contrib/ufrgscca/latex/ufrgscca-ppc.sty
index eb8b23dcb0..75d1ba6f22 100644
--- a/macros/latex/contrib/ufrgscca/latex/ufrgscca-ppc.sty
+++ b/macros/latex/contrib/ufrgscca/latex/ufrgscca-ppc.sty
@@ -12,7 +12,7 @@
%%
%% The Current Maintainer of this work is Alceu Frigeri
%%
-%% This is version {2.6} {2024/02/29}
+%% This is version {2.7} {2024/03/10}
%%
%% The list of files that compose this work can be found in the README.md file at
%% https://ctan.org/pkg/ufrgscca
@@ -27,8 +27,8 @@
\ProvidesExplPackage
{ufrgscca-ppc}
- {2024/02/29}
- {2.6}
+ {2024/03/10}
+ {2.7}
{UFRGS/CCA PPC commands}
%%%%%%%
@@ -41,8 +41,8 @@
{
name .code:n = {ufrgscca-ppc} ,
prefix .code:n = {ufrgscca} ,
- date .code:n = {2024/02/29},
- version .code:n = {2.6} ,
+ date .code:n = {2024/03/10},
+ version .code:n = {2.7} ,
description .code:n = {UFRGS/CCA~ auxiliary~ PPC-related~ (indicators)~ commands}
}
\cs_if_exist:NF \PkgInfo
@@ -56,6 +56,17 @@
%%%%%%%
+%%%%%%%
+%%%
+%%% V-less nightmare TO BE DONE!
+%%% => convert all V referenced sequences into 'starray sub structures'
+%%% less efficient, but 'portable' and V-safe.
+%%%
+%%% => Alternative approach: convert a _seq into a clist then store it into starray (argh! double damm)
+%%% => or just use ..._clist instead of _seq (replacing all _seq that are stored in starrays by a _clist)
+%%%
+%%%%%%%
+
\keys_define:nn { ufrgscca / ppc}
{
@@ -103,7 +114,7 @@
self = ,
view = \c_true_bool ,
has_lst = \c_false_bool ,
- seqlst = , %this is going to be a sequence of 'ind'
+ seqID = , %this will have an unique hash (for a sequence)
ind.struct =
{
self = ,
@@ -115,7 +126,7 @@
is_section = \c_false_bool ,
is_subsection = \c_false_bool ,
cnt = 0 , %auxiliar 'counter' (num of references)
- seqlst = , %auxiliar list (references' list)
+ seqID = , %this will have an unique hash (for a sequence)
labelref = , %this will contain the 'hyperref label' (at doc's end) to be used.
ref.struct =
{
@@ -143,15 +154,20 @@
}
+\tl_new:N \l__ufrgscca_uniqueID_tmpa_tl
+\tl_new:N \l__ufrgscca_uniqueID_tmpb_tl
\NewDocumentCommand{\declareindicator}{st+O{noref}mmm}
{
%#3: status #4:org #5:mark #6:short text
\starray_set_iter_from_hash:nnF {indicator}{#4}
{
\starray_new_term:nn {indicator}{#4}
- \seq_clear:N \l_tmpa_seq
- \starray_set_prop:nnV {indicator}{seqlst}{\l_tmpa_seq}
- %\seq_new:c {l__ufrgscca_ind_ #4 _seq}
+ \starray_get_unique_id:nNTF {indicator}\l__ufrgscca_uniqueID_tmpa_tl
+ {}
+ {\tl_set:Nn \l__ufrgscca_uniqueID_tmpa_tl {}}
+ \starray_set_prop:nnV {indicator}{seqID}\l__ufrgscca_uniqueID_tmpa_tl
+ \seq_new:c {l__ufrgscca_ind_ \l__ufrgscca_uniqueID_tmpa_tl _seq}
+
\starray_set_prop:nnn {indicator}{self}{#4}
}
\starray_new_term:nn {indicator.ind}{@#5}
@@ -161,29 +177,26 @@
status = {#3} ,
self = {#5} ,
labelref = {@ufrgscca@ #4 @ #5} , %% to be issued when "printing the indicators' list"
- %seqlst = {l__ufrgscca_ind_ #4 _ #5 _seq} ,
- %cnt = {l__ufrgscca_ind_ #4 _ #5 _cnt_int} ,
}
- \seq_clear:N \l_tmpa_seq
- \starray_set_prop:nnV {indicator.ind}{seqlst}{\l_tmpa_seq}
- %\seq_new:c {l__ufrgscca_ind_ #4 _ #5 _seq}
- %\int_new:c {l__ufrgscca_ind_ #4 _ #5 _cnt_int}
+ \starray_get_unique_id:nNTF {indicator.ind}\l__ufrgscca_uniqueID_tmpb_tl
+ {}
+ {\tl_set:Nn \l__ufrgscca_uniqueID_tmpb_tl {}}
+ \starray_set_prop:nnV {indicator.ind}{seqID}\l__ufrgscca_uniqueID_tmpb_tl
+ \seq_new:c {l__ufrgscca_ind_ \l__ufrgscca_uniqueID_tmpb_tl _seq}
\IfBooleanTF{#1}
{
- \starray_get_prop:nnN {indicator}{seqlst}\l_tmpa_seq
- \seq_put_right:Nn \l_tmpa_seq {@#5}
- \starray_set_prop:nnV {indicator}{seqlst}\l_tmpa_seq
- %\seq_put_right:cn {l__ufrgscca_ind_ #4 _seq}{@#5}
+ %% V-less : 'unique' seq
+ \seq_put_right:cn {l__ufrgscca_ind_ \l__ufrgscca_uniqueID_tmpa_tl _seq}{@#5}
+
\starray_set_prop:nnn {indicator.ind}{is_section}{\c_true_bool}
\starray_set_prop:nnn {indicator}{has_lst}{\c_true_bool}
}
{}
\IfBooleanTF{#2}
{
- \starray_get_prop:nnN {indicator}{seqlst}\l_tmpa_seq
- \seq_put_right:Nn \l_tmpa_seq {@#5}
- \starray_set_prop:nnV {indicator}{seqlst}\l_tmpa_seq
- %\seq_put_right:cn {l__ufrgscca_ind_ #4 _seq}{@#5}
+ %% V-less : 'unique' seq
+ \seq_put_right:cn {l__ufrgscca_ind_ \l__ufrgscca_uniqueID_tmpa_tl _seq}{@#5}
+
\starray_set_prop:nnn {indicator.ind}{is_subsection}{\c_true_bool}
\starray_set_prop:nnn {indicator}{has_lst}{\c_true_bool}
}
@@ -212,8 +225,9 @@
{
\starray_set_iter_from_hash:nnT {indicator}{#3}
{
- \starray_get_prop:nnN {indicator}{seqlst}\l_tmpa_seq
- \seq_map_inline:Nn \l_tmpa_seq
+ %% V-less : new seq
+ \starray_get_prop:nnN {indicator}{seqID}\l__ufrgscca_uniqueID_tmpa_tl
+ \seq_map_inline:cn {l__ufrgscca_ind_ \l__ufrgscca_uniqueID_tmpa_tl _seq}
{
\starray_set_iter_from_hash:nn {indicator.ind}{##1}
\starray_term_syntax:n {indicator.ind}
@@ -376,12 +390,14 @@
{\color{\l__ufrgscca_txtcolor_tl}\starray_get_prop:nn {indicator.ind}{short} \dotfill \normalsize\starray_get_prop:nn {indicator.ind}{status}}
\newline \starray_get_prop:nn {indicator.ind}{long} \starray_get_prop:nn {indicator.ind}{extra}
- \starray_get_prop:nnN {indicator.ind}{seqlst} \l_tmpa_seq
- \seq_if_empty:NF \l_tmpa_seq
+ %% V-less : new seq
+ \starray_get_prop:nnN {indicator.ind}{seqID}\l__ufrgscca_uniqueID_tmpb_tl
+ \seq_if_empty:cF {l__ufrgscca_ind_ \l__ufrgscca_uniqueID_tmpb_tl _seq}
{
\newline
\tl_set:Nn \l_tmpa_tl {} .\dotfill
- \seq_map_inline:Nn \l_tmpa_seq
+ %% V-less : new seq
+ \seq_map_inline:cn {l__ufrgscca_ind_ \l__ufrgscca_uniqueID_tmpb_tl _seq}
{
\l_tmpa_tl \ref{##1} ~(\pageref{##1})
\tl_set:Nn \l_tmpa_tl {,~}
@@ -466,13 +482,20 @@
{
\starray_gset_prop:nnn {indicator.ind}{status}{#2}
}
- \starray_get_prop:nnN {indicator.ind}{seqlst} \l_tmpa_seq
+ %% V-less : replacing / new seq
+ \starray_get_unique_id:nNTF {indicator.ind}\l__ufrgscca_uniqueID_tmpb_tl
+ {}
+ {\tl_set:Nn \l__ufrgscca_uniqueID_tmpb_tl {}}
+ % {l__ufrgscca_ind_ \l__ufrgscca_uniqueID_tmpb_tl _seq}
+
\starray_get_prop:nnN {indicator.ind}{cnt} \l_tmpb_tl
\int_set:Nn \l_tmpa_int {\l_tmpb_tl + 1}
\starray_set_prop:nnV {indicator.ind}{cnt} \l_tmpa_int
\tl_set:Ne \l__ufrgscca_tmp_indref_tl {@indlabel@ #3 @ #4 - \int_use:N \l_tmpa_int }
- \seq_put_right:Ne \l_tmpa_seq{\l__ufrgscca_tmp_indref_tl}
- \starray_set_prop:nnV {indicator.ind}{seqlst} \l_tmpa_seq
+
+ \seq_put_right:ce {l__ufrgscca_ind_ \l__ufrgscca_uniqueID_tmpb_tl _seq} {\l__ufrgscca_tmp_indref_tl}
+
+
\label{\l__ufrgscca_tmp_indref_tl}
\starray_term_syntax:n {indicator}
\bool_if:nT {\starray_parsed_get_prop:n {view}}
diff --git a/macros/latex/contrib/ufrgscca/latex/ufrgscca-terms-en.tex b/macros/latex/contrib/ufrgscca/latex/ufrgscca-terms-en.tex
index 8223ae33db..040dbb0fa0 100644
--- a/macros/latex/contrib/ufrgscca/latex/ufrgscca-terms-en.tex
+++ b/macros/latex/contrib/ufrgscca/latex/ufrgscca-terms-en.tex
@@ -12,7 +12,7 @@
%%
%% The Current Maintainer of this work is Alceu Frigeri
%%
-%% This is version {2.6} {2024/02/29}
+%% This is version {2.7} {2024/03/10}
%%
%% The list of files that compose this work can be found in the README.md file at
%% https://ctan.org/pkg/ufrgscca
diff --git a/macros/latex/contrib/ufrgscca/latex/ufrgscca-terms-ptBR.tex b/macros/latex/contrib/ufrgscca/latex/ufrgscca-terms-ptBR.tex
index 14d59b4505..c0f1de91cc 100644
--- a/macros/latex/contrib/ufrgscca/latex/ufrgscca-terms-ptBR.tex
+++ b/macros/latex/contrib/ufrgscca/latex/ufrgscca-terms-ptBR.tex
@@ -12,7 +12,7 @@
%%
%% The Current Maintainer of this work is Alceu Frigeri
%%
-%% This is version {2.6} {2024/02/29}
+%% This is version {2.7} {2024/03/10}
%%
%% The list of files that compose this work can be found in the README.md file at
%% https://ctan.org/pkg/ufrgscca
diff --git a/macros/latex/contrib/ufrgscca/latex/ufrgscca.cls b/macros/latex/contrib/ufrgscca/latex/ufrgscca.cls
index 5a5af3cbbe..eaa190443c 100644
--- a/macros/latex/contrib/ufrgscca/latex/ufrgscca.cls
+++ b/macros/latex/contrib/ufrgscca/latex/ufrgscca.cls
@@ -12,7 +12,7 @@
%%
%% The Current Maintainer of this work is Alceu Frigeri
%%
-%% This is version {2.6} {2024/02/29}
+%% This is version {2.7} {2024/03/10}
%%
%% The list of files that compose this work can be found in the README.md file at
%% https://ctan.org/pkg/ufrgscca
@@ -27,8 +27,8 @@
\ProvidesExplClass
{ufrgscca}
- {2024/02/29}
- {2.6}
+ {2024/03/10}
+ {2.7}
{UFRGS/CCA class}
@@ -42,8 +42,8 @@
{
name .code:n = {ufrgscca} ,
prefix .code:n = {ufrgscca} ,
- date .code:n = {2024/02/29},
- version .code:n = {2.6} ,
+ date .code:n = {2024/03/10},
+ version .code:n = {2.7} ,
description .code:n = {UFRGS/CCA~a~report~based~class~bundle}
}
\cs_if_exist:NF \PkgInfo
@@ -69,7 +69,7 @@
%%%%%%%%%%%%%%%%%%%%%%
%%%
%%% TODO: to be decided, where to leave that !!
-%%% general purpose _propeties !!
+%%% general purpose _properties !!
%%%
%%%%%%%%%%%%%%%%%%%%%%
@@ -140,6 +140,12 @@
\cs_new:Npn \UseConst #1
{ \prop_item:Ne \l__ufrgscca_const_prop {#1} }
+\NewDocumentCommand{\GetConst}{mm}
+ {
+ \prop_get:NnNTF \l__ufrgscca_const_prop {#1} \l_tmpa_tl
+ {\tl_gset:Ne #2 \l_tmpa_tl}
+ {\tl_gset:Nn #2 {}}
+ }
\bool_new:N \l__ufrgscca_repeatfields_bool
\bool_new:N \l__ufrgscca_timesroman_bool