Am 12.07.2011 08:23, schrieb limerlin:
>   Hi
> 
> 
> When i opened a MS PowerPoint file with OpenOffice,the fillings and 
> lines of OLE-Object's area does not display. Following is what I found 
> after error checking:
> 
> http://openoffice.org/bugzilla/show_bug.cgi?id=67705
> 
> 
> then i read the source code and made following changes to see if it works.
> 
> http://svn.services.openof 
> fice.org/opengrok/xref/Current%20(trunk)/svx/source/sdr/primitive2d/sdrole2primitive2d.cxx
>  
> <http://svn.services.openoffice.org/opengrok/xref/Current%20(trunk)/svx/source/sdr/primitive2d/sdrole2primitive2d.cxx>
> at line 86
> 
>      86  //*static*  *bool*  bB
>   ehaveCompatibleToPaintVersion  
> <http://svn.services.openoffice.org/opengrok/s?defs=bBehaveCompatibleToPaintVersion&project=/Current%20(trunk)>(*true*);//delete
> 
>          
> 
> bool bBehaveCompatibleToPaintVersion 
> <http://svn.services.openoffice.org/opengrok/s?defs=bBehaveCompatibleToPaintVersion&project=/Current%20(trunk)>
>  
> = false //add
> 
> It work well!

Hi limerlin,

the static bool bBehaveCompatibleToPaintVersion is there to
enable/disable adding graphical fill/line attributes if wanted. The
background is that OLE SdrObjects in the old paint version (before
changing to primitives) ignored the line and fill attributes which are
commonly defined for all SdrObjects. Sice these were ignored at paint
time but set in the ItemSet of the SdrObject (and saved in ODF over the
UNO API) switching this on was critical for a period of time, especially
for files saved before these attributes were corectly initialized for
OLE SdrObjects. I'm not sure anymore when this was done, but you should
not set it to false, this will ruin functionality.

When e.g. you define a new OLE and use the fill/line attributes (also
shadow), this will be ignored when switching the bool to false.

As can be seen some lines after this:

// add graphic content
appendPrimitive2DSequenceToPrimitive2DSequence(aRetval, getOLEContent());

the OLE graphic content is added after the line and fill primtives, so
it should be painted above line and fill anyways.

So: I cannot explain why the content is missing when you switch the
bool, but it is wrong to do so. It will ruin used functionality.

I would try to go in the direction to find out if getOLEContent() is
empty in your case and why.

Is the bugdoc available somewhere? I would like to take a look...

Regards,
        Armin


> How ever the limited knowledge of openoffice confused me that i dont 
> know is it approiate to make those changes.
> 
> Anyone can help me ?
> 
> --  
> Best regards,
> Merlin
> 
> 
> 
> 
>   
> 
> 
> 

--
ALG

-- 
-----------------------------------------------------------------
To unsubscribe send email to dev-unsubscr...@openoffice.org
For additional commands send email to sy...@openoffice.org
with Subject: help

Reply via email to