mirror of
https://github.com/mozilla/pdf.js.git
synced 2025-04-22 16:18:08 +02:00
Always use DW if it's a number for the font default width (bug 1903731)
This commit is contained in:
parent
9afd3a5b2f
commit
8c9a665728
3 changed files with 11 additions and 1 deletions
|
@ -3905,7 +3905,7 @@ class PartialEvaluator {
|
|||
let defaultVMetrics;
|
||||
if (properties.composite) {
|
||||
const dw = dict.get("DW");
|
||||
defaultWidth = Number.isInteger(dw) ? dw : 1000;
|
||||
defaultWidth = typeof dw === "number" ? Math.ceil(dw) : 1000;
|
||||
|
||||
const widths = dict.get("W");
|
||||
if (Array.isArray(widths)) {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue