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

Issue 484883003: Re-land: RenderTextHarfBuzz: Set font render parameters in font data functions (Closed)

Created:
6 years, 4 months ago by ckocagil
Modified:
6 years, 3 months ago
Reviewers:
msw, Daniel Erat
CC:
chromium-reviews, tapted, Andre, Alexei Svitkine (slow)
Project:
chromium
Visibility:
Public.

Description

Re-land: RenderTextHarfBuzz: Set font render parameters in font data functions Originally landed at: https://codereview.chromium.org/480533002/ - Properly pass font render settings to Skia font data functions. Otherwise Skia always returns rounded values. - If subpixel positioning is off, round the glyph positions to match Pango's rounding logic. BUG=402715, 402374, 402347 TEST=On Linux, character positions in UI text (address bar, infobars, tab titles) should be identical with --enable-harfbuzz-rendertext and --disable-harfbuzz-rendertext. Committed: https://crrev.com/04f49f48a13c337cb9eaef0146ec4f15ed91984a Cr-Commit-Position: refs/heads/master@{#291767}

Patch Set 1 #

Patch Set 2 : Mac GetFontRenderParams #

Total comments: 2

Patch Set 3 : nits #

Total comments: 2

Patch Set 4 : remove ifdef #

Patch Set 5 : disable subpixel positioning on win #

Total comments: 2

Patch Set 6 : added condition to rounding #

Total comments: 4

Patch Set 7 : rebased #

Patch Set 8 : comment fixed #

Unified diffs Side-by-side diffs Delta from patch set Stats (+57 lines, -36 lines) Patch
M ui/gfx/BUILD.gn View 1 2 3 4 5 6 1 chunk +3 lines, -2 lines 0 comments Download
M ui/gfx/font_render_params_android.cc View 1 2 1 chunk +1 line, -2 lines 0 comments Download
A + ui/gfx/font_render_params_mac.cc View 1 2 3 4 5 6 7 3 chunks +7 lines, -12 lines 0 comments Download
M ui/gfx/font_render_params_win.cc View 1 2 3 4 3 chunks +5 lines, -3 lines 0 comments Download
M ui/gfx/gfx.gyp View 1 1 chunk +3 lines, -2 lines 0 comments Download
M ui/gfx/render_text.h View 1 chunk +5 lines, -0 lines 0 comments Download
M ui/gfx/render_text.cc View 1 2 3 4 5 6 2 chunks +12 lines, -6 lines 0 comments Download
M ui/gfx/render_text_harfbuzz.h View 1 chunk +1 line, -0 lines 0 comments Download
M ui/gfx/render_text_harfbuzz.cc View 1 2 3 4 5 6 6 chunks +20 lines, -9 lines 0 comments Download

Messages

