Hello,

I would like to use the "<Reference> on Page <Page>" cross-referencing format from refstyle in LyX. I set the "Use refstyle (not prettyref) for cross-rferences" option in the Document settings, but LyX uses the \vref{LabelPrefix:Label} command for the references.

I tried to work around LyX with this:
\usepackage{xstring}
\renewcommand{\vref}[1]{\expandafter\csname\StrBefore{#1}{:}ref\endcsname[vref]{\StrBehind{#1}{:}}}

This should essentially replace the \vref{LabelPrefix:Label} command LyX inserts/outputs with \LabelPrefixref[vref]{Label} which would be the refstyle command to get the "<Reference> on Page <Page>" cross-referencing format.

Could someone who has more experience in TeX/LaTeX please point out what I did wrong.


Kind regards,
Hugo

Attachment: mwe.lyx
Description: Binary data

Reply via email to