]> git.parisson.com Git - pdf.js.git/commitdiff
(#867) Set Type3 font encoding; enable text selection testing
authornotmasteryet <async.processingjs@yahoo.com>
Sun, 4 Dec 2011 19:51:12 +0000 (13:51 -0600)
committernotmasteryet <async.processingjs@yahoo.com>
Sun, 4 Dec 2011 19:51:12 +0000 (13:51 -0600)
src/fonts.js
test/driver.js

index 672739ea49e36eaae33f7202a1c0e2c92c272c30..cc24f30c994f88c5184edd65b8f464f5ae952230 100644 (file)
@@ -765,8 +765,10 @@ var Font = (function Font() {
 
     this.fontMatrix = properties.fontMatrix;
     this.widthMultiplier = 1.0;
-    if (properties.type == 'Type3')
+    if (properties.type == 'Type3') {
+      this.encoding = properties.baseEncoding;
       return;
+    }
 
     // Trying to fix encoding using glyph CIDSystemInfo.
     this.loadCidToUnicode(properties);
@@ -2152,7 +2154,7 @@ var Font = (function Font() {
       };
     },
 
-    charsToGlyphs: function fonts_chars2Glyphs(chars) {
+    charsToGlyphs: function fonts_charsToGlyphs(chars) {
       var charsCache = this.charsCache;
       var glyphs;
 
index ffaf0b53aa0dc840cea2eace25e20b7b58ee315f..83f80ebed1f1bb55ddb93b0f9648b81f9cb7ac0c 100644 (file)
@@ -167,7 +167,8 @@ function nextPage(task, loadError) {
           if (error)
             failureMessage = 'render : ' + error.message;
           snapshotCurrentPage(task, failureMessage);
-        }
+        },
+        true
       );
     } catch (e) {
       failure = 'page setup : ' + e.toString();