3

I am using LyX to build a beamer presentation that has hyperlinks. I create the hyperlink in the following manner:

\hyperlink{test}{\beamerbutton{mybutton}}

Then, there is a frame after the \appendix command in my file which (from LyX source has):

\lyxframe{Test Slide\label{test}}
hello lyx!    
\lyxframeend{}

However, the link seems to go to the slide after this one. What is going on here? However, using the \hypertarget command works fine:

\lyxframe{Test Slide}
\hypertarget{test}{}
hello lyx!    
\lyxframeend{}
  • 1
    What happens if you put the label after \lyxframe{blurgh}, like this: \lyxframe{Test Slide}\label{test}hello lyx\lyxframeend{}? – moewe Oct 16 '13 at 6:11
  • 1
    Alex, for him/her to be notified of your comment, you should poke him with @moewe – scottkosty Oct 16 '13 at 17:55
  • @moewe: your comment worked, turn it into an answer – Alex Oct 16 '13 at 18:16
3

To get proper hyperlinks you need to use \label{test} after \lyxframe{blurgh}.

Like this

\lyxframe{Test Slide}\label{test}
  hello lyx
\lyxframeend{}

If LaTeX encounters a \label, it sets a link to where the last counter-modification appeared. If you use \label within the command modifying the counter alls sorts of things may happen, but probably not what you expect.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.