Skip to content

Commit

Permalink
Use \p@<type> macros in appropriate places for displaying refnums
Browse files Browse the repository at this point in the history
  • Loading branch information
brucemiller committed Jun 27, 2020
1 parent 456c715 commit 9f5c893
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 4 deletions.
6 changes: 3 additions & 3 deletions lib/LaTeXML/Package/TeX.pool.ltxml
Original file line number Diff line number Diff line change
Expand Up @@ -4980,11 +4980,11 @@ DefMacro('\lx@@typerefnum@@{}',
. '\@ifundefined{lx@name@#1}{'
. '\@ifundefined{#1name}{'
. '}{'
. '\lx@refnum@compose{\csname #1name\endcsname}{\lx@the@@{#1}}'
. '\lx@refnum@compose{\csname #1name\endcsname}{\csname p@#1\endcsname\lx@the@@{#1}}'
. '}}{'
. '\lx@refnum@compose{\csname lx@name@#1\endcsname}{\lx@the@@{#1}}'
. '\lx@refnum@compose{\csname lx@name@#1\endcsname}{\csname p@#1\endcsname\lx@the@@{#1}}'
. '}}{'
. '\lx@refnum@compose{\csname #1typerefname\endcsname}{\lx@the@@{#1}}'
. '\lx@refnum@compose{\csname #1typerefname\endcsname}{\csname p@#1\endcsname\lx@the@@{#1}}'
. '}');

AssignMapping('type_tag_formatter', 'typerefnum' => '\lx@typerefnum@@');
Expand Down
1 change: 1 addition & 0 deletions lib/LaTeXML/Package/hyperref.sty.ltxml
Original file line number Diff line number Diff line change
Expand Up @@ -217,6 +217,7 @@ DefMacro('\lx@autorefnum@@{}', sub {
(LookupDefinition(T_CS('\\' . $type_s . 'autorefname'))
? (Tokens(T_CS('\\' . $type_s . 'autorefname'), T_CS('\text@nobreakspace')))
: ()),
(LookupDefinition(T_CS('\p@' . $counter)) ? T_CS('\p@' . $counter) : ()),
T_CS('\the' . $counter)); });

AssignMapping('type_tag_formatter', 'autoref' => '\lx@autorefnum@@');
Expand Down
2 changes: 1 addition & 1 deletion lib/LaTeXML/Package/subfig.sty.ltxml
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ DefPrimitive('\newsubfloat[]{}', sub {
Let('\ext@sub' . $name, '\ext@' . $name);
DefMacro('\thesub' . $name, '\alph{sub' . $name . '}');
DefMacro('\fnum@sub' . $name, '(\thesub' . $name . ')');
DefMacro('\p@sub' . $name, '(\thesub' . $name . ')');
DefMacro('\p@sub' . $name, '\the' . $name);
# subcaption above or below?
# Crazy stuff; if the outer float hasn't seen it's caption yet,
# we've got to temporarily step it's counter, WITHOUT resetting the subcounter!
Expand Down

0 comments on commit 9f5c893

Please sign in to comment.