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

Issue 8565011: Implement font fallback in RenderTextWin. (Closed)

Created:
9 years, 1 month ago by Alexei Svitkine (slow)
Modified:
9 years, 1 month ago
Reviewers:
msw, sky
CC:
chromium-reviews
Visibility:
Public.

Description

Implement font fallback in RenderTextWin. This is done by using a metafile to capture the font that Uniscribe would use to render the text (since there is no API to get this from Uniscribe itself). Makes SCRIPT_CACHE be per-run, since different runs may have different fonts and the SCRIPT_CACHE cannot be re-used between these. This is similar to what is done in WebKit in FontCacheWin.cpp BUG=90426 TEST=Run chrome.exe --use-pure-views and paste some Hebrew text into the omnibox. It should show up properly. Committed: http://src.chromium.org/viewvc/chrome?view=rev&revision=109977

Patch Set 1 #

Patch Set 2 : '' #

Total comments: 4

Patch Set 3 : '' #

Total comments: 10

Patch Set 4 : '' #

Patch Set 5 : '' #

Unified diffs Side-by-side diffs Delta from patch set Stats (+82 lines, -17 lines) Patch
M ui/gfx/render_text_win.h View 3 chunks +3 lines, -4 lines 0 comments Download
M ui/gfx/render_text_win.cc View 1 2 3 4 11 chunks +79 lines, -13 lines 0 comments Download

Messages

Total messages: 12 (0 generated)
Alexei Svitkine (slow)
msw: review sky: OWNERS approval
9 years, 1 month ago (2011-11-14 15:39:43 UTC) #1
sky
http://codereview.chromium.org/8565011/diff/3002/ui/gfx/render_text_win.cc File ui/gfx/render_text_win.cc (right): http://codereview.chromium.org/8565011/diff/3002/ui/gfx/render_text_win.cc#newcode75 ui/gfx/render_text_win.cc:75: = reinterpret_cast<const EMREXTCREATEFONTINDIRECTW*>(record); = on previous line. http://codereview.chromium.org/8565011/diff/3002/ui/gfx/render_text_win.cc#newcode499 ui/gfx/render_text_win.cc:499: ...
9 years, 1 month ago (2011-11-14 16:30:40 UTC) #2
Alexei Svitkine (slow)
http://codereview.chromium.org/8565011/diff/3002/ui/gfx/render_text_win.cc File ui/gfx/render_text_win.cc (right): http://codereview.chromium.org/8565011/diff/3002/ui/gfx/render_text_win.cc#newcode75 ui/gfx/render_text_win.cc:75: = reinterpret_cast<const EMREXTCREATEFONTINDIRECTW*>(record); On 2011/11/14 16:30:41, sky wrote: > ...
9 years, 1 month ago (2011-11-14 16:41:37 UTC) #3
msw
LGTM with questions/nits. http://codereview.chromium.org/8565011/diff/6001/ui/gfx/render_text_win.cc File ui/gfx/render_text_win.cc (right): http://codereview.chromium.org/8565011/diff/6001/ui/gfx/render_text_win.cc#newcode73 ui/gfx/render_text_win.cc:73: LOGFONT* font = reinterpret_cast<LOGFONT*>(log_font); Can you ...
9 years, 1 month ago (2011-11-14 19:43:31 UTC) #4
Alexei Svitkine (slow)
http://codereview.chromium.org/8565011/diff/6001/ui/gfx/render_text_win.cc File ui/gfx/render_text_win.cc (right): http://codereview.chromium.org/8565011/diff/6001/ui/gfx/render_text_win.cc#newcode73 ui/gfx/render_text_win.cc:73: LOGFONT* font = reinterpret_cast<LOGFONT*>(log_font); On 2011/11/14 19:43:31, msw wrote: ...
9 years, 1 month ago (2011-11-14 19:56:58 UTC) #5
msw
http://codereview.chromium.org/8565011/diff/6001/ui/gfx/render_text_win.cc File ui/gfx/render_text_win.cc (right): http://codereview.chromium.org/8565011/diff/6001/ui/gfx/render_text_win.cc#newcode498 ui/gfx/render_text_win.cc:498: ScriptFreeCache(&run->script_cache); On 2011/11/14 19:56:58, Alexei Svitkine wrote: > On ...
9 years, 1 month ago (2011-11-14 20:05:25 UTC) #6
Alexei Svitkine (slow)
> Fair enough, but if ChooseFallbackFont doesn't find a suitable font, we may > still ...
9 years, 1 month ago (2011-11-14 20:15:24 UTC) #7
msw
Thanks. Also, can you set BUG=90426?
9 years, 1 month ago (2011-11-14 20:17:32 UTC) #8
Alexei Svitkine (slow)
On 2011/11/14 20:17:32, msw wrote: > Thanks. Also, can you set BUG=90426? Done.
9 years, 1 month ago (2011-11-14 20:25:00 UTC) #9
sky
LGTM
9 years, 1 month ago (2011-11-14 21:44:47 UTC) #10
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/asvitkine@chromium.org/8565011/1005
9 years, 1 month ago (2011-11-14 21:53:29 UTC) #11
commit-bot: I haz the power
9 years, 1 month ago (2011-11-14 23:22:17 UTC) #12
Change committed as 109977

Powered by Google App Engine
This is Rietveld 408576698