From 9b06da98ca1ddf8cb51183a2464e8b07b35289f5 Mon Sep 17 00:00:00 2001 From: Vivien Nicolas <21@vingtetun.org> Date: Mon, 25 Jul 2011 18:17:56 +0200 Subject: [PATCH] More fix to handle some others invert leading cases in PDF32000.pdf --- pdf.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pdf.js b/pdf.js index e388fc499..4bed1a851 100644 --- a/pdf.js +++ b/pdf.js @@ -4142,7 +4142,7 @@ var CanvasGraphics = (function() { this.current.textHScale = scale / 100; }, setLeading: function(leading) { - this.current.leading = leading; + this.current.leading = -leading; }, setFont: function(fontRef, size) { var font = this.xref.fetchIfRef(this.res.get('Font')); @@ -4194,7 +4194,7 @@ var CanvasGraphics = (function() { } }, setLeadingMoveText: function(x, y) { - this.setLeading(y); + this.setLeading(-y); this.moveText(x, y); }, setTextMatrix: function(a, b, c, d, e, f) { @@ -4207,7 +4207,7 @@ var CanvasGraphics = (function() { this.current.y = this.current.lineY = 0; }, nextLine: function() { - this.moveText(0, -this.current.leading); + this.moveText(0, this.current.leading); }, showText: function(text) { // TODO: apply charSpacing, wordSpacing, textHScale