Created attachment 140798 [details] Document to test border Open attached file. The paragraphs have paragraph styles assigned, which are all based on the style "BorderBasis", which sets a 6pt orange, solid border. The style "Border0none" sets the border style to "none". That is correctly written in ODF as fo:border="none". Save this file in .docx format, it does not matter whether strict OOXML or the MS variant. It should write a w:pBdr element with child elements having attribute w:val="none", but the w:pBdr element is empty. Because the parent style has a border, it is necessary to set the border style explicitly to "none". You see the error, when you open the .docx file in Word or LibreOffice. The paragraph 0 shows a border, but should not.
Hi Regina, I reproduce with LO 6.1.0.0.alpha0+ Build ID: dd4f1b1bd31daf080dc0420524712dc244e539b5 CPU threads: 2; OS: Windows 6.1; UI render: default; TinderBox: Win-x86@42, Branch:master, Time: 2018-03-20_23:26:38 Locale: en-US (fr_FR); Calc: CL See also the error in Word 2010.
Also reproduced in Version: 4.3.0.0.alpha1+ Build ID: c15927f20d4727c3b8de68497b6949e72f9e6e9e
proposed fix: https://gerrit.libreoffice.org/#/c/58803/ The existing code used "nil" instead of "none". Documentation indicates these two are identical, so I didn't attempt to change anything in that regard. "nil" (No Border) Specifies that no border shall be applied to the current item. "none" (No Border) Specifies that no border shall be applied to the current item. Spot checks in existing unit tests provided several proof examples and tableCurrupt.docx's header was a nice visual proof. There are no existing tests where (|| !rStyleProps->LineWidth) affects the other uses of impl_border, but almost every document shows it is definitely needed for paragraphs/styles to prevent peppering the document with "nil" borders.
Justin Luth committed a patch related to this issue. It has been pushed to "master": http://cgit.freedesktop.org/libreoffice/core/commit/?id=ae74abcd85dc529aeab9e710f18b3089fdf2906f tdf#116549 docx export: write "nil" to uninherit a border It will be available in 6.2.0. The patch should be included in the daily builds available at http://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More information about daily builds can be found at: http://wiki.documentfoundation.org/Testing_Daily_Builds Affected users are encouraged to test the fix and report feedback.