Bug 34305 - docx import: Imported images (gif, jpeg) not shown
Summary: docx import: Imported images (gif, jpeg) not shown
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
3.3.1 release
Hardware: Other All
: medium normal
Assignee: Noel Power
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-02-15 11:56 UTC by Tobias Burnus
Modified: 2012-05-05 08:59 UTC (History)
2 users (show)

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tobias Burnus 2011-02-15 11:56:00 UTC
Follow up to bug 31036. (Using openSUSE Factory with LO libreoffice-3.3.0.3 (3.3-rc3)).

The example at bug 31036 (DOX file, attachment 39617 [details]) is now correctly rendered - even though the second figure (OLE object with WMF replacement rendering) is shifted to the left - in Word 2003 it is placed further to the right (after the word "equation").

But now to this bug report ...


The more complicated example at
  https://bugzilla.novell.com/show_bug.cgi?id=645557
  DOCX file: https://bugzilla.novell.com/attachment.cgi?id=394228
still fails.

"word/media/" contains 4 WMF files, 3 gif and 2 jpeg. While the WMF files are shown, the JPEG and GIF files are not shown. (Not even place holder frames.)

(Other issues: Text-box text is not shown - only the framed text box itself. Text between "6 out of 6" and "LOWES" is missing. And the WMF images are all aligned on the left border and not at their proper place.)


The first GIF file (image5.gif) is included as follows. In _rels/document.xml.rels one finds:

<Relationship Id="rId12" Type="http://schemas.openxmlformats.org/officeDocument/2006/relationships/image" Target="media/image5.gif"/>

And in document.xml it is then used as:

<w:drawing>
  <wp:inline distT="0" distB="0" distL="0" distR="0">
    <wp:extent cx="569595" cy="112395"/>
    <wp:effectExtent l="19050" t="0" r="1905" b="0"/>
    <wp:docPr id="33" name="Picture 33" descr="5 out of 5"/>
    <wp:cNvGraphicFramePr>
      <a:graphicFrameLocks xmlns:a="http://schemas.openxmlformats.org/drawingml/2006/main"
                           noChangeAspect="1"/>
    </wp:cNvGraphicFramePr>
    <a:graphic xmlns:a="http://schemas.openxmlformats.org/drawingml/2006/main">
      <a:graphicData uri="http://schemas.openxmlformats.org/drawingml/2006/picture">
        <pic:pic xmlns:pic="http://schemas.openxmlformats.org/drawingml/2006/picture">
          <pic:nvPicPr>
            <pic:cNvPr id="0" name="Picture 33" descr="5 out of 5"/>
            <pic:cNvPicPr>
              <a:picLocks noChangeAspect="1" noChangeArrowheads="1"/>
            </pic:cNvPicPr>
          </pic:nvPicPr>
          <pic:blipFill>
            <a:blip r:embed="rId12" cstate="print"/>
            <a:srcRect/>
            <a:stretch>
              <a:fillRect/>
            </a:stretch>
          </pic:blipFill>
          <pic:spPr bwMode="auto">
            <a:xfrm>
              <a:off x="0" y="0"/> <a:ext cx="569595" cy="112395"/>
            </a:xfrm>
            <a:prstGeom prst="rect">
              <a:avLst/>
            </a:prstGeom>
            <a:noFill/>
            <a:ln w="9525">
              <a:noFill/> <a:miter lim="800000"/> <a:headEnd/> <a:tailEnd/>
            </a:ln>
          </pic:spPr>
        </pic:pic>
      </a:graphicData>
    </a:graphic>
  </wp:inline>
</w:drawing>


Cf. OOo issue 92625: http://qa.openoffice.org/issues/show_bug.cgi?id=92625
Comment 1 Noel Power 2011-02-21 02:23:34 UTC
I take a look at this
Comment 2 Noel Power 2011-02-22 04:43:16 UTC
there is a fix now in master for the import of the missing images see. 

http://cgit.freedesktop.org/libreoffice/filters/commit/?id=c1c4bf9b6069541d27f9472c23dbc0ad39752e2d

seems there are a number of (sub) issues mentioned in the bug here, it's always a good idea to keep a single bug report for a single issue otherwise things can get messy and confusing.

I will close this bug as the patch address the main problem. Please feel free to open separate bugs for the remaining issues. As I see it these are

a) the display of the wmf images, after looking a little deeper these images should not be shown at all. These are replacement graphics for activex controls. But of course these controls are unsupported and infact are controls that are hidden. Unfortunately we since we don't import these controls we don't release they are hidden :-/
b) 'Text between "5 out of 5" and "LOWES"' is missing. I am not sure what the problem you see is here, in ms2010 I see no text ( there is some hidden text, review comments I think ) 
c) the textbox content - yeah sure, this is a problem

And if you open issues then for a & c at least then you could assign them directly to me ( at least I would be interested in taking a deeper look... unfamiliar territory though :-) )
Comment 3 Tobias Burnus 2011-02-23 07:34:59 UTC
> there is a fix now in master for the import of the missing images

Thanks a lot!


> a) the display of the wmf images, after looking a little deeper these
> images should not be shown at all. These are replacement graphics
> for activex controls. But of course these controls are unsupported
> and infact are controls that are hidden. Unfortunately we since we
> don't import these controls we don't release they are hidden :-/

In Word 2003 + Compatibility pack, those appear, cf. attachment 43703 [details]. As I do not have Word 2010, I cannot see how it looks like and thus I did not fill a bug report.


> b) 'Text between "5 out of 5" and "LOWES"' is missing. I am not sure
> what the problem you see is here, in ms2010 I see no text ( there is
> some hidden text, review comments I think )

The text is indeed hidden. In Word 2003 is was shown because the "show paragraph" toolbar button was enabled, which also shows hidden text. As "View|Hidden paragraphs" of LibreOffice 3.3.1 does not show the text, I filled bug 34620.

> c) the textbox content - yeah sure, this is a problem

Filled as bug 34617.
Comment 4 Tobias Burnus 2011-05-09 02:59:16 UTC
(In reply to comment #3)
> > a) the display of the wmf images, after looking a little deeper these
> > images should not be shown at all. These are replacement graphics
> > for activex controls. But of course these controls are unsupported
> > and infact are controls that are hidden. Unfortunately we since we
> > don't import these controls we don't release they are hidden :-/

That's now bug 36999.
Comment 5 Roman Eisele 2012-05-05 08:59:00 UTC
Talking about DOCX import, this issue is (at least at the surface) a Writer issue, therefore changed the 'Component' field accordingly.