r20388 by craig -
scribus-commit
scribus-commit at lists.scribus.net
Wed Sep 16 21:02:59 UTC 2015
Author: craig
Date: Wed Sep 16 21:02:59 2015
New Revision: 20388
URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=20388
Log:
Use QString clear instead of constructor
Modified:
trunk/Scribus/scribus/colormgmt/sclcms2colormgmtengineimpl.cpp
trunk/Scribus/scribus/colormgmt/sclcmscolormgmtengineimpl.cpp
trunk/Scribus/scribus/gtaction.cpp
trunk/Scribus/scribus/gtparagraphstyle.cpp
trunk/Scribus/scribus/numeration.cpp
trunk/Scribus/scribus/scribus.cpp
trunk/Scribus/scribus/scribusdoc.cpp
trunk/Scribus/scribus/scribusstructs.h
trunk/Scribus/scribus/ui/colorlistbox.cpp
trunk/Scribus/scribus/ui/pagepalette_masterpages.cpp
trunk/Scribus/scribus/ui/printdialog.cpp
trunk/Scribus/scribus/ui/selfield.cpp
Modified: trunk/Scribus/scribus/colormgmt/sclcms2colormgmtengineimpl.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=20388&path=/trunk/Scribus/scribus/colormgmt/sclcms2colormgmtengineimpl.cpp
==============================================================================
--- trunk/Scribus/scribus/colormgmt/sclcms2colormgmtengineimpl.cpp (original)
+++ trunk/Scribus/scribus/colormgmt/sclcms2colormgmtengineimpl.cpp Wed Sep 16 21:02:59 2015
@@ -263,7 +263,7 @@
ScColorTransformInfo transInfo;
transInfo.inputProfile = inputProfile.productDescription();
transInfo.outputProfile = outputProfile.productDescription();
- transInfo.proofingProfile = QString();
+ transInfo.proofingProfile.clear();
transInfo.inputFormat = inputFormat;
transInfo.outputFormat = outputFormat;
transInfo.renderIntent = renderIntent;
@@ -274,9 +274,9 @@
if (transInfo.inputProfile == transInfo.outputProfile)
{
// This is a null transform
- transInfo.inputProfile = QString();
- transInfo.outputProfile = QString();
- transInfo.proofingProfile = QString();
+ transInfo.inputProfile.clear();
+ transInfo.outputProfile.clear();
+ transInfo.proofingProfile.clear();
transInfo.renderIntent = (eRenderIntent) 0;
transInfo.proofingIntent = (eRenderIntent) 0;
transInfo.flags = 0;
@@ -385,9 +385,9 @@
if (transInfo.inputProfile == transInfo.outputProfile)
{
lcmsFlags |= cmsFLAGS_NULLTRANSFORM;
- transInfo.inputProfile = QString();
- transInfo.outputProfile = QString();
- transInfo.proofingProfile = QString();
+ transInfo.inputProfile.clear();
+ transInfo.outputProfile.clear();
+ transInfo.proofingProfile.clear();
transInfo.renderIntent = (eRenderIntent) 0;
transInfo.proofingIntent = (eRenderIntent) 0;
transInfo.flags = 0;
Modified: trunk/Scribus/scribus/colormgmt/sclcmscolormgmtengineimpl.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=20388&path=/trunk/Scribus/scribus/colormgmt/sclcmscolormgmtengineimpl.cpp
==============================================================================
--- trunk/Scribus/scribus/colormgmt/sclcmscolormgmtengineimpl.cpp (original)
+++ trunk/Scribus/scribus/colormgmt/sclcmscolormgmtengineimpl.cpp Wed Sep 16 21:02:59 2015
@@ -298,7 +298,7 @@
ScColorTransformInfo transInfo;
transInfo.inputProfile = inputProfile.productDescription();
transInfo.outputProfile = outputProfile.productDescription();
- transInfo.proofingProfile = QString();
+ transInfo.proofingProfile.clear();
transInfo.inputFormat = inputFormat;
transInfo.outputFormat = outputFormat;
transInfo.renderIntent = renderIntent;
@@ -309,9 +309,9 @@
if (transInfo.inputProfile == transInfo.outputProfile)
{
// This is a null transform
- transInfo.inputProfile = QString();
- transInfo.outputProfile = QString();
- transInfo.proofingProfile = QString();
+ transInfo.inputProfile.clear();
+ transInfo.outputProfile.clear();
+ transInfo.proofingProfile.clear();
transInfo.renderIntent = (eRenderIntent) 0;
transInfo.proofingIntent = (eRenderIntent) 0;
transInfo.flags = 0;
@@ -446,9 +446,9 @@
if (transInfo.inputProfile == transInfo.outputProfile)
{
lcmsFlags |= cmsFLAGS_NULLTRANSFORM;
- transInfo.inputProfile = QString();
- transInfo.outputProfile = QString();
- transInfo.proofingProfile = QString();
+ transInfo.inputProfile.clear();
+ transInfo.outputProfile.clear();
+ transInfo.proofingProfile.clear();
transInfo.renderIntent = (eRenderIntent) 0;
transInfo.proofingIntent = (eRenderIntent) 0;
transInfo.flags = 0;
Modified: trunk/Scribus/scribus/gtaction.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=20388&path=/trunk/Scribus/scribus/gtaction.cpp
==============================================================================
--- trunk/Scribus/scribus/gtaction.cpp (original)
+++ trunk/Scribus/scribus/gtaction.cpp Wed Sep 16 21:02:59 2015
@@ -762,7 +762,7 @@
QString gtAction::findFontName(gtFont* font)
{
- QString ret = QString();
+ QString ret;
for (uint i = 0; i < static_cast<uint>(gtFont::NAMECOUNT); ++i)
{
QString nname = font->getName(i);
Modified: trunk/Scribus/scribus/gtparagraphstyle.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=20388&path=/trunk/Scribus/scribus/gtparagraphstyle.cpp
==============================================================================
--- trunk/Scribus/scribus/gtparagraphstyle.cpp (original)
+++ trunk/Scribus/scribus/gtparagraphstyle.cpp Wed Sep 16 21:02:59 2015
@@ -79,8 +79,8 @@
m_numFormat = 0;
m_numLevel = 0;
m_numStart = 1;
- m_numPrefix = QString();
- m_numSuffix = QString();
+ m_numPrefix.clear();
+ m_numSuffix.clear();
adjToBaseline = false;
autoLineSpacing = false;
isVisible = true;
Modified: trunk/Scribus/scribus/numeration.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=20388&path=/trunk/Scribus/scribus/numeration.cpp
==============================================================================
--- trunk/Scribus/scribus/numeration.cpp (original)
+++ trunk/Scribus/scribus/numeration.cpp Wed Sep 16 21:02:59 2015
@@ -19,7 +19,7 @@
QString getFormatName(int format)
{
- QString name = QString();
+ QString name;
if (format == Type_1_2_3)
name = "1_2_3";
else if (format == Type_i_ii_iii)
Modified: trunk/Scribus/scribus/scribus.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=20388&path=/trunk/Scribus/scribus/scribus.cpp
==============================================================================
--- trunk/Scribus/scribus/scribus.cpp (original)
+++ trunk/Scribus/scribus/scribus.cpp Wed Sep 16 21:02:59 2015
@@ -4362,7 +4362,7 @@
mainWindowStatusLabel->setText( tr("Printing..."));
if (doc->Print_Options.firstUse)
{
- doc->Print_Options.printer = QString();
+ doc->Print_Options.printer.clear();
if (!doc->DocName.startsWith( tr("Document")))
{
QFileInfo fi(doc->DocName);
Modified: trunk/Scribus/scribus/scribusdoc.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=20388&path=/trunk/Scribus/scribus/scribusdoc.cpp
==============================================================================
--- trunk/Scribus/scribus/scribusdoc.cpp (original)
+++ trunk/Scribus/scribus/scribusdoc.cpp Wed Sep 16 21:02:59 2015
@@ -5874,7 +5874,7 @@
if (pageItem->isTempFile)
{
QFile::remove(pageItem->Pfile);
- pageItem->Pfile = QString();
+ pageItem->Pfile.clear();
}
pageItem->isInlineImage = false;
pageItem->isTempFile = false;
@@ -16790,7 +16790,7 @@
++currNum;
setNumerationCounter(numName, level, currNum);
- QString result = QString();
+ QString result;
for (int i=0; i <= level; ++i)
{
Numeration num = numS->m_nums[i];
@@ -16865,7 +16865,7 @@
count++;
m_counters.replace(level, count);
//m_nums.insert(level, num);
- QString result = QString();
+ QString result;
for (int i=0; i <= level; ++i)
{
result.append(m_nums.at(i).prefix);
@@ -18306,7 +18306,7 @@
bool ScribusDoc::validateNSet(NotesStyle NS, QString newName)
{
//check if choosen numbering type is avaiable with choosen range, prefix and suffix
- QString errStr = QString();
+ QString errStr;
foreach (NotesStyle* NS2, m_docNotesStylesList)
{
if (newName.isEmpty())
Modified: trunk/Scribus/scribus/scribusstructs.h
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=20388&path=/trunk/Scribus/scribus/scribusstructs.h
==============================================================================
--- trunk/Scribus/scribus/scribusstructs.h (original)
+++ trunk/Scribus/scribus/scribusstructs.h Wed Sep 16 21:02:59 2015
@@ -357,7 +357,7 @@
if (val.isEmpty() || (val == ""))
{
valid = false;
- value = QString();
+ value.clear();
}
else
{
Modified: trunk/Scribus/scribus/ui/colorlistbox.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=20388&path=/trunk/Scribus/scribus/ui/colorlistbox.cpp
==============================================================================
--- trunk/Scribus/scribus/ui/colorlistbox.cpp (original)
+++ trunk/Scribus/scribus/ui/colorlistbox.cpp Wed Sep 16 21:02:59 2015
@@ -243,14 +243,14 @@
void ColorListBox::slotRightClick()
{
blockSignals(true);
- QString currentSel = QString();
+ QString currentSel;
QListWidgetItem* itc = currentItem();
if (itc)
currentSel = itc->text();
QListWidgetItem* it = item(0);
if (it)
{
- QString first = QString();
+ QString first;
QMenu *pmen = new QMenu();
pmen->addAction( tr("Sort by Name"));
pmen->addAction( tr("Sort by Color"));
Modified: trunk/Scribus/scribus/ui/pagepalette_masterpages.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=20388&path=/trunk/Scribus/scribus/ui/pagepalette_masterpages.cpp
==============================================================================
--- trunk/Scribus/scribus/ui/pagepalette_masterpages.cpp (original)
+++ trunk/Scribus/scribus/ui/pagepalette_masterpages.cpp Wed Sep 16 21:02:59 2015
@@ -435,7 +435,7 @@
if (!m_doc || !m_view)
return;
- m_currentPage = QString();
+ m_currentPage.clear();
for (int i = 0; i < masterPageListBox->count(); ++i)
{
QListWidgetItem* item = masterPageListBox->item(i);
Modified: trunk/Scribus/scribus/ui/printdialog.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=20388&path=/trunk/Scribus/scribus/ui/printdialog.cpp
==============================================================================
--- trunk/Scribus/scribus/ui/printdialog.cpp (original)
+++ trunk/Scribus/scribus/ui/printdialog.cpp Wed Sep 16 21:02:59 2015
@@ -430,7 +430,7 @@
#ifdef HAVE_CUPS
m_doc->Print_Options.printerOptions = PrinterOpts;
#else
- m_doc->Print_Options.printerOptions = QString();
+ m_doc->Print_Options.printerOptions.clear();
#endif
m_doc->Print_Options.devMode = DevMode;
}
Modified: trunk/Scribus/scribus/ui/selfield.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=20388&path=/trunk/Scribus/scribus/ui/selfield.cpp
==============================================================================
--- trunk/Scribus/scribus/ui/selfield.cpp (original)
+++ trunk/Scribus/scribus/ui/selfield.cpp Wed Sep 16 21:02:59 2015
@@ -127,7 +127,7 @@
void SelectFields::SetRetVal()
{
- S_Fields = QString();
+ S_Fields.clear();
if (FTyp > 1)
{
if (SelFields->count() > 0)
More information about the scribus-commit
mailing list