metanorma / isodoc

Generate HTML/Word from Metanorma XML
https://www.metanorma.org
BSD 2-Clause "Simplified" License
3 stars 3 forks source link

Have Word HTML cope with custom ordered list numberings #247

Open opoudjis opened 3 years ago

opoudjis commented 3 years ago

We have left the door ajar to allowing custom ordered list numberings in Metanorma, as opposed to a single numbering. Provided we can embed list paragraphs from one list style in list paragraphs from another (e.g. <p style="mso-list:l3 level1 lfo3;"> followed by <p style="mso-list:l4 level2 lfo3;">, we will expand this to Word.

That is a big if. It will require five extra ordered list styles, to cope with each of our allowed numberings, and it will require indentation to be parameterised as variables in the Word CSS, to keep them consistent. I do not know how the lfo numbering, which preserves list identity, will work. It will make the routines in html2doc which keep track of lists much more complicated, if it does work.

And this is not allowing start: start in Word HTML is handled as a brand new list style instance, which means I would have to duplicate list styles in Word CSS on the fly in html2doc. I can, but if I can avoid doing so, I will.

opoudjis commented 2 years ago

Because list numbers are manually set in Word ISO DIS, we can leave things open whereby start numbering is ignored in draft ISO Word output, but respected in DIS output.