On 30.04.2016 20:13, racoon wrote:
On 30.04.2016 19:51, racoon wrote:
On 30.04.2016 18:10, Richard Heck wrote:
On 04/30/2016 11:55 AM, racoon wrote:
On 30.04.2016 16:56, Richard Heck wrote:
On 04/30/2016 10:00 AM, racoon wrote:
Thanks Jürgen. I guess your reply implies that there is no special
function for this in LyX.

No, but it would not be hard to create a simple module that did this.

I'll give it a try. Two things are holding me a bit back though

1. The code by Jürgen does not work in environments.

May need to use \csgdef or something. It's possible the defintion is
being made local to the environment. But I'm not sure.

Well, if it is without LyX help then there are the necessary commands
already in the hyperref package: \hypertarget and \hyperref.

https://en.wikibooks.org/wiki/LaTeX/Hyperlinks#Hyperlink_and_Hypertarget

They uglify the text though.

Just for completeness, here is a solution:

http://tex.stackexchange.com/questions/168832/using-hypertarget-caption-in-hyperlink-caption


However, without the help of a frontend that provides a list of labels,
like LyX does for other cross references, it is pretty cumbersome and
makes the text less readable in the editor.

Is it possible to implement such a list via a module or would one have
to dig deeper into LyX for that?

I just realized that LyX has a "problem" with this solution. If the caption of the link is changed and the preview is created the hyperlink is not appropriately updated. It seems that it needs an extra compilation...

Daniel


Daniel


Daniel


2. The Customization documentation seems a bit on the short side when
it comes to examples.

All the layout and module files that LyX ships are examples, e.g.,
enumitem.module.

Richard









Attachment: hypertarget.lyx
Description: application/lyx

Reply via email to