Compare commits

..

6 Commits

Author SHA1 Message Date
Bastien Dumont
7f39828d3f Merge branch 'no-early-expansion'
Prevent early expansion of \crossrefenum
2023-02-20 17:43:19 +01:00
Bastien Dumont
96356e74fe Updated version number and date in crossrefenum.tex too 2023-02-20 11:41:44 +01:00
Bastien Dumont
62d344c3d5 Updated version and changelog 2023-02-20 11:39:26 +01:00
Bastien Dumont
1e9b8c33d8 Protected \crossrefenum against early expansion.
It occured in ConTeXt in a \footnote with \setupinteraction[state=start].'
2023-02-20 11:35:41 +01:00
Bastien Dumont
9838ed6166 about the fact that all significant changes must be made in crossrefenum.tex directly, not in the wrapper files. 2023-02-20 11:19:41 +01:00
Bastien Dumont
30adbaa3f3 Removed useless .. in t-crossrefenum.tex
It seems that t-crossrefenum.tex and crossrefenum.sty cannot be made to load the file crossrefenum.tex that is in the development repository for the base path will always be the working directory of the main compiled file.
2023-02-20 11:10:49 +01:00
5 changed files with 25 additions and 5 deletions

View File

@ -1,3 +1,7 @@
## Changes ## Changes
### 2022/11/11: Version 1.0 ### 2022/11/11: Version 1.0
### 2023/02/20: Version 1.0.1
`\crossrefenum` is now protected against early expansion.

View File

@ -1,4 +1,4 @@
# crossrefenum 2022/11/11 v1.0 # crossrefenum 2023/02/20 v1.0.1
Smart typesetting of enumerated cross-references for various TeX formats. Smart typesetting of enumerated cross-references for various TeX formats.

View File

@ -1,3 +1,6 @@
% This file cannot be loaded in main-test.tex for it would load the version of crossrefenum.tex
% installed in the texmf tree.
% As a consequence, it should not be changed to correct bugs or implement new features.
\input crossrefenum.tex \input crossrefenum.tex
\ProvidesPackage{crossrefenum}[\crfnmDate{} v\crfnmVersion{} Enumeration of cross-references] \ProvidesPackage{crossrefenum}[\crfnmDate{} v\crfnmVersion{} Enumeration of cross-references]
\endinput \endinput

View File

@ -2,8 +2,8 @@
\def\crfnmName{crossrefenum} \def\crfnmName{crossrefenum}
\def\crfnmShortDesc{Smart typesetting of enumerated cross-references for various TeX formats} \def\crfnmShortDesc{Smart typesetting of enumerated cross-references for various TeX formats}
\def\crfnmAuthor{Bastien Dumont} \def\crfnmAuthor{Bastien Dumont}
\def\crfnmDate{2022/11/11} \def\crfnmDate{2023/02/20}
\def\crfnmVersion{0.1} \def\crfnmVersion{1.0.1}
% %
% Copyright 2022 by Bastien Dumont (bastien.dumont@posteo.net) % Copyright 2022 by Bastien Dumont (bastien.dumont@posteo.net)
% %
@ -524,13 +524,22 @@
%%% \crossrefenum: Public macro with optional arguments %%% %%% \crossrefenum: Public macro with optional arguments %%%
\crfnm@case[\fmtname]
\crfnm@context: {
\unexpanded\def\crossrefenum{\crfnm@crossrefenum}
}
\crfnm@latex: {
\protected\def\crossrefenum{\crfnm@crossrefenum}
}
\crfnm@endCases
% \crossrefenum has two optional arguments. % \crossrefenum has two optional arguments.
% See the definition of \crfnm@enum below for the recognized values. % See the definition of \crfnm@enum below for the recognized values.
\def\crfnm@firstArg@default{page} \def\crfnm@firstArg@default{page}
\def\crfnm@secondArg@default{withprefix} \def\crfnm@secondArg@default{withprefix}
\def\crossrefenum{% \def\crfnm@crossrefenum{%
\futurelet\crfnm@nextToken\crfnm@setEnumMacro \futurelet\crfnm@nextToken\crfnm@setEnumMacro
} }

View File

@ -9,10 +9,14 @@
%D copyright=Bastien Dumont, %D copyright=Bastien Dumont,
%D license=GNU Public License v. 3.0 or higher] %D license=GNU Public License v. 3.0 or higher]
% This file cannot be loaded in main-test.tex for it would load the version of crossrefenum.tex
% installed in the texmf tree.
% As a consequence, it should not be changed to correct bugs or implement new features.
\startmodule[crossrefenum] \startmodule[crossrefenum]
\unprotect \unprotect
\input ../crossrefenum.tex \input crossrefenum.tex
\protect \protect
\stopmodule \stopmodule