Knowl'ing an xref

20 views
Skip to first unread message

Charles M

unread,
Aug 11, 2026, 3:03:37 PM (8 days ago) Aug 11
to PreTeXt support
This is a low-priority suggestion since workarounds exist, though not trivially implemented.

In one of my current book projects, I have the code

<xref ref="thm-euler-circuit" text="title" />.

It would be helpful to have an @knowl option so that the hyperlink would open a knowl with the statement of the theorem instead of redirecting the reader to the "in context" statement of the theorem.  Suggested code would be

<xref ref="thm-euler-circuit" text="title" knowl="yes" />,

where @text is clearly optional.

The default behavior should be knowl="no".

A @knowl option could be added to any xref (theorems, notes, remarks, figures, etc.) by the author.

The intended purpose of this would be to enhance reading continuity be keeping the reader at the current position while still allowing a reading of the full theorem (figure, etc.).  This is how bibliographic references are already handled by PreTeXt.

One added power of such a change lies in PreTeXt's ability to improve consistency in a book;  i.e., xref "remembers" whether a cited item is a theorem, lemma, corollary, proposition, etc., and it remembers the title when provided.  (This alone has made my authoring immeasurably easier.)

Regards,
Charles

David W. Farmer

unread,
Aug 11, 2026, 3:23:20 PM (8 days ago) Aug 11
to PreTeXt support

I am confused.

When you xref something, isn't the default behavior in the HTML
version an knowl?

Or are you saying that a knowl is the default, and you want to change the
default?

Regards,

David
> --
> You received this message because you are subscribed to the Google Groups "PreTeXt support" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to pretext-suppo...@googlegroups.com.
> To view this discussion visit
> https://groups.google.com/d/msgid/pretext-support/b6959e4e-b63a-4e33-80d5-dc1ab8ddd5b0n%40googlegroups.com.
>
>

Mitch Keller

unread,
Aug 11, 2026, 3:45:58 PM (8 days ago) Aug 11
to pretext...@googlegroups.com
I can confirm that an xref using title does provide a knowl, as I just tested in one of my projects. Perhaps Charles has used something in Subsection 45.5.25: xref Options to adjust the options?

Charles M

unread,
Aug 11, 2026, 4:23:36 PM (8 days ago) Aug 11
to PreTeXt support
Dear All:

My sincere apologies.  David and Mitch, you are correct.  The feature that I want is already there.  My mistake was viewing my current project only in Live Preview in VS and not checking the behavior in the build on Safari.

Please pardon my impulsiveness.

Regards,
Charles

David W. Farmer

unread,
Aug 11, 2026, 4:27:47 PM (8 days ago) Aug 11
to PreTeXt support

Dear Charles,

No problem, and this actually is something we need to warn people
about. If you want to see something really confusing, try clicking
on an xref in pretext.plus .
> https://groups.google.com/d/msgid/pretext-support/997548ee-ee79-433c-9e1c-6461d319a738n%40googlegroups.com.
>
>
Reply all
Reply to author
Forward
0 new messages