filter/source/svg/svgreader.cxx |    6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

New commits:
commit e44119c5803a807ce414d45fa060e329db1856e2
Author: Xisco Fauli <aniste...@gmail.com>
Date:   Tue Nov 10 00:24:41 2015 +0100

    SVG: tdf#95714 stop-color can be defined once too
    
    Change-Id: I8a660281a255d28981e23d3cf30ff6c337f0424d
    Reviewed-on: https://gerrit.libreoffice.org/19876
    Tested-by: Jenkins <c...@libreoffice.org>
    Reviewed-by: Armin Le Grand <armin.le.gr...@cib.de>

diff --git a/filter/source/svg/svgreader.cxx b/filter/source/svg/svgreader.cxx
index 04d8e01..4dfc072 100644
--- a/filter/source/svg/svgreader.cxx
+++ b/filter/source/svg/svgreader.cxx
@@ -513,8 +513,12 @@ struct AnnotatingVisitor
             return true; // cannot write style, svm import case
 
         // do we have a gradient fill? then write out gradient as well
-        if( rState.meFillType == GRADIENT && 
rState.maFillGradient.maStops.size() > 1 )
+        if( rState.meFillType == GRADIENT && 
rState.maFillGradient.maStops.size() > 0 )
         {
+            // if only one stop-color is defined
+            if( rState.maFillGradient.maStops.size() == 1 )
+                
rState.maFillGradient.maStops.push_back(rState.maFillGradient.maStops[0]);
+
             // TODO(F3): ODF12 supposedly also groks 
svg:linear/radialGradient. But CL says: nope.
             xAttrs->AddAttribute( "draw:name", getStyleName("svggradient", 
rState.maFillGradient.mnId) );
             if( rState.maFillGradient.meType == Gradient::LINEAR )
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to