Richard Heck wrote: > Ultimately, refstyle has much better and more flexible support for this > sort of thing. Thus, one can write in LaTeX: > \Tabref[vref]{tab:foo} > and then you get: > table 3 on the previous page
Yes, I know. However, I prefer to customize this globally. If I decide (or the publisher urges me) to take out the "on page X" references completely for figures (or add them for chapters), I do not want to revisit any single reference. (that's why I do not much like your proposed solution of letting lyx2lyx change global definitions to fixed ones, such as "\Tabref{tab:what} on page \pageref{tab:what}") > or whatever. So we could support that sort of thing directly in LyX. And > refstyle will do other things, too, like plurals and ranges, e.g., > "sections 3 to 5". Looks promising. I'm eager to see if this can handle different syntactic cases as well (which is slightly more relevant in German than English -- "vgl. die Abschnitte 3 bis 5" vs. "in den Abschnitten 3 bis 5" -- and even more relevant in other languages) > But you can also do the sort of thing you do there. E.g., we can > redefine figure refs as follows: > > \newref{fig}{% > name = \RSfigtxt, > names = \RSfigstxt, > Name = \RSFigtxt, > Names = \RSFigstxt, > rngtxt = \RSrngtxt, > lsttxt = \RSlsttxt, > refcmd = \ref{#1} \vpageref{#1}} > > Other than refcmd, this is all just from refstyle.cfg. There isn't any > straightforward way just to redefine refcmd for figs. I see. I guess this would do for my case. But anyway, this change will probably affect many more documents. So if we come to decide that prettyref will be dropped, we will have to add a big fat warning in the release notes. Jürgen