Work around Opera's translation of font-weight:normal to font-weight:400
This commit is contained in:
parent
69bd9305c9
commit
fe8c5b9899
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
|
@ -1307,9 +1307,11 @@
|
|||
if (text.length == 1 && font.skew && font.skew[n]) {span.bbox.skew = font.skew[n]}
|
||||
},
|
||||
checkFont: function (font,style) {
|
||||
var weight = (style.fontWeight||"normal");
|
||||
if (weight.match(/^\d+$/)) {weight = (parseInt(weight) >= 600 ? "bold" : "normal")}
|
||||
return (font.family.replace(/'/g,"") === style.fontFamily.replace(/'/g,"") &&
|
||||
(font.style||"normal") === (style.fontStyle||"normal") &&
|
||||
(font.weight||"normal") === (style.fontWeight||"normal"));
|
||||
(font.weight||"normal") === weight);
|
||||
},
|
||||
|
||||
handleFont: function (span,font,force) {
|
||||
|
|
Loading…
Reference in New Issue
Block a user