[Pkg-javascript-commits] [pdf.js] 45/141: Handle 'space' character correctly in WinAnsiEncoding (bug 850854)

David Prévot taffit at moszumanska.debian.org
Sat Apr 19 22:40:28 UTC 2014


This is an automated email from the git hooks/post-receive script.

taffit pushed a commit to branch master
in repository pdf.js.

commit 9e6c66be12733796af0a2a90b7a1fea9e49dd7b5
Author: Jonas Jenwald <jonas.jenwald at gmail.com>
Date:   Tue Apr 8 13:07:29 2014 +0200

    Handle 'space' character correctly in WinAnsiEncoding (bug 850854)
---
 src/core/fonts.js       |  2 +-
 test/pdfs/.gitignore    |  1 +
 test/pdfs/bug850854.pdf | 70 +++++++++++++++++++++++++++++++++++++++++++++++++
 test/test_manifest.json |  9 +++++++
 4 files changed, 81 insertions(+), 1 deletion(-)

diff --git a/src/core/fonts.js b/src/core/fonts.js
index e828073..076715a 100644
--- a/src/core/fonts.js
+++ b/src/core/fonts.js
@@ -210,7 +210,7 @@ var Encodings = {
     'guilsinglleft', 'OE', 'bullet', 'Zcaron', 'bullet', 'bullet', 'quoteleft',
     'quoteright', 'quotedblleft', 'quotedblright', 'bullet', 'endash',
     'emdash', 'tilde', 'trademark', 'scaron', 'guilsinglright', 'oe', 'bullet',
-    'zcaron', 'Ydieresis', '', 'exclamdown', 'cent', 'sterling',
+    'zcaron', 'Ydieresis', 'space', 'exclamdown', 'cent', 'sterling',
     'currency', 'yen', 'brokenbar', 'section', 'dieresis', 'copyright',
     'ordfeminine', 'guillemotleft', 'logicalnot', 'hyphen', 'registered',
     'macron', 'degree', 'plusminus', 'twosuperior', 'threesuperior', 'acute',
diff --git a/test/pdfs/.gitignore b/test/pdfs/.gitignore
index aa06cc0..7afd7e0 100644
--- a/test/pdfs/.gitignore
+++ b/test/pdfs/.gitignore
@@ -50,6 +50,7 @@
 !issue925.pdf
 !gradientfill.pdf
 !bug903856.pdf
+!bug850854.pdf
 !basicapi.pdf
 !mixedfonts.pdf
 !shading_extend.pdf
diff --git a/test/pdfs/bug850854.pdf b/test/pdfs/bug850854.pdf
new file mode 100644
index 0000000..94fbc61
--- /dev/null
+++ b/test/pdfs/bug850854.pdf
@@ -0,0 +1,70 @@
+%PDF-1.7
+11 0 obj
+<<
+/Type /Catalog
+/Pages 12 0 R
+>>
+endobj
+12 0 obj
+<<
+/Type /Pages
+/MediaBox [ 0 0 200 50 ]
+/Count 1
+/Kids [ 13 0 R ]
+>>
+endobj
+13 0 obj
+<<
+/Type /Page
+/Parent 12 0 R
+/Resources <<
+/Font <<
+/F1 14 0 R
+>>
+
+>>
+
+/Contents 15 0 R
+>>
+endobj
+14 0 obj
+<<
+/Type /Font
+/BaseFont /Helvetica
+/Subtype /Type1
+/Encoding /WinAnsiEncoding
+>>
+endobj
+15 0 obj
+<<
+/Length 52
+>>
+stream
+BT
+10 20 TD
+/F1 20 Tf
+(Bug\240\240\240850854) Tj
+ET
+endstream
+endobj
+xref
+0 1
+0000000000 65535 f
+11 1
+0000000009 00000 n
+12 1
+0000000060 00000 n
+13 1
+0000000146 00000 n
+14 1
+0000000254 00000 n
+15 1
+0000000352 00000 n
+trailer
+<<
+/Size 5
+/Root 11 0 R
+>>
+startxref
+454
+%%EOF
\ No newline at end of file
diff --git a/test/test_manifest.json b/test/test_manifest.json
index 8de813f..78ada4c 100644
--- a/test/test_manifest.json
+++ b/test/test_manifest.json
@@ -378,6 +378,15 @@
        "rounds": 1,
        "type": "load"
     },
+    {  "id": "bug850854",
+       "file": "pdfs/bug850854.pdf",
+       "md5": "346a034a80120d123b9fefc42bcb11da",
+       "rounds": 1,
+       "link": false,
+       "firstPage": 1,
+       "lastPage": 1,
+       "type": "eq"
+    },
     {  "id": "wdsg_fitc",
        "file": "pdfs/wdsg_fitc.pdf",
        "md5": "5bb1c2b83705d4cdfc43197ee74f07f9",

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-javascript/pdf.js.git



More information about the Pkg-javascript-commits mailing list