|
From: | Sam Liddicott |
Subject: | Re: [Texmacs-dev] Complete Re: adding pdf hyperlink support |
Date: | Wed, 13 Jul 2011 09:51:21 +0100 |
User-agent: | Mozilla/5.0 (X11; U; Linux i686; en-US; rv:1.9.2.20pre) Gecko/20110712 Lightning/1.0b2 Lanikai/3.1.12pre |
Hi Miguel - thanks for your comments and interest. Today I am able
to give a more worthy response. On 12/07/11 22:10, Miguel de Benito Delgado wrote: Hi, Maybe your link target is on the same page? Otherwise I have ghostscript 9.01 and use ps2pdf to make the PDF which I view with evince, but Foxit PDF reader also works. What pdf viewer are you using?
You don't need to know the number of the page you are jumping to. http://partners.adobe.com/public/developer/en/acrobat/sdk/pdf/pdf_creation_apis_and_specs/pdfmarkReference.pdf Defining Named DestinationsAs for the view, on page 45: Viewwe use XYZ with NULL as zoom so as not to change the zoom the user already has: XYZ left top zoomNow left and top are the position of the rect being rendered at the label; here is a sample from one of my files: [ /Dest(#footnr-2) cvn /View [/XYZ 363 2948 null] /DEST pdfmark and here is the link to it: [ /Dest(#footnote-2) cvn /Rect [ 363 2924 393 2887 ] /Border [16 16 1 [3 10]] /Color [1 0 0] /Subtype /Link /ANN pdfmark Please could you try this PDF and see if it works for you: http://git.savannah.gnu.org/cgit/fangle.git/plain/fangle.pdf GOOD NEWS - I note that links from the table-of-contents DO jump to the right part of the page! If the TOC entry is to a new section - that has the page-number at the bottom of the page instead of the top of the page, then I notice that evince takes me to the bottom of the page. If the TOC entry is to a subsection and the page number is shown at the top of the page, then evince takes me to the top of the page. To see, try: http://git.savannah.gnu.org/cgit/fangle.git/plain/fangle.pdf and in the contents, click on "4 Using Fangle with Lyx ... 17" - it goes to the bottom of the page where the page 17 is. Then try "4.4 configuring the build script ... 19" and see that it goes to the top of the page. In both cases where the page number is printed. In the .ps, the destination for configuring the build script is: [ /Dest(#auto-18) cvn /View [/XYZ 108 4144 null] /DEST pdfmark and the toc link is: [ /Dest(#auto-18) cvn /Rect [ 3568 3296 3651 3243 ] /Border [16 16 1 [3 10]] /Color [1 0 0] /Subtype /Link /ANN pdfmark Hopefully that gives me enough clue to work out the problem why it doesn't position properly for other links. But I'm very interested in your links not working at all, and would like to see the .ps and .pdf (and .tm file). Sam
|
[Prev in Thread] | Current Thread | [Next in Thread] |