Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge r222221 - Do not mutate RenderText content during layout.
https://bugs.webkit.org/show_bug.cgi?id=176219 <rdar://problem/34205724> Reviewed by David Hyatt. Source/WebCore: Update combined text when the style/content change as opposed to lazily, during layout. -content mutation during layout might make the inline tree go out of sync. Test: fast/text/international/dynamic-text-combine-crash.html * rendering/RenderBlockFlow.cpp: (WebCore::RenderBlockFlow::computeInlinePreferredLogicalWidths const): * rendering/RenderCombineText.cpp: (WebCore::RenderCombineText::styleDidChange): (WebCore::RenderCombineText::setRenderedText): (WebCore::RenderCombineText::combineTextIfNeeded): (WebCore::RenderCombineText::combineText): Deleted. * rendering/RenderCombineText.h: * rendering/RenderText.h: * rendering/line/BreakingContext.h: (WebCore::BreakingContext::handleText): * rendering/line/LineBreaker.cpp: (WebCore::LineBreaker::skipLeadingWhitespace): LayoutTests: * fast/text/international/dynamic-text-combine-crash.html: Added. * fast/text/text-combine-crash-expected.txt:
- Loading branch information
1 parent
5f520ae
commit e8488c1
Showing
12 changed files
with
79 additions
and
11 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
6 changes: 6 additions & 0 deletions
6
LayoutTests/fast/text/international/dynamic-text-combine-crash-expected.txt
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,6 @@ | ||
Pass if no crash. | ||
 | ||
|
||
|
||
|
||
|
20 changes: 20 additions & 0 deletions
20
LayoutTests/fast/text/international/dynamic-text-combine-crash.html
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,20 @@ | ||
<!DOCTYPE html> | ||
<html> | ||
<head> | ||
<style> | ||
h3 { | ||
max-height: 0; | ||
-webkit-text-combine: horizontal; | ||
-webkit-writing-mode: vertical-rl; | ||
} | ||
</style> | ||
</head> | ||
<body><listing>Pass if no crash.<dd contenteditable="true"><h3 id="h">foobar</h3></body> | ||
<script> | ||
if (window.testRunner) | ||
testRunner.dumpAsText(); | ||
window.getSelection().setPosition(h, 1); | ||
document.execCommand("delete", false); | ||
document.execCommand("delete", false); | ||
</script> | ||
</html> |
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