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

Issue 24622002: Workaround font preference in CJK DOM locales (Closed)

Created:
7 years, 2 months ago by Xianzhu
Modified:
7 years, 2 months ago
CC:
blink-reviews, jamesr, dsinclair, danakj, dglazkov+blink, Rik, apavlov+blink_chromium.org, darktears, Stephen Chennney, jeez, pdr.
Base URL:
https://chromium.googlesource.com/chromium/blink.git@master
Visibility:
Public.

Description

Workaround font preference in CJK DOM locales For now Android system doesn't support per-family per-script font preferences, but Chrome needs to prefer Japanese font when DOM locale is ja (and maybe also zh and ko if fallback_fonts.xml is customized. This CL is a workaround of the issue before there is full support from Android system and Skia. The preferred fallback font of the CJK DOM locale will be used if no or generic family is specified in CSS. BUG=266412 TEST=manually test with <html lang="ja">...</html> TEST=fast/text/international/lang-glyph-cache-separation.html (ensures glyph caches of different langs not to interfere) Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=158398

Patch Set 1 : #

Patch Set 2 : Test #

Total comments: 2
Unified diffs Side-by-side diffs Delta from patch set Stats (+99 lines, -3 lines) Patch
A LayoutTests/fast/text/international/lang-glyph-cache-separation.html View 1 1 chunk +18 lines, -0 lines 2 comments Download
A LayoutTests/fast/text/international/lang-glyph-cache-separation-expected.html View 1 1 chunk +18 lines, -0 lines 0 comments Download
M Source/core/css/CSSFontSelector.cpp View 2 chunks +4 lines, -0 lines 0 comments Download
M Source/core/platform/graphics/FontCache.h View 1 chunk +4 lines, -0 lines 0 comments Download
M Source/core/platform/graphics/chromium/FontCacheAndroid.cpp View 1 chunk +55 lines, -3 lines 0 comments Download

Messages

Total messages: 15 (0 generated)
Xianzhu
Sorry I just accidentally pressed the "Delete" button when editing the original CL 24482002, so ...
7 years, 2 months ago (2013-09-25 17:40:41 UTC) #1
jungshik at Google
On 2013/09/25 17:40:41, Xianzhu wrote: > Sorry I just accidentally pressed the "Delete" button when ...
7 years, 2 months ago (2013-09-25 19:05:14 UTC) #2
Xianzhu
eae@/eseidel@, would you please review this CL as owners? Thanks.
7 years, 2 months ago (2013-09-25 22:11:05 UTC) #3
falken
lgtm too (but I'm not an owner)
7 years, 2 months ago (2013-09-26 10:17:16 UTC) #4
Xianzhu
ping owners...
7 years, 2 months ago (2013-09-26 19:20:11 UTC) #5
eae
While this is a good change (or good workaround until we can solve it properly) ...
7 years, 2 months ago (2013-09-26 20:12:25 UTC) #6
Xianzhu
On 2013/09/26 20:12:25, eae wrote: > While this is a good change (or good workaround ...
7 years, 2 months ago (2013-09-26 20:28:34 UTC) #7
eae
On 2013/09/26 20:28:34, Xianzhu wrote: > On 2013/09/26 20:12:25, eae wrote: > > While this ...
7 years, 2 months ago (2013-09-26 20:29:40 UTC) #8
Xianzhu
On 2013/09/26 20:29:40, eae wrote: > Thanks for the clarification. Would be great if we ...
7 years, 2 months ago (2013-09-26 20:46:28 UTC) #9
eae
LGTM Awesome, thank you.
7 years, 2 months ago (2013-09-26 20:48:44 UTC) #10
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/wangxianzhu@chromium.org/24622002/13001
7 years, 2 months ago (2013-09-26 20:49:08 UTC) #11
commit-bot: I haz the power
Change committed as 158398
7 years, 2 months ago (2013-09-26 22:25:31 UTC) #12
jungshik at Google
Can you use U+76F4 instead in a follow-up CL? Thanks. https://codereview.chromium.org/24622002/diff/13001/LayoutTests/fast/text/international/lang-glyph-cache-separation.html File LayoutTests/fast/text/international/lang-glyph-cache-separation.html (right): https://codereview.chromium.org/24622002/diff/13001/LayoutTests/fast/text/international/lang-glyph-cache-separation.html#newcode18 ...
7 years, 2 months ago (2013-09-27 23:37:05 UTC) #13
jungshik at Google
On 2013/09/27 23:37:05, Jungshik Shin wrote: > Can you use U+76F4 instead in a follow-up ...
7 years, 2 months ago (2013-09-27 23:38:09 UTC) #14
Xianzhu
7 years, 2 months ago (2013-09-28 00:35:20 UTC) #15
Message was sent while issue was closed.
https://codereview.chromium.org/24622002/diff/13001/LayoutTests/fast/text/int...
File LayoutTests/fast/text/international/lang-glyph-cache-separation.html
(right):

https://codereview.chromium.org/24622002/diff/13001/LayoutTests/fast/text/int...
LayoutTests/fast/text/international/lang-glyph-cache-separation.html:18: <div
id="zh" lang="zh">Chinese: &#x4E00;&#x4E01;</div>
On 2013/09/27 23:37:05, Jungshik Shin wrote:
> For a human inspection, I'd use glyphs that are actually visually different
> instead of rather simple characters like U+4E00, U+4E01 for which ja and zh
> variants are very hard to distinguish if their styles are matched. 
> 
> Perhaps, U+76F4 would be a pretty good one (it's the 'notorious' one :-)).
And,
> using 'zh-CN' would be better than 'zh'. 
> 

Sure. Thanks for the suggestion.

Powered by Google App Engine
This is Rietveld 408576698