https://bugs.freedesktop.org/show_bug.cgi?id=79082

--- Comment #4 from Piet van Oostrum <[email protected]> ---
I found the problem. I loaded the Tabs.ppt file in Powerpoint (the real one on
Windows) and the tabs were there. So the problem appears to be on importing the
PPT file in Impress. 

In libreoffice-4.3.2.2/filter/source/msfilter/svdfppt.cxx, line 6160 there is a
line

    if ( mbTab )    // makes it sense to apply tabsettings

which makes setting the tab stops in a paragraph conditional upon there being
real tabs in the paragraph, supposedly as a kind of optimization. On a slide
master the tabs are retained, however.

This is bad for 3 reasons:
1. It is not a good idea to throw away information that a user has put
deliberately in a file.

2. If the user intends to edit the imported PPT file, and add some tabs then
(s)he has to recreate the tabs.

3. [This is the most serious one]. In Powerpoint 97-2003 a text frame can only
have one sets of tab stops for all paragraphs. When a PPT file is saved in e.g.
Powerpoint 2007 or 2010, the tab stops of the first paragraph of the text frame
is used and the tab stops of the subsequent paragraphs in the same text frame
disappear. The Impress PPT export code does the same as it has no choice. Now
suppose the imported PPT file has the first paragraph without tabs in it but
the next one does have them. Then when you make some change to the file and
save it again as PPT, the tabs in the text frame will be replaced by the
default tab stops because the tab stops of the first paragraph had been deleted
on the import.

So that test should be eliminated. As mbTab is only used for this purpose also
the code to set it can be eliminated.

There was also a second issue, that the default tabs that were in the imported
presentation had an offset of 0.3 cm. This is caused by the fact that the
default tab stops that the paragraph gets come from the slide master. The
paragraph in the slide master has an indent of 0.3 cm (in this presentation),
because it is bulleted.

Now in PPT tab stops are relative to the left margin of the text frame, but in
Impress they are relative to the text indent. So on import export this has to
be compensated, which is just what happened.

-- 
You are receiving this mail because:
You are the assignee for the bug.
_______________________________________________
Libreoffice-bugs mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/libreoffice-bugs

Reply via email to