-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
[LBSE] Computation of on-screen font scaling factor ignores page zoom #15000
[LBSE] Computation of on-screen font scaling factor ignores page zoom #15000
Conversation
EWS run on previous version of this PR (hash 469e0f7) |
The 100th LBSE patch (see nikolaszimmermann/WebKitIgalia#1) got a nice PR number: 15000 :-) |
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.
Looks good, but it seems zoom-zoom-coords.xhtml needs fixing.
Yop, will take care of it later, thanks @rwlbuis! |
469e0f7
to
5eed14e
Compare
EWS run on current version of this PR (hash 5eed14e) |
Hah, zoom-zoom-coords.xhtml delivers the same results for LBSE and the legacy SVG engine, both across all platforms! :-) Can finally remove the platform specific results for that tricky test case. |
https://bugs.webkit.org/show_bug.cgi?id=258120 Reviewed by Rob Buis. For standalone SVG documents the page zoom has to be taken into account when computing the on-screen font scaling factor. Currently we ignore the effective zoom factor and thus select a sub-optimal font. Non-scaling-stroke (webkit.org/b/139322) works properly in LBSE, if this fix is applied as well. Two tests fail in LBSE without this patch: svg/text/non-scaling-stroke-textRendering-default.svg and svg/text/non-scaling-stroke-textRendering-geometricPrecision.svg). Covered by new tests added by webkit.org/b/139322 -- easy to test with non-scaling-stroke. Without non-scaling-stroke, this is most noticeable in zoom-zoom-coords.html which now exposes slighly different metrics for <text> since the internal font-size scaling factor changed (now taking zoom into account, as the legacy SVG engine already does). zoom-zoom-coords.xhtml now delivers correct results across all platforms and is identical for legacy SVG engine and LBSE -- get rid of platform specific results, finally. * LayoutTests/platform/glib/svg/zoom/page/zoom-zoom-coords-expected.txt: Removed. * LayoutTests/platform/mac-ventura-wk2-lbse-text/svg/zoom/page/zoom-zoom-coords-expected.txt: Removed. * LayoutTests/platform/mac/svg/zoom/page/zoom-zoom-coords-expected.txt: Removed. * LayoutTests/svg/zoom/page/zoom-zoom-coords-expected.txt: Finally a single non-LBSE/LBSE result for all platforms. * LayoutTests/svg/zoom/page/zoom-zoom-coords.xhtml: * Source/WebCore/rendering/svg/SVGLayerTransformComputation.h: (WebCore::SVGLayerTransformComputation::calculateScreenFontSizeScalingFactor const): Multiply scaling factor by effectiveZoom() (which includes page zoom), but only for non-standalone SVG documents. For standalone SVG documents the page-zoom induced scaling is already part of the CTM. Canonical link: https://commits.webkit.org/265208@main
5eed14e
to
988fed7
Compare
Committed 265208@main (988fed7): https://commits.webkit.org/265208@main Reviewed commits have been landed. Closing PR #15000 and removing active labels. |
988fed7
5eed14e
π wincairoπ§ͺ gtk-wk2π§ͺ mac-AS-debug-wk2