Hi,

Regina Henschel suggested to use the attached patch for AOO as well. I developped it for LibreOffice and Regina was able to build AOO with the patch applied.

License: Apache License v2

Christina Roßmanith
>From 1392b3d7690cee6d963e36750d806087831f3640 Mon Sep 17 00:00:00 2001
From: "Chr. Rossmanith" <chrrossman...@gmx.de>
Date: Sun, 6 Oct 2013 08:26:42 +0200
Subject: [PATCH] fdo63235 - correct usage of marker-start/-end for svg path
 data

marker orientation will be corrected in a subsequent patch

Change-Id: I0c833b62d06ad21ebe5fbaf170cfb22cecbf146d
---
 svgio/source/svgreader/svgstyleattributes.cxx |   10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)

diff --git a/svgio/source/svgreader/svgstyleattributes.cxx b/svgio/source/svgreader/svgstyleattributes.cxx
index 511872e..67219e7 100644
--- a/svgio/source/svgreader/svgstyleattributes.cxx
+++ b/svgio/source/svgreader/svgstyleattributes.cxx
@@ -949,7 +949,7 @@ namespace svgio
                         basegfx::B2DRange aClipRange;
                         const SvgMarkerNode* pPrepared = 0;
 
-                        if(pStart)
+                        if(pStart && a==0)
                         {
                             if(prepare_singleMarker(aMarkerPrimitives, aMarkerTransform, aClipRange, *pStart))
                             {
@@ -958,20 +958,22 @@ namespace svgio
                             }
                         }
 
-                        if(pMid && nMarkerCount > 2)
+                        if(pMid)
                         {
                             if(pMid == pPrepared || prepare_singleMarker(aMarkerPrimitives, aMarkerTransform, aClipRange, *pMid))
                             {
                                 pPrepared = pMid;
+                                const sal_uInt32 nFirstIndex(a==0 ? 1 : 0);
+                                const sal_uInt32 nLastIndex(a==nCount-1 ? nMarkerCount-1 : nMarkerCount);
 
-                                for(sal_uInt32 b(1); b < nMarkerCount - 1; b++)
+                                for(sal_uInt32 b(nFirstIndex); b < nLastIndex; b++)
                                 {
                                     add_singleMarker(rTarget, aMarkerPrimitives, aMarkerTransform, aClipRange, *pPrepared, aCandidate, b);
                                 }
                             }
                         }
 
-                        if(pEnd)
+                        if(pEnd && a==nCount-1)
                         {
                             if(pEnd == pPrepared || prepare_singleMarker(aMarkerPrimitives, aMarkerTransform, aClipRange, *pEnd))
                             {
-- 
1.7.9.5


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@openoffice.apache.org
For additional commands, e-mail: dev-h...@openoffice.apache.org

Reply via email to