Dear List,

If it is possible, I would also like to know how to use a processor
for the page number in the \setregisterentry command. If not, could it
be implemented?

Regards

Marcus Vinicius

On Sun, Aug 25, 2024 at 3:37 PM Henning Hraban Ramm <te...@fiee.net> wrote:
>
> Hi again,
>
> the page number of register entries from a glossary should have a
> different color:
>
> \defineprocessor[glossar][color=green]
> \define[1]\GlIndex{\index[glossar->]{#1}}
>
> This works, but I’d like to apply a macro to the text, and then I need
> to set the sort order:
>
> \define[1]\GlIndex{\index[glossar->#1]{\Word{#1}}}
>
> This also works, but I get separate index entries from
> \index{Something}
> and
> \GlIndex{something}
>
> Glossary entries may be lowercase, but in the index I’d like to
> normalize to uppercase initials. (The index command is part of a lemma
> setup.)
>
> How can I combine the entries?
>
> I also tried \setregisterentry but didn’t find out how to use a
> processor for the page number. In the wiki, the (generally working)
> processor option is undocumented, so if there’s another option, it’s
> also missing.
> In the source, I found processors for entry & page, but not how to
> address the latter.
>
> MWE:
> """
> \defineprocessor[glossar][color=green]
> \define[1]\GlIndex{\index[glossar->#1]{\Word{#1}}}
>
> \starttext
>
> \samplefile{ward}
> \index{something}
> \index{anything}
> \page
>
> \samplefile{tufte}
> \GlIndex{something}
> \GlIndex{anything}
>
> \page
> \placeindex
> \stoptext
>
> """
>
> Hraban
> ___________________________________________________________________________________
> 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
> ___________________________________________________________________________________



-- 
Todas as coisas fatigam o corpo, salvo a música, que não fatiga nem o
corpo nem seus membros, por ser descanso da alma, primavera do
coração, distração do aflito, entretenimento do solitário, e viático
do viajante.

Kunnâsh al-Hâ'ik (Cancioneiro de al-Hâ'ik)
___________________________________________________________________________________
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
___________________________________________________________________________________

Reply via email to