![](https://secure.gravatar.com/avatar/b79687264c3e06cba13b54d05b12a9f5.jpg?s=120&d=mm&r=g)
Am 26.06.2013 um 09:13 schrieb Thomas A. Schmitz
Hi all,
back with a question on index entries in xml. I have the problem that my processing command inserts empty spaces. \removeunwantedspaces does not remove the unwanted spaces; \ignorespaces removes even wanted spaces. Can anybody help?
Thanks and all best
Thomas
\starttext
\startbuffer[demo] <document> <p>Gustave <indexterm keyword="Flaubert, Gustave">Flaubert</indexterm> originated from <indexterm>Rouen</indexterm>.</p> </document> \stopbuffer
\startxmlsetups xml:test \xmlsetsetup{#1}{*}{-} \xmlsetsetup{#1}{document|p|indexterm}{xml:*} \stopxmlsetups
\xmlregistersetup{xml:test}
\startxmlsetups xml:document \xmlflush{#1} \stopxmlsetups
\startxmlsetups xml:p \xmlflush{#1} \par \stopxmlsetups
\startxmlsetups xml:indexterm \doifelse{\xmlattdef{#1}{keyword}{@@@}}{@@@} {\expanded{\index{\xmlflush{#1}}}\xmlflush{#1}\removeunwantedspaces} {\expanded{\index{\xmlatt{#1}{keyword}}}\xmlflush{#1}\removeunwantedspaces}
There is a space at the end of this line, remove it and it will also disappear from the output. Wolfgang