From 715c2e39aabdcbca54b39891faedb5fb7a5c7aa7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Luiz=20Am=C3=A9rico=20Pereira=20C=C3=A2mara?= Date: Sat, 3 May 2025 00:03:33 -0300 Subject: [PATCH] Remove AFMFont.charWidths --- lib/font/afm.js | 5 ----- 1 file changed, 5 deletions(-) diff --git a/lib/font/afm.js b/lib/font/afm.js index d9e47a6..610f381 100644 --- a/lib/font/afm.js +++ b/lib/font/afm.js @@ -111,11 +111,6 @@ class AFMFont { this.kernPairs = {}; this.parse(); - // todo: remove charWidths since appears to not be used - this.charWidths = new Array(256); - for (let char = 0; char <= 255; char++) { - this.charWidths[char] = this.glyphWidths[characters[char]]; - } this.bbox = this.attributes['FontBBox'].split(/\s+/).map((e) => +e); this.ascender = +(this.attributes['Ascender'] || 0);