]> git.parisson.com Git - pdf.js.git/commitdiff
Fix a regression on the application of the textMatrix extracted from a CFF font
authorVivien Nicolas <21@vingtetun.org>
Tue, 19 Jul 2011 12:29:05 +0000 (14:29 +0200)
committerVivien Nicolas <21@vingtetun.org>
Tue, 19 Jul 2011 12:29:05 +0000 (14:29 +0200)
fonts.js

index 9a064f4c5d3b136e56d981808a8c7af0638bea78..d08d43a7c7e0a7e39f4d719c2db9f9e62e7dd16a 100755 (executable)
--- a/fonts.js
+++ b/fonts.js
@@ -375,7 +375,6 @@ function getUnicodeRangeFor(value) {
 var Font = (function Font() {
   var constructor = function font_constructor(name, file, properties) {
     this.name = name;
-    this.textMatrix = properties.textMatrix || IDENTITY_MATRIX;
     this.encoding = properties.encoding;
 
     // If the font is to be ignored, register it like an already loaded font
@@ -411,6 +410,7 @@ var Font = (function Font() {
         break;
     }
     this.data = data;
+    this.textMatrix = properties.textMatrix || IDENTITY_MATRIX;
     this.type = properties.type;
     this.id = Fonts.registerFont(name, data, properties);
     this.loadedName = 'pdfFont' + this.id;