r23147 by jghali - Remove useless parseSVG() function in svg importer
scribus-commit
scribus-commit at lists.scribus.net
Fri Aug 23 03:35:32 UTC 2019
Author: jghali
Date: Fri Aug 23 03:35:32 2019
New Revision: 23147
URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=23147
Log:
Remove useless parseSVG() function in svg importer
Modified:
trunk/Scribus/scribus/plugins/import/svg/svgplugin.cpp
trunk/Scribus/scribus/plugins/import/svg/svgplugin.h
Modified: trunk/Scribus/scribus/plugins/import/svg/svgplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23147&path=/trunk/Scribus/scribus/plugins/import/svg/svgplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/svg/svgplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/svg/svgplugin.cpp Fri Aug 23 03:35:32 2019
@@ -1100,7 +1100,7 @@
while (b2.nodeName() == "use")
b2 = getReferencedNode(b2);
if (b2.nodeName() == "path")
- parseSVG(b2.attribute("d"), &clip);
+ clip.parseSVG(b2.attribute("d"));
else if (b2.nodeName() == "rect")
{
double x = parseUnit(b2.attribute("x", "0.0"));
@@ -1688,18 +1688,15 @@
double baseY = m_Doc->currentPage()->yOffset();
setupNode(e);
SvgStyle *gc = m_gc.top();
- PageItem::ItemType itype = parseSVG(e.attribute("d"), &pArray) ? PageItem::PolyLine : PageItem::Polygon;
+ PageItem::ItemType itype = pArray.parseSVG(e.attribute("d")) ? PageItem::PolyLine : PageItem::Polygon;
int z = m_Doc->itemAdd(itype, PageItem::Unspecified, baseX, baseY, 10, 10, gc->LWidth, gc->FillCol, gc->StrokeCol);
PageItem* ite = m_Doc->Items->at(z);
ite->fillRule = (gc->fillRule != "nonzero");
ite->PoLine = pArray;
if (ite->PoLine.size() < 4)
{
-// m_Doc->m_Selection->addItem(ite);
tmpSel->addItem(ite);
-// m_Doc->itemSelection_DeleteItem();
m_Doc->itemSelection_DeleteItem(tmpSel);
-// m_Doc->m_Selection->clear();
}
else
{
@@ -2328,11 +2325,6 @@
ptr++;
return ptr;
-}
-
-bool SVGPlug::parseSVG(const QString &s, FPointArray *ite)
-{
- return ite->parseSVG(s);
}
QString SVGPlug::parseColor(const QString &s)
Modified: trunk/Scribus/scribus/plugins/import/svg/svgplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23147&path=/trunk/Scribus/scribus/plugins/import/svg/svgplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/svg/svgplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/svg/svgplugin.h Fri Aug 23 03:35:32 2019
@@ -276,7 +276,6 @@
double parseFontSize(const QString& fsize);
double parseUnit(const QString &unit);
QTransform parseTransform(const QString &transform);
- bool parseSVG( const QString &s, FPointArray *ite );
QString parseColor( const QString &s );
QString parseIccColor( const QString &s );
QString parseTagName( const QDomElement &e );
More information about the scribus-commit
mailing list