Skip to content

Commit fa7c7e5

Browse files
authored
[macros] Make xref hack work with newer memoir class (#6890)
1 parent 9ec133c commit fa7c7e5

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

source/macros.tex

+4-4
Original file line numberDiff line numberDiff line change
@@ -78,12 +78,12 @@
7878

7979
% Set the xref label for a clause to be "Clause n", not just "n".
8080
\makeatletter
81-
\newcommand{\customlabel}[2]{%
82-
\@bsphack \begingroup \protected@edef \@currentlabel {\protect \M@TitleReference{#2}{\M@currentTitle}}\MNR@label{#1}\endgroup \@esphack%
81+
\newcommand{\customlabel}[3]{%
82+
\@bsphack \protected@write\@auxout{}{\string\newlabel{#1}{{#3}{\thepage}{}{#2.\thechapter}{}}} \@esphack%
8383
}
8484
\makeatother
85-
\newcommand{\clauselabel}[1]{\customlabel{#1}{Clause \thechapter}}
86-
\newcommand{\annexlabel}[1]{\customlabel{#1}{Annex \thechapter}}
85+
\newcommand{\clauselabel}[1]{\customlabel{#1}{chapter}{Clause \thechapter}}
86+
\newcommand{\annexlabel}[1]{\customlabel{#1}{appendix}{Annex \thechapter}}
8787

8888
% Use prefix "Annex" in the table of contents
8989
\newcommand{\annexnumberlinebox}[2]{Annex #2\space}

0 commit comments

Comments
 (0)