Issue 79119

Summary: Size of OLE replacement picture seems to be wrong
Product: General Reporter: tino.rachui
Component: codeAssignee: AOO issues mailing list <issues>
Status: CONFIRMED --- QA Contact:
Severity: Trivial    
Priority: P3 CC: issues
Version: 680m217   
Target Milestone: ---   
Hardware: Mac   
OS: Mac OS X, all   
Issue Type: DEFECT Latest Confirmation in: ---
Developer Difficulty: ---
Description Flags
OLE object pasted into OOo
Same OLE object pasted into MS Excel
A small patch that could probably fix the problem. If the pGraphic argument is NULL, more changes in application implementation is required. none

Description tino.rachui 2007-07-02 21:01:57 UTC
Copy some content in MS Word on Mac OS X paste the content into OOo as "Microsoft Word 
Document" (OLE). The size of the replacement picture displayed is wrong (see attached screenshots).
Comment 1 tino.rachui 2007-07-02 21:03:53 UTC
Created attachment 46454 [details]
OLE object pasted into OOo
Comment 2 tino.rachui 2007-07-02 21:04:42 UTC
Created attachment 46455 [details]
Same OLE object pasted into MS Excel
Comment 3 tino.rachui 2007-07-02 21:07:23 UTC
tra->mav: Regarding the OOo screenshot: The upper picure is what you will see in OOo when you paste 
the clipboard content as picture. The lower picture is what you'll see when pasting the clipboard content 
as OLE object. The same problem with Calc and the other OOo apps. Any idea?
Comment 4 mikhail.voytenko 2007-07-25 12:17:04 UTC
I could not reproduce the problem on Windows. It looks like the default size is
used in this case for the object. Changing the target.
Comment 5 tino.rachui 2007-07-26 08:30:22 UTC
tra->mav: What makes me wonder is the fact that if I insert the picture from the
clipboard the size is correct while when inserting the OLE object the size is
incorrect though I thought that the same picture will be used in that case.
Where would I start looking for the root cause of the problem? Where will be
decided if the default size (whatever that is) or a different size will be used
for the replacement picture?
Comment 6 mikhail.voytenko 2007-07-26 11:33:47 UTC
Currently I can not say how the mac clipboard works, I can only give information
about windows copy/paste objects workflow.

The problem with the picture size ( at least on Windows ) is that the picture
size is not always correct as well as the size provided by clipboard explicitly,
so it can not be used. For this reason the OLE server is explicitly asked for
the size ( in some cases the object even creates own OLE component using windows
API and ignoring OOo clipboard ).

But you are right, in case the object can not retrieve the size from the server,
the picture size could be used as a fallback.

If you like to test whether the assumption is correct please apply the following
patch for svtools/source/misc/embedtransfer.cxx file.
Comment 7 mikhail.voytenko 2007-07-26 11:36:14 UTC
Created attachment 47104 [details]
A small patch that could probably fix the problem. If the pGraphic argument is NULL, more changes in application implementation is required.
Comment 8 mikhail.voytenko 2008-06-02 06:43:55 UTC
Not enough resources - moving to 3.x
Comment 9 mikhail.voytenko 2008-06-02 06:44:29 UTC
Comment 10 Marcus 2017-05-20 10:55:55 UTC
Reset assigne to the default "".