Skip to content

Commit 5f53a23

Browse files
committed
Force measurement of unknown characters, even when noReflows is active.
1 parent 665f56a commit 5f53a23

File tree

1 file changed

+3
-1
lines changed
  • unpacked/jax/output/HTML-CSS

1 file changed

+3
-1
lines changed

unpacked/jax/output/HTML-CSS/jax.js

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -939,7 +939,8 @@
939939
for (i = 0, m = SPANS.length; i < m; i++) {
940940
span = SPANS[i]; if (!span) continue;
941941
bbox = span.bbox; parent = this.parentNode(span);
942-
if (bbox.exactW || bbox.width || bbox.w === 0 || bbox.isMultiline || this.config.noReflows) {
942+
if (bbox.exactW || bbox.width || bbox.w === 0 || bbox.isMultiline ||
943+
(this.config.noReflows && bbox.exactW !== false)) {
943944
if (!parent.bbox) {parent.bbox = bbox}
944945
continue;
945946
}
@@ -1524,6 +1525,7 @@
15241525
if (span.bbox.w + c[3]/1000 < span.bbox.lw) {span.bbox.lw = span.bbox.w + c[3]/1000}
15251526
if (span.bbox.w + c[4]/1000 > span.bbox.rw) {span.bbox.rw = span.bbox.w + c[4]/1000}
15261527
span.bbox.w += c[2]/1000;
1528+
if ((c[5]||{}).isUnknown) span.bbox.exactW = false; // force measurement
15271529
}
15281530
if (newtext.length) {this.addText(SPAN,newtext)}
15291531
if (span.scale && span.scale !== 1) {

0 commit comments

Comments
 (0)