export of Calc functions to OOXML

Winfried Donkers W.Donkers at dci-electronics.nl
Tue Jul 29 23:10:06 PDT 2014


Hi Eike,


> There are already entry points that do something similar for the old non-ODFF (aka PODF) OOo-XML format, i.e. in formula/source/core/api/FormulaCompiler.cxx
> FormulaCompiler::CreateStringFromTokenArray() and in formula/source/core/api/token.cxx all functions with *Rewrite*()

> The MissingConvention and FormulaMissingContext need to handle also the OOXML cases, or probably better create a derived MissingConvention for the OOXML case so there are less explicit comparisons and/or switch cases to differentiate.

I note that the PODF-handling is always done when saving, regardless of the file type being saved (e.g. ods, xlsx).
The result is that e.g. the formula GAMMADIST(1,2,5) (4th argument is optional) is always extended to GAMMADIST(1,2,5,1).
Whether this is a desired functionality or not may be a matter of taste, but it makes FormulaCompiler::CreateStringFromTokenArray() an unsuitable starting point for OOXML-modifications.

Am I overlooking something?

Winfried


More information about the LibreOffice mailing list