[Libreoffice-commits] core.git: writerfilter/source

Justin Luth (via logerrit) logerrit at kemper.freedesktop.org
Tue Jan 7 16:49:37 UTC 2020


 writerfilter/source/dmapper/DomainMapper.cxx |   10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

New commits:
commit ccfccf4365362b5ba1d82b5816d5fc81a67de548
Author:     Justin Luth <justin.luth at collabora.com>
AuthorDate: Mon Dec 23 18:47:47 2019 +0300
Commit:     Justin Luth <justin_luth at sil.org>
CommitDate: Tue Jan 7 17:49:03 2020 +0100

    tdf#129522 writerfilter: allow char shadow_NONE overrides
    
    Exporting will take some extra work, so keeping that part
    separate for now.  The unit test will come when exporting
    works.
    
    The same change was made for paragraph style-overrides
    in an earlier patch, and this patch depends on it for
    proper UNO processing.
    (commit 4ca73073a0d7c62b12a7354f76f8f80adc5d98c1)
    
    Change-Id: I5282a319e89be9a63dbd99e00e35fb2d176a631d
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/85869
    Tested-by: Jenkins
    Reviewed-by: Justin Luth <justin_luth at sil.org>

diff --git a/writerfilter/source/dmapper/DomainMapper.cxx b/writerfilter/source/dmapper/DomainMapper.cxx
index 4e4fc983db07..4093980c3c9e 100644
--- a/writerfilter/source/dmapper/DomainMapper.cxx
+++ b/writerfilter/source/dmapper/DomainMapper.cxx
@@ -1913,11 +1913,11 @@ void DomainMapper::sprmWithProps( Sprm& rSprm, const PropertyMapPtr& rContext )
                 rContext->Insert( PROP_CHAR_LEFT_BORDER_DISTANCE, uno::makeAny( pBorderHandler->getLineDistance()));
                 rContext->Insert( PROP_CHAR_RIGHT_BORDER_DISTANCE, uno::makeAny( pBorderHandler->getLineDistance()));
 
-                if( pBorderHandler->getShadow() )
-                {
-                    table::ShadowFormat aFormat = writerfilter::dmapper::PropertyMap::getShadowFromBorder(pBorderHandler->getBorderLine());
-                    rContext->Insert(PROP_CHAR_SHADOW_FORMAT, uno::makeAny(aFormat));
-                }
+                table::ShadowFormat aFormat;
+                // Word only allows shadows on visible borders
+                if ( pBorderHandler->getShadow() && pBorderHandler->getBorderLine().LineStyle != table::BorderLineStyle::NONE )
+                    aFormat = writerfilter::dmapper::PropertyMap::getShadowFromBorder(pBorderHandler->getBorderLine());
+                rContext->Insert(PROP_CHAR_SHADOW_FORMAT, uno::makeAny(aFormat));
             }
         }
         break;


More information about the Libreoffice-commits mailing list