Permalink
Show file tree
Hide file tree
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Browse files
Don't detach whitespace nodes when the previous sibling is an out of …
…flow block Don't detach whitespace nodes when the previous sibling is an out of flow block https://bugs.webkit.org/show_bug.cgi?id=247683 Reviewed by Alan Baradlay. Merge - https://src.chromium.org/viewvc/blink?revision=195585&view=revision A whitespace node was not being rendered after an out of flow block element was inserted in front of it and the container was an inline element. Normally a block element would cause the whitespace node to be detached as it should no longer be rendered since the block element creates a new line. This doesn't matter though if the block element is out of the normal flow of the document. Now we correctly verify that the inserted block element is in the normal flow the document before deciding if no renderer is needed. * Source/WebCore/rendering/updating/RenderTreeUpdater.cpp: (RenderTreeUpdater::textRendererIsNeeded): Add "isOutOfFlowPositioned" condition * LayoutTests/fast/inline/do-not-detach-whitespace-with-out-of-flow-siblings-inside-inline-parent.html: Add Test Case * LayoutTests/fast/inline/do-not-detach-whitespace-with-out-of-flow-siblings-inside-inline-parent-expected.html: Add Test Case Expectation * LayoutTests/fast/block/positioning/relative-positioned-inline-container-expected.txt: Updated Test Expectations * LayoutTests/imported/w3c/web-platform-tests/css/css-position/position-absolute-crash-chrome-007.txt: Ditto * LayoutTests/platform/glib/fast/block/positioning/052-expected.txt: Ditto * LayoutTests/platform/glib/fast/block/positioning/058-expected.txt: Ditto * LayoutTests/platform/glib/fast/block/positioning/relative-positioned-inline-container-expected.txt: Ditto * LayoutTests/platform/glib/fast/block/positioning/trailing-space-test-expected.txt: Ditto * LayoutTests/platform/gtk/fast/block/positioning/052-expected.png: Ditto * LayoutTests/platform/gtk/fast/block/positioning/058-expected.png: Ditto * LayoutTests/platform/gtk/fast/block/positioning/rtl-static-positioning-expected.txt: Ditto * LayoutTests/platform/gtk/fast/block/positioning/trailing-space-test-expected.png: Ditto * LayoutTests/platform/ios/fast/block/positioning/052-expected.txt: Ditto * LayoutTests/platform/ios/fast/block/positioning/058-expected.txt: Ditto * LayoutTests/platform/ios/fast/block/positioning/rtl-static-positioning-expected.txt: Ditto * LayoutTests/platform/ios/fast/block/positioning/trailing-space-test-expected.txt: Ditto * LayoutTests/platform/mac/fast/block/positioning/052-expected.txt: Ditto * LayoutTests/platform/mac/fast/block/positioning/058-expected.txt: Ditto * LayoutTests/platform/mac/fast/block/positioning/rtl-static-positioning-expected.txt: Ditto * LayoutTests/platform/mac/fast/block/positioning/trailing-space-test-expected.txt: Ditto Canonical link: https://commits.webkit.org/256602@main
- Loading branch information
1 parent
2b519ff
commit af4bfb1cdbf87b2c7f020cd627ea2d72177fee26
Showing
21 changed files
with
48 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
<!DOCTYPE html> | ||
<style> | ||
/* Disable kerning because kerning may differ for different node tree. */ | ||
html { font-kerning: none; } | ||
</style> | ||
<body> | ||
<span> | ||
<span>A</span> | ||
<span>B</span> | ||
</span> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
<!DOCTYPE html> | ||
<style> | ||
/* Disable kerning because kerning may differ for different node tree. */ | ||
html { font-kerning: none; } | ||
</style> | ||
<body> | ||
<span> | ||
<span id="A">A</span> | ||
<span>B</span> | ||
</span> | ||
<script> | ||
var a = document.getElementById('A'); | ||
var d = document.createElement('div'); | ||
d.style.position = "absolute"; | ||
a.parentNode.insertBefore(d, a.nextSibling); | ||
</script> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,7 @@ | ||
parent | ||
start split start | ||
splitter | ||
split middle css-container start ABSFULLABS css container end split end parent end | ||
split middle css-container start ABS FULLABS css container end split end parent end | ||
|
||
PASS test passes if it does not crash | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
BIN
-3 Bytes
(100%)
LayoutTests/platform/gtk/fast/block/positioning/052-expected.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
BIN
-27 Bytes
(100%)
LayoutTests/platform/gtk/fast/block/positioning/058-expected.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
BIN
+17 Bytes
(100%)
LayoutTests/platform/gtk/fast/block/positioning/trailing-space-test-expected.png
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters