This is a multi-part message in MIME format. --===============1623532019557524865== Content-Type: multipart/alternative; boundary="------------000300070205010103090205" This is a multi-part message in MIME format. --------------000300070205010103090205 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit On 03/26/2013 04:32 PM, Sebastian Sauer wrote: > On 03/26/2013 02:51 PM, Lassi Nieminen wrote: >> Hola, >> >> On Mon, Mar 25, 2013 at 8:12 PM, Inge Wallin > > wrote: >> >> On Monday, March 25, 2013 17:54:53 matus.uzak@gmail.com >> wrote: >> > Hi, >> > >> > sorry for not discussing earlier, but I did not have much free >> time last >> > two weeks. >> > >> > I think we should continue the parser type discussion in order >> to also >> > improve state of things in libmsooxml. What we have there is a >> PULL >> > parser. And I identified the following problems (Would be cool >> is Lassi >> > could check those): >> > >> > 1. OOXML sometimes requires us to run the parser twice at one >> element in >> > order to first collect selected information required to convert >> the content >> > of child elements. >> > >> > 2. There are situations when conversion of the 1st child of the >> root >> > element requires information from the last child of the root >> element. >> >> It would be interesting to see some examples of these two issues. >> >> >> As an example : in pptx files, in slides, >> there can be text which is specified to use theme color lt1 >> >> Don't remember the exact syntax, but something like >>

>> >> Hejsan >>

>> >> Then as the last element of that slide there may or may not be >> // or something similar >> >> Which means that lt1 should be interpreted to be bg1 for this >> particular slide. >> Currently what we're doing is that we first read the slide once, >> skipping everything >> except clrMap. Then we read the slide again (yay!) and start the real >> conversion. >> >> There was something similar in xlsx filters too if my memory serves >> me correctly. >> > > See also somewhat related XmlWriteBuffer in > filters/libmsooxml/MsooXmlUtils.h which is used "when information that > has to be written in advance is based on XML elements parsed later. > In such case the information cannot be saved in one pass" for OOXML=>ODF. > > In the case of XSLT I also remember that there where a problem with > offset-references. Means something like (pseudo-xml): > > > > > // where 1 references to the second > stlye-item > > > XSLT does iirc not allow such index-based reference-fetching making it > needed to for-loop with counter over the