Re: [NTG-context] use of preceding-sibling in xmlsetsetup

2015-10-20 Thread Hans Hagen
On 10/20/2015 11:48 AM, mass...@fastwebnet.it wrote: Here's the (complete) code: \startbuffer[test] Dear list, this paragraph should not be indented, because it follows the “incipit” of the letter. This one and the following ones should be indented. You may question whether “Dea

Re: [NTG-context] use of preceding-sibling in xmlsetsetup

2015-10-20 Thread massifr
Here's the (complete) code: \startbuffer[test] Dear list, this paragraph should not be indented, because it follows the “incipit” of the letter. This one and the following ones should be indented. You may question whether “Dear list,” should be a paragraph of his own, but my text is

Re: [NTG-context] use of preceding-sibling in xmlsetsetup

2015-10-19 Thread Thomas A. Schmitz
On 10/17/2015 11:19 AM, mf wrote: "reverse-sibling" is ConTeXt specific and very useful: it's a "reversed preceding-sibling", so that you find the nearest sibling at index [1]. I've used it successfully in a \doif statement, but I failed in translating it in a \xmlsetsetup statement, to tell ConT

Re: [NTG-context] use of preceding-sibling in xmlsetsetup

2015-10-17 Thread mf
Thank you for your answer, Thomas. I tried something similar (putting a \noindentation at the end of the "incipit" paragraph, but it failed if I put a \blank after that). The sibling part In the book of the history of luatex (v 0.50) it is said that the sibling functions would not be implemented s

Re: [NTG-context] use of preceding-sibling in xmlsetsetup

2015-10-15 Thread Thomas A. Schmitz
On 10/14/2015 01:34 PM, mass...@fastwebnet.it wrote: I've found a better solution: \startxmlsetups xml:p \doif{\xmlattribute{#1}{reverse-sibling::p[1]}{class}}{incipit}{\noindent}% \xmlflush{#1}\par \stopxmlsetups Still I did not manage to put that rule in a xmlsetsetup. Tried this: \xml

Re: [NTG-context] use of preceding-sibling in xmlsetsetup

2015-10-14 Thread massifr
I've found a better solution: \startxmlsetups xml:p \doif{\xmlattribute{#1}{reverse-sibling::p[1]}{class}}{incipit}{\noindent}% \xmlflush{#1}\par \stopxmlsetups Still I did not manage to put that rule in a xmlsetsetup. Tried this: \xmlsetsetup{#1}{p[reverse-sibling::p[1]/attribute('class') =

[NTG-context] use of preceding-sibling in xmlsetsetup

2015-10-12 Thread massifr
Hello list, I need a lpath expression to intercept the first p (HTML paragraph) after a p of class "incipit". Here's a (not) working example: \startbuffer[test] Dear list, this paragraph should not be indented, because it follows the “incipit” of the letter. This one and the following on