Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1183)

Issue 12310107: Merge 143356 (Closed)

Created:
7 years, 10 months ago by Peter Beverloo
Modified:
7 years, 10 months ago
Reviewers:
Peter Beverloo
CC:
chromium-reviews
Base URL:
http://svn.webkit.org/repository/webkit/branches/chromium/1410/
Visibility:
Public.

Description

Merge 143356 > Text Autosizing: prevent oscillation of font sizes during autosizing > https://bugs.webkit.org/show_bug.cgi?id=108205 > > Patch by Tim Volodine <timvolodine@chromium.org>; on 2013-02-19 > Reviewed by Kenneth Rohde Christiansen. > > Source/WebCore: > > On some websites autosized font-sizes oscillate due to layouts caused by > hovering or incremental page loading (and on other sites font sizes do > eventually stabilize, but it takes many layouts before they reach a steady > size). To prevent all these cases, we no longer allow the autosizing > multiplier to change after it has been set (to a value other than 1). > > This won't always give exactly the same results, but testing on 2000 top > sites shows that this makes little difference in practice, and it prevents > these very jarring cases. As a happy side-effect, this speeds up layouts > as font sizes change less. > > Test: fast/text-autosizing/oscillation-javascript-fontsize-change.html > > * page/FrameView.cpp: > (WebCore::FrameView::setFrameRect): > * page/Settings.cpp: > (WebCore::Settings::setTextAutosizingFontScaleFactor): > * rendering/TextAutosizer.cpp: > (WebCore::TextAutosizer::recalculateMultipliers): > (WebCore): > (WebCore::TextAutosizer::processContainer): > * rendering/TextAutosizer.h: > (TextAutosizer): > > LayoutTests: > > Added overflow-y:hidden to some existing tests, since previously those tests > would start off with incorrect multipliers (because mainFrame->view()-layoutSize() > is initially 785 instead of 800 as ScrollView wrongly guesses a scrollbar will > be needed), and then the multipliers would get corrected on a subsequent layout. > Now that we don't allow the multiplier to change after being set, it needs to be > right first time. > Also added specific oscillation test triggered by javascript. > > * fast/text-autosizing/constrained-height-body-expected.html: > * fast/text-autosizing/constrained-height-body.html: > * fast/text-autosizing/constrained-then-float-ancestors-expected.html: > * fast/text-autosizing/constrained-then-float-ancestors.html: > * fast/text-autosizing/constrained-then-position-fixed-ancestors-expected.html: > * fast/text-autosizing/constrained-then-position-fixed-ancestors.html: > * fast/text-autosizing/nested-em-line-height-expected.html: > * fast/text-autosizing/nested-em-line-height.html: > * fast/text-autosizing/oscillation-javascript-fontsize-change-expected.html: Added. > * fast/text-autosizing/oscillation-javascript-fontsize-change.html: Added. > * fast/text-autosizing/simple-paragraph-expected.html: > * fast/text-autosizing/simple-paragraph.html: > * fast/text-autosizing/span-child-expected.html: > * fast/text-autosizing/span-child.html: > * fast/text-autosizing/unwrappable-blocks-expected.html: > * fast/text-autosizing/unwrappable-blocks.html: > * fast/text-autosizing/unwrappable-inlines-expected.html: > * fast/text-autosizing/unwrappable-inlines.html: TBR=commit-queue@webkit.org Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=143934

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+43 lines, -15 lines) Patch
M LayoutTests/fast/text-autosizing/constrained-height-body.html View 1 chunk +1 line, -1 line 0 comments Download
M LayoutTests/fast/text-autosizing/constrained-height-body-expected.html View 1 chunk +1 line, -1 line 0 comments Download
M LayoutTests/fast/text-autosizing/constrained-then-float-ancestors.html View 1 chunk +1 line, -1 line 0 comments Download
M LayoutTests/fast/text-autosizing/constrained-then-float-ancestors-expected.html View 1 chunk +1 line, -1 line 0 comments Download
M LayoutTests/fast/text-autosizing/constrained-then-position-fixed-ancestors.html View 1 chunk +1 line, -1 line 0 comments Download
M LayoutTests/fast/text-autosizing/constrained-then-position-fixed-ancestors-expected.html View 1 chunk +1 line, -1 line 0 comments Download
M LayoutTests/fast/text-autosizing/nested-em-line-height.html View 1 chunk +1 line, -1 line 0 comments Download
M LayoutTests/fast/text-autosizing/nested-em-line-height-expected.html View 1 chunk +1 line, -1 line 0 comments Download
A + LayoutTests/fast/text-autosizing/oscillation-javascript-fontsize-change.html View 0 chunks +-1 lines, --1 lines 0 comments Download
A + LayoutTests/fast/text-autosizing/oscillation-javascript-fontsize-change-expected.html View 0 chunks +-1 lines, --1 lines 0 comments Download
M LayoutTests/fast/text-autosizing/simple-paragraph.html View 1 chunk +1 line, -1 line 0 comments Download
M LayoutTests/fast/text-autosizing/simple-paragraph-expected.html View 1 chunk +1 line, -1 line 0 comments Download
M LayoutTests/fast/text-autosizing/span-child.html View 1 chunk +1 line, -1 line 0 comments Download
M LayoutTests/fast/text-autosizing/span-child-expected.html View 1 chunk +1 line, -1 line 0 comments Download
M LayoutTests/fast/text-autosizing/unwrappable-blocks.html View 1 chunk +1 line, -1 line 0 comments Download
M LayoutTests/fast/text-autosizing/unwrappable-blocks-expected.html View 1 chunk +1 line, -1 line 0 comments Download
M LayoutTests/fast/text-autosizing/unwrappable-inlines.html View 1 chunk +1 line, -1 line 0 comments Download
M LayoutTests/fast/text-autosizing/unwrappable-inlines-expected.html View 1 chunk +1 line, -1 line 0 comments Download
M Source/WebCore/page/FrameView.cpp View 1 chunk +11 lines, -0 lines 0 comments Download
M Source/WebCore/page/Settings.cpp View 2 chunks +6 lines, -0 lines 0 comments Download
M Source/WebCore/rendering/TextAutosizer.h View 1 chunk +1 line, -0 lines 0 comments Download
M Source/WebCore/rendering/TextAutosizer.cpp View 2 chunks +11 lines, -1 line 0 comments Download

Messages

Total messages: 2 (0 generated)
Peter Beverloo
7 years, 10 months ago (2013-02-25 17:02:21 UTC) #1
Peter Beverloo
7 years, 10 months ago (2013-02-25 17:03:24 UTC) #2
Message was sent while issue was closed.
Committed patchset #1 manually as r143934.

Powered by Google App Engine
This is Rietveld 408576698