fix: image element row margin error

pr675
Hufe921 3 years ago
parent 59065bb29e
commit 3daacc6cb8

@ -1025,7 +1025,7 @@ export class Draw {
} }
const ascent = (element.imgDisplay !== ImageDisplay.INLINE && element.type === ElementType.IMAGE) || const ascent = (element.imgDisplay !== ImageDisplay.INLINE && element.type === ElementType.IMAGE) ||
element.type === ElementType.LATEX element.type === ElementType.LATEX
? metrics.height ? metrics.height + rowMargin
: metrics.boundingBoxAscent + rowMargin : metrics.boundingBoxAscent + rowMargin
const height = rowMargin + metrics.boundingBoxAscent + metrics.boundingBoxDescent + rowMargin const height = rowMargin + metrics.boundingBoxAscent + metrics.boundingBoxDescent + rowMargin
const rowElement: IRowElement = Object.assign(element, { const rowElement: IRowElement = Object.assign(element, {

Loading…
Cancel
Save