|
Make Document::caretRangeFromPoint() to work with :first-letter style
This patch makes Document::caretRangeFromPoint() to work with :first-letter style by changing HitTestResult class to know whether specified point is in a renderer for :first-letter or not. Because of text nodes having :first-letter style are associated to two renderer, one for first letter and another is rest of text, this patch changes nodeFromPoint() to rendererFromPoint() and makes Document::caretRangeFromPoint() to use it.
This patch is a part of fixing issue 174349. Another patch will make selection to work with :first-letter style.
BUG=n/a
TEST=LayoutTests/fast/dom/Document/CaretRangeFromPoint/caretRangeFromPoint-with-first-letter-style.html
R=ojan@chromium.org
Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=159012
Total comments: 1
|
Unified diffs |
Side-by-side diffs |
Delta from patch set |
Stats (+108 lines, -12 lines) |
Patch |
|
A |
LayoutTests/fast/dom/Document/CaretRangeFromPoint/caretRangeFromPoint-with-first-letter-style.html
|
View
|
1
|
1 chunk |
+28 lines, -0 lines |
0 comments
|
Download
|
|
A |
LayoutTests/fast/dom/Document/CaretRangeFromPoint/caretRangeFromPoint-with-first-letter-style-expected.txt
|
View
|
|
1 chunk |
+11 lines, -0 lines |
0 comments
|
Download
|
|
M |
Source/core/dom/Document.cpp
|
View
|
1
|
2 chunks |
+3 lines, -5 lines |
0 comments
|
Download
|
|
M |
Source/core/dom/TreeScope.h
|
View
|
|
2 chunks |
+2 lines, -1 line |
0 comments
|
Download
|
|
M |
Source/core/dom/TreeScope.cpp
|
View
|
1
|
2 chunks |
+10 lines, -5 lines |
0 comments
|
Download
|
|
M |
Source/core/rendering/HitTestResult.h
|
View
|
|
4 chunks |
+5 lines, -0 lines |
0 comments
|
Download
|
|
M |
Source/core/rendering/HitTestResult.cpp
|
View
|
|
7 chunks |
+17 lines, -0 lines |
0 comments
|
Download
|
|
M |
Source/core/rendering/RenderText.h
|
View
|
|
1 chunk |
+1 line, -0 lines |
0 comments
|
Download
|
|
M |
Source/core/rendering/RenderText.cpp
|
View
|
1
|
1 chunk |
+2 lines, -1 line |
0 comments
|
Download
|
|
M |
Source/core/rendering/RenderTextFragment.h
|
View
|
|
2 chunks |
+3 lines, -0 lines |
0 comments
|
Download
|
|
M |
Source/core/rendering/RenderTextFragment.cpp
|
View
|
|
3 chunks |
+26 lines, -0 lines |
0 comments
|
Download
|
Total messages: 5 (0 generated)
|