On 16-2-2012 20:38, Aditya Mahajan wrote:

I do agree if the export tags were configurable. Something similar to
multi-lingual interface, but for output rather than input.

It's no big deal to add a remapper although I'd do the renaming on the final xml tree. After all, with a proper css any xml file should render ok and I'd rather stick to generic tagging.

local str = [[<aditya>test<wolfgang>more</wolfgang>done</aditya>]]

local x = xml.convert(str)

local remap = {
    aditya   = 'wolfgang',
    wolfgang = 'aditya',
}

print(xml.tostring(x))

for e in xml.collected(x,"*") do
    e.tg = remap[e.tg] or e.tg
end

print(xml.tostring(x))

Hans



-----------------------------------------------------------------
                                          Hans Hagen | PRAGMA ADE
              Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
    tel: 038 477 53 69 | voip: 087 875 68 74 | www.pragma-ade.com
                                             | www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the 
Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : http://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

Reply via email to