Issue 20575 - [ODF] Invertion of pixel-graphic is not saved and not read
Summary: [ODF] Invertion of pixel-graphic is not saved and not read
Status: CONFIRMED
Alias: None
Product: Draw
Classification: Application
Component: code (show other issues)
Version: OOo 1.1
Hardware: PC Windows XP
: P3 Trivial (vote)
Target Milestone: AOO Later
Assignee: AOO issues mailing list
QA Contact:
URL:
Keywords: oooqa
Depends on:
Blocks:
 
Reported: 2003-10-01 22:20 UTC by Unknown
Modified: 2017-05-20 11:27 UTC (History)
4 users (show)

See Also:
Issue Type: DEFECT
Latest Confirmation in: ---
Developer Difficulty: ---


Attachments
Container with picture and document with linked graphic (151.21 KB, application/zip)
2013-07-07 13:34 UTC, Regina Henschel
no flags Details
Writer Testdocument; zip container with picture and .odt-file (151.67 KB, application/zip)
2013-07-08 11:45 UTC, Regina Henschel
no flags Details

Note You need to log in before you can comment on or make changes to this issue.
Description Unknown 2003-10-01 22:20:00 UTC
If one imports a pixel-graphic (e.g. a bitmap) and uses the invertion function
to invert it, it is correctly inverted. But after saving and loading again, it
is just as before, as if the inversion wasn't saved.
Comment 1 utomo99 2003-10-03 04:00:02 UTC
Please explain more about your problem, your information is not enough 
to investigate the problem. Please explain step by step. Thanks 
Comment 2 Unknown 2003-10-03 09:14:45 UTC
Step-by-step:
Create a new document, click Insert->Graphics.
Choose a picture and make sure that "link" is checked (I missed that
point, because I wasn't aware, that it's important), click ok.
Select the picture, click Filter->Invert (the Icon on the upper-left),
save it, close it and reload it and then it is uninverted again.
Comment 3 utomo99 2003-10-06 08:00:37 UTC
I can Reproduce the problem on 
OpenOffice 1.1 (default Install, US), Win XP Pro Sp1. 
(And MS Office XP Sp2). 
It is real problem
instruction step by step as reporter instruction. and explanation
Comment 4 wolframgarten 2003-10-06 09:04:10 UTC
Yes thanks, now I can reproduce it. 
Reassigned to Christian. Please have a look.
Comment 5 clippka 2003-10-20 12:35:35 UTC
problem is only with linked images. They have to be unlinked when
using a graphic effect
Comment 6 Uwe Fischer 2006-10-24 13:51:49 UTC
wrote a note to Help file shared/guide/insert_bitmap.xhp:

The Export command writes the picture with all applied filter effects to a file.
The Save as Picture command in the context menu saves the picture without any
filter effects, if the picture was inserted as a linked picture. An embedded
picture will always be saved or exported with filters applied.

(Tested this with a jpg in m187 Draw, using the Invert effect)
Comment 7 versurppersio 2010-11-10 16:31:31 UTC
Created attachment 73207
Comment 8 Regina Henschel 2013-06-16 22:02:57 UTC
I think, that the current way AOO inverts the colors is wrong. ODF 1.2 has the attribute draw:color-inversion. There is no problem to use this attribute in the style of a linked graphic. Currently embedded pictures are actually inverted instead of setting the attribute draw:color-inversion.

Suggestion: Use the attribute draw:color-inversion for linked and for embedded graphics. It does not break older documents, because this attribute is currently not written to file, if the user inverts the colors and therefore older documents do not contain the attribute.

Set owner back to default because no work on the issue since six years.
Comment 9 Regina Henschel 2013-07-07 13:21:03 UTC
AOO ignores the attribute "draw:color-inversion" on import.
Comment 10 Regina Henschel 2013-07-07 13:34:02 UTC
Created attachment 81027 [details]
Container with picture and document with linked graphic

Open the container. Examine content.xml in the .odg-file. It has set the attribute draw:color-inversion="true" for the second picture. Open the file in AOO. Notice, the second image is not inverted.
Comment 11 Armin Le Grand 2013-07-08 10:35:50 UTC
ALG: Grepping
Comment 12 Regina Henschel 2013-07-08 11:45:22 UTC
Created attachment 81029 [details]
Writer Testdocument; zip container with picture and .odt-file

In Writer the attribute is read and the display is OK then. But Writer has a wrong implementation for .uno:GraphicFilterInvert. When you click on "invert", the picture is embedded without asking and with no note to the user. Then inverting is applied to the embedded picture.

Writer writes the attribute draw:color-inversion with value "false" for a linked graphic.

In API exists already a property "GraphicIsInverted" in TextGraphicObject. I think, the same property should be used in GraphicObjectShape, perhaps as optional property.
Comment 13 Marcus 2017-05-20 11:27:44 UTC
Reset assigne to the default "issues@openoffice.apache.org".