-
Notifications
You must be signed in to change notification settings - Fork 10.2k
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
[TextLayer] Immediately set the padding, rather than checking if it's empty, in expandTextDivs
#11586
[TextLayer] Immediately set the padding, rather than checking if it's empty, in expandTextDivs
#11586
Conversation
… empty, in `expandTextDivs` In practice it's extremely rare[1] for the padding to be zero in *all* components, hence it seems better to just set it directly rather than creating a temporary variable and checking for the "no padding"-case. --- [1] In the `tracemonkey.pdf` file that only happens with `0.08%` of all text elements.
Was there a specific PDF that this was added for? |
Don't think so, it's probably just a case of a premature optimization. |
/botio test |
From: Bot.io (Linux m4)ReceivedCommand cmd_test from @Snuffleupagus received. Current queue size: 0 Live output at: http://54.67.70.0:8877/1a8430f32416a6a/output.txt |
From: Bot.io (Windows)ReceivedCommand cmd_test from @Snuffleupagus received. Current queue size: 0 Live output at: http://54.215.176.217:8877/83b0cd0e6e5441d/output.txt |
From: Bot.io (Windows)FailedFull output at http://54.215.176.217:8877/83b0cd0e6e5441d/output.txt Total script time: 2.20 mins
Image differences available at: http://54.215.176.217:8877/83b0cd0e6e5441d/reftest-analyzer.html#web=eq.log |
From: Bot.io (Linux m4)FailedFull output at http://54.67.70.0:8877/1a8430f32416a6a/output.txt Total script time: 20.16 mins
Image differences available at: http://54.67.70.0:8877/1a8430f32416a6a/reftest-analyzer.html#web=eq.log |
/botio-window test |
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.
r+ if the windows bot runs okay
/botio-windows test |
From: Bot.io (Windows)ReceivedCommand cmd_test from @brendandahl received. Current queue size: 0 Live output at: http://54.215.176.217:8877/cce30b17ebeb421/output.txt |
From: Bot.io (Windows)FailedFull output at http://54.215.176.217:8877/cce30b17ebeb421/output.txt Total script time: 26.93 mins
Image differences available at: http://54.215.176.217:8877/cce30b17ebeb421/reftest-analyzer.html#web=eq.log |
Looks good to me! |
In practice it's extremely rare[1] for the padding to be zero in all components, hence it seems better to just set it directly rather than creating a temporary variable and checking for the "no padding"-case.
[1] In the
tracemonkey.pdf
file that only happens with0.08%
of all text elements.