r23705 by craig - Code cleanup for inconsistent parameter names and virtual to override
scribus-commit
scribus-commit at lists.scribus.net
Tue May 5 22:44:11 UTC 2020
Author: craig
Date: Tue May 5 22:44:11 2020
New Revision: 23705
URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=23705
Log:
Code cleanup for inconsistent parameter names and virtual to override
cleanup in plugins
Modified:
trunk/Scribus/scribus/plugins/barcodegenerator/barcode.cpp
trunk/Scribus/scribus/plugins/barcodegenerator/barcode.h
trunk/Scribus/scribus/plugins/colorwheel/colorwheel.cpp
trunk/Scribus/scribus/plugins/colorwheel/colorwheel.h
trunk/Scribus/scribus/plugins/export/pixmapexport/export.cpp
trunk/Scribus/scribus/plugins/export/pixmapexport/export.h
trunk/Scribus/scribus/plugins/export/svgexplugin/svgexplugin.cpp
trunk/Scribus/scribus/plugins/export/svgexplugin/svgexplugin.h
trunk/Scribus/scribus/plugins/export/xpsexport/xpsexplugin.cpp
trunk/Scribus/scribus/plugins/export/xpsexport/xpsexplugin.h
trunk/Scribus/scribus/plugins/fileloader/oldscribusformat/oldscribusformat.h
trunk/Scribus/scribus/plugins/fileloader/scribus12format/scribus12format.cpp
trunk/Scribus/scribus/plugins/fileloader/scribus12format/scribus12format.h
trunk/Scribus/scribus/plugins/fileloader/scribus134format/scribus134format.cpp
trunk/Scribus/scribus/plugins/fileloader/scribus134format/scribus134format.h
trunk/Scribus/scribus/plugins/fileloader/scribus13format/scribus13format.cpp
trunk/Scribus/scribus/plugins/fileloader/scribus13format/scribus13format.h
trunk/Scribus/scribus/plugins/fileloader/scribus150format/scribus150format.cpp
trunk/Scribus/scribus/plugins/fileloader/scribus150format/scribus150format.h
trunk/Scribus/scribus/plugins/fontpreview/fontpreviewplugin.cpp
trunk/Scribus/scribus/plugins/fontpreview/fontpreviewplugin.h
trunk/Scribus/scribus/plugins/import/ai/importai.cpp
trunk/Scribus/scribus/plugins/import/ai/importaiplugin.cpp
trunk/Scribus/scribus/plugins/import/ai/importaiplugin.h
trunk/Scribus/scribus/plugins/import/cdr/importcdrplugin.cpp
trunk/Scribus/scribus/plugins/import/cdr/importcdrplugin.h
trunk/Scribus/scribus/plugins/import/cgm/importcgmplugin.cpp
trunk/Scribus/scribus/plugins/import/cgm/importcgmplugin.h
trunk/Scribus/scribus/plugins/import/cvg/importcvgplugin.cpp
trunk/Scribus/scribus/plugins/import/cvg/importcvgplugin.h
trunk/Scribus/scribus/plugins/import/drw/importdrwplugin.cpp
trunk/Scribus/scribus/plugins/import/drw/importdrwplugin.h
trunk/Scribus/scribus/plugins/import/emf/importemfplugin.cpp
trunk/Scribus/scribus/plugins/import/emf/importemfplugin.h
trunk/Scribus/scribus/plugins/import/fh/importfhplugin.cpp
trunk/Scribus/scribus/plugins/import/fh/importfhplugin.h
trunk/Scribus/scribus/plugins/import/idml/importidml.cpp
trunk/Scribus/scribus/plugins/import/idml/importidmlplugin.cpp
trunk/Scribus/scribus/plugins/import/idml/importidmlplugin.h
trunk/Scribus/scribus/plugins/import/idml_old/importidml.h
trunk/Scribus/scribus/plugins/import/odg/importodgplugin.cpp
trunk/Scribus/scribus/plugins/import/odg/importodgplugin.h
trunk/Scribus/scribus/plugins/import/oodraw/oodrawimp.cpp
trunk/Scribus/scribus/plugins/import/oodraw/oodrawimp.h
trunk/Scribus/scribus/plugins/import/pages/importpagesplugin.cpp
trunk/Scribus/scribus/plugins/import/pages/importpagesplugin.h
trunk/Scribus/scribus/plugins/import/pct/importpct.cpp
trunk/Scribus/scribus/plugins/import/pct/importpctplugin.cpp
trunk/Scribus/scribus/plugins/import/pct/importpctplugin.h
trunk/Scribus/scribus/plugins/import/pdf/importpdfplugin.cpp
trunk/Scribus/scribus/plugins/import/pdf/importpdfplugin.h
trunk/Scribus/scribus/plugins/import/pm/importpmplugin.cpp
trunk/Scribus/scribus/plugins/import/pm/importpmplugin.h
trunk/Scribus/scribus/plugins/import/ps/importpsplugin.h
trunk/Scribus/scribus/plugins/import/pub/importpubplugin.cpp
trunk/Scribus/scribus/plugins/import/pub/importpubplugin.h
trunk/Scribus/scribus/plugins/import/qxp/importqxpplugin.h
trunk/Scribus/scribus/plugins/import/shape/importshapeplugin.cpp
trunk/Scribus/scribus/plugins/import/shape/importshapeplugin.h
trunk/Scribus/scribus/plugins/import/sml/importsmlplugin.cpp
trunk/Scribus/scribus/plugins/import/sml/importsmlplugin.h
trunk/Scribus/scribus/plugins/import/svg/svgplugin.cpp
trunk/Scribus/scribus/plugins/import/svg/svgplugin.h
trunk/Scribus/scribus/plugins/import/svm/importsvmplugin.cpp
trunk/Scribus/scribus/plugins/import/svm/importsvmplugin.h
trunk/Scribus/scribus/plugins/import/uniconvertor/uniconvplugin.cpp
trunk/Scribus/scribus/plugins/import/uniconvertor/uniconvplugin.h
trunk/Scribus/scribus/plugins/import/viva/importviva.cpp
trunk/Scribus/scribus/plugins/import/viva/importvivaplugin.cpp
trunk/Scribus/scribus/plugins/import/viva/importvivaplugin.h
trunk/Scribus/scribus/plugins/import/vsd/importvsdplugin.cpp
trunk/Scribus/scribus/plugins/import/vsd/importvsdplugin.h
trunk/Scribus/scribus/plugins/import/wmf/wmfimportplugin.cpp
trunk/Scribus/scribus/plugins/import/wmf/wmfimportplugin.h
trunk/Scribus/scribus/plugins/import/wpg/importwpgplugin.cpp
trunk/Scribus/scribus/plugins/import/wpg/importwpgplugin.h
trunk/Scribus/scribus/plugins/import/xar/importxar.cpp
trunk/Scribus/scribus/plugins/import/xar/importxarplugin.cpp
trunk/Scribus/scribus/plugins/import/xar/importxarplugin.h
trunk/Scribus/scribus/plugins/import/xfig/importxfigplugin.cpp
trunk/Scribus/scribus/plugins/import/xfig/importxfigplugin.h
trunk/Scribus/scribus/plugins/import/xps/importxpsplugin.cpp
trunk/Scribus/scribus/plugins/import/xps/importxpsplugin.h
trunk/Scribus/scribus/plugins/import/zmf/importzmfplugin.h
trunk/Scribus/scribus/plugins/imposition/imposition.h
trunk/Scribus/scribus/plugins/imposition/impositionplugin.h
trunk/Scribus/scribus/plugins/myplugin/myplugin.h
trunk/Scribus/scribus/plugins/newfromtemplateplugin/nftemplate.h
trunk/Scribus/scribus/plugins/picbrowser/picturebrowserplugin.cpp
trunk/Scribus/scribus/plugins/picbrowser/picturebrowserplugin.h
trunk/Scribus/scribus/plugins/saveastemplateplugin/satemplate.cpp
trunk/Scribus/scribus/plugins/saveastemplateplugin/satemplate.h
trunk/Scribus/scribus/plugins/scripter/scripter.h
trunk/Scribus/scribus/plugins/scriptplugin/cmdannotations.cpp
trunk/Scribus/scribus/plugins/scriptplugin/scriptercore.cpp
trunk/Scribus/scribus/plugins/scriptplugin/scriptercore.h
trunk/Scribus/scribus/plugins/scriptplugin/scriptplugin.cpp
trunk/Scribus/scribus/plugins/scriptplugin/scriptplugin.h
trunk/Scribus/scribus/plugins/scriptplugin_py2x/pconsole.h
trunk/Scribus/scribus/plugins/scriptplugin_py2x/scriptplugin.h
trunk/Scribus/scribus/plugins/shapes/shapeplugin.cpp
trunk/Scribus/scribus/plugins/shapes/shapeplugin.h
trunk/Scribus/scribus/plugins/short-words/shortwords.cpp
trunk/Scribus/scribus/plugins/short-words/shortwords.h
trunk/Scribus/scribus/plugins/tools/2geomtools/meshdistortion/meshdistortion.cpp
trunk/Scribus/scribus/plugins/tools/2geomtools/meshdistortion/meshdistortion.h
trunk/Scribus/scribus/plugins/tools/2geomtools/meshdistortion/meshdistortiondialog.cpp
trunk/Scribus/scribus/plugins/tools/2geomtools/meshdistortion/meshdistortiondialog.h
trunk/Scribus/scribus/plugins/tools/2geomtools/pathalongpath/pathalongpath.cpp
trunk/Scribus/scribus/plugins/tools/2geomtools/pathalongpath/pathalongpath.h
trunk/Scribus/scribus/plugins/tools/flattenpath/flattenpath.cpp
trunk/Scribus/scribus/plugins/tools/flattenpath/flattenpath.h
trunk/Scribus/scribus/plugins/tools/hunspellcheck/hunspellplugin.cpp
trunk/Scribus/scribus/plugins/tools/hunspellcheck/hunspellplugin.h
trunk/Scribus/scribus/plugins/tools/lenseffects/lensdialog.cpp
trunk/Scribus/scribus/plugins/tools/lenseffects/lenseffects.cpp
trunk/Scribus/scribus/plugins/tools/lenseffects/lenseffects.h
trunk/Scribus/scribus/plugins/tools/pathconnect/pathconnect.cpp
trunk/Scribus/scribus/plugins/tools/pathconnect/pathconnect.h
trunk/Scribus/scribus/plugins/tools/pathcut/pathcut.cpp
trunk/Scribus/scribus/plugins/tools/pathcut/pathcut.h
trunk/Scribus/scribus/plugins/tools/pathfinder/pathfinder.cpp
trunk/Scribus/scribus/plugins/tools/pathfinder/pathfinder.h
trunk/Scribus/scribus/plugins/tools/pathfinder/pathfinderdialog.cpp
trunk/Scribus/scribus/plugins/tools/pathfinder/pathfinderdialog.h
trunk/Scribus/scribus/plugins/tools/pathstroker/pathstroker.cpp
trunk/Scribus/scribus/plugins/tools/pathstroker/pathstroker.h
trunk/Scribus/scribus/plugins/tools/smoothpath/smoothpath.cpp
trunk/Scribus/scribus/plugins/tools/smoothpath/smoothpath.h
trunk/Scribus/scribus/plugins/tools/subdivide/subdivide.cpp
trunk/Scribus/scribus/plugins/tools/subdivide/subdivide.h
trunk/Scribus/scribus/scplugin.h
trunk/Scribus/scribus/text/frect.h
Modified: trunk/Scribus/scribus/plugins/barcodegenerator/barcode.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/barcodegenerator/barcode.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/barcodegenerator/barcode.cpp (original)
+++ trunk/Scribus/scribus/plugins/barcodegenerator/barcode.cpp Tue May 5 22:44:11 2020
@@ -37,7 +37,7 @@
m_actionInfo.needsNumObjects = -1;
}
-const QString Barcode::fullTrName() const
+QString Barcode::fullTrName() const
{
return QObject::tr("Barcode Generator");
}
Modified: trunk/Scribus/scribus/plugins/barcodegenerator/barcode.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/barcodegenerator/barcode.h
==============================================================================
--- trunk/Scribus/scribus/plugins/barcodegenerator/barcode.h (original)
+++ trunk/Scribus/scribus/plugins/barcodegenerator/barcode.h Tue May 5 22:44:11 2020
@@ -25,7 +25,7 @@
/*! \brief run the plug
\param target none usage here */
bool run(ScribusDoc* doc, const QString& target = QString()) override;
- const QString fullTrName() const override;
+ QString fullTrName() const override;
const AboutData* getAboutData() const override;
void deleteAboutData(const AboutData* about) const override;
void languageChange() override;
Modified: trunk/Scribus/scribus/plugins/colorwheel/colorwheel.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/colorwheel/colorwheel.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/colorwheel/colorwheel.cpp (original)
+++ trunk/Scribus/scribus/plugins/colorwheel/colorwheel.cpp Tue May 5 22:44:11 2020
@@ -53,7 +53,7 @@
m_actionInfo.needsNumObjects = -1;
}
-const QString ColorWheelPlugin::fullTrName() const
+QString ColorWheelPlugin::fullTrName() const
{
return QObject::tr("Color Wheel");
}
Modified: trunk/Scribus/scribus/plugins/colorwheel/colorwheel.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/colorwheel/colorwheel.h
==============================================================================
--- trunk/Scribus/scribus/plugins/colorwheel/colorwheel.h (original)
+++ trunk/Scribus/scribus/plugins/colorwheel/colorwheel.h Tue May 5 22:44:11 2020
@@ -28,7 +28,7 @@
ColorWheelPlugin();
virtual ~ColorWheelPlugin();
bool run(ScribusDoc* doc, const QString& target = QString()) override;
- const QString fullTrName() const override;
+ QString fullTrName() const override;
const AboutData* getAboutData() const override;
void deleteAboutData(const AboutData* about) const override;
void languageChange() override;
Modified: trunk/Scribus/scribus/plugins/export/pixmapexport/export.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/export/pixmapexport/export.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/export/pixmapexport/export.cpp (original)
+++ trunk/Scribus/scribus/plugins/export/pixmapexport/export.cpp Tue May 5 22:44:11 2020
@@ -69,7 +69,7 @@
m_actionInfo.needsNumObjects = -1;
}
-const QString PixmapExportPlugin::fullTrName() const
+QString PixmapExportPlugin::fullTrName() const
{
return tr("Export As Image");
}
Modified: trunk/Scribus/scribus/plugins/export/pixmapexport/export.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/export/pixmapexport/export.h
==============================================================================
--- trunk/Scribus/scribus/plugins/export/pixmapexport/export.h (original)
+++ trunk/Scribus/scribus/plugins/export/pixmapexport/export.h Tue May 5 22:44:11 2020
@@ -24,7 +24,7 @@
PixmapExportPlugin();
virtual ~PixmapExportPlugin();
bool run(ScribusDoc* doc, const QString& target = QString()) override;
- const QString fullTrName() const override;
+ QString fullTrName() const override;
const AboutData* getAboutData() const override;
void deleteAboutData(const AboutData* about) const override;
void languageChange() override;
Modified: trunk/Scribus/scribus/plugins/export/svgexplugin/svgexplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/export/svgexplugin/svgexplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/export/svgexplugin/svgexplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/export/svgexplugin/svgexplugin.cpp Tue May 5 22:44:11 2020
@@ -102,7 +102,7 @@
m_actionInfo.needsNumObjects = -1;
}
-const QString SVGExportPlugin::fullTrName() const
+QString SVGExportPlugin::fullTrName() const
{
return QObject::tr("SVG Export");
}
Modified: trunk/Scribus/scribus/plugins/export/svgexplugin/svgexplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/export/svgexplugin/svgexplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/export/svgexplugin/svgexplugin.h (original)
+++ trunk/Scribus/scribus/plugins/export/svgexplugin/svgexplugin.h Tue May 5 22:44:11 2020
@@ -43,7 +43,7 @@
\retval bool true
*/
bool run(ScribusDoc* doc=nullptr, const QString& filename = QString()) override;
- const QString fullTrName() const override;
+ QString fullTrName() const override;
const AboutData* getAboutData() const override;
void deleteAboutData(const AboutData* about) const override;
void languageChange() override;
Modified: trunk/Scribus/scribus/plugins/export/xpsexport/xpsexplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/export/xpsexport/xpsexplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/export/xpsexport/xpsexplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/export/xpsexport/xpsexplugin.cpp Tue May 5 22:44:11 2020
@@ -105,7 +105,7 @@
m_actionInfo.needsNumObjects = -1;
}
-const QString XPSExportPlugin::fullTrName() const
+QString XPSExportPlugin::fullTrName() const
{
return QObject::tr("XPS Export");
}
Modified: trunk/Scribus/scribus/plugins/export/xpsexport/xpsexplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/export/xpsexport/xpsexplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/export/xpsexport/xpsexplugin.h (original)
+++ trunk/Scribus/scribus/plugins/export/xpsexport/xpsexplugin.h Tue May 5 22:44:11 2020
@@ -45,7 +45,7 @@
\retval bool true
*/
bool run(ScribusDoc* doc=nullptr, const QString& filename = QString()) override;
- const QString fullTrName() const override;
+ QString fullTrName() const override;
const AboutData* getAboutData() const override;
void deleteAboutData(const AboutData* about) const override;
void languageChange() override;
Modified: trunk/Scribus/scribus/plugins/fileloader/oldscribusformat/oldscribusformat.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/fileloader/oldscribusformat/oldscribusformat.h
==============================================================================
--- trunk/Scribus/scribus/plugins/fileloader/oldscribusformat/oldscribusformat.h (original)
+++ trunk/Scribus/scribus/plugins/fileloader/oldscribusformat/oldscribusformat.h Tue May 5 22:44:11 2020
@@ -18,15 +18,15 @@
// Standard plugin implementation
OldScribusFormat();
virtual ~OldScribusFormat();
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
virtual bool fileSupported(QIODevice* file) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
virtual bool saveFile(const QString & fileName, const FileFormat & fmt);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
// Special features - .sla page extraction support
bool loadPage(int pageNumber, bool Mpage);
Modified: trunk/Scribus/scribus/plugins/fileloader/scribus12format/scribus12format.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/fileloader/scribus12format/scribus12format.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/fileloader/scribus12format/scribus12format.cpp (original)
+++ trunk/Scribus/scribus/plugins/fileloader/scribus12format/scribus12format.cpp Tue May 5 22:44:11 2020
@@ -63,7 +63,7 @@
fmt->filter = fmt->trName + " (*.sla *.SLA *.sla.gz *.SLA.GZ *.scd *.SCD *.scd.gz *.SCD.GZ)";
}
-const QString Scribus12Format::fullTrName() const
+QString Scribus12Format::fullTrName() const
{
return QObject::tr("Scribus 1.2.x Support");
}
Modified: trunk/Scribus/scribus/plugins/fileloader/scribus12format/scribus12format.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/fileloader/scribus12format/scribus12format.h
==============================================================================
--- trunk/Scribus/scribus/plugins/fileloader/scribus12format/scribus12format.h (original)
+++ trunk/Scribus/scribus/plugins/fileloader/scribus12format/scribus12format.h Tue May 5 22:44:11 2020
@@ -29,24 +29,24 @@
// Standard plugin implementation
Scribus12Format();
virtual ~Scribus12Format();
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
//Not the same as readSLA. This one only reads max 4k of the file for speed.
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
-
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual bool saveFile(const QString & fileName, const FileFormat & fmt);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ bool saveFile(const QString & fileName, const FileFormat & fmt) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
// Special features - .sla page extraction support
- virtual bool loadPage(const QString & fileName, int pageNumber, bool Mpage, const QString& renamedPageName=QString());
- virtual bool readStyles(const QString& fileName, ScribusDoc* doc, StyleSet<ParagraphStyle> &docParagraphStyles);
- virtual bool readLineStyles(const QString& fileName, QHash<QString, multiLine> *Sty);
- virtual bool readColors(const QString& fileName, ColorList & colors);
- virtual bool readPageCount(const QString& fileName, int *num1, int *num2, QStringList & masterPageNames);
- virtual void getReplacedFontData(bool& getNewReplacement, QMap<QString,QString> &getReplacedFonts, QList<ScFace> &getDummyScFaces);
+ bool loadPage(const QString & fileName, int pageNumber, bool Mpage, const QString& renamedPageName=QString()) override;
+ bool readStyles(const QString& fileName, ScribusDoc* doc, StyleSet<ParagraphStyle> &docParagraphStyles) override;
+ bool readLineStyles(const QString& fileName, QHash<QString, multiLine> *Sty) override;
+ bool readColors(const QString& fileName, ColorList & colors) override;
+ bool readPageCount(const QString& fileName, int *num1, int *num2, QStringList & masterPageNames) override;
+ void getReplacedFontData(bool& getNewReplacement, QMap<QString,QString> &getReplacedFonts, QList<ScFace> &getDummyScFaces) override;
private:
void registerFormats();
Modified: trunk/Scribus/scribus/plugins/fileloader/scribus134format/scribus134format.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/fileloader/scribus134format/scribus134format.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/fileloader/scribus134format/scribus134format.cpp (original)
+++ trunk/Scribus/scribus/plugins/fileloader/scribus134format/scribus134format.cpp Tue May 5 22:44:11 2020
@@ -72,7 +72,7 @@
fmt->filter = fmt->trName + " (*.sla *.SLA *.sla.gz *.SLA.GZ *.scd *.SCD *.scd.gz *.SCD.GZ)";
}
-const QString Scribus134Format::fullTrName() const
+QString Scribus134Format::fullTrName() const
{
return QObject::tr("Scribus 1.3.4+ Support");
}
Modified: trunk/Scribus/scribus/plugins/fileloader/scribus134format/scribus134format.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/fileloader/scribus134format/scribus134format.h
==============================================================================
--- trunk/Scribus/scribus/plugins/fileloader/scribus134format/scribus134format.h (original)
+++ trunk/Scribus/scribus/plugins/fileloader/scribus134format/scribus134format.h Tue May 5 22:44:11 2020
@@ -38,25 +38,25 @@
// Standard plugin implementation
Scribus134Format();
virtual ~Scribus134Format();
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
//Not the same as readSLA. This one only reads max 4k of the file for speed.
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual bool saveFile(const QString & fileName, const FileFormat & fmt) { return false; };
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ bool saveFile(const QString & fileName, const FileFormat & fmt) override { return false; };
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
// Special features - .sla page extraction support
- virtual bool loadPage(const QString & fileName, int pageNumber, bool Mpage, const QString& renamedPageName=QString());
- virtual bool readStyles(const QString& fileName, ScribusDoc* doc, StyleSet<ParagraphStyle> &docParagraphStyles);
- virtual bool readCharStyles(const QString& fileName, ScribusDoc* doc, StyleSet<CharStyle> &docCharStyles);
- virtual bool readLineStyles(const QString& fileName, QHash<QString, multiLine> *Sty);
- virtual bool readColors(const QString& fileName, ColorList & colors);
- virtual bool readPageCount(const QString& fileName, int *num1, int *num2, QStringList & masterPageNames);
- virtual void getReplacedFontData(bool & getNewReplacement, QMap<QString,QString> &getReplacedFonts, QList<ScFace> &getDummyScFaces);
+ bool loadPage(const QString & fileName, int pageNumber, bool Mpage, const QString& renamedPageName=QString()) override;
+ bool readStyles(const QString& fileName, ScribusDoc* doc, StyleSet<ParagraphStyle> &docParagraphStyles) override;
+ bool readCharStyles(const QString& fileName, ScribusDoc* doc, StyleSet<CharStyle> &docCharStyles) override;
+ bool readLineStyles(const QString& fileName, QHash<QString, multiLine> *Sty) override;
+ bool readColors(const QString& fileName, ColorList & colors) override;
+ bool readPageCount(const QString& fileName, int *num1, int *num2, QStringList & masterPageNames) override;
+ void getReplacedFontData(bool & getNewReplacement, QMap<QString,QString> &getReplacedFonts, QList<ScFace> &getDummyScFaces) override;
private:
Modified: trunk/Scribus/scribus/plugins/fileloader/scribus13format/scribus13format.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/fileloader/scribus13format/scribus13format.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/fileloader/scribus13format/scribus13format.cpp (original)
+++ trunk/Scribus/scribus/plugins/fileloader/scribus13format/scribus13format.cpp Tue May 5 22:44:11 2020
@@ -65,7 +65,7 @@
fmt->filter = fmt->trName + " (*.sla *.SLA *.sla.gz *.SLA.GZ *.scd *.SCD *.scd.gz *.SCD.GZ)";
}
-const QString Scribus13Format::fullTrName() const
+QString Scribus13Format::fullTrName() const
{
return QObject::tr("Scribus 1.3.0->1.3.3.x Support");
}
Modified: trunk/Scribus/scribus/plugins/fileloader/scribus13format/scribus13format.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/fileloader/scribus13format/scribus13format.h
==============================================================================
--- trunk/Scribus/scribus/plugins/fileloader/scribus13format/scribus13format.h (original)
+++ trunk/Scribus/scribus/plugins/fileloader/scribus13format/scribus13format.h Tue May 5 22:44:11 2020
@@ -27,24 +27,24 @@
// Standard plugin implementation
Scribus13Format();
virtual ~Scribus13Format();
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
//Not the same as readSLA. This one only reads max 4k of the file for speed.
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual bool saveFile(const QString & fileName, const FileFormat & fmt) { return false; };
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ bool saveFile(const QString & fileName, const FileFormat & fmt) override { return false; };
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
// Special features - .sla page extraction support
- virtual bool loadPage(const QString & fileName, int pageNumber, bool Mpage, const QString& renamedPageName=QString());
- virtual bool readStyles(const QString& fileName, ScribusDoc* doc, StyleSet<ParagraphStyle> &docParagraphStyles);
- virtual bool readLineStyles(const QString& fileName, QHash<QString, multiLine> *Sty);
- virtual bool readColors(const QString& fileName, ColorList & colors);
- virtual bool readPageCount(const QString& fileName, int *num1, int *num2, QStringList & masterPageNames);
- virtual void getReplacedFontData(bool & getNewReplacement, QMap<QString,QString> &getReplacedFonts, QList<ScFace> &getDummyScFaces);
+ bool loadPage(const QString & fileName, int pageNumber, bool Mpage, const QString& renamedPageName=QString()) override;
+ bool readStyles(const QString& fileName, ScribusDoc* doc, StyleSet<ParagraphStyle> &docParagraphStyles) override;
+ bool readLineStyles(const QString& fileName, QHash<QString, multiLine> *Sty) override;
+ bool readColors(const QString& fileName, ColorList & colors) override;
+ bool readPageCount(const QString& fileName, int *num1, int *num2, QStringList & masterPageNames) override;
+ void getReplacedFontData(bool & getNewReplacement, QMap<QString,QString> &getReplacedFonts, QList<ScFace> &getDummyScFaces) override;
private:
void registerFormats();
Modified: trunk/Scribus/scribus/plugins/fileloader/scribus150format/scribus150format.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/fileloader/scribus150format/scribus150format.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/fileloader/scribus150format/scribus150format.cpp (original)
+++ trunk/Scribus/scribus/plugins/fileloader/scribus150format/scribus150format.cpp Tue May 5 22:44:11 2020
@@ -78,7 +78,7 @@
fmt->filter = fmt->trName + " (*.sla *.SLA *.sla.gz *.SLA.GZ *.scd *.SCD *.scd.gz *.SCD.GZ)";
}
-const QString Scribus150Format::fullTrName() const
+QString Scribus150Format::fullTrName() const
{
return QObject::tr("Scribus 1.5.0+ Support");
}
@@ -6288,7 +6288,6 @@
QString mlName = attrs.valueAsString("Name");
QString mlName2 = mlName;
readMultiline(ml, reader);
- int copyC = 1;
QHash<QString,multiLine>::ConstIterator mlit = m_Doc->MLineStyles.find(mlName2);
if (mlit != m_Doc->MLineStyles.end() && ml != mlit.value())
mlName2 = getUniqueName(mlName2, m_Doc->MLineStyles);
Modified: trunk/Scribus/scribus/plugins/fileloader/scribus150format/scribus150format.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/fileloader/scribus150format/scribus150format.h
==============================================================================
--- trunk/Scribus/scribus/plugins/fileloader/scribus150format/scribus150format.h (original)
+++ trunk/Scribus/scribus/plugins/fileloader/scribus150format/scribus150format.h Tue May 5 22:44:11 2020
@@ -42,29 +42,29 @@
// Standard plugin implementation
Scribus150Format();
virtual ~Scribus150Format();
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
//Not the same as readSLA. This one only reads max 4k of the file for speed.
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
-
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual bool saveFile(const QString & fileName, const FileFormat & fmt);
- virtual bool savePalette(const QString & fileName);
- virtual QString saveElements(double xp, double yp, double wp, double hp, Selection* selection, QByteArray &prevData);
- virtual bool loadPalette(const QString & fileName);
- virtual bool loadElements(const QString & data, const QString& fileDir, int toLayer, double Xp_in, double Yp_in, bool loc);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ bool saveFile(const QString & fileName, const FileFormat & fmt) override;
+ bool savePalette(const QString & fileName) override;
+ QString saveElements(double xp, double yp, double wp, double hp, Selection* selection, QByteArray &prevData) override;
+ bool loadPalette(const QString & fileName) override;
+ bool loadElements(const QString & data, const QString& fileDir, int toLayer, double Xp_in, double Yp_in, bool loc) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
// Special features - .sla page extraction support
- virtual bool loadPage(const QString & fileName, int pageNumber, bool Mpage, const QString& renamedPageName=QString());
- virtual bool readStyles(const QString& fileName, ScribusDoc* doc, StyleSet<ParagraphStyle> &docParagraphStyles);
- virtual bool readCharStyles(const QString& fileName, ScribusDoc* doc, StyleSet<CharStyle> &docCharStyles);
- virtual bool readLineStyles(const QString& fileName, QHash<QString, multiLine> *Sty);
- virtual bool readColors(const QString& fileName, ColorList & colors);
- virtual bool readPageCount(const QString& fileName, int *num1, int *num2, QStringList & masterPageNames);
- virtual void getReplacedFontData(bool & getNewReplacement, QMap<QString,QString> &getReplacedFonts, QList<ScFace> &getDummyScFaces);
+ bool loadPage(const QString & fileName, int pageNumber, bool Mpage, const QString& renamedPageName=QString()) override;
+ bool readStyles(const QString& fileName, ScribusDoc* doc, StyleSet<ParagraphStyle> &docParagraphStyles) override;
+ bool readCharStyles(const QString& fileName, ScribusDoc* doc, StyleSet<CharStyle> &docCharStyles) override;
+ bool readLineStyles(const QString& fileName, QHash<QString, multiLine> *Sty) override;
+ bool readColors(const QString& fileName, ColorList & colors) override;
+ bool readPageCount(const QString& fileName, int *num1, int *num2, QStringList & masterPageNames) override;
+ void getReplacedFontData(bool & getNewReplacement, QMap<QString,QString> &getReplacedFonts, QList<ScFace> &getDummyScFaces) override;
private:
Modified: trunk/Scribus/scribus/plugins/fontpreview/fontpreviewplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/fontpreview/fontpreviewplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/fontpreview/fontpreviewplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/fontpreview/fontpreviewplugin.cpp Tue May 5 22:44:11 2020
@@ -54,7 +54,7 @@
m_actionInfo.needsNumObjects = -1;
}
-const QString FontPreviewPlugin::fullTrName() const
+QString FontPreviewPlugin::fullTrName() const
{
return QObject::tr("Font Preview");
}
Modified: trunk/Scribus/scribus/plugins/fontpreview/fontpreviewplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/fontpreview/fontpreviewplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/fontpreview/fontpreviewplugin.h (original)
+++ trunk/Scribus/scribus/plugins/fontpreview/fontpreviewplugin.h Tue May 5 22:44:11 2020
@@ -22,7 +22,7 @@
virtual ~FontPreviewPlugin();
bool run(ScribusDoc* doc, const QString& target = QString()) override;
bool run(QWidget *parent, ScribusDoc* doc, const QString& target = QString()) override;
- const QString fullTrName() const override;
+ QString fullTrName() const override;
const AboutData* getAboutData() const override;
void deleteAboutData(const AboutData* about) const override;
void languageChange() override;
Modified: trunk/Scribus/scribus/plugins/import/ai/importai.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/ai/importai.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/ai/importai.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/ai/importai.cpp Tue May 5 22:44:11 2020
@@ -239,9 +239,9 @@
return tmpImage;
}
-bool AIPlug::readColors(const QString& fNameIn, ColorList & colors)
+bool AIPlug::readColors(const QString& fileName, ColorList & colors)
{
- QString fName = fNameIn;
+ QString fName(fileName);
bool success = false;
cancel = false;
double x, y, b, h;
Modified: trunk/Scribus/scribus/plugins/import/ai/importaiplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/ai/importaiplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/ai/importaiplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/ai/importaiplugin.cpp Tue May 5 22:44:11 2020
@@ -1,256 +1,256 @@
-/*
-For general Scribus (>=1.3.2) copyright and licensing information please refer
-to the COPYING file provided with the program. Following this notice may exist
-a copyright and/or license notice that predates the release of Scribus 1.3.2
-for which a new license (GPL+exception) is in place.
-*/
-#include "commonstrings.h"
-
-#include "importai.h"
-#include "importaiplugin.h"
-
-#include "prefscontext.h"
-#include "prefsfile.h"
-#include "prefsmanager.h"
-#include "scconfig.h"
-#include "scpage.h"
-#include "scraction.h"
-#include "scribuscore.h"
-#include "undomanager.h"
-#include "util_formats.h"
-
-#include "ui/customfdialog.h"
-#include "ui/scmessagebox.h"
-#include "ui/scmwmenumanager.h"
-
-#include <QApplication>
-#include <QMessageBox>
-
-int importai_getPluginAPIVersion()
-{
- return PLUGIN_API_VERSION;
-}
-
-ScPlugin* importai_getPlugin()
-{
- ImportAIPlugin* plug = new ImportAIPlugin();
- Q_CHECK_PTR(plug);
- return plug;
-}
-
-void importai_freePlugin(ScPlugin* plugin)
-{
- ImportAIPlugin* plug = dynamic_cast<ImportAIPlugin*>(plugin);
- Q_ASSERT(plug);
- delete plug;
-}
-
-ImportAIPlugin::ImportAIPlugin() :
- importAction(new ScrAction(ScrAction::DLL, "", QKeySequence(), this))
-{
- // Set action info in languageChange, so we only have to do it in one
- // place. This includes registering file format support.
- registerFormats();
- languageChange();
-}
-
-void ImportAIPlugin::languageChange()
-{
- importAction->setText( tr("Import AI..."));
- FileFormat* fmt = getFormatByExt("ai");
- fmt->trName = FormatsManager::instance()->nameOfFormat(FormatsManager::AI); // Human readable name
- fmt->filter = FormatsManager::instance()->extensionsForFormat(FormatsManager::AI); // QFileDialog filter
-}
-
-ImportAIPlugin::~ImportAIPlugin()
-{
- unregisterAll();
-}
-
-const QString ImportAIPlugin::fullTrName() const
-{
- return QObject::tr("Adobe Illustrator Importer");
-}
-
-
-const ScActionPlugin::AboutData* ImportAIPlugin::getAboutData() const
-{
- AboutData* about = new AboutData;
- about->authors = "Franz Schmid <franz at scribus.info>";
- about->shortDescription = tr("Imports Illustrator Files");
- about->description = tr("Imports most Illustrator files into the current document, converting their vector data into Scribus objects.");
- about->license = "GPL";
- Q_CHECK_PTR(about);
- return about;
-}
-
-void ImportAIPlugin::deleteAboutData(const AboutData* about) const
-{
- Q_ASSERT(about);
- delete about;
-}
-
-void ImportAIPlugin::registerFormats()
-{
- FileFormat fmt(this);
- fmt.trName = FormatsManager::instance()->nameOfFormat(FormatsManager::AI); // Human readable name
- fmt.formatId = 0;
- fmt.filter = FormatsManager::instance()->extensionsForFormat(FormatsManager::AI); // QFileDialog filter
- fmt.fileExtensions = QStringList() << "ai";
- fmt.load = true;
- fmt.save = false;
- fmt.thumb = true;
- fmt.colorReading = true;
- fmt.mimeTypes = FormatsManager::instance()->mimetypeOfFormat(FormatsManager::AI); // MIME types
- fmt.priority = 64; // Priority
- registerFormat(fmt);
-}
-
-bool ImportAIPlugin::fileSupported(QIODevice* /* file */, const QString & fileName) const
-{
- // TODO: check for %!PS-Adobe
- return true;
-}
-
-bool ImportAIPlugin::loadFile(const QString & fileName, const FileFormat &, int flags, int /*index*/)
-{
- // There's only one format to handle, so we just call import(...)
- return import(fileName, flags);
-}
-
-bool ImportAIPlugin::import(QString fileName, int flags)
-{
- if (!checkFlags(flags))
- return false;
- if (fileName.isEmpty())
- {
- flags |= lfInteractive;
- PrefsContext* prefs = PrefsManager::instance().prefsFile->getPluginContext("importai");
- QString wdir = prefs->get("wdir", ".");
- CustomFDialog diaf(ScCore->primaryMainWindow(), wdir, QObject::tr("Open"), FormatsManager::instance()->fileDialogFormatList(FormatsManager::AI));
- if (diaf.exec())
- {
- fileName = diaf.selectedFile();
- prefs->set("wdir", fileName.left(fileName.lastIndexOf("/")));
- }
- else
- return true;
- }
- m_Doc=ScCore->primaryMainWindow()->doc;
- UndoTransaction activeTransaction;
- bool emptyDoc = (m_Doc == nullptr);
- bool hasCurrentPage = (m_Doc && m_Doc->currentPage());
- TransactionSettings trSettings;
- trSettings.targetName = hasCurrentPage ? m_Doc->currentPage()->getUName() : "";
- trSettings.targetPixmap = Um::IImageFrame;
- trSettings.actionName = Um::ImportAI;
- trSettings.description = fileName;
- trSettings.actionPixmap = Um::IAI;
- if (emptyDoc || !(flags & lfInteractive) || !(flags & lfScripted))
- UndoManager::instance()->setUndoEnabled(false);
- if (UndoManager::undoEnabled())
- activeTransaction = UndoManager::instance()->beginTransaction(trSettings);
-#ifdef HAVE_POPPLER
- if (!(flags & LoadSavePlugin::lfLoadAsPattern))
- {
-/* Check if the file is an old style AI or one of the newer PDF wrapped ones */
- QFile fT(fileName);
- if (fT.open(QIODevice::ReadOnly))
- {
- QByteArray tempBuf(25, ' ');
- fT.read(tempBuf.data(), 24);
- fT.close();
- if (tempBuf.startsWith("%PDF"))
- {
- qApp->changeOverrideCursor(QCursor(Qt::ArrowCursor));
- ScMessageBox msgBox(ScCore->primaryMainWindow());
- msgBox.setText( tr("This file contains 2 versions of the data."));
- msgBox.setInformativeText( tr("Choose which one should be imported"));
- msgBox.setIcon(QMessageBox::Question);
- QPushButton *pdfButton = msgBox.addButton( tr("Use the pdf part"), QMessageBox::ActionRole);
- msgBox.addButton( tr("Use the ai part"), QMessageBox::ActionRole);
- msgBox.setDefaultButton(pdfButton);
- msgBox.exec();
- if ((QPushButton *)msgBox.clickedButton() == pdfButton)
- {
- //Import PDF
- const FileFormat *fmt = LoadSavePlugin::getFormatByExt("pdf");
- if (!fmt)
- {
- ScMessageBox::warning(ScCore->primaryMainWindow(), CommonStrings::trWarning, tr("The PDF Import plugin could not be found"));
- return false;
- }
- qApp->changeOverrideCursor(QCursor(Qt::WaitCursor));
- bool success = fmt->loadFile(fileName, flags);
- if (activeTransaction)
- activeTransaction.commit();
- if (emptyDoc || !(flags & lfInteractive) || !(flags & lfScripted))
- UndoManager::instance()->setUndoEnabled(true);
- if (!success)
- ScMessageBox::warning(ScCore->primaryMainWindow(), CommonStrings::trWarning, tr("The file could not be imported"));
- return success;
- }
- qApp->changeOverrideCursor(QCursor(Qt::WaitCursor));
- }
- else if (tempBuf.startsWith("%!PS-Adobe-3.0 EPSF-3.0"))
- {
- //Import EPS
- const FileFormat *fmt = LoadSavePlugin::getFormatByExt("eps");
- if (!fmt)
- {
- ScMessageBox::warning(ScCore->primaryMainWindow(), CommonStrings::trWarning, tr("The EPS Import plugin could not be found"));
- return false;
- }
- qApp->changeOverrideCursor(QCursor(Qt::WaitCursor));
- bool success = fmt->loadFile(fileName, flags);
- if (activeTransaction)
- activeTransaction.commit();
- if (emptyDoc || !(flags & lfInteractive) || !(flags & lfScripted))
- UndoManager::instance()->setUndoEnabled(true);
- if (!success)
- ScMessageBox::warning(ScCore->primaryMainWindow(), CommonStrings::trWarning, tr("The file could not be imported"));
- return success;
- }
- }
- }
-#endif
- AIPlug *dia = new AIPlug(m_Doc, flags);
- Q_CHECK_PTR(dia);
- bool success = dia->import(fileName, trSettings, flags, !(flags & lfScripted));
- if (activeTransaction)
- activeTransaction.commit();
- if (emptyDoc || !(flags & lfInteractive) || !(flags & lfScripted))
- UndoManager::instance()->setUndoEnabled(true);
- if (!success)
- ScMessageBox::warning(ScCore->primaryMainWindow(), CommonStrings::trWarning, tr("The file could not be imported"));
- delete dia;
- return success;
-}
-
-QImage ImportAIPlugin::readThumbnail(const QString& fileName)
-{
- if (fileName.isEmpty())
- return QImage();
- UndoManager::instance()->setUndoEnabled(false);
- m_Doc = nullptr;
- AIPlug *dia = new AIPlug(m_Doc, lfCreateThumbnail);
- Q_CHECK_PTR(dia);
- QImage ret = dia->readThumbnail(fileName);
- UndoManager::instance()->setUndoEnabled(true);
- delete dia;
- return ret;
-}
-
-bool ImportAIPlugin::readColors(const QString& fileName, ColorList &colors)
-{
- if (fileName.isEmpty())
- return false;
- UndoManager::instance()->setUndoEnabled(false);
- m_Doc = nullptr;
- AIPlug *dia = new AIPlug(m_Doc, lfCreateThumbnail);
- Q_CHECK_PTR(dia);
- bool ret = dia->readColors(fileName, colors);
- UndoManager::instance()->setUndoEnabled(true);
- delete dia;
- return ret;
-}
+/*
+For general Scribus (>=1.3.2) copyright and licensing information please refer
+to the COPYING file provided with the program. Following this notice may exist
+a copyright and/or license notice that predates the release of Scribus 1.3.2
+for which a new license (GPL+exception) is in place.
+*/
+#include "commonstrings.h"
+
+#include "importai.h"
+#include "importaiplugin.h"
+
+#include "prefscontext.h"
+#include "prefsfile.h"
+#include "prefsmanager.h"
+#include "scconfig.h"
+#include "scpage.h"
+#include "scraction.h"
+#include "scribuscore.h"
+#include "undomanager.h"
+#include "util_formats.h"
+
+#include "ui/customfdialog.h"
+#include "ui/scmessagebox.h"
+#include "ui/scmwmenumanager.h"
+
+#include <QApplication>
+#include <QMessageBox>
+
+int importai_getPluginAPIVersion()
+{
+ return PLUGIN_API_VERSION;
+}
+
+ScPlugin* importai_getPlugin()
+{
+ ImportAIPlugin* plug = new ImportAIPlugin();
+ Q_CHECK_PTR(plug);
+ return plug;
+}
+
+void importai_freePlugin(ScPlugin* plugin)
+{
+ ImportAIPlugin* plug = dynamic_cast<ImportAIPlugin*>(plugin);
+ Q_ASSERT(plug);
+ delete plug;
+}
+
+ImportAIPlugin::ImportAIPlugin() :
+ importAction(new ScrAction(ScrAction::DLL, "", QKeySequence(), this))
+{
+ // Set action info in languageChange, so we only have to do it in one
+ // place. This includes registering file format support.
+ registerFormats();
+ languageChange();
+}
+
+void ImportAIPlugin::languageChange()
+{
+ importAction->setText( tr("Import AI..."));
+ FileFormat* fmt = getFormatByExt("ai");
+ fmt->trName = FormatsManager::instance()->nameOfFormat(FormatsManager::AI); // Human readable name
+ fmt->filter = FormatsManager::instance()->extensionsForFormat(FormatsManager::AI); // QFileDialog filter
+}
+
+ImportAIPlugin::~ImportAIPlugin()
+{
+ unregisterAll();
+}
+
+QString ImportAIPlugin::fullTrName() const
+{
+ return QObject::tr("Adobe Illustrator Importer");
+}
+
+
+const ScActionPlugin::AboutData* ImportAIPlugin::getAboutData() const
+{
+ AboutData* about = new AboutData;
+ about->authors = "Franz Schmid <franz at scribus.info>";
+ about->shortDescription = tr("Imports Illustrator Files");
+ about->description = tr("Imports most Illustrator files into the current document, converting their vector data into Scribus objects.");
+ about->license = "GPL";
+ Q_CHECK_PTR(about);
+ return about;
+}
+
+void ImportAIPlugin::deleteAboutData(const AboutData* about) const
+{
+ Q_ASSERT(about);
+ delete about;
+}
+
+void ImportAIPlugin::registerFormats()
+{
+ FileFormat fmt(this);
+ fmt.trName = FormatsManager::instance()->nameOfFormat(FormatsManager::AI); // Human readable name
+ fmt.formatId = 0;
+ fmt.filter = FormatsManager::instance()->extensionsForFormat(FormatsManager::AI); // QFileDialog filter
+ fmt.fileExtensions = QStringList() << "ai";
+ fmt.load = true;
+ fmt.save = false;
+ fmt.thumb = true;
+ fmt.colorReading = true;
+ fmt.mimeTypes = FormatsManager::instance()->mimetypeOfFormat(FormatsManager::AI); // MIME types
+ fmt.priority = 64; // Priority
+ registerFormat(fmt);
+}
+
+bool ImportAIPlugin::fileSupported(QIODevice* /* file */, const QString & fileName) const
+{
+ // TODO: check for %!PS-Adobe
+ return true;
+}
+
+bool ImportAIPlugin::loadFile(const QString & fileName, const FileFormat & /*fmt*/, int flags, int /*index*/)
+{
+ // There's only one format to handle, so we just call import(...)
+ return import(fileName, flags);
+}
+
+bool ImportAIPlugin::import(QString fileName, int flags)
+{
+ if (!checkFlags(flags))
+ return false;
+ if (fileName.isEmpty())
+ {
+ flags |= lfInteractive;
+ PrefsContext* prefs = PrefsManager::instance().prefsFile->getPluginContext("importai");
+ QString wdir = prefs->get("wdir", ".");
+ CustomFDialog diaf(ScCore->primaryMainWindow(), wdir, QObject::tr("Open"), FormatsManager::instance()->fileDialogFormatList(FormatsManager::AI));
+ if (diaf.exec())
+ {
+ fileName = diaf.selectedFile();
+ prefs->set("wdir", fileName.left(fileName.lastIndexOf("/")));
+ }
+ else
+ return true;
+ }
+ m_Doc=ScCore->primaryMainWindow()->doc;
+ UndoTransaction activeTransaction;
+ bool emptyDoc = (m_Doc == nullptr);
+ bool hasCurrentPage = (m_Doc && m_Doc->currentPage());
+ TransactionSettings trSettings;
+ trSettings.targetName = hasCurrentPage ? m_Doc->currentPage()->getUName() : "";
+ trSettings.targetPixmap = Um::IImageFrame;
+ trSettings.actionName = Um::ImportAI;
+ trSettings.description = fileName;
+ trSettings.actionPixmap = Um::IAI;
+ if (emptyDoc || !(flags & lfInteractive) || !(flags & lfScripted))
+ UndoManager::instance()->setUndoEnabled(false);
+ if (UndoManager::undoEnabled())
+ activeTransaction = UndoManager::instance()->beginTransaction(trSettings);
+#ifdef HAVE_POPPLER
+ if (!(flags & LoadSavePlugin::lfLoadAsPattern))
+ {
+/* Check if the file is an old style AI or one of the newer PDF wrapped ones */
+ QFile fT(fileName);
+ if (fT.open(QIODevice::ReadOnly))
+ {
+ QByteArray tempBuf(25, ' ');
+ fT.read(tempBuf.data(), 24);
+ fT.close();
+ if (tempBuf.startsWith("%PDF"))
+ {
+ qApp->changeOverrideCursor(QCursor(Qt::ArrowCursor));
+ ScMessageBox msgBox(ScCore->primaryMainWindow());
+ msgBox.setText( tr("This file contains 2 versions of the data."));
+ msgBox.setInformativeText( tr("Choose which one should be imported"));
+ msgBox.setIcon(QMessageBox::Question);
+ QPushButton *pdfButton = msgBox.addButton( tr("Use the pdf part"), QMessageBox::ActionRole);
+ msgBox.addButton( tr("Use the ai part"), QMessageBox::ActionRole);
+ msgBox.setDefaultButton(pdfButton);
+ msgBox.exec();
+ if ((QPushButton *)msgBox.clickedButton() == pdfButton)
+ {
+ //Import PDF
+ const FileFormat *fmt = LoadSavePlugin::getFormatByExt("pdf");
+ if (!fmt)
+ {
+ ScMessageBox::warning(ScCore->primaryMainWindow(), CommonStrings::trWarning, tr("The PDF Import plugin could not be found"));
+ return false;
+ }
+ qApp->changeOverrideCursor(QCursor(Qt::WaitCursor));
+ bool success = fmt->loadFile(fileName, flags);
+ if (activeTransaction)
+ activeTransaction.commit();
+ if (emptyDoc || !(flags & lfInteractive) || !(flags & lfScripted))
+ UndoManager::instance()->setUndoEnabled(true);
+ if (!success)
+ ScMessageBox::warning(ScCore->primaryMainWindow(), CommonStrings::trWarning, tr("The file could not be imported"));
+ return success;
+ }
+ qApp->changeOverrideCursor(QCursor(Qt::WaitCursor));
+ }
+ else if (tempBuf.startsWith("%!PS-Adobe-3.0 EPSF-3.0"))
+ {
+ //Import EPS
+ const FileFormat *fmt = LoadSavePlugin::getFormatByExt("eps");
+ if (!fmt)
+ {
+ ScMessageBox::warning(ScCore->primaryMainWindow(), CommonStrings::trWarning, tr("The EPS Import plugin could not be found"));
+ return false;
+ }
+ qApp->changeOverrideCursor(QCursor(Qt::WaitCursor));
+ bool success = fmt->loadFile(fileName, flags);
+ if (activeTransaction)
+ activeTransaction.commit();
+ if (emptyDoc || !(flags & lfInteractive) || !(flags & lfScripted))
+ UndoManager::instance()->setUndoEnabled(true);
+ if (!success)
+ ScMessageBox::warning(ScCore->primaryMainWindow(), CommonStrings::trWarning, tr("The file could not be imported"));
+ return success;
+ }
+ }
+ }
+#endif
+ AIPlug *dia = new AIPlug(m_Doc, flags);
+ Q_CHECK_PTR(dia);
+ bool success = dia->import(fileName, trSettings, flags, !(flags & lfScripted));
+ if (activeTransaction)
+ activeTransaction.commit();
+ if (emptyDoc || !(flags & lfInteractive) || !(flags & lfScripted))
+ UndoManager::instance()->setUndoEnabled(true);
+ if (!success)
+ ScMessageBox::warning(ScCore->primaryMainWindow(), CommonStrings::trWarning, tr("The file could not be imported"));
+ delete dia;
+ return success;
+}
+
+QImage ImportAIPlugin::readThumbnail(const QString& fileName)
+{
+ if (fileName.isEmpty())
+ return QImage();
+ UndoManager::instance()->setUndoEnabled(false);
+ m_Doc = nullptr;
+ AIPlug *dia = new AIPlug(m_Doc, lfCreateThumbnail);
+ Q_CHECK_PTR(dia);
+ QImage ret = dia->readThumbnail(fileName);
+ UndoManager::instance()->setUndoEnabled(true);
+ delete dia;
+ return ret;
+}
+
+bool ImportAIPlugin::readColors(const QString& fileName, ColorList &colors)
+{
+ if (fileName.isEmpty())
+ return false;
+ UndoManager::instance()->setUndoEnabled(false);
+ m_Doc = nullptr;
+ AIPlug *dia = new AIPlug(m_Doc, lfCreateThumbnail);
+ Q_CHECK_PTR(dia);
+ bool ret = dia->readColors(fileName, colors);
+ UndoManager::instance()->setUndoEnabled(true);
+ delete dia;
+ return ret;
+}
Modified: trunk/Scribus/scribus/plugins/import/ai/importaiplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/ai/importaiplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/ai/importaiplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/ai/importaiplugin.h Tue May 5 22:44:11 2020
@@ -27,15 +27,15 @@
\brief Returns name of plugin
\retval QString containing name of plugin: Import EPS/PDF/PS...
*/
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual bool readColors(const QString& fileName, ColorList & colors);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ bool readColors(const QString& fileName, ColorList & colors) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/cdr/importcdrplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/cdr/importcdrplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/cdr/importcdrplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/cdr/importcdrplugin.cpp Tue May 5 22:44:11 2020
@@ -63,7 +63,7 @@
unregisterAll();
}
-const QString ImportCdrPlugin::fullTrName() const
+QString ImportCdrPlugin::fullTrName() const
{
return QObject::tr("Corel Draw Importer");
}
Modified: trunk/Scribus/scribus/plugins/import/cdr/importcdrplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/cdr/importcdrplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/cdr/importcdrplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/cdr/importcdrplugin.h Tue May 5 22:44:11 2020
@@ -27,14 +27,14 @@
\brief Returns name of plugin
\retval QString containing name of plugin: Import EPS/PDF/PS...
*/
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/cgm/importcgmplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/cgm/importcgmplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/cgm/importcgmplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/cgm/importcgmplugin.cpp Tue May 5 22:44:11 2020
@@ -68,7 +68,7 @@
unregisterAll();
}
-const QString ImportCgmPlugin::fullTrName() const
+QString ImportCgmPlugin::fullTrName() const
{
return QObject::tr("Cgm Importer");
}
Modified: trunk/Scribus/scribus/plugins/import/cgm/importcgmplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/cgm/importcgmplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/cgm/importcgmplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/cgm/importcgmplugin.h Tue May 5 22:44:11 2020
@@ -34,14 +34,14 @@
\brief Returns name of plugin
\retval QString containing name of plugin: Import EPS/PDF/PS...
*/
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/cvg/importcvgplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/cvg/importcvgplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/cvg/importcvgplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/cvg/importcvgplugin.cpp Tue May 5 22:44:11 2020
@@ -61,7 +61,7 @@
unregisterAll();
}
-const QString ImportCvgPlugin::fullTrName() const
+QString ImportCvgPlugin::fullTrName() const
{
return QObject::tr("Calamus Vector Graphics Importer");
}
Modified: trunk/Scribus/scribus/plugins/import/cvg/importcvgplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/cvg/importcvgplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/cvg/importcvgplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/cvg/importcvgplugin.h Tue May 5 22:44:11 2020
@@ -27,14 +27,14 @@
\brief Returns name of plugin
\retval QString containing name of plugin: Import EPS/PDF/PS...
*/
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/drw/importdrwplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/drw/importdrwplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/drw/importdrwplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/drw/importdrwplugin.cpp Tue May 5 22:44:11 2020
@@ -69,7 +69,7 @@
unregisterAll();
}
-const QString ImportDrwPlugin::fullTrName() const
+QString ImportDrwPlugin::fullTrName() const
{
return QObject::tr("DRW Importer");
}
Modified: trunk/Scribus/scribus/plugins/import/drw/importdrwplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/drw/importdrwplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/drw/importdrwplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/drw/importdrwplugin.h Tue May 5 22:44:11 2020
@@ -34,14 +34,14 @@
\brief Returns name of plugin
\retval QString containing name of plugin: Import EPS/PDF/PS...
*/
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/emf/importemfplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/emf/importemfplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/emf/importemfplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/emf/importemfplugin.cpp Tue May 5 22:44:11 2020
@@ -66,7 +66,7 @@
unregisterAll();
}
-const QString ImportEmfPlugin::fullTrName() const
+QString ImportEmfPlugin::fullTrName() const
{
return QObject::tr("EMF Importer");
}
Modified: trunk/Scribus/scribus/plugins/import/emf/importemfplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/emf/importemfplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/emf/importemfplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/emf/importemfplugin.h Tue May 5 22:44:11 2020
@@ -32,14 +32,14 @@
\brief Returns name of plugin
\retval QString containing name of plugin: Import EPS/PDF/PS...
*/
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/fh/importfhplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/fh/importfhplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/fh/importfhplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/fh/importfhplugin.cpp Tue May 5 22:44:11 2020
@@ -61,7 +61,7 @@
unregisterAll();
}
-const QString ImportFhPlugin::fullTrName() const
+QString ImportFhPlugin::fullTrName() const
{
return QObject::tr("Freehand Importer");
}
Modified: trunk/Scribus/scribus/plugins/import/fh/importfhplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/fh/importfhplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/fh/importfhplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/fh/importfhplugin.h Tue May 5 22:44:11 2020
@@ -27,14 +27,14 @@
\brief Returns name of plugin
\retval QString containing name of plugin: Import EPS/PDF/PS...
*/
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/idml/importidml.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/idml/importidml.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/idml/importidml.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/idml/importidml.cpp Tue May 5 22:44:11 2020
@@ -213,18 +213,18 @@
return tmp;
}
-bool IdmlPlug::readColors(const QString& fNameIn, ColorList & colors)
+bool IdmlPlug::readColors(const QString& fileName, ColorList & colors)
{
bool success = false;
importedColors.clear();
QByteArray f;
- QFileInfo fi = QFileInfo(fNameIn);
+ QFileInfo fi = QFileInfo(fileName);
QString ext = fi.suffix().toLower();
if (ext == "idml")
{
m_zip = new ScZipHandler();
- if (!m_zip->open(fNameIn))
+ if (!m_zip->open(fileName))
{
delete m_zip;
m_zip = nullptr;
@@ -235,7 +235,7 @@
}
else if (ext == "idms")
{
- loadRawText(fNameIn, f);
+ loadRawText(fileName, f);
}
if (f.isEmpty())
Modified: trunk/Scribus/scribus/plugins/import/idml/importidmlplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/idml/importidmlplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/idml/importidmlplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/idml/importidmlplugin.cpp Tue May 5 22:44:11 2020
@@ -70,7 +70,7 @@
unregisterAll();
}
-const QString ImportIdmlPlugin::fullTrName() const
+QString ImportIdmlPlugin::fullTrName() const
{
return QObject::tr("Idml Importer");
}
Modified: trunk/Scribus/scribus/plugins/import/idml/importidmlplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/idml/importidmlplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/idml/importidmlplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/idml/importidmlplugin.h Tue May 5 22:44:11 2020
@@ -40,15 +40,15 @@
\brief Returns name of plugin
\retval QString containing name of plugin: Import EPS/PDF/PS...
*/
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual bool readColors(const QString& fileName, ColorList & colors);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ bool readColors(const QString& fileName, ColorList & colors) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/idml_old/importidml.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/idml_old/importidml.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/idml_old/importidml.h (original)
+++ trunk/Scribus/scribus/plugins/import/idml_old/importidml.h Tue May 5 22:44:11 2020
@@ -29,13 +29,13 @@
virtual ~ImportIdml();
//! \brief main method to run the plug
virtual bool run(ScribusDoc* doc, QString target = QString());
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
// virtual bool import(QString fileName = QString(), int flags = lfUseCurrentPage|lfInteractive);
void registerFormats();
};
Modified: trunk/Scribus/scribus/plugins/import/odg/importodgplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/odg/importodgplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/odg/importodgplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/odg/importodgplugin.cpp Tue May 5 22:44:11 2020
@@ -70,7 +70,7 @@
unregisterAll();
}
-const QString ImportOdgPlugin::fullTrName() const
+QString ImportOdgPlugin::fullTrName() const
{
return QObject::tr("Open Document Importer");
}
Modified: trunk/Scribus/scribus/plugins/import/odg/importodgplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/odg/importodgplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/odg/importodgplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/odg/importodgplugin.h Tue May 5 22:44:11 2020
@@ -40,14 +40,14 @@
\brief Returns name of plugin
\retval QString containing name of plugin: Import EPS/PDF/PS...
*/
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/oodraw/oodrawimp.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/oodraw/oodrawimp.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/oodraw/oodrawimp.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/oodraw/oodrawimp.cpp Tue May 5 22:44:11 2020
@@ -97,7 +97,7 @@
fmt2->filter = tr("OpenOffice.org 1.x Draw (*.sxd *.SXD)");
}
-const QString OODrawImportPlugin::fullTrName() const
+QString OODrawImportPlugin::fullTrName() const
{
return QObject::tr("OpenOffice.org Draw Importer");
}
Modified: trunk/Scribus/scribus/plugins/import/oodraw/oodrawimp.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/oodraw/oodrawimp.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/oodraw/oodrawimp.h (original)
+++ trunk/Scribus/scribus/plugins/import/oodraw/oodrawimp.h Tue May 5 22:44:11 2020
@@ -27,14 +27,14 @@
// Standard plugin implementation
OODrawImportPlugin();
virtual ~OODrawImportPlugin();
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
// Special features - File->Import slot
public slots:
Modified: trunk/Scribus/scribus/plugins/import/pages/importpagesplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/pages/importpagesplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/pages/importpagesplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/pages/importpagesplugin.cpp Tue May 5 22:44:11 2020
@@ -67,7 +67,7 @@
unregisterAll();
}
-const QString ImportPagesPlugin::fullTrName() const
+QString ImportPagesPlugin::fullTrName() const
{
return QObject::tr("Pages Importer");
}
Modified: trunk/Scribus/scribus/plugins/import/pages/importpagesplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/pages/importpagesplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/pages/importpagesplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/pages/importpagesplugin.h Tue May 5 22:44:11 2020
@@ -40,14 +40,14 @@
\brief Returns name of plugin
\retval QString containing name of plugin: Import EPS/PDF/PS...
*/
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/pct/importpct.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/pct/importpct.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/pct/importpct.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/pct/importpct.cpp Tue May 5 22:44:11 2020
@@ -63,7 +63,10 @@
{
QFileInfo fi = QFileInfo(fName);
baseFile = QDir::cleanPath(QDir::toNativeSeparators(fi.absolutePath()+"/"));
- double b, h, x, y;
+ double b {0.0};
+ double h {0.0};
+ double x {0.0};
+ double y {0.0};
parseHeader(fName, x, y, b, h);
if (b == 0.0)
b = PrefsManager::instance().appPrefs.docSetupPrefs.pageWidth;
@@ -2084,7 +2087,7 @@
return QRect(QPoint(RectY, RectX), QPoint(RectH, RectW));
}
-QByteArray PctPlug::decodeRLE(QByteArray &in, quint16 bytesPerLine, int multByte)
+QByteArray PctPlug::decodeRLE(QByteArray &in, quint16 bytesPerLine, int twoByte)
{
QByteArray ret = QByteArray(bytesPerLine, ' ');
uchar *ptrOut, *ptrIn;
@@ -2102,13 +2105,13 @@
{
// Copy next len+1 bytes literally.
len++;
- len *= multByte;
+ len *= twoByte;
while (len != 0)
{
*ptrOut++ = *ptrIn++;
len--;
count++;
- if (multByte == 2)
+ if (twoByte == 2)
{
*ptrOut++ = *ptrIn++;
len--;
@@ -2122,8 +2125,8 @@
// (Interpret len as a negative 8-bit int.)
len ^= 0xFF;
len += 2;
- len *= multByte;
- if (multByte == 2)
+ len *= twoByte;
+ if (twoByte == 2)
{
c = *ptrIn++;
count++;
Modified: trunk/Scribus/scribus/plugins/import/pct/importpctplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/pct/importpctplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/pct/importpctplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/pct/importpctplugin.cpp Tue May 5 22:44:11 2020
@@ -61,7 +61,7 @@
unregisterAll();
}
-const QString ImportPctPlugin::fullTrName() const
+QString ImportPctPlugin::fullTrName() const
{
return QObject::tr("Pict Importer");
}
Modified: trunk/Scribus/scribus/plugins/import/pct/importpctplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/pct/importpctplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/pct/importpctplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/pct/importpctplugin.h Tue May 5 22:44:11 2020
@@ -27,14 +27,14 @@
\brief Returns name of plugin
\retval QString containing name of plugin: Import EPS/PDF/PS...
*/
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/pdf/importpdfplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/pdf/importpdfplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/pdf/importpdfplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/pdf/importpdfplugin.cpp Tue May 5 22:44:11 2020
@@ -76,7 +76,7 @@
unregisterAll();
}
-const QString ImportPdfPlugin::fullTrName() const
+QString ImportPdfPlugin::fullTrName() const
{
return QObject::tr("PDF Importer");
}
Modified: trunk/Scribus/scribus/plugins/import/pdf/importpdfplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/pdf/importpdfplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/pdf/importpdfplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/pdf/importpdfplugin.h Tue May 5 22:44:11 2020
@@ -27,14 +27,14 @@
\brief Returns name of plugin
\retval QString containing name of plugin: Import EPS/PDF/PS...
*/
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/pm/importpmplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/pm/importpmplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/pm/importpmplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/pm/importpmplugin.cpp Tue May 5 22:44:11 2020
@@ -61,7 +61,7 @@
unregisterAll();
}
-const QString ImportPmPlugin::fullTrName() const
+QString ImportPmPlugin::fullTrName() const
{
return QObject::tr("Pagemaker Importer");
}
Modified: trunk/Scribus/scribus/plugins/import/pm/importpmplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/pm/importpmplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/pm/importpmplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/pm/importpmplugin.h Tue May 5 22:44:11 2020
@@ -27,14 +27,14 @@
\brief Returns name of plugin
\retval QString containing name of plugin: Import EPS/PDF/PS...
*/
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/ps/importpsplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/ps/importpsplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/ps/importpsplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/ps/importpsplugin.h Tue May 5 22:44:11 2020
@@ -27,13 +27,13 @@
\brief Returns name of plugin
\retval QString containing name of plugin: Import EPS/PDF/PS...
*/
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/pub/importpubplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/pub/importpubplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/pub/importpubplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/pub/importpubplugin.cpp Tue May 5 22:44:11 2020
@@ -61,7 +61,7 @@
unregisterAll();
}
-const QString ImportPubPlugin::fullTrName() const
+QString ImportPubPlugin::fullTrName() const
{
return QObject::tr("PUB Importer");
}
Modified: trunk/Scribus/scribus/plugins/import/pub/importpubplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/pub/importpubplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/pub/importpubplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/pub/importpubplugin.h Tue May 5 22:44:11 2020
@@ -27,14 +27,14 @@
\brief Returns name of plugin
\retval QString containing name of plugin: Import EPS/PDF/PS...
*/
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/qxp/importqxpplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/qxp/importqxpplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/qxp/importqxpplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/qxp/importqxpplugin.h Tue May 5 22:44:11 2020
@@ -27,14 +27,14 @@
\brief Returns name of plugin
\retval QString containing name of plugin: Import EPS/PDF/PS...
*/
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/shape/importshapeplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/shape/importshapeplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/shape/importshapeplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/shape/importshapeplugin.cpp Tue May 5 22:44:11 2020
@@ -61,7 +61,7 @@
unregisterAll();
}
-const QString ImportShapePlugin::fullTrName() const
+QString ImportShapePlugin::fullTrName() const
{
return QObject::tr("Shape Importer");
}
Modified: trunk/Scribus/scribus/plugins/import/shape/importshapeplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/shape/importshapeplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/shape/importshapeplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/shape/importshapeplugin.h Tue May 5 22:44:11 2020
@@ -27,14 +27,14 @@
\brief Returns name of plugin
\retval QString containing name of plugin: Import EPS/PDF/PS...
*/
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/sml/importsmlplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/sml/importsmlplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/sml/importsmlplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/sml/importsmlplugin.cpp Tue May 5 22:44:11 2020
@@ -61,7 +61,7 @@
unregisterAll();
}
-const QString ImportSmlPlugin::fullTrName() const
+QString ImportSmlPlugin::fullTrName() const
{
return QObject::tr("Sml Importer");
}
Modified: trunk/Scribus/scribus/plugins/import/sml/importsmlplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/sml/importsmlplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/sml/importsmlplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/sml/importsmlplugin.h Tue May 5 22:44:11 2020
@@ -27,14 +27,14 @@
\brief Returns name of plugin
\retval QString containing name of plugin: Import EPS/PDF/PS...
*/
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/svg/svgplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&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 Tue May 5 22:44:11 2020
@@ -101,7 +101,7 @@
fmt->filter = FormatsManager::instance()->extensionsForFormat(FormatsManager::SVG);
}
-const QString SVGImportPlugin::fullTrName() const
+QString SVGImportPlugin::fullTrName() const
{
return QObject::tr("SVG Import");
}
Modified: trunk/Scribus/scribus/plugins/import/svg/svgplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&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 Tue May 5 22:44:11 2020
@@ -33,14 +33,14 @@
// Standard plugin implementation
SVGImportPlugin();
virtual ~SVGImportPlugin();
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/svm/importsvmplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/svm/importsvmplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/svm/importsvmplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/svm/importsvmplugin.cpp Tue May 5 22:44:11 2020
@@ -67,7 +67,7 @@
unregisterAll();
}
-const QString ImportSvmPlugin::fullTrName() const
+QString ImportSvmPlugin::fullTrName() const
{
return QObject::tr("SVM Importer");
}
Modified: trunk/Scribus/scribus/plugins/import/svm/importsvmplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/svm/importsvmplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/svm/importsvmplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/svm/importsvmplugin.h Tue May 5 22:44:11 2020
@@ -32,14 +32,14 @@
\brief Returns name of plugin
\retval QString containing name of plugin: Import EPS/PDF/PS...
*/
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/uniconvertor/uniconvplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/uniconvertor/uniconvplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/uniconvertor/uniconvplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/uniconvertor/uniconvplugin.cpp Tue May 5 22:44:11 2020
@@ -72,7 +72,7 @@
fmt->filter = name + " (" + FormatsManager::instance()->extensionListForFormat( FormatsManager::UNICONV, 0)+")";
}
-const QString UniconvImportPlugin::fullTrName() const
+QString UniconvImportPlugin::fullTrName() const
{
return QObject::tr("Uniconvertor Import");
}
Modified: trunk/Scribus/scribus/plugins/import/uniconvertor/uniconvplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/uniconvertor/uniconvplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/uniconvertor/uniconvplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/uniconvertor/uniconvplugin.h Tue May 5 22:44:11 2020
@@ -26,13 +26,13 @@
// Standard plugin implementation
UniconvImportPlugin();
virtual ~UniconvImportPlugin();
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/viva/importviva.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/viva/importviva.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/viva/importviva.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/viva/importviva.cpp Tue May 5 22:44:11 2020
@@ -163,7 +163,7 @@
return tmp;
}
-bool VivaPlug::readColors(const QString& fNameIn, ColorList & colors)
+bool VivaPlug::readColors(const QString& fileName, ColorList & colors)
{
bool success = false;
m_Doc = new ScribusDoc();
@@ -173,7 +173,7 @@
m_Doc->setGUI(false, ScCore->primaryMainWindow(), nullptr);
importedColors.clear();
QByteArray f;
- loadRawText(fNameIn, f);
+ loadRawText(fileName, f);
if (designMapDom.setContent(f))
{
QDomElement docElem = designMapDom.documentElement();
Modified: trunk/Scribus/scribus/plugins/import/viva/importvivaplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/viva/importvivaplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/viva/importvivaplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/viva/importvivaplugin.cpp Tue May 5 22:44:11 2020
@@ -67,7 +67,7 @@
unregisterAll();
}
-const QString ImportVivaPlugin::fullTrName() const
+QString ImportVivaPlugin::fullTrName() const
{
return QObject::tr("Viva Importer");
}
Modified: trunk/Scribus/scribus/plugins/import/viva/importvivaplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/viva/importvivaplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/viva/importvivaplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/viva/importvivaplugin.h Tue May 5 22:44:11 2020
@@ -40,15 +40,15 @@
\brief Returns name of plugin
\retval QString containing name of plugin: Import EPS/PDF/PS...
*/
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual bool readColors(const QString& fileName, ColorList & colors);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ bool readColors(const QString& fileName, ColorList & colors) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/vsd/importvsdplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/vsd/importvsdplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/vsd/importvsdplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/vsd/importvsdplugin.cpp Tue May 5 22:44:11 2020
@@ -61,7 +61,7 @@
unregisterAll();
}
-const QString ImportVsdPlugin::fullTrName() const
+QString ImportVsdPlugin::fullTrName() const
{
return QObject::tr("MS Visio Importer");
}
Modified: trunk/Scribus/scribus/plugins/import/vsd/importvsdplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/vsd/importvsdplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/vsd/importvsdplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/vsd/importvsdplugin.h Tue May 5 22:44:11 2020
@@ -27,14 +27,14 @@
\brief Returns name of plugin
\retval QString containing name of plugin: Import EPS/PDF/PS...
*/
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/wmf/wmfimportplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/wmf/wmfimportplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/wmf/wmfimportplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/wmf/wmfimportplugin.cpp Tue May 5 22:44:11 2020
@@ -80,7 +80,7 @@
fmt->filter = FormatsManager::instance()->extensionsForFormat(FormatsManager::WMF);
}
-const QString WMFImportPlugin::fullTrName() const
+QString WMFImportPlugin::fullTrName() const
{
return QObject::tr("WMF Import");
}
Modified: trunk/Scribus/scribus/plugins/import/wmf/wmfimportplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/wmf/wmfimportplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/wmf/wmfimportplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/wmf/wmfimportplugin.h Tue May 5 22:44:11 2020
@@ -25,14 +25,14 @@
// Standard plugin implementation
WMFImportPlugin();
virtual ~WMFImportPlugin();
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/wpg/importwpgplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/wpg/importwpgplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/wpg/importwpgplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/wpg/importwpgplugin.cpp Tue May 5 22:44:11 2020
@@ -61,7 +61,7 @@
unregisterAll();
}
-const QString ImportWpgPlugin::fullTrName() const
+QString ImportWpgPlugin::fullTrName() const
{
return QObject::tr("WPG Importer");
}
Modified: trunk/Scribus/scribus/plugins/import/wpg/importwpgplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/wpg/importwpgplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/wpg/importwpgplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/wpg/importwpgplugin.h Tue May 5 22:44:11 2020
@@ -27,14 +27,14 @@
\brief Returns name of plugin
\retval QString containing name of plugin: Import EPS/PDF/PS...
*/
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/xar/importxar.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/xar/importxar.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/xar/importxar.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/xar/importxar.cpp Tue May 5 22:44:11 2020
@@ -67,12 +67,12 @@
progressDialog = nullptr;
}
-bool XarPlug::readColors(const QString& fNameIn, ColorList &colors)
+bool XarPlug::readColors(const QString& fileName, ColorList & colors)
{
progressDialog = nullptr;
bool success = false;
importedColors.clear();
- QFile f(fNameIn);
+ QFile f(fileName);
if (f.open(QIODevice::ReadOnly))
{
QDataStream ts(&f);
Modified: trunk/Scribus/scribus/plugins/import/xar/importxarplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/xar/importxarplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/xar/importxarplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/xar/importxarplugin.cpp Tue May 5 22:44:11 2020
@@ -61,7 +61,7 @@
unregisterAll();
}
-const QString ImportXarPlugin::fullTrName() const
+QString ImportXarPlugin::fullTrName() const
{
return QObject::tr("Xara Importer");
}
@@ -168,7 +168,7 @@
return ret;
}
-bool ImportXarPlugin::readColors(const QString& fileName, ColorList &colors)
+bool ImportXarPlugin::readColors(const QString& fileName, ColorList & colors)
{
if (fileName.isEmpty())
return false;
Modified: trunk/Scribus/scribus/plugins/import/xar/importxarplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/xar/importxarplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/xar/importxarplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/xar/importxarplugin.h Tue May 5 22:44:11 2020
@@ -27,15 +27,15 @@
\brief Returns name of plugin
\retval QString containing name of plugin: Import EPS/PDF/PS...
*/
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual bool readColors(const QString& fileName, ColorList & colors);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ bool readColors(const QString& fileName, ColorList & colors) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/xfig/importxfigplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/xfig/importxfigplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/xfig/importxfigplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/xfig/importxfigplugin.cpp Tue May 5 22:44:11 2020
@@ -61,7 +61,7 @@
unregisterAll();
}
-const QString ImportXfigPlugin::fullTrName() const
+QString ImportXfigPlugin::fullTrName() const
{
return QObject::tr("Xfig Importer");
}
Modified: trunk/Scribus/scribus/plugins/import/xfig/importxfigplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/xfig/importxfigplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/xfig/importxfigplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/xfig/importxfigplugin.h Tue May 5 22:44:11 2020
@@ -27,14 +27,14 @@
\brief Returns name of plugin
\retval QString containing name of plugin: Import EPS/PDF/PS...
*/
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/xps/importxpsplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/xps/importxpsplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/import/xps/importxpsplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/import/xps/importxpsplugin.cpp Tue May 5 22:44:11 2020
@@ -70,7 +70,7 @@
unregisterAll();
}
-const QString ImportXpsPlugin::fullTrName() const
+QString ImportXpsPlugin::fullTrName() const
{
return QObject::tr("Xps Importer");
}
Modified: trunk/Scribus/scribus/plugins/import/xps/importxpsplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/xps/importxpsplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/xps/importxpsplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/xps/importxpsplugin.h Tue May 5 22:44:11 2020
@@ -40,14 +40,14 @@
\brief Returns name of plugin
\retval QString containing name of plugin: Import EPS/PDF/PS...
*/
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/import/zmf/importzmfplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/import/zmf/importzmfplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/import/zmf/importzmfplugin.h (original)
+++ trunk/Scribus/scribus/plugins/import/zmf/importzmfplugin.h Tue May 5 22:44:11 2020
@@ -27,14 +27,14 @@
\brief Returns name of plugin
\retval QString containing name of plugin: Import EPS/PDF/PS...
*/
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual bool fileSupported(QIODevice* file, const QString & fileName=QString()) const;
- virtual bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0);
- virtual QImage readThumbnail(const QString& fileName);
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ bool fileSupported(QIODevice* file, const QString & fileName=QString()) const override;
+ bool loadFile(const QString & fileName, const FileFormat & fmt, int flags, int index = 0) override;
+ QImage readThumbnail(const QString& fileName) override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
public slots:
/*!
Modified: trunk/Scribus/scribus/plugins/imposition/imposition.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/imposition/imposition.h
==============================================================================
--- trunk/Scribus/scribus/plugins/imposition/imposition.h (original)
+++ trunk/Scribus/scribus/plugins/imposition/imposition.h Tue May 5 22:44:11 2020
@@ -67,7 +67,7 @@
void booklet16p(QList<int>*);
protected slots:
- virtual void languageChange();
+ void languageChange() override;
void setPageSize(const QString &);
void customizeSize();
void change2SidesBox(int);
Modified: trunk/Scribus/scribus/plugins/imposition/impositionplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/imposition/impositionplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/imposition/impositionplugin.h (original)
+++ trunk/Scribus/scribus/plugins/imposition/impositionplugin.h Tue May 5 22:44:11 2020
@@ -36,11 +36,11 @@
virtual bool run(QWidget* parent, ScribusDoc* doc, QString target = QString());
virtual bool run(ScribusDoc* doc, QString target = QString());
- virtual void languageChange();
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ void languageChange() override;
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
};
extern "C" PLUGIN_API int imposition_getPluginAPIVersion();
Modified: trunk/Scribus/scribus/plugins/myplugin/myplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/myplugin/myplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/myplugin/myplugin.h (original)
+++ trunk/Scribus/scribus/plugins/myplugin/myplugin.h Tue May 5 22:44:11 2020
@@ -24,11 +24,11 @@
virtual ~MyPlugin();
//! \brief main method to run the plug
virtual bool run(ScribusDoc* doc, QString target = QString());
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
// Special features (none)
};
Modified: trunk/Scribus/scribus/plugins/newfromtemplateplugin/nftemplate.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/newfromtemplateplugin/nftemplate.h
==============================================================================
--- trunk/Scribus/scribus/plugins/newfromtemplateplugin/nftemplate.h (original)
+++ trunk/Scribus/scribus/plugins/newfromtemplateplugin/nftemplate.h Tue May 5 22:44:11 2020
@@ -23,11 +23,11 @@
virtual ~NewFromTemplatePlugin();
//! \brief main method
virtual bool run(ScribusDoc* doc, QString target = QString());
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual void addToMainWindowMenu(ScribusMainWindow *) {};
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ void addToMainWindowMenu(ScribusMainWindow *) override {};
// Special features (none)
};
Modified: trunk/Scribus/scribus/plugins/picbrowser/picturebrowserplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/picbrowser/picturebrowserplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/picbrowser/picturebrowserplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/picbrowser/picturebrowserplugin.cpp Tue May 5 22:44:11 2020
@@ -48,7 +48,7 @@
m_actionInfo.enabledOnStartup = false;
}
-const QString PictureBrowserPlugin::fullTrName() const
+QString PictureBrowserPlugin::fullTrName() const
{
return QObject::tr ( "Picture Browser" );
}
Modified: trunk/Scribus/scribus/plugins/picbrowser/picturebrowserplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/picbrowser/picturebrowserplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/picbrowser/picturebrowserplugin.h (original)
+++ trunk/Scribus/scribus/plugins/picbrowser/picturebrowserplugin.h Tue May 5 22:44:11 2020
@@ -26,7 +26,7 @@
bool cleanupPlugin() override;
//! \brief main method to run the plug
bool run ( ScribusDoc* doc, const QString& target = QString() ) override;
- const QString fullTrName() const override;
+ QString fullTrName() const override;
const AboutData* getAboutData() const override;
void deleteAboutData ( const AboutData* about ) const override;
void languageChange() override;
Modified: trunk/Scribus/scribus/plugins/saveastemplateplugin/satemplate.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/saveastemplateplugin/satemplate.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/saveastemplateplugin/satemplate.cpp (original)
+++ trunk/Scribus/scribus/plugins/saveastemplateplugin/satemplate.cpp Tue May 5 22:44:11 2020
@@ -63,7 +63,7 @@
m_actionInfo.needsNumObjects = -1;
}
-const QString SaveAsTemplatePlugin::fullTrName() const
+QString SaveAsTemplatePlugin::fullTrName() const
{
return QObject::tr("Save As Template");
}
Modified: trunk/Scribus/scribus/plugins/saveastemplateplugin/satemplate.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/saveastemplateplugin/satemplate.h
==============================================================================
--- trunk/Scribus/scribus/plugins/saveastemplateplugin/satemplate.h (original)
+++ trunk/Scribus/scribus/plugins/saveastemplateplugin/satemplate.h Tue May 5 22:44:11 2020
@@ -21,7 +21,7 @@
SaveAsTemplatePlugin();
virtual ~SaveAsTemplatePlugin();
bool run(ScribusDoc* doc, const QString& target = QString()) override;
- const QString fullTrName() const override;
+ QString fullTrName() const override;
const AboutData* getAboutData() const override;
void deleteAboutData(const AboutData* about) const override;
void languageChange() override;
Modified: trunk/Scribus/scribus/plugins/scripter/scripter.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/scripter/scripter.h
==============================================================================
--- trunk/Scribus/scribus/plugins/scripter/scripter.h (original)
+++ trunk/Scribus/scribus/plugins/scripter/scripter.h Tue May 5 22:44:11 2020
@@ -19,13 +19,13 @@
public:
Scripter();
virtual ~Scripter();
- virtual bool initPlugin();
- virtual bool cleanupPlugin();
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual void addToMainWindowMenu(ScribusMainWindow *);
+ bool initPlugin() override;
+ bool cleanupPlugin() override;
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ void addToMainWindowMenu(ScribusMainWindow *) override;
private:
ScripterImpl *scripterImpl;
Modified: trunk/Scribus/scribus/plugins/scriptplugin/cmdannotations.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/scriptplugin/cmdannotations.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/scriptplugin/cmdannotations.cpp (original)
+++ trunk/Scribus/scribus/plugins/scriptplugin/cmdannotations.cpp Tue May 5 22:44:11 2020
@@ -52,7 +52,7 @@
if (item == nullptr)
return nullptr;
- if (item->isAnnotation() == false)
+ if (!item->isAnnotation())
{
PyErr_SetString(PyExc_RuntimeError,
QObject::tr("Page item must be an annotation", "python error").toLocal8Bit().constData());
@@ -123,7 +123,7 @@
if (item == nullptr)
return nullptr;
- if (item->isAnnotation() == false)
+ if (!item->isAnnotation())
{
PyErr_SetString(PyExc_RuntimeError,
QObject::tr("Page item must be an annotation", "python error").toLocal8Bit().constData());
Modified: trunk/Scribus/scribus/plugins/scriptplugin/scriptercore.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/scriptplugin/scriptercore.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/scriptplugin/scriptercore.cpp (original)
+++ trunk/Scribus/scribus/plugins/scriptplugin/scriptercore.cpp Tue May 5 22:44:11 2020
@@ -200,12 +200,12 @@
finishScriptRun();
}
-void ScripterCore::StdScript(const QString& basefilename)
+void ScripterCore::StdScript(const QString& baseFilename)
{
QString pfad = ScPaths::instance().scriptDir();
QString pfad2;
pfad2 = QDir::toNativeSeparators(pfad);
- QString fn = pfad2+basefilename+".py";
+ QString fn = pfad2+baseFilename+".py";
QFileInfo fd(fn);
if (!fd.exists())
return;
Modified: trunk/Scribus/scribus/plugins/scriptplugin/scriptercore.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/scriptplugin/scriptercore.h
==============================================================================
--- trunk/Scribus/scribus/plugins/scriptplugin/scriptercore.h (original)
+++ trunk/Scribus/scribus/plugins/scriptplugin/scriptercore.h Tue May 5 22:44:11 2020
@@ -36,7 +36,7 @@
public slots:
void runScriptDialog();
- void StdScript(const QString& filebasename);
+ void StdScript(const QString& baseFilename);
void RecentScript(const QString& fn);
void slotRunScriptFile(const QString& fileName, bool inMainInterpreter = false);
void slotRunScriptFile(const QString& fileName, QStringList arguments, bool inMainInterpreter = false);
Modified: trunk/Scribus/scribus/plugins/scriptplugin/scriptplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/scriptplugin/scriptplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/scriptplugin/scriptplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/scriptplugin/scriptplugin.cpp Tue May 5 22:44:11 2020
@@ -131,7 +131,7 @@
scripterCore->addToMainWindowMenu(mw);
}
-const QString ScriptPlugin::fullTrName() const
+QString ScriptPlugin::fullTrName() const
{
return QObject::tr("Scripter");
}
Modified: trunk/Scribus/scribus/plugins/scriptplugin/scriptplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/scriptplugin/scriptplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/scriptplugin/scriptplugin.h (original)
+++ trunk/Scribus/scribus/plugins/scriptplugin/scriptplugin.h Tue May 5 22:44:11 2020
@@ -28,7 +28,7 @@
~ScriptPlugin() override;
bool initPlugin() override;
bool cleanupPlugin() override;
- const QString fullTrName() const override;
+ QString fullTrName() const override;
const AboutData* getAboutData() const override;
void deleteAboutData(const AboutData* about) const override;
void languageChange() override;
Modified: trunk/Scribus/scribus/plugins/scriptplugin_py2x/pconsole.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/scriptplugin_py2x/pconsole.h
==============================================================================
--- trunk/Scribus/scribus/plugins/scriptplugin_py2x/pconsole.h (original)
+++ trunk/Scribus/scribus/plugins/scriptplugin_py2x/pconsole.h Tue May 5 22:44:11 2020
@@ -78,7 +78,7 @@
QString cursorTemplate;
protected slots:
- virtual void languageChange();
+ void languageChange() override;
void documentChanged(bool state);
};
Modified: trunk/Scribus/scribus/plugins/scriptplugin_py2x/scriptplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/scriptplugin_py2x/scriptplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/scriptplugin_py2x/scriptplugin.h (original)
+++ trunk/Scribus/scribus/plugins/scriptplugin_py2x/scriptplugin.h Tue May 5 22:44:11 2020
@@ -28,7 +28,7 @@
~ScriptPlugin() override;
bool initPlugin() override;
bool cleanupPlugin() override;
- const QString fullTrName() const override;
+ QString fullTrName() const override;
const AboutData* getAboutData() const override;
void deleteAboutData(const AboutData* about) const override;
void languageChange() override;
Modified: trunk/Scribus/scribus/plugins/shapes/shapeplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/shapes/shapeplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/shapes/shapeplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/shapes/shapeplugin.cpp Tue May 5 22:44:11 2020
@@ -80,7 +80,7 @@
mw->scrMenuMgr->addMenuItemStringsToMenuBar("Windows", m_actions);
}
-const QString ShapePlugin::fullTrName() const
+QString ShapePlugin::fullTrName() const
{
return QObject::tr("Custom Shapes");
}
Modified: trunk/Scribus/scribus/plugins/shapes/shapeplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/shapes/shapeplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/shapes/shapeplugin.h (original)
+++ trunk/Scribus/scribus/plugins/shapes/shapeplugin.h Tue May 5 22:44:11 2020
@@ -26,13 +26,13 @@
// Standard plugin implementation
ShapePlugin();
virtual ~ShapePlugin();
- virtual bool initPlugin();
- virtual bool cleanupPlugin();
- virtual const QString fullTrName() const;
- virtual const AboutData* getAboutData() const;
- virtual void deleteAboutData(const AboutData* about) const;
- virtual void languageChange();
- virtual void addToMainWindowMenu(ScribusMainWindow *);
+ bool initPlugin() override;
+ bool cleanupPlugin() override;
+ QString fullTrName() const override;
+ const AboutData* getAboutData() const override;
+ void deleteAboutData(const AboutData* about) const override;
+ void languageChange() override;
+ void addToMainWindowMenu(ScribusMainWindow *) override;
ShapePalette* sc_palette;
protected:
Modified: trunk/Scribus/scribus/plugins/short-words/shortwords.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/short-words/shortwords.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/short-words/shortwords.cpp (original)
+++ trunk/Scribus/scribus/plugins/short-words/shortwords.cpp Tue May 5 22:44:11 2020
@@ -81,7 +81,7 @@
m_actionInfo.needsNumObjects = -1;
}
-const QString ShortWordsPlugin::fullTrName() const
+QString ShortWordsPlugin::fullTrName() const
{
return QObject::tr("Short Words");
}
Modified: trunk/Scribus/scribus/plugins/short-words/shortwords.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/short-words/shortwords.h
==============================================================================
--- trunk/Scribus/scribus/plugins/short-words/shortwords.h (original)
+++ trunk/Scribus/scribus/plugins/short-words/shortwords.h Tue May 5 22:44:11 2020
@@ -28,7 +28,7 @@
ShortWordsPlugin();
virtual ~ShortWordsPlugin();
bool run(ScribusDoc* doc, const QString& target = QString()) override;
- const QString fullTrName() const override;
+ QString fullTrName() const override;
const AboutData* getAboutData() const override;
void deleteAboutData(const AboutData* about) const override;
void languageChange() override;
Modified: trunk/Scribus/scribus/plugins/tools/2geomtools/meshdistortion/meshdistortion.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/tools/2geomtools/meshdistortion/meshdistortion.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/tools/2geomtools/meshdistortion/meshdistortion.cpp (original)
+++ trunk/Scribus/scribus/plugins/tools/2geomtools/meshdistortion/meshdistortion.cpp Tue May 5 22:44:11 2020
@@ -88,7 +88,7 @@
m_actionInfo.needsNumObjects = 3;
}
-const QString MeshDistortionPlugin::fullTrName() const
+QString MeshDistortionPlugin::fullTrName() const
{
return QObject::tr("MeshDistortion");
}
Modified: trunk/Scribus/scribus/plugins/tools/2geomtools/meshdistortion/meshdistortion.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/tools/2geomtools/meshdistortion/meshdistortion.h
==============================================================================
--- trunk/Scribus/scribus/plugins/tools/2geomtools/meshdistortion/meshdistortion.h (original)
+++ trunk/Scribus/scribus/plugins/tools/2geomtools/meshdistortion/meshdistortion.h Tue May 5 22:44:11 2020
@@ -44,7 +44,7 @@
MeshDistortionPlugin();
virtual ~MeshDistortionPlugin();
bool run(ScribusDoc* doc, const QString& target = QString()) override;
- const QString fullTrName() const override;
+ QString fullTrName() const override;
const AboutData* getAboutData() const override;
void deleteAboutData(const AboutData* about) const override;
void languageChange() override;
Modified: trunk/Scribus/scribus/plugins/tools/2geomtools/meshdistortion/meshdistortiondialog.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/tools/2geomtools/meshdistortion/meshdistortiondialog.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/tools/2geomtools/meshdistortion/meshdistortiondialog.cpp (original)
+++ trunk/Scribus/scribus/plugins/tools/2geomtools/meshdistortion/meshdistortiondialog.cpp Tue May 5 22:44:11 2020
@@ -42,7 +42,7 @@
#include "selection.h"
#include "util_math.h"
-NodeItem::NodeItem(QRectF geom, uint num, MeshDistortionDialog *parent) : QGraphicsEllipseItem(geom)
+NodeItem::NodeItem(QRectF geom, uint num, MeshDistortionDialog* parent) : QGraphicsEllipseItem(geom)
{
dialog = parent;
handle = num;
@@ -55,18 +55,18 @@
mousePressed = false;
}
-void NodeItem::paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget)
+void NodeItem::paint(QPainter *painter, const QStyleOptionGraphicsItem *item, QWidget* widget)
{
Q_UNUSED(widget);
- if (option->state & QStyle::State_Selected)
+ if (item->state & QStyle::State_Selected)
{
painter->setBrush(Qt::red);
- painter->setPen(QPen(Qt::red, qMax(0.1, 1.0 / option->levelOfDetail)));
+ painter->setPen(QPen(Qt::red, qMax(0.1, 1.0 / item->levelOfDetail)));
}
else
{
painter->setBrush(Qt::NoBrush);
- painter->setPen(QPen(Qt::red, qMax(0.2, 2.0 / option->levelOfDetail)));
+ painter->setPen(QPen(Qt::red, qMax(0.2, 2.0 / item->levelOfDetail)));
}
painter->drawEllipse(rect());
}
Modified: trunk/Scribus/scribus/plugins/tools/2geomtools/meshdistortion/meshdistortiondialog.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/tools/2geomtools/meshdistortion/meshdistortiondialog.h
==============================================================================
--- trunk/Scribus/scribus/plugins/tools/2geomtools/meshdistortion/meshdistortiondialog.h (original)
+++ trunk/Scribus/scribus/plugins/tools/2geomtools/meshdistortion/meshdistortiondialog.h Tue May 5 22:44:11 2020
@@ -62,10 +62,10 @@
class PLUGIN_API NodeItem : public QGraphicsEllipseItem
{
public:
- NodeItem(QRectF geom, uint num, MeshDistortionDialog *parent);
+ NodeItem(QRectF geom, uint num, MeshDistortionDialog* parent);
~NodeItem() {};
- void paint(QPainter *painter, const QStyleOptionGraphicsItem *item, QWidget *widget);
+ void paint(QPainter *painter, const QStyleOptionGraphicsItem *item, QWidget* widget);
uint handle;
bool mouseMoving;
bool mousePressed;
Modified: trunk/Scribus/scribus/plugins/tools/2geomtools/pathalongpath/pathalongpath.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/tools/2geomtools/pathalongpath/pathalongpath.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/tools/2geomtools/pathalongpath/pathalongpath.cpp (original)
+++ trunk/Scribus/scribus/plugins/tools/2geomtools/pathalongpath/pathalongpath.cpp Tue May 5 22:44:11 2020
@@ -108,7 +108,7 @@
m_actionInfo.secondObjectType.append(PageItem::Polygon);
}
-const QString PathAlongPathPlugin::fullTrName() const
+QString PathAlongPathPlugin::fullTrName() const
{
return QObject::tr("PathAlongPath");
}
Modified: trunk/Scribus/scribus/plugins/tools/2geomtools/pathalongpath/pathalongpath.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/tools/2geomtools/pathalongpath/pathalongpath.h
==============================================================================
--- trunk/Scribus/scribus/plugins/tools/2geomtools/pathalongpath/pathalongpath.h (original)
+++ trunk/Scribus/scribus/plugins/tools/2geomtools/pathalongpath/pathalongpath.h Tue May 5 22:44:11 2020
@@ -61,7 +61,7 @@
PathAlongPathPlugin();
virtual ~PathAlongPathPlugin();
bool run(ScribusDoc* doc, const QString& target = QString()) override;
- const QString fullTrName() const override;
+ QString fullTrName() const override;
const AboutData* getAboutData() const override;
void deleteAboutData(const AboutData* about) const override;
void languageChange() override;
Modified: trunk/Scribus/scribus/plugins/tools/flattenpath/flattenpath.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/tools/flattenpath/flattenpath.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/tools/flattenpath/flattenpath.cpp (original)
+++ trunk/Scribus/scribus/plugins/tools/flattenpath/flattenpath.cpp Tue May 5 22:44:11 2020
@@ -88,7 +88,7 @@
m_actionInfo.needsNumObjects = 1;
}
-const QString FlattenPathPlugin::fullTrName() const
+QString FlattenPathPlugin::fullTrName() const
{
return QObject::tr("FlattenPath");
}
Modified: trunk/Scribus/scribus/plugins/tools/flattenpath/flattenpath.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/tools/flattenpath/flattenpath.h
==============================================================================
--- trunk/Scribus/scribus/plugins/tools/flattenpath/flattenpath.h (original)
+++ trunk/Scribus/scribus/plugins/tools/flattenpath/flattenpath.h Tue May 5 22:44:11 2020
@@ -39,7 +39,7 @@
FlattenPathPlugin();
virtual ~FlattenPathPlugin();
bool run(ScribusDoc* doc, const QString& target = QString()) override;
- const QString fullTrName() const override;
+ QString fullTrName() const override;
const AboutData* getAboutData() const override;
void deleteAboutData(const AboutData* about) const override;
void languageChange() override;
Modified: trunk/Scribus/scribus/plugins/tools/hunspellcheck/hunspellplugin.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/tools/hunspellcheck/hunspellplugin.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/tools/hunspellcheck/hunspellplugin.cpp (original)
+++ trunk/Scribus/scribus/plugins/tools/hunspellcheck/hunspellplugin.cpp Tue May 5 22:44:11 2020
@@ -56,7 +56,7 @@
m_actionInfo.needsNumObjects = 1;
}
-const QString HunspellPlugin::fullTrName() const
+QString HunspellPlugin::fullTrName() const
{
return QObject::tr("Hunspell Plugin");
}
Modified: trunk/Scribus/scribus/plugins/tools/hunspellcheck/hunspellplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/tools/hunspellcheck/hunspellplugin.h
==============================================================================
--- trunk/Scribus/scribus/plugins/tools/hunspellcheck/hunspellplugin.h (original)
+++ trunk/Scribus/scribus/plugins/tools/hunspellcheck/hunspellplugin.h Tue May 5 22:44:11 2020
@@ -25,7 +25,7 @@
//! \brief main method to run the plug
bool run(ScribusDoc* doc, const QString& target = QString()) override;
bool run(QWidget* p, ScribusDoc* doc, const QString& target = QString()) override;
- const QString fullTrName() const override;
+ QString fullTrName() const override;
const AboutData* getAboutData() const override;
void deleteAboutData(const AboutData* about) const override;
void languageChange() override;
Modified: trunk/Scribus/scribus/plugins/tools/lenseffects/lensdialog.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/tools/lenseffects/lensdialog.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/tools/lenseffects/lensdialog.cpp (original)
+++ trunk/Scribus/scribus/plugins/tools/lenseffects/lensdialog.cpp Tue May 5 22:44:11 2020
@@ -58,10 +58,10 @@
}
-void LensItem::paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget)
+void LensItem::paint(QPainter *painter, const QStyleOptionGraphicsItem *item, QWidget *widget)
{
Q_UNUSED(widget);
- painter->setPen(QPen(Qt::black, 1.0 / option->levelOfDetail));
+ painter->setPen(QPen(Qt::black, 1.0 / item->levelOfDetail));
QRadialGradient radialGrad(QPointF(0.5, 0.5), 1.0);
radialGrad.setColorAt(0.0, QColor(255, 0, 0, 127));
radialGrad.setColorAt(0.1, QColor(255, 0, 0, 127));
@@ -69,13 +69,13 @@
radialGrad.setCoordinateMode(QGradient::ObjectBoundingMode);
painter->setBrush(radialGrad);
painter->drawEllipse(rect().toRect());
- if (option->state & QStyle::State_Selected)
- {
- scaling = option->levelOfDetail;
- double siz = 6.0 / option->levelOfDetail;
+ if (item->state & QStyle::State_Selected)
+ {
+ scaling = item->levelOfDetail;
+ double siz = 6.0 / item->levelOfDetail;
QRectF br = boundingRect();
painter->setBrush(Qt::NoBrush);
- painter->setPen(QPen(Qt::red, 1.0 / option->levelOfDetail, Qt::DotLine));
+ painter->setPen(QPen(Qt::red, 1.0 / item->levelOfDetail, Qt::DotLine));
painter->drawRect(br);
painter->setBrush(Qt::red);
painter->setPen(Qt::NoPen);
Modified: trunk/Scribus/scribus/plugins/tools/lenseffects/lenseffects.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/tools/lenseffects/lenseffects.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/tools/lenseffects/lenseffects.cpp (original)
+++ trunk/Scribus/scribus/plugins/tools/lenseffects/lenseffects.cpp Tue May 5 22:44:11 2020
@@ -83,7 +83,7 @@
m_actionInfo.needsNumObjects = 3;
}
-const QString LensEffectsPlugin::fullTrName() const
+QString LensEffectsPlugin::fullTrName() const
{
return QObject::tr("Lens Effects");
}
Modified: trunk/Scribus/scribus/plugins/tools/lenseffects/lenseffects.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/tools/lenseffects/lenseffects.h
==============================================================================
--- trunk/Scribus/scribus/plugins/tools/lenseffects/lenseffects.h (original)
+++ trunk/Scribus/scribus/plugins/tools/lenseffects/lenseffects.h Tue May 5 22:44:11 2020
@@ -43,7 +43,7 @@
LensEffectsPlugin();
virtual ~LensEffectsPlugin();
bool run(ScribusDoc* doc, const QString& target = QString()) override;
- const QString fullTrName() const override;
+ QString fullTrName() const override;
const AboutData* getAboutData() const override;
void deleteAboutData(const AboutData* about) const override;
void languageChange() override;
Modified: trunk/Scribus/scribus/plugins/tools/pathconnect/pathconnect.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/tools/pathconnect/pathconnect.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/tools/pathconnect/pathconnect.cpp (original)
+++ trunk/Scribus/scribus/plugins/tools/pathconnect/pathconnect.cpp Tue May 5 22:44:11 2020
@@ -86,7 +86,7 @@
m_actionInfo.needsNumObjects = 2;
}
-const QString PathConnectPlugin::fullTrName() const
+QString PathConnectPlugin::fullTrName() const
{
return QObject::tr("PathConnect");
}
Modified: trunk/Scribus/scribus/plugins/tools/pathconnect/pathconnect.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/tools/pathconnect/pathconnect.h
==============================================================================
--- trunk/Scribus/scribus/plugins/tools/pathconnect/pathconnect.h (original)
+++ trunk/Scribus/scribus/plugins/tools/pathconnect/pathconnect.h Tue May 5 22:44:11 2020
@@ -47,7 +47,7 @@
PathConnectPlugin();
virtual ~PathConnectPlugin();
bool run(ScribusDoc* doc, const QString& target = QString()) override;
- const QString fullTrName() const override;
+ QString fullTrName() const override;
const AboutData* getAboutData() const override;
void deleteAboutData(const AboutData* about) const override;
void languageChange() override;
Modified: trunk/Scribus/scribus/plugins/tools/pathcut/pathcut.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/tools/pathcut/pathcut.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/tools/pathcut/pathcut.cpp (original)
+++ trunk/Scribus/scribus/plugins/tools/pathcut/pathcut.cpp Tue May 5 22:44:11 2020
@@ -94,7 +94,7 @@
m_actionInfo.secondObjectType.append(PageItem::Polygon);
}
-const QString PathCutPlugin::fullTrName() const
+QString PathCutPlugin::fullTrName() const
{
return QObject::tr("PathCutter");
}
Modified: trunk/Scribus/scribus/plugins/tools/pathcut/pathcut.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/tools/pathcut/pathcut.h
==============================================================================
--- trunk/Scribus/scribus/plugins/tools/pathcut/pathcut.h (original)
+++ trunk/Scribus/scribus/plugins/tools/pathcut/pathcut.h Tue May 5 22:44:11 2020
@@ -43,7 +43,7 @@
PathCutPlugin();
virtual ~PathCutPlugin();
bool run(ScribusDoc* doc, const QString& target = QString()) override;
- const QString fullTrName() const override;
+ QString fullTrName() const override;
const AboutData* getAboutData() const override;
void deleteAboutData(const AboutData* about) const override;
void languageChange() override;
Modified: trunk/Scribus/scribus/plugins/tools/pathfinder/pathfinder.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/tools/pathfinder/pathfinder.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/tools/pathfinder/pathfinder.cpp (original)
+++ trunk/Scribus/scribus/plugins/tools/pathfinder/pathfinder.cpp Tue May 5 22:44:11 2020
@@ -100,7 +100,7 @@
m_actionInfo.needsNumObjects = 2;
}
-const QString PathFinderPlugin::fullTrName() const
+QString PathFinderPlugin::fullTrName() const
{
return QObject::tr("PathFinder");
}
Modified: trunk/Scribus/scribus/plugins/tools/pathfinder/pathfinder.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/tools/pathfinder/pathfinder.h
==============================================================================
--- trunk/Scribus/scribus/plugins/tools/pathfinder/pathfinder.h (original)
+++ trunk/Scribus/scribus/plugins/tools/pathfinder/pathfinder.h Tue May 5 22:44:11 2020
@@ -44,7 +44,7 @@
PathFinderPlugin();
virtual ~PathFinderPlugin();
bool run(ScribusDoc* doc, const QString& target = QString()) override;
- const QString fullTrName() const override;
+ QString fullTrName() const override;
const AboutData* getAboutData() const override;
void deleteAboutData(const AboutData* about) const override;
void languageChange() override;
Modified: trunk/Scribus/scribus/plugins/tools/pathfinder/pathfinderdialog.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/tools/pathfinder/pathfinderdialog.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/tools/pathfinder/pathfinderdialog.cpp (original)
+++ trunk/Scribus/scribus/plugins/tools/pathfinder/pathfinderdialog.cpp Tue May 5 22:44:11 2020
@@ -275,12 +275,12 @@
return out;
}
-const QString PathFinderDialog::getOtherFillColor()
+QString PathFinderDialog::getOtherFillColor()
{
return otherColorComboFill->currentText();
}
-const QString PathFinderDialog::getOtherLineColor()
+QString PathFinderDialog::getOtherLineColor()
{
return otherColorComboLine->currentText();
}
Modified: trunk/Scribus/scribus/plugins/tools/pathfinder/pathfinderdialog.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/tools/pathfinder/pathfinderdialog.h
==============================================================================
--- trunk/Scribus/scribus/plugins/tools/pathfinder/pathfinderdialog.h (original)
+++ trunk/Scribus/scribus/plugins/tools/pathfinder/pathfinderdialog.h Tue May 5 22:44:11 2020
@@ -25,8 +25,8 @@
~PathFinderDialog() = default;
void updatePreview(QLabel *label, QPainterPath &path, const QColor& color, double scale);
void updatePartPreview(const QColor& color, double scale);
- const QString getOtherFillColor();
- const QString getOtherLineColor();
+ QString getOtherFillColor();
+ QString getOtherLineColor();
bool keepItem1;
bool keepItem2;
Modified: trunk/Scribus/scribus/plugins/tools/pathstroker/pathstroker.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/tools/pathstroker/pathstroker.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/tools/pathstroker/pathstroker.cpp (original)
+++ trunk/Scribus/scribus/plugins/tools/pathstroker/pathstroker.cpp Tue May 5 22:44:11 2020
@@ -96,7 +96,7 @@
m_actionInfo.needsNumObjects = 1;
}
-const QString PathStrokerPlugin::fullTrName() const
+QString PathStrokerPlugin::fullTrName() const
{
return QObject::tr("PathStroker");
}
Modified: trunk/Scribus/scribus/plugins/tools/pathstroker/pathstroker.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/tools/pathstroker/pathstroker.h
==============================================================================
--- trunk/Scribus/scribus/plugins/tools/pathstroker/pathstroker.h (original)
+++ trunk/Scribus/scribus/plugins/tools/pathstroker/pathstroker.h Tue May 5 22:44:11 2020
@@ -43,7 +43,7 @@
PathStrokerPlugin();
virtual ~PathStrokerPlugin();
bool run(ScribusDoc* doc, const QString& target = QString()) override;
- const QString fullTrName() const override;
+ QString fullTrName() const override;
const AboutData* getAboutData() const override;
void deleteAboutData(const AboutData* about) const override;
void languageChange() override;
Modified: trunk/Scribus/scribus/plugins/tools/smoothpath/smoothpath.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/tools/smoothpath/smoothpath.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/tools/smoothpath/smoothpath.cpp (original)
+++ trunk/Scribus/scribus/plugins/tools/smoothpath/smoothpath.cpp Tue May 5 22:44:11 2020
@@ -94,7 +94,7 @@
m_actionInfo.needsNumObjects = 1;
}
-const QString SmoothPathPlugin::fullTrName() const
+QString SmoothPathPlugin::fullTrName() const
{
return QObject::tr("SmoothPath");
}
Modified: trunk/Scribus/scribus/plugins/tools/smoothpath/smoothpath.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/tools/smoothpath/smoothpath.h
==============================================================================
--- trunk/Scribus/scribus/plugins/tools/smoothpath/smoothpath.h (original)
+++ trunk/Scribus/scribus/plugins/tools/smoothpath/smoothpath.h Tue May 5 22:44:11 2020
@@ -39,7 +39,7 @@
SmoothPathPlugin();
virtual ~SmoothPathPlugin();
bool run(ScribusDoc* doc, const QString& target = QString()) override;
- const QString fullTrName() const override;
+ QString fullTrName() const override;
const AboutData* getAboutData() const override;
void deleteAboutData(const AboutData* about) const override;
void languageChange() override;
Modified: trunk/Scribus/scribus/plugins/tools/subdivide/subdivide.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/tools/subdivide/subdivide.cpp
==============================================================================
--- trunk/Scribus/scribus/plugins/tools/subdivide/subdivide.cpp (original)
+++ trunk/Scribus/scribus/plugins/tools/subdivide/subdivide.cpp Tue May 5 22:44:11 2020
@@ -78,7 +78,7 @@
m_actionInfo.needsNumObjects = 1;
}
-const QString SubdividePlugin::fullTrName() const
+QString SubdividePlugin::fullTrName() const
{
return QObject::tr("Subdivide");
}
Modified: trunk/Scribus/scribus/plugins/tools/subdivide/subdivide.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/plugins/tools/subdivide/subdivide.h
==============================================================================
--- trunk/Scribus/scribus/plugins/tools/subdivide/subdivide.h (original)
+++ trunk/Scribus/scribus/plugins/tools/subdivide/subdivide.h Tue May 5 22:44:11 2020
@@ -43,7 +43,7 @@
SubdividePlugin();
virtual ~SubdividePlugin();
bool run(ScribusDoc* doc, const QString& target = QString()) override;
- const QString fullTrName() const override;
+ QString fullTrName() const override;
const AboutData* getAboutData() const override;
void deleteAboutData(const AboutData* about) const override;
void languageChange() override;
Modified: trunk/Scribus/scribus/scplugin.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/scplugin.h
==============================================================================
--- trunk/Scribus/scribus/scplugin.h (original)
+++ trunk/Scribus/scribus/scplugin.h Tue May 5 22:44:11 2020
@@ -143,7 +143,7 @@
* The results of testing the value of this can not be guaranteed,
* as its value may change depending on locale and change at runtime.
*/
- virtual const QString fullTrName() const = 0;
+ virtual QString fullTrName() const = 0;
/**
* \brief Create and return a prefs UI panel for the plugin.
@@ -512,7 +512,7 @@
//
// The API version is currently simply incremented with each incompatible
// change. Future versions may introduce a minor/major scheme if necessary.
-#define PLUGIN_API_VERSION 0x00000106
+#define PLUGIN_API_VERSION 0x00000107
#endif
Modified: trunk/Scribus/scribus/text/frect.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=23705&path=/trunk/Scribus/scribus/text/frect.h
==============================================================================
--- trunk/Scribus/scribus/text/frect.h (original)
+++ trunk/Scribus/scribus/text/frect.h Tue May 5 22:44:11 2020
@@ -5,7 +5,7 @@
**
** Created : 931028
**
-** Copyright (C) 1992-2000 Trolltech AS. All rights reserved.
+** Copyright (C) 1992-2000 Trolltech AS. All rights reserved.
**
** This file is part of the kernel module of the Qt GUI Toolkit.
**
@@ -26,7 +26,7 @@
** WARRANTY OF DESIGN, MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE.
**
** See http://www.trolltech.com/pricing.html or email sales at trolltech.com for
-** information about Qt Commercial License Agreements.
+** information about Qt Commercial License Agreements.
** See http://www.trolltech.com/qpl/ for QPL licensing information.
** See http://www.trolltech.com/gpl/ for GPL licensing information.
**
@@ -38,133 +38,129 @@
#ifndef FRECT_H
#define FRECT_H
-//#ifndef QT_H
#include "fsize.h"
-//#endif // QT_H
#if defined(topLeft)
#error "Macro definition of topLeft conflicts with FRect"
// don't just silently undo people's defines: #undef topLeft
#endif
-class FRect // rectangle class
-{
-public:
- FRect() { x1 = y1 = 0; x2 = y2 = -1; }
- FRect( FPoint &topleft, FPoint &bottomright );
- FRect( FPoint &topleft, FSize &size );
- FRect( qreal left, qreal top, qreal width, qreal height );
-
- bool isNull() const;
- bool isEmpty() const;
- bool isValid() const;
- FRect normalize() const;
-
- qreal left() const;
- qreal top() const;
- qreal right() const;
- qreal bottom() const;
-
- qreal &rLeft();
- qreal &rTop();
- qreal &rRight();
- qreal &rBottom();
-
- qreal x() const;
- qreal y() const;
- void setLeft( qreal pos );
- void setTop( qreal pos );
- void setRight( qreal pos );
- void setBottom( qreal pos );
- void setX( qreal x );
- void setY( qreal y );
-
- void setTopLeft( FPoint &p );
- void setBottomRight( FPoint &p );
- void setTopRight( FPoint &p );
- void setBottomLeft( FPoint &p );
-
- FPoint topLeft() const;
- FPoint bottomRight() const;
- FPoint topRight() const;
- FPoint bottomLeft() const;
- FPoint center() const;
-
- void rect( qreal *x, qreal *y, qreal *w, qreal *h ) const;
- void coords( qreal *xp1, qreal *yp1, qreal *xp2, qreal *yp2 ) const;
-
- void moveLeft( qreal pos );
- void moveTop( qreal pos );
- void moveRight( qreal pos );
- void moveBottom( qreal pos );
- void moveTopLeft( FPoint &p );
- void moveBottomRight( FPoint &p );
- void moveTopRight( FPoint &p );
- void moveBottomLeft( FPoint &p );
- void moveCenter( FPoint &p );
- void moveBy( qreal dx, qreal dy );
-
- void setRect( qreal x, qreal y, qreal w, qreal h );
- void setCoords( qreal xp1, qreal yp1, qreal xp2, qreal yp );
- void addCoords( qreal xp1, qreal yp1, qreal xp2, qreal yp2 );
-
- FSize size() const;
- qreal width() const;
- qreal height() const;
- void setWidth( qreal w );
- void setHeight( qreal h );
- void setSize( const FSize &s );
-
- FRect operator|(const FRect &r) const;
- FRect operator&(const FRect &r) const;
- FRect& operator|=(const FRect &r);
- FRect& operator&=(const FRect &r);
-
- bool contains( FPoint &p, bool proper=false ) const;
- bool contains( qreal x, qreal y ) const; // inline methods, _don't_ merge these
- bool contains( qreal x, qreal y, bool proper ) const;
- bool contains( const FRect &r, bool proper=false ) const;
- FRect unite( const FRect &r ) const;
- FRect intersect( const FRect &r ) const;
- bool intersects( const FRect &r ) const;
-
- friend bool operator==( const FRect &, const FRect & );
- friend bool operator!=( const FRect &, const FRect & );
-
-private:
-#if defined(Q_OS_LINUX) || defined(Q_OS_TEMP)
- friend void qt_setCoords( FRect *r, qreal xp1, qreal yp1, qreal xp2, qreal yp2 );
-#endif
-
- qreal x1;
- qreal y1;
- qreal x2;
- qreal y2;
-
+class FRect // rectangle class
+{
+ public:
+ FRect() {}
+ FRect(FPoint &topleft, FPoint &bottomright);
+ FRect(FPoint &topleft, FSize &size);
+ FRect(qreal left, qreal top, qreal width, qreal height);
+
+ bool isNull() const;
+ bool isEmpty() const;
+ bool isValid() const;
+ FRect normalize() const;
+
+ qreal left() const;
+ qreal top() const;
+ qreal right() const;
+ qreal bottom() const;
+
+ qreal &rLeft();
+ qreal &rTop();
+ qreal &rRight();
+ qreal &rBottom();
+
+ qreal x() const;
+ qreal y() const;
+ void setLeft(qreal pos);
+ void setTop(qreal pos);
+ void setRight(qreal pos);
+ void setBottom(qreal pos);
+ void setX(qreal x);
+ void setY(qreal y);
+
+ void setTopLeft(FPoint &p);
+ void setBottomRight(FPoint &p);
+ void setTopRight(FPoint &p);
+ void setBottomLeft(FPoint &p);
+
+ FPoint topLeft() const;
+ FPoint bottomRight() const;
+ FPoint topRight() const;
+ FPoint bottomLeft() const;
+ FPoint center() const;
+
+ void rect(qreal *x, qreal *y, qreal *w, qreal *h) const;
+ void coords(qreal *xp1, qreal *yp1, qreal *xp2, qreal *yp2) const;
+
+ void moveLeft(qreal pos);
+ void moveTop(qreal pos);
+ void moveRight(qreal pos);
+ void moveBottom(qreal pos);
+ void moveTopLeft(FPoint &p);
+ void moveBottomRight(FPoint &p);
+ void moveTopRight(FPoint &p);
+ void moveBottomLeft(FPoint &p);
+ void moveCenter(FPoint &p);
+ void moveBy(qreal dx, qreal dy);
+
+ void setRect(qreal x, qreal y, qreal w, qreal h);
+ void setCoords(qreal xp1, qreal yp1, qreal xp2, qreal yp);
+ void addCoords(qreal xp1, qreal yp1, qreal xp2, qreal yp2);
+
+ FSize size() const;
+ qreal width() const;
+ qreal height() const;
+ void setWidth(qreal w);
+ void setHeight(qreal h);
+ void setSize(const FSize &s);
+
+ FRect operator|(const FRect &r) const;
+ FRect operator&(const FRect &r) const;
+ FRect& operator|=(const FRect &r);
+ FRect& operator&=(const FRect &r);
+
+ bool contains(FPoint &p, bool proper=false) const;
+ bool contains(qreal x, qreal y) const; // inline methods, _don't_ merge these
+ bool contains(qreal x, qreal y, bool proper) const;
+ bool contains(const FRect &r, bool proper=false) const;
+ FRect unite(const FRect &r) const;
+ FRect intersect(const FRect &r) const;
+ bool intersects(const FRect &r) const;
+
+ friend bool operator==(const FRect &, const FRect &);
+ friend bool operator!=(const FRect &, const FRect &);
+
+ private:
+ #if defined(Q_OS_LINUX) || defined(Q_OS_TEMP)
+ friend void qt_setCoords(FRect *r, qreal xp1, qreal yp1, qreal xp2, qreal yp2);
+ #endif
+ qreal x1 {0.0};
+ qreal y1 {0.0};
+ qreal x2 {-1.0};
+ qreal y2 {-1.0};
};
-bool operator==( const FRect &, const FRect & );
-bool operator!=( const FRect &, const FRect & );
+bool operator==(const FRect &, const FRect &);
+bool operator!=(const FRect &, const FRect &);
/*****************************************************************************
- FRect stream functions
+ FRect stream functions
*****************************************************************************/
// #ifndef QT_NO_DATASTREAM
-// Q_EXPORT QDataStream &operator<<( QDataStream &, const FRect & );
-// Q_EXPORT QDataStream &operator>>( QDataStream &, FRect & );
+// Q_EXPORT QDataStream &operator<<(QDataStream &, const FRect &);
+// Q_EXPORT QDataStream &operator>>(QDataStream &, FRect &);
// #endif
/*****************************************************************************
- FRect inline member functions
+ FRect inline member functions
*****************************************************************************/
-inline FRect::FRect( qreal left, qreal top, qreal width, qreal height )
-{
- x1 = (qreal)left;
- y1 = (qreal)top;
- x2 = (qreal)(left+width-1);
- y2 = (qreal)(top+height-1);
+inline FRect::FRect(qreal left, qreal top, qreal width, qreal height)
+{
+ x1 = (qreal)left;
+ y1 = (qreal)top;
+ x2 = (qreal)(left+width-1);
+ y2 = (qreal)(top+height-1);
}
inline bool FRect::isNull() const
@@ -206,22 +202,22 @@
inline qreal FRect::y() const
{ return y1; }
-inline void FRect::setLeft( qreal pos )
+inline void FRect::setLeft(qreal pos)
{ x1 = (qreal)pos; }
-inline void FRect::setTop( qreal pos )
+inline void FRect::setTop(qreal pos)
{ y1 = (qreal)pos; }
-inline void FRect::setRight( qreal pos )
+inline void FRect::setRight(qreal pos)
{ x2 = (qreal)pos; }
-inline void FRect::setBottom( qreal pos )
+inline void FRect::setBottom(qreal pos)
{ y2 = (qreal)pos; }
-inline void FRect::setX( qreal x )
+inline void FRect::setX(qreal x)
{ x1 = (qreal)x; }
-inline void FRect::setY( qreal y )
+inline void FRect::setY(qreal y)
{ y1 = (qreal)y; }
inline FPoint FRect::topLeft() const
@@ -240,29 +236,28 @@
{ return FPoint((x1+x2)/2, (y1+y2)/2); }
inline qreal FRect::width() const
-{ return x2 - x1 + 1; }
+{ return x2 - x1 + 1; }
inline qreal FRect::height() const
-{ return y2 - y1 + 1; }
+{ return y2 - y1 + 1; }
inline FSize FRect::size() const
{ return FSize(x2-x1+1, y2-y1+1); }
-inline bool FRect::contains( qreal x, qreal y, bool proper ) const
-{
- if ( proper )
- return x > x1 && x < x2 &&
- y > y1 && y < y2;
- else
- return x >= x1 && x <= x2 &&
- y >= y1 && y <= y2;
+inline bool FRect::contains(qreal x, qreal y, bool proper) const
+{
+ if (proper)
+ return x > x1 && x < x2 &&
+ y > y1 && y < y2;
+ else
+ return x >= x1 && x <= x2 &&
+ y >= y1 && y <= y2;
}
-inline bool FRect::contains( qreal x, qreal y ) const
-{
- return x >= x1 && x <= x2 &&
- y >= y1 && y <= y2;
+inline bool FRect::contains(qreal x, qreal y) const
+{
+ return x >= x1 && x <= x2 &&
+ y >= y1 && y <= y2;
}
-// #define Q_DEFINED_QRECT
-// #include "qwinexport.h"
- #endif // QRECT_H
+
+ #endif // FRECT_H
More information about the scribus-commit
mailing list