r24210 by jghali - Code cleanups

scribus-commit scribus-commit at lists.scribus.net
Sun Nov 8 17:35:04 UTC 2020


Author: jghali
Date: Sun Nov  8 17:35:04 2020
New Revision: 24210

URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=24210
Log:
Code cleanups

Modified:
    trunk/Scribus/scribus/scribusapp.cpp

Modified: trunk/Scribus/scribus/scribusapp.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=24210&path=/trunk/Scribus/scribus/scribusapp.cpp
==============================================================================
--- trunk/Scribus/scribus/scribusapp.cpp	(original)
+++ trunk/Scribus/scribus/scribusapp.cpp	Sun Nov  8 17:35:04 2020
@@ -619,16 +619,18 @@
 void ScribusQApp::showAvailLangs()
 {
 	QFile f;
-	f.open(stderr, QIODevice::WriteOnly);
+	if (!f.open(stderr, QIODevice::WriteOnly))
+		return;
+
 	QTextStream ts(&f);
-	ts << tr("Installed interface languages for Scribus are as follows:"); Qt::endl(ts);
+	ts << tr("Installed interface languages for Scribus are as follows:") << Qt::endl;
 	Qt::endl(ts);
 
 	LanguageManager::instance()->printInstalledList();
-
 	Qt::endl(ts);
-	ts << tr("To override the default language choice:"); Qt::endl(ts);
-	ts << tr("scribus -l xx or scribus --lang xx, where xx is the language of choice."); Qt::endl(ts);
+
+	ts << tr("To override the default language choice:") << Qt::endl;
+	ts << tr("scribus -l xx or scribus --lang xx, where xx is the language of choice.") << Qt::endl;
 }
 
 void ScribusQApp::showVersion()




More information about the scribus-commit mailing list