<html>
    <head>
      <base href="https://bugs.documentfoundation.org/">
    </head>
    <body><table border="1" cellspacing="0" cellpadding="8">
        <tr>
          <th>Bug ID</th>
          <td><a class="bz_bug_link 
          bz_status_UNCONFIRMED "
   title="UNCONFIRMED - FILEOPEN ODT setting only one of MARGIN-TOP/MARGIN-BOTTOM uses the settings of the style:default-style instead of the assigned style for the other"
   href="https://bugs.documentfoundation.org/show_bug.cgi?id=118829">118829</a>
          </td>
        </tr>

        <tr>
          <th>Summary</th>
          <td>FILEOPEN ODT setting only one of MARGIN-TOP/MARGIN-BOTTOM uses the settings of the style:default-style instead of the assigned style for the other
          </td>
        </tr>

        <tr>
          <th>Product</th>
          <td>LibreOffice
          </td>
        </tr>

        <tr>
          <th>Version</th>
          <td>unspecified
          </td>
        </tr>

        <tr>
          <th>Hardware</th>
          <td>All
          </td>
        </tr>

        <tr>
          <th>OS</th>
          <td>All
          </td>
        </tr>

        <tr>
          <th>Status</th>
          <td>UNCONFIRMED
          </td>
        </tr>

        <tr>
          <th>Severity</th>
          <td>normal
          </td>
        </tr>

        <tr>
          <th>Priority</th>
          <td>medium
          </td>
        </tr>

        <tr>
          <th>Component</th>
          <td>Writer
          </td>
        </tr>

        <tr>
          <th>Assignee</th>
          <td>libreoffice-bugs@lists.freedesktop.org
          </td>
        </tr>

        <tr>
          <th>Reporter</th>
          <td>jluth@mail.com
          </td>
        </tr></table>
      <p>
        <div>
        <pre>Created <span class=""><a href="http://bugs.documentfoundation.org/attachment.cgi?id=143622" name="attach_143622" title="margin.odt: hand-modified to remove one of each pair of margins.">attachment 143622</a> <a href="http://bugs.documentfoundation.org/attachment.cgi?id=143622&action=edit" title="margin.odt: hand-modified to remove one of each pair of margins.">[details]</a></span>
margin.odt: hand-modified to remove one of each pair of margins.

The problem in tdf#118521 can be reproduced for ODT as well.  If the paragraph
defines only one of fo:margin-top or fo:margin-bottom, the undefined one ought
to assume the value of the defined style (MyStyle in this case). However, it
reverts to the style:default-style value instead.

(The same thing is true for margin-left and margin-right.)

Paragraph 1
<style:style style:name="P1" style:family="paragraph"
style:parent-style-name="MyStyle"><style:paragraph-properties
fo:margin-top="0cm" fo:margin-right="0cm"

Paragraph 2
<style:style style:name="P2" style:family="paragraph"
style:parent-style-name="MyStyle"><style:paragraph-properties
fo:margin-bottom="0cm" fo:margin-left="0cm"

MyStyle
<style:style style:name="MyStyle" style:family="paragraph"
style:parent-style-name="Standard" <style:paragraph-properties
fo:margin-top="0.9cm" fo:margin-bottom="0cm" fo:margin-left="0cm"
fo:margin-right="1.9cm"

Document Defaults
<style:default-style style:family="paragraph"><style:paragraph-properties
fo:margin-top="4cm" fo:margin-bottom="3cm" fo:margin-left="2cm"
fo:margin-right="5cm"

To reproduce.
1.) open the ODT file and notice that both paragraphs are set to MyStyle.
2.) look at the paragraph properties. Notice that the spacing that is not zero
matches the Docuemnt Defaults, not the MyStyle settings.

Expected results: Paragraph 1 has no upper/lower space and not left/right
space. Paragraph 2 has a top margin of .9 and a right margin of 1.9

Actual results: Paragraph 1 has "Before text" 2cm and "Below paragraph" 3cm.
Paragraph 2 has "After Text" 5cm and "Above paragraph" 4cm</pre>
        </div>
      </p>


      <hr>
      <span>You are receiving this mail because:</span>

      <ul>
          <li>You are the assignee for the bug.</li>
      </ul>
    </body>
</html>