From: Fridrich S. <str...@us...> - 2010-06-06 21:06:24
|
Update of /cvsroot/libwpg/libwpg/src/lib In directory sfp-cvsdas-2.v30.ch3.sourceforge.com:/tmp/cvs-serv27614/src/lib Modified Files: WPG2Parser.cpp Log Message: Index: WPG2Parser.cpp =================================================================== RCS file: /cvsroot/libwpg/libwpg/src/lib/WPG2Parser.cpp,v retrieving revision 1.103 retrieving revision 1.104 diff -u -d -r1.103 -r1.104 --- WPG2Parser.cpp 4 Jun 2010 15:19:00 -0000 1.103 +++ WPG2Parser.cpp 6 Jun 2010 21:06:16 -0000 1.104 @@ -648,7 +648,12 @@ else m_style.insert("svg:fill-rule", "evenodd"); - m_painter->setStyle( context.compoundFilled ? m_gradient : ::WPXPropertyListVector(), m_style ); + WPXPropertyList tmpStyle = m_style; + + if (context.compoundFilled) + tmpStyle.insert("draw:fill", "none"); + + m_painter->setStyle( context.compoundFilled ? m_gradient : ::WPXPropertyListVector(), tmpStyle ); if (context.compoundClosed) { @@ -1323,6 +1328,11 @@ parseCharacterization(&objCh); m_matrix = objCh.matrix; + WPXPropertyList tmpStyle = m_style; + + if (objCh.filled) + tmpStyle.insert("draw:fill", "none"); + bool insideCompound = m_groupStack.empty() ? false : m_groupStack.top().isCompoundPolygon(); @@ -1374,7 +1384,9 @@ m_style.insert("svg:fill-rule", "nonzero"); else m_style.insert("svg:fill-rule", "evenodd"); - m_painter->setStyle( objCh.filled ? m_gradient : ::WPXPropertyListVector(), m_style ); + + m_painter->setStyle( objCh.filled ? m_gradient : ::WPXPropertyListVector(), tmpStyle ); + if (objCh.filled || objCh.closed) m_painter->drawPolygon(points); else @@ -1382,7 +1394,8 @@ } else { - m_painter->setStyle( ::WPXPropertyListVector(), m_style ); + + m_painter->setStyle( ::WPXPropertyListVector(), tmpStyle ); m_painter->drawPolyline(points); } } @@ -1413,6 +1426,11 @@ parseCharacterization(&objCh); m_matrix = objCh.matrix; + WPXPropertyList tmpStyle = m_style; + + if (objCh.filled) + tmpStyle.insert("draw:fill", "none"); + bool insideCompound = m_groupStack.empty() ? false : m_groupStack.top().isCompoundPolygon(); @@ -1472,7 +1490,7 @@ m_style.insert("svg:fill-rule", "nonzero"); else m_style.insert("svg:fill-rule", "evenodd"); - m_painter->setStyle( objCh.filled ? m_gradient : ::WPXPropertyListVector(), m_style ); + m_painter->setStyle( objCh.filled ? m_gradient : ::WPXPropertyListVector(), tmpStyle ); m_painter->drawPath(path); } } @@ -1485,6 +1503,11 @@ parseCharacterization(&objCh); m_matrix = objCh.matrix; + WPXPropertyList tmpStyle = m_style; + + if (objCh.filled) + tmpStyle.insert("draw:fill", "none"); + long x1 = (m_doublePrecision) ? readS32() : readS16(); long y1 = (m_doublePrecision) ? readS32() : readS16(); TRANSFORM_XY(x1,y1); @@ -1510,7 +1533,7 @@ propList.insert("svg:rx", (TO_DOUBLE(rx)/m_xres)); propList.insert("svg:ry", (TO_DOUBLE(ry)/m_yres)); - m_painter->setStyle( objCh.filled ? m_gradient : ::WPXPropertyListVector(), m_style ); + m_painter->setStyle( objCh.filled ? m_gradient : ::WPXPropertyListVector(), tmpStyle ); m_painter->drawRectangle(propList); WPG_DEBUG_MSG((" X1 : %li\n", x1)); @@ -1529,6 +1552,11 @@ parseCharacterization(&objCh); m_matrix = objCh.matrix; + WPXPropertyList tmpStyle = m_style; + + if (objCh.filled) + tmpStyle.insert("draw:fill", "none"); + long cx = (m_doublePrecision) ? readS32() : readS16(); long cy = (m_doublePrecision) ? readS32() : readS16(); TRANSFORM_XY(cx,cy); @@ -1552,7 +1580,7 @@ if (objCh.rotate) propList.insert("libwpg:rotate", objCh.rotationAngle, WPX_GENERIC); - m_painter->setStyle( objCh.filled ? m_gradient : ::WPXPropertyListVector(), m_style ); + m_painter->setStyle( objCh.filled ? m_gradient : ::WPXPropertyListVector(), tmpStyle ); m_painter->drawEllipse(propList); WPG_DEBUG_MSG((" Center point x : %li\n", cx)); |