[chromium] Font::drawComplexText can not draw a segment of text run
authorcommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 18 Nov 2011 05:25:01 +0000 (05:25 +0000)
committercommit-queue@webkit.org <commit-queue@webkit.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Fri, 18 Nov 2011 05:25:01 +0000 (05:25 +0000)
commit7f9d11278102f3dec9a9b99b0809796ab20de501
tree4d9225d9bc17d3344e9c930e9cb5c8d95f80b859
parentd0043d1e9c1c0f58bc4ce826022b474ac82c9d27
[chromium] Font::drawComplexText can not draw a segment of text run
https://bugs.webkit.org/show_bug.cgi?id=72095

Patch by Robin Cao <robin.cao@torchmobile.com.cn> on 2011-11-17
Reviewed by Adam Barth.

Source/WebCore:

drawComplexText() should respect the 'from' and 'to' arguments.
Drawing the whole text run may result in text overlapping.

Test: platform/chromium-linux/fast/text/international/draw-complex-text-from-to.html

* platform/graphics/chromium/ComplexTextControllerLinux.cpp:
(WebCore::ComplexTextController::glyphsForRange):
* platform/graphics/chromium/ComplexTextControllerLinux.h:
* platform/graphics/chromium/FontLinux.cpp:
(WebCore::Font::drawComplexText):

LayoutTests:

* platform/chromium-linux/fast/text/international/draw-complex-text-from-to-expected.png: Added.
* platform/chromium-linux/fast/text/international/draw-complex-text-from-to-expected.txt: Added.
* platform/chromium-linux/fast/text/international/draw-complex-text-from-to.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@100718 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/platform/chromium-linux/fast/text/international/draw-complex-text-from-to-expected.png [new file with mode: 0644]
LayoutTests/platform/chromium-linux/fast/text/international/draw-complex-text-from-to-expected.txt [new file with mode: 0644]
LayoutTests/platform/chromium-linux/fast/text/international/draw-complex-text-from-to.html [new file with mode: 0644]
Source/WebCore/ChangeLog
Source/WebCore/platform/graphics/chromium/ComplexTextControllerLinux.cpp
Source/WebCore/platform/graphics/chromium/ComplexTextControllerLinux.h
Source/WebCore/platform/graphics/chromium/FontLinux.cpp