r24819 by jghali - Move variable declaration closer to its first use

scribus-commit scribus-commit at lists.scribus.net
Sun Jan 23 14:04:47 UTC 2022


Author: jghali
Date: Sun Jan 23 14:04:47 2022
New Revision: 24819

URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=24819
Log:
Move variable declaration closer to its first use

Modified:
    trunk/Scribus/scribus/plugins/import/svg/svgplugin.cpp

Modified: trunk/Scribus/scribus/plugins/import/svg/svgplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=24819&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	Sun Jan 23 14:04:47 2022
@@ -392,7 +392,6 @@
 void SVGPlug::convert(const TransactionSettings& trSettings, int flags)
 {
 	bool ret = false;
-	SvgStyle *gc = new SvgStyle;
 	QDomElement docElem = inpdoc.documentElement();
 	QSizeF wh = parseWidthHeight(docElem);
 	double width = wh.width();
@@ -431,6 +430,8 @@
 		m_Doc->view()->updatesOn(false);
 	m_Doc->scMW()->setScriptRunning(true);
 	qApp->setOverrideCursor(QCursor(Qt::WaitCursor));
+
+	SvgStyle *gc = new SvgStyle;
 	gc->FontFamily = m_Doc->itemToolPrefs().textFont;
 	if (!m_Doc->PageColors.contains("Black"))
 		m_Doc->PageColors.insert("Black", ScColor(0, 0, 0, 255));




More information about the scribus-commit mailing list