Date: prev next · Thread: first prev next last
2011 Archives by date, by thread · List index


On 16/08/11 17:32, Lionel Elie Mamane wrote:
I disabled the "export out any embedded image object" code by adding a
"return;" before it, and it does not loose the embedded images, even
after restarting LO and re-opening the document.

( after refamiliarising myself with this code ) this behaviour is not at all expected.

It seems that base documents are doing something strange ( well maybe better to say different ) here, in fact if you add, save and then remove some image controls ( with embedded images ) then the Picture streams are never discarded. With the other applications ( calc, writer etc. ) when you save you save you save to new storage and the storage content is regenerated from the document model so effectively the existing content is thrown away and recreated. In the case of basic of course some optimizations might occur like copying existing 'Basic' substorages to rather than writing to the target storage based on the in-memory libraries model.

With that in mind and after doing a little testing I think your patch for loading the library in SfxDialogLibraryContainer::storeLibrariesToStorage is the simplest thing to do and should avoid any such problems in any other applications like the one you mentioned ( that I cannot reproduce ) in calc. So I will push this ( and good job too tracking it down )

The issue with the leaking 'Picture/xxxxxxxxxx.png" etc. streams still remains, I guess I would need to understand what base actually does when saving with the existing content to see what we can do there, probably it is just a case of excluding the Pictures directory rather than blanket copying stuff.

thanks,

Noel

Context


Privacy Policy | Impressum (Legal Info) | Copyright information: Unless otherwise specified, all text and images on this website are licensed under the Creative Commons Attribution-Share Alike 3.0 License. This does not include the source code of LibreOffice, which is licensed under the Mozilla Public License (MPLv2). "LibreOffice" and "The Document Foundation" are registered trademarks of their corresponding registered owners or are in actual use as trademarks in one or more countries. Their respective logos and icons are also subject to international copyright laws. Use thereof is explained in our trademark policy.