Dear list,

I have a question when dealing with XML.

Is there any way to write a conditional based on the number of
characters in a given field?

I mean, the following field:

    \xmltext{#1}{h1[@class='subtitle']}

If subtitle > 60 chars, then fontsize = 10pt.
If subtitle > 50 chars, then fontsize = 12pt.
If subtitle > 40 chars, then fontsize = 14pt.
If subtitle > 30 chars, then fontsize = 16pt.

How could I write these conditionals?

Many thanks for your help,


Pablo
-- 
http://www.ousia.tk
___________________________________________________________________________________
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