XFA - Don't use system font when a font is not embeded but there is a substitution
- always use a font coming from pdf.js when there is one: this way we don't use a system font which could looks wrong.
This commit is contained in:
parent
d80651e572
commit
5744dd773d
@ -481,7 +481,7 @@ function setFontFamily(xfaFont, fontFinder, style) {
|
|||||||
if (typeface) {
|
if (typeface) {
|
||||||
const { fontFamily } = typeface.regular.cssFontInfo;
|
const { fontFamily } = typeface.regular.cssFontInfo;
|
||||||
if (fontFamily !== name) {
|
if (fontFamily !== name) {
|
||||||
style.fontFamily += `,"${fontFamily}"`;
|
style.fontFamily = `"${fontFamily}"`;
|
||||||
}
|
}
|
||||||
if (style.lineHeight) {
|
if (style.lineHeight) {
|
||||||
// Already something so don't overwrite.
|
// Already something so don't overwrite.
|
||||||
|
Loading…
x
Reference in New Issue
Block a user