webodf / WebODF

WebODF - JavaScript Document Engine
http://webodf.org/
787 stars 165 forks source link

Images Overlapp #848

Open Tesla2k opened 9 years ago

Tesla2k commented 9 years ago

When I place 2 Images under each other they overlap when displayed with WebODF. Also text under the Image is displayed in the image instead below of it.

It looks like this (WebODF 0.5.4): webodf

It should look like this (LibreOffice): libreoffice

Why can I not upload the odt file here?

peitschie commented 9 years ago

I agree it would be a handy feature. Unfortunately. GitHub dictates what can be uploaded.

Are those floating images or anchored as characters?

KristofVanKriekingen commented 9 years ago

@Tesla2k I think you can zip them and upload them.

I'm also experiencing this though and some other issues with images & video's. :x As you can see here: /issues/847

Tesla2k commented 9 years ago

@KristofVanKriekingen uploading ZIP also is not possible

@peitschie I just used Drag & Drop to place them there I have the german version of LibreOffice so I hope I get the right translations. They are anchored at the parapgraph and they are non floating ("Kein Umlauf")

This is the XML Code

    <style:style style:name="fr1" style:family="graphic" style:parent-style-name="Graphics">
      <style:graphic-properties style:horizontal-pos="center" style:horizontal-rel="paragraph" style:mirror="none" fo:clip="rect(0cm, 0cm, 0cm, 0cm)" draw:luminance="0%" draw:contrast="0%" draw:red="0%" draw:green="0%" draw:blue="0%" draw:gamma="100%" draw:color-inversion="false" draw:image-opacity="100%" draw:color-mode="standard"/>
    </style:style>
...

   <office:text>
      <text:sequence-decls>
        <text:sequence-decl text:display-outline-level="0" text:name="Illustration"/>
        <text:sequence-decl text:display-outline-level="0" text:name="Table"/>
        <text:sequence-decl text:display-outline-level="0" text:name="Text"/>
        <text:sequence-decl text:display-outline-level="0" text:name="Drawing"/>
      </text:sequence-decls>
      <text:p text:style-name="P8">
        <draw:frame draw:style-name="fr1" draw:name="Bild2" text:anchor-type="paragraph" svg:width="5.821cm" svg:height="7.549cm" draw:z-index="1">
          <draw:image xlink:href="Pictures/10000000000000A5000000D68DB3AF7C.jpg" xlink:type="simple" xlink:show="embed" xlink:actuate="onLoad"/>
        </draw:frame>
        <draw:frame draw:style-name="fr1" draw:name="Bild1" text:anchor-type="paragraph" svg:width="5.821cm" svg:height="7.549cm" draw:z-index="0">
          <draw:image xlink:href="Pictures/10000000000000A5000000D68DB3AF7C.jpg" xlink:type="simple" xlink:show="embed" xlink:actuate="onLoad"/>
        </draw:frame>
      </text:p>
      <text:p text:style-name="P10">
        <draw:frame draw:style-name="fr1" draw:name="Bild3" text:anchor-type="paragraph" svg:width="5.821cm" svg:height="7.549cm" draw:z-index="2">
          <draw:image xlink:href="Pictures/10000000000000A5000000D68DB3AF7C.jpg" xlink:type="simple" xlink:show="embed" xlink:actuate="onLoad"/>
        </draw:frame>
      </text:p>
      <text:p text:style-name="P11">Sdlfjsdfasfjölfj ölk öf jölf jlö jlösdj
        <text:span text:style-name="T1">adsfa dsfa jsdöfsf öasd sa f</text:span>lösfj lösdj</text:p>
    </office:text>
barrytielkes commented 9 years ago

I have fixed this using css, document body p frame { position: static !important; } It happens because they are positioned absolute and therefore don't give there size to the parent.

But it should be fixed in the js where the css is generated.