diff options
Diffstat (limited to 'Master/texmf-dist/tex/latex/oberdiek/zref-titleref.sty')
-rw-r--r-- | Master/texmf-dist/tex/latex/oberdiek/zref-titleref.sty | 21 |
1 files changed, 17 insertions, 4 deletions
diff --git a/Master/texmf-dist/tex/latex/oberdiek/zref-titleref.sty b/Master/texmf-dist/tex/latex/oberdiek/zref-titleref.sty index 6cc952cb316..d7077402594 100644 --- a/Master/texmf-dist/tex/latex/oberdiek/zref-titleref.sty +++ b/Master/texmf-dist/tex/latex/oberdiek/zref-titleref.sty @@ -33,8 +33,8 @@ %% \NeedsTeXFormat{LaTeX2e} \ProvidesPackage{zref-titleref}% - [2007/05/06 v2.0 Module titleref for zref (HO)]% -\RequirePackage{zref-base}[2007/05/06] + [2007/05/28 v2.1 Module titleref for zref (HO)]% +\RequirePackage{zref-base}[2007/05/28] \@ifundefined{ZREF@baseok}{\endinput}{} \RequirePackage{keyval} \let\zref@titleref@current\@empty @@ -176,7 +176,7 @@ \@ifpackageloaded{titlesec}{% \ZREF@patch{ttl@sect@i}{% \def\ttl@sect@i#1#2[#3]#4{% - \zref@titlesec@setcurrent{#4}% + \zref@titleref@setcurrent{#4}% \ZREF@org@ttl@sect@i{#1}{#2}[{#3}]{#4}% }% }% @@ -185,7 +185,20 @@ \ZREF@patch{LT@c@ption}{% \def\LT@c@ption#1[#2]#3{% \ZREF@org@LT@c@ption{#1}[{#2}]{#3}% - \zref@titlesec@setcurrent{#2}% + \zref@titleref@setcurrent{#2}% + }% + }% + }{}% + \@ifpackageloaded{listings}{% + \ZREF@patch{lst@MakeCaption}{% + \def\lst@MakeCaption{% + \ifx\lst@label\@empty + \else + \expandafter\zref@titleref@setcurrent\expandafter{% + \lst@@caption + }% + \fi + \ZREF@org@lst@MakeCaption }% }% }{}% |