diff options
author | Liang Qi <liang.qi@theqtcompany.com> | 2016-04-11 08:48:27 +0200 |
---|---|---|
committer | Liang Qi <liang.qi@theqtcompany.com> | 2016-04-11 09:12:36 +0200 |
commit | f34e73a16a3d757057e007874cb5008f16e20f02 (patch) | |
tree | bcc228617cf240773fd09daac1a1a2614b552b68 /src/gui/painting/qpdf.cpp | |
parent | 5380808453728a354ae28aae76e85ac448245cf1 (diff) | |
parent | b9d386f2ccd69c7f6a766a6d90a6024eeb48e90a (diff) |
Merge remote-tracking branch 'origin/5.7' into dev
Conflicts:
src/corelib/kernel/qobject.cpp
src/gui/painting/qpaintengine_raster.cpp
Change-Id: I74e1779832f43d033708dcfd6b666c7b4f0111fb
Diffstat (limited to 'src/gui/painting/qpdf.cpp')
-rw-r--r-- | src/gui/painting/qpdf.cpp | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/src/gui/painting/qpdf.cpp b/src/gui/painting/qpdf.cpp index 86f176bc99..02f9be197f 100644 --- a/src/gui/painting/qpdf.cpp +++ b/src/gui/painting/qpdf.cpp @@ -1561,6 +1561,7 @@ void QPdfEnginePrivate::embedFont(QFontSubset *font) int toUnicode = requestObject(); QFontEngine::Properties properties = font->fontEngine->properties(); + QByteArray postscriptName = properties.postscriptName.replace(' ', '_'); { qreal scale = 1000/properties.emSquare.toReal(); @@ -1574,7 +1575,7 @@ void QPdfEnginePrivate::embedFont(QFontSubset *font) s << (char)('A' + (tag % 26)); tag /= 26; } - s << '+' << properties.postscriptName << "\n" + s << '+' << postscriptName << "\n" "/Flags " << 4 << "\n" "/FontBBox [" << properties.boundingBox.x()*scale @@ -1617,7 +1618,7 @@ void QPdfEnginePrivate::embedFont(QFontSubset *font) QPdf::ByteStream s(&cid); s << "<< /Type /Font\n" "/Subtype /CIDFontType2\n" - "/BaseFont /" << properties.postscriptName << "\n" + "/BaseFont /" << postscriptName << "\n" "/CIDSystemInfo << /Registry (Adobe) /Ordering (Identity) /Supplement 0 >>\n" "/FontDescriptor " << fontDescriptor << "0 R\n" "/CIDToGIDMap /Identity\n" @@ -1641,7 +1642,7 @@ void QPdfEnginePrivate::embedFont(QFontSubset *font) QPdf::ByteStream s(&font); s << "<< /Type /Font\n" "/Subtype /Type0\n" - "/BaseFont /" << properties.postscriptName << "\n" + "/BaseFont /" << postscriptName << "\n" "/Encoding /Identity-H\n" "/DescendantFonts [" << cidfont << "0 R]\n" "/ToUnicode " << toUnicode << "0 R" |