|
@@ -28,8 +28,8 @@ factory((root.pdfjsDistBuildPdfCombined = {}));
|
|
|
// Use strict in our context only - users might not want it
|
|
|
'use strict';
|
|
|
|
|
|
-var pdfjsVersion = '1.5.404';
|
|
|
-var pdfjsBuild = 'a75b020';
|
|
|
+var pdfjsVersion = '1.5.406';
|
|
|
+var pdfjsBuild = 'ffa9939';
|
|
|
|
|
|
var pdfjsFilePath =
|
|
|
typeof document !== 'undefined' && document.currentScript ?
|
|
@@ -46547,9 +46547,17 @@ var PartialEvaluator = (function PartialEvaluatorClosure() {
|
|
|
|
|
|
switch (fn | 0) {
|
|
|
case OPS.setFont:
|
|
|
+ // Optimization to ignore multiple identical Tf commands.
|
|
|
+ var fontNameArg = args[0].name, fontSizeArg = args[1];
|
|
|
+ if (textState.font && fontNameArg === textState.fontName &&
|
|
|
+ fontSizeArg === textState.fontSize) {
|
|
|
+ break;
|
|
|
+ }
|
|
|
+
|
|
|
flushTextContentItem();
|
|
|
- textState.fontSize = args[1];
|
|
|
- next(handleSetFont(args[0].name, null));
|
|
|
+ textState.fontName = fontNameArg;
|
|
|
+ textState.fontSize = fontSizeArg;
|
|
|
+ next(handleSetFont(fontNameArg, null));
|
|
|
return;
|
|
|
case OPS.setTextRise:
|
|
|
flushTextContentItem();
|
|
@@ -46766,6 +46774,7 @@ var PartialEvaluator = (function PartialEvaluatorClosure() {
|
|
|
}
|
|
|
var gStateFont = gState.get('Font');
|
|
|
if (gStateFont) {
|
|
|
+ textState.fontName = null;
|
|
|
textState.fontSize = gStateFont[1];
|
|
|
next(handleSetFont(null, gStateFont[0]));
|
|
|
return;
|
|
@@ -47685,6 +47694,7 @@ var StateManager = (function StateManagerClosure() {
|
|
|
var TextState = (function TextStateClosure() {
|
|
|
function TextState() {
|
|
|
this.ctm = new Float32Array(IDENTITY_MATRIX);
|
|
|
+ this.fontName = null;
|
|
|
this.fontSize = 0;
|
|
|
this.font = null;
|
|
|
this.fontMatrix = FONT_IDENTITY_MATRIX;
|