r17352 by jghali - #10614: combo boxes display random characters prior to selecting an option
scribus-commit
scribus-commit at lists.scribus.net
Fri Mar 2 22:12:50 UTC 2012
Author: jghali
Date: Fri Mar 2 22:12:50 2012
New Revision: 17352
URL: http://scribus.net/websvn/listing.php?repname=Scribus&sc=1&rev=17352
Log:
#10614: combo boxes display random characters prior to selecting an option
Modified:
trunk/Scribus/scribus/pdflib_core.cpp
Modified: trunk/Scribus/scribus/pdflib_core.cpp
URL: http://scribus.net/websvn/diff.php?repname=Scribus&rev=17352&path=/trunk/Scribus/scribus/pdflib_core.cpp
==============================================================================
--- trunk/Scribus/scribus/pdflib_core.cpp (original)
+++ trunk/Scribus/scribus/pdflib_core.cpp Fri Mar 2 22:12:50 2012
@@ -370,7 +370,7 @@
QString tmp = in;
QByteArray cres = ucs2Codec->fromUnicode( tmp );
#ifndef WORDS_BIGENDIAN
- // on little endian systems we ned to swap bytes:
+ // on little endian systems we need to swap bytes:
uchar sw;
for(int d = 0; d < cres.size()-1; d += 2)
{
@@ -8843,15 +8843,12 @@
break;
case 5:
case 6:
- PutDoc("/FT /Ch\n/V (");
- if (bmst.count() > 0)
- PutDoc(bmst[0]);
- PutDoc(")\n/DV ");
- cnx = "(";
- if (bmst.count() > 0)
- cnx += bmstUtf16[0];
- cnx += ")";
- PutDoc(EncStringUTF16(cnx,annotationObj)+"\n");
+ cnx = "(%1)";
+ cnx = cnx.arg((bmstUtf16.count() > 0) ? bmstUtf16[0] : "");
+ cnx = EncStringUTF16(cnx, annotationObj);
+ PutDoc("/FT /Ch\n");
+ PutDoc("/V " + cnx + "\n");
+ PutDoc("/DV " + cnx + "\n");
PutDoc("/Opt [ ");
for (int bmc = 0; bmc < bmstUtf16.count(); ++bmc)
PutDoc(EncStringUTF16("("+bmstUtf16[bmc]+")",annotationObj)+"\n");
More information about the scribus-commit
mailing list