(again) wrong destination types?
Dear list, sorry for insisting, but this is important for my documents. I have the following sample: \setupinteraction[state=start, page=name, focus=standard] \starttext a\footnote{b} \stoptext If page is set to anything different than no in \setupinteractionscreen, focus=standard will not work (it will be used as focus=fit). Could anyone confirm the issue or explain me what I’m doing wrong? Many thanks for your help Pablo
On 20 Nov 2023, at 18:01, Pablo Rodriguez via ntg-context
wrote: Dear list,
sorry for insisting, but this is important for my documents.
I have the following sample:
\setupinteraction[state=start, page=name, focus=standard] \starttext a\footnote{b} \stoptext
If page is set to anything different than no in \setupinteractionscreen, focus=standard will not work (it will be used as focus=fit).
Could anyone confirm the issue or explain me what I’m doing wrong?
Many thanks for your help
I changed your example to the following: \setupinteraction[state=start, page=name, focus=standard] \starttext \input knuth \par a\footnote{b} \par \input knuth \par \input knuth \par \input knuth \par \input knuth \par \input knuth \par \input knuth \par \input knuth \par \stoptext Using Preview on the Mac I see the following behaviour: a) The doc opens at page 1, in continuous scroll mode, with the table of contents sidebar open. I'm pretty sure it's opening at 100% zoom but it's surprisingly hard to verify that in Preview. b) When I click on the superscript 1 in the main body of the text nothing happens. This is because the footnote text is already visible. c) When I click on the superscipt 1 in the footnote then the view changes and the document is scrolled so that the superscript 1 line in the main text is at the top of the window. This is what I would expect for focus=standard as described on the Wiki. Adobe Acrobat Reader is the same except that the opening view is different - I think it is defaulting to my preferences which is to have a double-page view. — Bruce Horrocks Hampshire, UK
On 11/22/23 00:06, Bruce Horrocks wrote:
[...] I changed your example to the following: \setupinteraction[state=start, page=name, focus=standard] \starttext \input knuth \par a\footnote{b} \par \dorecurse{7}{\input knuth \par} \stoptext
Many thanks for your fast reply, Bruce. I wanted to reply much sooner, but it was really impossible for me. From your explanation, the first link (body to footnote, your point b) has destination to fit the whole page inside the viewer. The second link (footnote to body, your point c) has the destination to reach a position inside the page (where the destination lies). This is what "focus=standard" should achieve. In PDF terms (simplified), fit to page destinations are /Fit destinations and placed destinations are /XYZ destinations. This sample shows what might be the root issue here: \setupinteraction[state=start, page=name, focus=standard] \starttext \completecontent \chapter{Chapter} a\footnote{b} \stoptext ConTeXt handles internally links in categories. For some reason unknown to me, "page=name" triggers that special operation links contain /Fit instead /XYZ destinations. This is similar to the wrong link destinations (fit instead of standard) from TOC (but not in footnotes [which are right]) when compiled with MkIV: \setupinteraction[state=start, focus=standard] \starttext \completecontent \chapter{Chapter} a\footnote{b} \stoptext I hope it is clearer now. Let me know if it is not. My issue is that I cannot avoid having "page=name" for links to external documents, but this breaks footnotes and other special operation links. Many thanks for your help, Pablo
On 3 Dec 2023, at 15:26, Pablo Rodriguez via ntg-context
wrote: On 11/22/23 00:06, Bruce Horrocks wrote:
[...] I changed your example to the following: \setupinteraction[state=start, page=name, focus=standard] \starttext \input knuth \par a\footnote{b} \par \dorecurse{7}{\input knuth \par} \stoptext
Many thanks for your fast reply, Bruce.
I wanted to reply much sooner, but it was really impossible for me.
From your explanation, the first link (body to footnote, your point b) has destination to fit the whole page inside the viewer.
The second link (footnote to body, your point c) has the destination to reach a position inside the page (where the destination lies). This is what "focus=standard" should achieve.
In PDF terms (simplified), fit to page destinations are /Fit destinations and placed destinations are /XYZ destinations.
This sample shows what might be the root issue here:
\setupinteraction[state=start, page=name, focus=standard] \starttext \completecontent \chapter{Chapter} a\footnote{b} \stoptext
ConTeXt handles internally links in categories. For some reason unknown to me, "page=name" triggers that special operation links contain /Fit instead /XYZ destinations.
This is similar to the wrong link destinations (fit instead of standard) from TOC (but not in footnotes [which are right]) when compiled with MkIV:
\setupinteraction[state=start, focus=standard] \starttext \completecontent \chapter{Chapter} a\footnote{b} \stoptext
I hope it is clearer now. Let me know if it is not.
My issue is that I cannot avoid having "page=name" for links to external documents, but this breaks footnotes and other special operation links.
What are you using for links to external documents? If just a single command such as \goto then you might be able to get away with defining a wrapper (e.g. \myGoto) that does \setupinteraction[state=start,page=name,focus=standard] then the \goto command then \setupinteraction[state=start,page=fit,focus=standard] afterwards. (Assuming calling \setupinteraction that many times does not cause problems in itself.) — Bruce Horrocks Hampshire, UK
On 12/5/23 00:21, Bruce Horrocks wrote:
On 3 Dec 2023, at 15:26, Pablo Rodriguez via ntg-context wrote: […] My issue is that I cannot avoid having "page=name" for links to external documents, but this breaks footnotes and other special operation links.
What are you using for links to external documents? If just a single command such as \goto then you might be able to get away with defining a wrapper (e.g. \myGoto) that does \setupinteraction[state=start,page=name,focus=standard] then the \goto command then \setupinteraction[state=start,page=fit,focus=standard] afterwards.
Many thanks for your reply, Bruce. The following code seems to solve my issues: \def\MyGoTo#1[#2]{\setupinteraction[state=start, style=, display=new, color=, contrastcolor=, page={auto,name}, focus=standard]% \goto{#1}[#2]} \setupinteraction[state=start, style=, display=new, color=, contrastcolor=, page={no}, focus=standard] I didn’t thought this issue would be so easy to be solved. Many thanks for your help, Pablo
participants (2)
-
Bruce Horrocks
-
Pablo Rodriguez