Simple line layout: Text jumps sometimes on naughty strings page
authorzalan@apple.com <zalan@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 27 Aug 2015 21:39:20 +0000 (21:39 +0000)
committerzalan@apple.com <zalan@apple.com@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Thu, 27 Aug 2015 21:39:20 +0000 (21:39 +0000)
commit025bfbb16bf429be6ad5c4d7fda10ec95c24e1a2
tree52c209e205e9ca9cf877abcbad3f613d1fd38cdd
parent3a262665112776acc54d38ea6d562b686642677f
Simple line layout: Text jumps sometimes on naughty strings page
https://bugs.webkit.org/show_bug.cgi?id=148399
rdar://problem/22212568

Reviewed by Antti Koivisto.

The x position we set for tab characters during painting should
be the same as if it was set by the inline box tree painting.

Inline box tree computes the distance from the rootbox for each line
and sets this value as the xPos for the TextRun.
Currently simple line layout does not support cases where a line
would have an offset, so this value is always 0.

Source/WebCore:

Test: fast/text/whitespace/simple-line-layout-tab-position.html

* rendering/SimpleLineLayoutFunctions.cpp:
(WebCore::SimpleLineLayout::paintFlow):

LayoutTests:

* fast/text/whitespace/simple-line-layout-tab-position-expected.html: Added.
* fast/text/whitespace/simple-line-layout-tab-position.html: Added.

git-svn-id: https://svn.webkit.org/repository/webkit/trunk@189058 268f45cc-cd09-0410-ab3c-d52691b4dbfc
LayoutTests/ChangeLog
LayoutTests/fast/text/whitespace/simple-line-layout-tab-position-expected.html [new file with mode: 0644]
LayoutTests/fast/text/whitespace/simple-line-layout-tab-position.html [new file with mode: 0644]
Source/WebCore/ChangeLog
Source/WebCore/rendering/SimpleLineLayoutFunctions.cpp