-
Notifications
You must be signed in to change notification settings - Fork 10k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Take the FirstChar
/LastChar
properties into account when computing the hash in PartialEvaluator.preEvaluateFont
(issue 10665)
#10685
Take the FirstChar
/LastChar
properties into account when computing the hash in PartialEvaluator.preEvaluateFont
(issue 10665)
#10685
Conversation
…atedFonts` in `PartialEvaluator.loadFont` Note that `PartialEvaluator.preEvaluateFont` will return an empty string when no hash was computed. This will complete short-circuit the `fontAlias` comparison in `PartialEvaluator.loadFont`, since fonts which are totally different will then match if their `hash`es are empty.
/botio test |
From: Bot.io (Windows)ReceivedCommand cmd_test from @Snuffleupagus received. Current queue size: 0 Live output at: http://54.215.176.217:8877/ff112ed912299cf/output.txt |
From: Bot.io (Linux m4)ReceivedCommand cmd_test from @Snuffleupagus received. Current queue size: 0 Live output at: http://54.67.70.0:8877/de37a56625116ff/output.txt |
From: Bot.io (Linux m4)SuccessFull output at http://54.67.70.0:8877/de37a56625116ff/output.txt Total script time: 18.46 mins
|
From: Bot.io (Windows)FailedFull output at http://54.215.176.217:8877/ff112ed912299cf/output.txt Total script time: 25.57 mins
Image differences available at: http://54.215.176.217:8877/ff112ed912299cf/reftest-analyzer.html#web=eq.log |
…g the hash in `PartialEvaluator.preEvaluateFont` (issue 10665) Without this some fonts may incorrectly end up with matching `hash`es, thus breaking rendering since we'll not actually try to load/parse some of the fonts.
12a9321
to
9077abc
Compare
@@ -2352,6 +2350,10 @@ var PartialEvaluator = (function PartialEvaluatorClosure() { | |||
} | |||
} | |||
|
|||
const firstChar = (dict.get('FirstChar') || 0); | |||
const lastChar = (dict.get('LastChar') || (composite ? 0xFFFF : 0xFF)); | |||
hash.update(`${firstChar}-${lastChar}`); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The updated patch only changed the separator here, since using the same one (i.e. comma) as in the 'Differences' array
case above may perhaps not be the best idea.
/botio-linux preview |
From: Bot.io (Linux m4)ReceivedCommand cmd_preview from @timvandermeij received. Current queue size: 1 Live output at: http://54.67.70.0:8877/5251367b63df86a/output.txt |
From: Bot.io (Linux m4)SuccessFull output at http://54.67.70.0:8877/5251367b63df86a/output.txt Total script time: 1.86 mins Published |
Thank you! I'll make reference images in the other PR to save resources. |
Without this some fonts may incorrectly end up with matching
hash
es, thus breaking rendering since we'll not actually try to load/parse some of the fonts.Fixes #10665.