pptx import filter

Jean-Tiare LE BIGOT admin at jtlebi.fr
Sun Aug 19 07:25:46 PDT 2012


Hi all,

Thanks for the tip. I spend hours tracing the bug with GDB but I stuck. 
I can not figure out where to fix it.

Here is the situation: I have a pptx file with

- title (fine)
- 4 items in a list (buggy)

In Powerpoint, all the text in the list is 18p but a signe word is 8p.
In Impress, the begin of the text is 20p, the word at 8p is 8p an the 
remaining text is 8p also.

After bisecting the pptx file, it appears that there is an empty "span" 
at the very beginning of the first list item. It's size is set to 20p. 
The only other "span" with a size specified is the one at 8p. All other 
elements have no size information on them.

When an element has no size specified, it is imported with the same size 
as the immediate previous element whereas it should take the default 
size specified in the theme. In my case, the size is specified in the 
MasterSlide->OtherStyle->lvl1pPr.

in the import filter, there is a file 
oox/source/drawingml/textrun.cxx:63 This is the only line where the size 
appears to be used in a computation. Ideed, manually forcing the size to 
18 when at 0 fixes the problem for me.

But... It's really not the right place nor the right way to do it since 
it would orverride the theme...
I also know the themes in the master slide are imported properly.

I also traced the code down to pptshape.cxx where the text seems to be 
imported into the core. I obviously missed something...

My question is: where can I fix this ????

Thanks a lot for your help (and patient reading)

Le 2012-08-17 15:31, Miklos Vajna a écrit :
> On Fri, Aug 17, 2012 at 03:54:25PM +0200, Jean-Tiare LE BIGOT <admin at jtlebi.fr> wrote:
>> Is there anyone already working on the pptx import filter ?
>> I'd like to work on the font size import.
>>
>> Is there any code shared between the pptx/docx/... filters ?
>
> Hi,
>
> Look under the oox/ module, that's shared between docx/xlsx/pptx.
>
> Miklos
> _______________________________________________
> LibreOffice mailing list
> LibreOffice at lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/libreoffice
>


-- 
Jean-Tiare


More information about the LibreOffice mailing list