writerfilter/source/dmapper/DomainMapper_Impl.cxx |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit f2a10d9e751bdbc4ba981b6ca9d0dc127439a3c2
Author:     Justin Luth <justin.l...@collabora.com>
AuthorDate: Mon Mar 13 09:52:08 2023 -0400
Commit:     Justin Luth <jl...@mail.com>
CommitDate: Wed Mar 15 09:48:02 2023 +0000

    tdf#154129 writerfilter framePr: nhRule obey comment instructions
    
    The comment says
    "[MS-OE376] Word uses a default value of "atLeast" for
     this attribute when the value of the h attribute is not 0."
    
    But the code was setting MIN even when the attribute was 0.
    I think that was a mistake.
    
    Errata documentation confirms:
    "The standard states that 0 is a valid value of the h attribute.
    HOWEVER Word treats a value of 0 on this attribute as a value of auto."
    
    // The height of the object is determined by the content only.
        const short SizeType::VARIABLE = 0;
    
    Change-Id: I1a74da6c5cd25024aba82a68238580a7ca90c9c2
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/148806
    Tested-by: Jenkins
    Reviewed-by: Justin Luth <jl...@mail.com>

diff --git a/writerfilter/source/dmapper/DomainMapper_Impl.cxx 
b/writerfilter/source/dmapper/DomainMapper_Impl.cxx
index 910fe366fa93..adbb436b9fec 100644
--- a/writerfilter/source/dmapper/DomainMapper_Impl.cxx
+++ b/writerfilter/source/dmapper/DomainMapper_Impl.cxx
@@ -1670,7 +1670,7 @@ void DomainMapper_Impl::CheckUnregisteredFrameConversion( 
)
         }
         if (nhRule < 0)
         {
-            if (bValidH)
+            if (bValidH && nHeight)
             {
                 // [MS-OE376] Word uses a default value of "atLeast" for
                 // this attribute when the value of the h attribute is not 0.

Reply via email to