Total messages: 27 (0 generated)
ckocagil
So I failed to realize that the linker error was legit and managed to get ...
6 years, 4 months ago (2014-08-19 04:42:52 UTC) #1
Daniel Erat
On 2014/08/19 04:42:52, ckocagil wrote: > So I failed to realize that the linker error ...
6 years, 4 months ago (2014-08-19 14:24:17 UTC) #2
ckocagil
On 2014/08/19 14:24:17, Daniel Erat wrote: > On 2014/08/19 04:42:52, ckocagil wrote: > > So ...
6 years, 4 months ago (2014-08-19 15:52:12 UTC) #3
Daniel Erat
lgtm but do we need to support this at all? what breaks if we don't ...
6 years, 4 months ago (2014-08-19 15:59:06 UTC) #4
ckocagil
On 2014/08/19 15:59:06, Daniel Erat wrote: > lgtm > > but do we need to ...
6 years, 4 months ago (2014-08-19 16:12:56 UTC) #5
msw
LGTM with a nit. https://codereview.chromium.org/484883003/diff/60001/ui/gfx/render_text_harfbuzz.cc File ui/gfx/render_text_harfbuzz.cc (right): https://codereview.chromium.org/484883003/diff/60001/ui/gfx/render_text_harfbuzz.cc#newcode887 ui/gfx/render_text_harfbuzz.cc:887: #if defined(OS_WIN) || defined(OS_LINUX) nit: ...
6 years, 4 months ago (2014-08-19 17:26:22 UTC) #6
ckocagil
https://codereview.chromium.org/484883003/diff/60001/ui/gfx/render_text_harfbuzz.cc File ui/gfx/render_text_harfbuzz.cc (right): https://codereview.chromium.org/484883003/diff/60001/ui/gfx/render_text_harfbuzz.cc#newcode887 ui/gfx/render_text_harfbuzz.cc:887: #if defined(OS_WIN) || defined(OS_LINUX) On 2014/08/19 17:26:21, msw wrote: ...
6 years, 4 months ago (2014-08-19 17:34:25 UTC) #7
ckocagil
The CQ bit was checked by ckocagil@chromium.org
6 years, 4 months ago (2014-08-19 17:34:30 UTC) #8
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/ckocagil@chromium.org/484883003/80001
6 years, 4 months ago (2014-08-19 17:35:59 UTC) #9
ckocagil
The CQ bit was unchecked by ckocagil@chromium.org
6 years, 4 months ago (2014-08-19 18:19:31 UTC) #10
ckocagil
This actually breaks glyph positioning on Windows. I'll investigate.
6 years, 4 months ago (2014-08-19 21:39:53 UTC) #11
ckocagil
+bungeman: could you help us out with Skia text rendering? When subpixel positioning is enabled ...
6 years, 4 months ago (2014-08-20 02:20:32 UTC) #12
bungeman-skia
On 2014/08/20 02:20:32, ckocagil wrote: > +bungeman: could you help us out with Skia text ...
6 years, 4 months ago (2014-08-20 13:45:15 UTC) #13
bungeman-skia
On 2014/08/20 13:45:15, bungeman1 wrote: > On 2014/08/20 02:20:32, ckocagil wrote: > > +bungeman: could ...
6 years, 4 months ago (2014-08-20 14:46:50 UTC) #14
tomhudson
On 2014/08/20 02:20:32, ckocagil wrote: > Is this an error? Or are we not supposed ...
6 years, 4 months ago (2014-08-20 16:14:35 UTC) #15
ckocagil
Reading Tom's document on subpixel positioning this much more clearer. Thanks! I will find a ...
6 years, 4 months ago (2014-08-21 13:40:22 UTC) #16
ckocagil
PTAL. I disabled subpixel positioning on Win for UI (we need http://crbug.com/389649 for that), and ...
6 years, 4 months ago (2014-08-22 21:38:27 UTC) #17
msw
https://codereview.chromium.org/484883003/diff/100001/ui/gfx/render_text_harfbuzz.cc File ui/gfx/render_text_harfbuzz.cc (right): https://codereview.chromium.org/484883003/diff/100001/ui/gfx/render_text_harfbuzz.cc#newcode1158 ui/gfx/render_text_harfbuzz.cc:1158: run->width = std::floor(run->width + 0.5f); I wonder if this ...
6 years, 4 months ago (2014-08-22 21:59:36 UTC) #18
ckocagil
https://codereview.chromium.org/484883003/diff/100001/ui/gfx/render_text_harfbuzz.cc File ui/gfx/render_text_harfbuzz.cc (right): https://codereview.chromium.org/484883003/diff/100001/ui/gfx/render_text_harfbuzz.cc#newcode1158 ui/gfx/render_text_harfbuzz.cc:1158: run->width = std::floor(run->width + 0.5f); On 2014/08/22 21:59:36, msw ...
6 years, 4 months ago (2014-08-22 22:22:40 UTC) #19
msw
lgtm; thanks, Cem!
6 years, 4 months ago (2014-08-22 22:26:23 UTC) #20
ckocagil
Daniel, can you take another look? Thanks.
6 years, 4 months ago (2014-08-25 17:45:01 UTC) #21
Daniel Erat
lgtm https://codereview.chromium.org/484883003/diff/120001/ui/gfx/font_render_params_mac.cc File ui/gfx/font_render_params_mac.cc (right): https://codereview.chromium.org/484883003/diff/120001/ui/gfx/font_render_params_mac.cc#newcode31 ui/gfx/font_render_params_mac.cc:31: // Customized font rendering settings are not yet ...
6 years, 4 months ago (2014-08-25 18:27:12 UTC) #22
ckocagil
This CL should be ready now. Land ahoy! https://codereview.chromium.org/484883003/diff/120001/ui/gfx/font_render_params_mac.cc File ui/gfx/font_render_params_mac.cc (right): https://codereview.chromium.org/484883003/diff/120001/ui/gfx/font_render_params_mac.cc#newcode31 ui/gfx/font_render_params_mac.cc:31: // ...
6 years, 4 months ago (2014-08-25 20:49:12 UTC) #23
ckocagil
The CQ bit was checked by ckocagil@chromium.org
6 years, 4 months ago (2014-08-25 20:49:29 UTC) #24
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/ckocagil@chromium.org/484883003/160001
6 years, 4 months ago (2014-08-25 20:51:11 UTC) #25
commit-bot: I haz the power
Committed patchset #8 (160001) as 3d95ea64e7c8f5df67c1620dfdb9409f7685dc3c
6 years, 4 months ago (2014-08-25 22:14:29 UTC) #26
commit-bot: I haz the power
6 years, 3 months ago (2014-09-10 02:37:48 UTC) #27
Message was sent while issue was closed.
Patchset 8 (id:??) landed as
https://crrev.com/04f49f48a13c337cb9eaef0146ec4f15ed91984a
Cr-Commit-Position: refs/heads/master@{#291767}

Powered by Google App Engine
This is Rietveld 408576698