DescriptionShows Japanese and English mixed queries correctly.
This CL respects the common height and baseline of the fonts in the given font list, and draw text according to the baseline.
The cause of vertically-misaligned queries was that
1. ASCII characters have 23 pixels in height
2. Japanese characters have 17 pixels in height
pango_layout_get_pixel_size(), which is called in RenderTextLinux::GetStringSize(), returns the above size.
Also see:
https://docs.google.com/a/chromium.org/document/d/1e2n9lEM_usn37Pld8tMeo_qpfLRQQjkx-O1hTHi3sPo/edit?usp=sharing
BUG=244323
TEST=Test manually.
Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=211664
Patch Set 1 #Patch Set 2 : Fixes RenderText::GetAlignmentOffset(). #
Total comments: 2
Patch Set 3 : Switched the way to fix the issue. #Patch Set 4 : Adds a unit test. #
Total comments: 16
Patch Set 5 : Fixes based on review comments. #
Total comments: 10
Patch Set 6 : Fixed code style and comments. #Patch Set 7 : Synced. #Patch Set 8 : Disables the test on Android. #
Messages
Total messages: 19 (0 generated)
|