RESOLVED FIXED299816
[CSS ZOOM] Zoom evaluation-time flag causes double zoom on border-width with em units
https://bugs.webkit.org/show_bug.cgi?id=299816
Summary [CSS ZOOM] Zoom evaluation-time flag causes double zoom on border-width with ...
Taher
Reported 2025-09-29 12:40:52 PDT
After PR #51076 is merged, we need to investigate and fix failures in tests such as: LayoutTests/fast/sub-pixel/zoomed-em-border.html The flag introduced in the PR #51076 enables applying zoom at evaluation time instead of style-build time. The goal is to move zoom application from style building into layout/rendering, and the feature flag is meant to prevent zoom from being applied during style building to avoid double zooming. However, what currently happens is: - The em unit on border-width is being resolved against the computed font size rather than the specified size - The computed font size already includes the zoom factor - When zoom is applied again during evaluation time to the border-width, it causes double zooming To address this, I modified font size computation at style-build time in computedFontSizeFromSpecifiedSize. I skipped applying zoom if the evaluation-time flag was enabled. This fixes the double zoom issue for border-width with font-related units but a new problem gets introduced: text itself is no longer zoom-induced as expected. This breaks assumptions in other parts of the engine where the computed font size is expected to already include zoom. Could this change also break other assumptions that rely on zoomed computed font sizes?
Attachments
Radar WebKit Bug Importer
Comment 1 2025-09-29 12:40:59 PDT
Vitor Roriz
Comment 2 2025-10-09 17:00:36 PDT
Taher
Comment 3 2025-10-13 22:28:03 PDT
investigate: LayoutTests/svg/zoom/page/zoom-replaced-intrinsic-ratio-001.htm
EWS
Comment 4 2025-10-17 20:12:51 PDT
Committed 301757@main (4082642c7f1c): <https://commits.webkit.org/301757@main> Reviewed commits have been landed. Closing PR #52094 and removing active labels.
Note You need to log in before you can comment on or make changes to this bug.