Newsgroups: comp.text.tex
From: Heiko Oberdiek <oberd...@ruf.uni-freiburg.de>
Date: 2000/05/29
Subject: Re: hyperref and figures
Sebastian Rahtz <sebastian.ra...@computing-services.oxford.ac.uk>
wrote: >Gekke Eekhoorn <ge...@beneden.pandora.be> writes: I agree with Sebastian, in general it is not possible. >> Is there some way to make the reference to the label point to the beginning >In a word, "no". Its a complicated business, because a `figure' can In limited and special cases you can try package `hypcap', that I have written last year. But have to mark the begin of the figure with \capstart or you can use option `figure', but then each figure environment has to use a \caption command, ... It does not work with package `subfigure' and I expect problems with similar packages. Yours sincerely %%% cut %%% hypcap.sty %%% cut %%% \@ifundefined{hyper@@anchor}{% }{} \newcommand*\hc@org@caption{} \let\hc@org@caption\caption \newcommand*\hc@caption{% } \newif\if@capstart \newcommand*\hypcapspace{.5\baselineskip} \newcommand*\capstart{% } \def\hc@caption{% \@dblarg{\hc@@caption\@captype}% } \long\def\hc@@caption#1[#2]#3{% \let\caption\hc@org@caption \@capstartfalse \hyper@makecurrent\@captype \par\addcontentsline{% \csname ext@#1\endcsname}{#1}{% \protect\numberline{% \csname the#1\endcsname }{\ignorespaces #2}% }% \begingroup \@parboxrestore \normalsize \@makecaption{\csname fnum@#1\endcsname}{% \ignorespaces#3% }% \par \endgroup } \def\hc@redef#1{% \expandafter\hc@@redef\csname hc@org#1\expandafter\endcsname \csname hc@orgend#1\expandafter\endcsname \expandafter{#1}% } \def\hc@@redef#1#2#3{% \expandafter\let\expandafter#1\csname#3\endcsname \expandafter\let\expandafter#2\csname end#3\endcsname \renewenvironment*{#3}[1][]{% \ifx\\##1\\% #1\relax \else #1[##1]% \fi \capstart }{% \if@capstart \PackageError{hypcap}{You have forgotten to use \string\caption}% \else \fi #2% } } \DeclareOption{figure}{\hc@redef{\CurrentOption}} \DeclareOption{figure*}{\hc@redef{\CurrentOption}} \DeclareOption{table}{\hc@redef{\CurrentOption}} \DeclareOption{table*}{\hc@redef{\CurrentOption}} \ProcessOptions\relax \let\hc@redef\@undefined \let\hc@@redef\@undefined \endinput %%% cut %%% hypcap.sty %%% cut %%% You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
| ||||||||||||||