Can context automatically italicize foreign words?

Its common convention to italicize words that are of a different language. I've tried marking these words, but then when they also appear in the glossary and index, they are not appearing in the correct placement--somehow the italicized words appear under the "s" category, no matter what letter they start with. Is there any way in ConTeXt to just give it a list of words, and it will italicize them wherever they are found in the text, no matter they are in the body, some index, etc.? --Joel

Am 20.03.25 um 17:28 schrieb Joel via ntg-context:
Its common convention to italicize words that are of a different language. I've tried marking these words, but then when they also appear in the glossary and index, they are not appearing in the correct placement--somehow the italicized words appear under the "s" category, no matter what letter they start with.
You’re looking for "processors": https://wiki.contextgarden.net/References_notes_and_floats/Registers_and_ind...
Is there any way in ConTeXt to just give it a list of words, and it will italicize them wherever they are found in the text, no matter they are in the body, some index, etc.?
There are several ways for replacements, I don’t know which fits. Hraban

Hi Joel, On Thu, 2025-03-20 at 16:28 +0000, Joel via ntg-context wrote:
Is there any way in ConTeXt to just give it a list of words, and it will italicize them wherever they are found in the text, no matter they are in the body, some index, etc.?
You should be able to use either \translateinput or \replaceword: https://wiki.contextgarden.net/Command/replaceword https://tex.stackexchange.com/a/17024 Thanks, -- Max

At least for the Index, Joel, here is how I achieved that: \defineprocessor[special][style=italic] And then by way of an example in the text referring to a newspaper: \index{special->Age, The} {\em The Age} of 31 July 2018 Julian On 21/3/25 03:28, Joel via ntg-context wrote:
Its common convention to italicize words that are of a different language. I've tried marking these words, but then when they also appear in the glossary and index, they are not appearing in the correct placement--somehow the italicized words appear under the "s" category, no matter what letter they start with.
Is there any way in ConTeXt to just give it a list of words, and it will italicize them wherever they are found in the text, no matter they are in the body, some index, etc.?
--Joel
___________________________________________________________________________________ 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 ___________________________________________________________________________________

On 2025-03-20 18:29, jbf wrote:
At least for the Index, Joel, here is how I achieved that:
\defineprocessor[special][style=italic]
And then by way of an example in the text referring to a newspaper:
\index{special->Age, The} {\em The Age} of 31 July 2018
Julian
On 21/3/25 03:28, Joel via ntg-context wrote:
Its common convention to italicize words that are of a different language. I've tried marking these words, but then when they also appear in the glossary and index, they are not appearing in the correct placement--somehow the italicized words appear under the "s" category, no matter what letter they start with.
Is there any way in ConTeXt to just give it a list of words, and it will italicize them wherever they are found in the text, no matter they are in the body, some index, etc.?
--Joel
One can also use a construct such as \index[New York Times]{{\em The New York Times}} -- Rik
participants (5)
-
Henning Hraban Ramm
-
jbf
-
Joel
-
Max Chernoff
-
Rik Kabel