r17767 by jghali - #11054: Inserting a glyph using the "Unicode search" fails

scribus-commit scribus-commit at lists.scribus.net
Sat Sep 1 13:20:31 UTC 2012


Author: jghali
Date: Sat Sep  1 13:20:31 2012
New Revision: 17767

URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=17767
Log:
#11054: Inserting a glyph using the "Unicode search" fails

Modified:
    trunk/Scribus/scribus/chartablemodel.cpp

Modified: trunk/Scribus/scribus/chartablemodel.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=17767&path=/trunk/Scribus/scribus/chartablemodel.cpp
==============================================================================
--- trunk/Scribus/scribus/chartablemodel.cpp (original)
+++ trunk/Scribus/scribus/chartablemodel.cpp Sat Sep  1 13:20:31 2012
@@ -164,7 +164,9 @@
 	bool ok;
 	int a = s.indexOf("#");
 	QString si = s.left(a);
-	QString sf = s.mid(a+1);
+	QString sf = (a >= 0) ? s.mid(a+1) : "";
+	if (sf.isEmpty())
+		sf = m_fontInUse;
 	int val = si.toInt(&ok, base);
 	if (!ok)
 		return;




More information about the scribus-commit mailing list