Revert of Calculate the centering baseline in RenderText correctly. (patchset #12...
commit477c64781a88553fbf7957d87029fd5ef01ed912
authorpkasting <pkasting@chromium.org>
Fri, 20 Feb 2015 03:08:48 +0000 (19 19:08 -0800)
committerCommit bot <commit-bot@chromium.org>
Fri, 20 Feb 2015 03:09:12 +0000 (20 03:09 +0000)
treeb5788a817e2747d4ad4a3eaa08951b733955a7fd
parentf02143b69cc35842a9c5a79a9bd122602d732d64
Revert of Calculate the centering baseline in RenderText correctly. (patchset #12 id:220001 of https://codereview.chromium.org/855763002/)

Reason for revert:
Reverting as agreed after discussion on https://codereview.chromium.org/873233006/ -- this isn't the right fix for this bug.

Original issue's description:
> Font metrics reported by DirectWrite are a touch larger than those reported by GDI on Windows.
>
> As a result the selection rectangle in RenderText at times fills the textfield completely leading to ugliness.
>
> The fix is to ensure that the RenderText centering baseline which is used to calculate the line offsets is greater than the font list baseline. This is achieved by
> calculating the baseline shift via a floating point division and rounding up.
>
> BUG=445366
> TEST=Covered by gfx_unittest RenderTextTest.CenteringBaselineTest, RenderTestText.CenteringBaselineTestForUniscribeFonts
>
> Committed: https://crrev.com/63ebd5da9c9957773b48e335d01ffd90231db3a5
> Cr-Commit-Position: refs/heads/master@{#312753}

TBR=msw@chromium.org,sky@chromium.org,asvitkine@chromium.org,ananta@chromium.org
BUG=445366

Review URL: https://codereview.chromium.org/945583005

Cr-Commit-Position: refs/heads/master@{#317227}
ui/gfx/render_text.cc
ui/gfx/render_text_unittest.cc