From: "Thomas A. Schmitz" <thomas.schmitz@uni-bonn.de>
To: mailing list for ConTeXt users <ntg-context@ntg.nl>
Subject: [NTG-context] Re: more register questions!
Date: Fri, 3 May 2024 22:24:35 +0200 [thread overview]
Message-ID: <460d1472-31ac-4aeb-982e-f9927fb75c87@uni-bonn.de> (raw)
In-Reply-To: <c97c9035-2629-433a-8da6-5204489cff49@fastwebnet.it>
Hi Massi,
yes, that was a very good idea! I can detect if the element <indexentry>
occurs within a footnote by testing
\xmldoiftext {#1} {ancestor::footnote}
and then apply a processor to these entries. That would be a good
solution for the time being.
Thanks and all best
Thomas
On 5/2/24 17:55, mf wrote:
>
> I did something like that, with a processor that added a "n" after the
> occurrence page number.
>
> Since you typeset XML, maybe you can detect that an index (register)
> reference happens inside a note from the DOM element you are typesetting.
>
> Then you use a command like this:
>
> \index[NoteProcessor->sortkey]{index term}
>
> where NoteProcessor is defined like this:
>
> \defineprocessor[NoteProcessor][right={\itx n}]
>
> In this case I'm adding a smaller "n" to the right of the page number of
> the occurrence.
>
> Adding the \high style is not difficult:
>
> \defineprocessor[NoteProcessor][right=\high{n}]
>
> but replacing a fixed "n" with the footnote number is quite challenging.
>
> The second argument of \defineprocessor has a "command=\...##1" option
> that could be exploited, but I don't know exactly what gets passed to
> that custom command as ##1; maybe the page number of the occurrence.
>
> In that case, I'd look for a way to store the association between that
> occurrence and the footnote number, and retrieve that in the custom
> command.
>
> Massi
--
Prof. Dr. Thomas A. Schmitz
Institut für Klassische und Romanische Philologie
Universität Bonn
Rabinstr. 8
53111 Bonn
http://www.philologie.uni-bonn.de/de/personal/schmitz
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!
maillist : ntg-context@ntg.nl / https://mailman.ntg.nl/mailman3/lists/ntg-context.ntg.nl
webpage : https://www.pragma-ade.nl / https://context.aanhet.net (mirror)
archive : https://github.com/contextgarden/context
wiki : https://wiki.contextgarden.net
___________________________________________________________________________________
next prev parent reply other threads:[~2024-05-03 20:27 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-05-02 15:01 [NTG-context] " Thomas A. Schmitz
2024-05-02 15:55 ` [NTG-context] " mf
2024-05-03 20:24 ` Thomas A. Schmitz [this message]
2024-05-03 20:36 ` Henning Hraban Ramm
2024-05-03 10:18 ` Wolfgang Schuster
2024-05-03 21:12 ` Thomas A. Schmitz
2024-05-08 2:22 ` Rik Kabel
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=460d1472-31ac-4aeb-982e-f9927fb75c87@uni-bonn.de \
--to=thomas.schmitz@uni-bonn.de \
--cc=ntg-context@ntg.nl \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).