Diff
Modified: trunk/LayoutTests/ChangeLog (210984 => 210985)
--- trunk/LayoutTests/ChangeLog 2017-01-20 22:07:28 UTC (rev 210984)
+++ trunk/LayoutTests/ChangeLog 2017-01-20 22:12:02 UTC (rev 210985)
@@ -1,3 +1,17 @@
+2017-01-20 Zalan Bujtas <[email protected]>
+
+ Simple line layout: Add support for non-breaking space character.
+ https://bugs.webkit.org/show_bug.cgi?id=167250
+ <rdar://problem/30119638>
+
+ Reviewed by Antti Koivisto.
+
+ These are output progressions (they do not reflect changes in functionality).
+
+ * fast/block/float/br-with-clear-2-expected.txt:
+ * platform/mac/css1/text_properties/text_transform-expected.txt:
+ * platform/mac/tables/mozilla/bugs/bug4427-expected.txt:
+
2017-01-20 Ryan Haddad <[email protected]>
Marking macos-fullscreen-media-controls/macos-fullscreen-media-controls-buttons-containers-styles.html as flaky on mac-wk1.
Modified: trunk/LayoutTests/fast/block/float/br-with-clear-2-expected.txt (210984 => 210985)
--- trunk/LayoutTests/fast/block/float/br-with-clear-2-expected.txt 2017-01-20 22:07:28 UTC (rev 210984)
+++ trunk/LayoutTests/fast/block/float/br-with-clear-2-expected.txt 2017-01-20 22:12:02 UTC (rev 210985)
@@ -7,7 +7,7 @@
RenderBlock (floating) {DIV} at (0,0) size 50x50 [color=#FF0000] [bgcolor=#FFFFE0]
RenderText {#text} at (0,0) size 75x25
text run at (0,0) width 75: " A"
- RenderBR {BR} at (0,0) size 0x0
+ RenderBR {BR} at (75,20) size 0x0
RenderBR {BR} at (0,25) size 0x25
RenderText {#text} at (0,50) size 25x25
text run at (0,50) width 25: "B"
@@ -22,7 +22,7 @@
RenderBlock (floating) {DIV} at (0,0) size 50x50 [color=#FF0000] [bgcolor=#FFFFE0]
RenderText {#text} at (0,0) size 75x25
text run at (0,0) width 75: " A"
- RenderBR {BR} at (0,0) size 0x0
+ RenderBR {BR} at (75,20) size 0x0
RenderBR {BR} at (0,25) size 0x25
RenderText {#text} at (0,50) size 25x25
text run at (0,50) width 25: "B"
Modified: trunk/LayoutTests/platform/mac/css1/text_properties/text_transform-expected.txt (210984 => 210985)
--- trunk/LayoutTests/platform/mac/css1/text_properties/text_transform-expected.txt 2017-01-20 22:07:28 UTC (rev 210984)
+++ trunk/LayoutTests/platform/mac/css1/text_properties/text_transform-expected.txt 2017-01-20 22:12:02 UTC (rev 210985)
@@ -70,7 +70,7 @@
RenderBlock {P} at (4,56) size 747x54
RenderText {#text} at (0,0) size 724x54
text run at (0,0) width 724: "This Paragraph Is Capitalized And The First Letter In Each Word Should Therefore Appear In Uppercase. Words"
- text run at (0,18) width 719: "That Are In Uppercase In The Source (E.g. USA) Should Remain So. There Should Be A Capital Letter After A"
+ text run at (0,18) width 718: "That Are In Uppercase In The Source (E.g. USA) Should Remain So. There Should Be A Capital Letter After A"
text run at (0,36) width 577: "Non-Breaking Space (&Nbsp;). Both Those Characters Appear In The Previous Sentence."
RenderBlock {P} at (4,126) size 747x36
RenderText {#text} at (0,0) size 743x36
Modified: trunk/LayoutTests/platform/mac/tables/mozilla/bugs/bug4427-expected.txt (210984 => 210985)
--- trunk/LayoutTests/platform/mac/tables/mozilla/bugs/bug4427-expected.txt 2017-01-20 22:07:28 UTC (rev 210984)
+++ trunk/LayoutTests/platform/mac/tables/mozilla/bugs/bug4427-expected.txt 2017-01-20 22:12:02 UTC (rev 210985)
@@ -94,7 +94,7 @@
text run at (2,56) width 103: "San Francisco, "
text run at (104,56) width 31: "CA "
text run at (134,56) width 45: "94132 "
- RenderBR {BR} at (0,0) size 0x0
+ RenderBR {BR} at (178,70) size 1x0
RenderTableCell {TD} at (252,1) size 25x5 [border: (1px inset #808080)] [r=0 c=2 rs=1 cs=1]
RenderImage {IMG} at (2,2) size 20x1
RenderTableCell {TD} at (277,1) size 148x38 [border: (1px inset #808080)] [r=0 c=3 rs=1 cs=1]
@@ -125,7 +125,7 @@
RenderText {#text} at (2,56) size 75x18
text run at (2,56) width 31: "CA "
text run at (32,56) width 45: "00000 "
- RenderBR {BR} at (0,0) size 0x0
+ RenderBR {BR} at (76,70) size 1x0
RenderText {#text} at (2,74) size 100x18
text run at (2,74) width 100: "(000) 000-0000"
RenderTableCell {TD} at (252,102) size 25x5 [border: (1px inset #808080)] [r=2 c=2 rs=1 cs=1]
Modified: trunk/Source/WebCore/ChangeLog (210984 => 210985)
--- trunk/Source/WebCore/ChangeLog 2017-01-20 22:07:28 UTC (rev 210984)
+++ trunk/Source/WebCore/ChangeLog 2017-01-20 22:12:02 UTC (rev 210985)
@@ -1,3 +1,22 @@
+2017-01-20 Zalan Bujtas <[email protected]>
+
+ Simple line layout: Add support for non-breaking space character.
+ https://bugs.webkit.org/show_bug.cgi?id=167250
+ <rdar://problem/30119638>
+
+ Reviewed by Antti Koivisto.
+
+ Do not bail out on noBreakSpace character.
+ The line breaking logic already takes noBreakSpace characters into account.
+ (except the peculiar "-webkit-nbsp-mode: space" mode)
+
+ Covered by existing test cases.
+
+ * rendering/SimpleLineLayout.cpp:
+ (WebCore::SimpleLineLayout::canUseForText):
+ (WebCore::SimpleLineLayout::canUseForStyle):
+ (WebCore::SimpleLineLayout::printReason):
+
2017-01-20 Antoine Quint <[email protected]>
Web Animations should be off by default and enabled as an experimental feature
Modified: trunk/Source/WebCore/rendering/SimpleLineLayout.cpp (210984 => 210985)
--- trunk/Source/WebCore/rendering/SimpleLineLayout.cpp 2017-01-20 22:07:28 UTC (rev 210984)
+++ trunk/Source/WebCore/rendering/SimpleLineLayout.cpp 2017-01-20 22:12:02 UTC (rev 210985)
@@ -76,27 +76,27 @@
FlowHasUnsupportedUnderlineDecoration = 1LLU << 11,
FlowHasJustifiedNonLatinText = 1LLU << 12,
FlowHasOverflowVisible = 1LLU << 13,
- FlowIsNotLTR = 1LLU << 14,
- FlowHasLineBoxContainProperty = 1LLU << 15,
- FlowIsNotTopToBottom = 1LLU << 16,
- FlowHasLineBreak = 1LLU << 17,
- FlowHasNonNormalUnicodeBiDi = 1LLU << 18,
- FlowHasRTLOrdering = 1LLU << 19,
- FlowHasLineAlignEdges = 1LLU << 20,
- FlowHasLineSnap = 1LLU << 21,
- FlowHasHypensAuto = 1LLU << 22,
- FlowHasTextEmphasisFillOrMark = 1LLU << 23,
- FlowHasTextShadow = 1LLU << 24,
- FlowHasPseudoFirstLine = 1LLU << 25,
- FlowHasPseudoFirstLetter = 1LLU << 26,
- FlowHasTextCombine = 1LLU << 27,
- FlowHasTextFillBox = 1LLU << 28,
- FlowHasBorderFitLines = 1LLU << 29,
- FlowHasNonAutoLineBreak = 1LLU << 30,
- FlowHasNonAutoTrailingWord = 1LLU << 31,
- FlowHasSVGFont = 1LLU << 32,
- FlowTextIsEmpty = 1LLU << 33,
- FlowTextHasNoBreakSpace = 1LLU << 34,
+ FlowHasWebKitNBSPMode = 1LLU << 14,
+ FlowIsNotLTR = 1LLU << 15,
+ FlowHasLineBoxContainProperty = 1LLU << 16,
+ FlowIsNotTopToBottom = 1LLU << 17,
+ FlowHasLineBreak = 1LLU << 18,
+ FlowHasNonNormalUnicodeBiDi = 1LLU << 19,
+ FlowHasRTLOrdering = 1LLU << 20,
+ FlowHasLineAlignEdges = 1LLU << 21,
+ FlowHasLineSnap = 1LLU << 22,
+ FlowHasHypensAuto = 1LLU << 23,
+ FlowHasTextEmphasisFillOrMark = 1LLU << 24,
+ FlowHasTextShadow = 1LLU << 25,
+ FlowHasPseudoFirstLine = 1LLU << 26,
+ FlowHasPseudoFirstLetter = 1LLU << 27,
+ FlowHasTextCombine = 1LLU << 28,
+ FlowHasTextFillBox = 1LLU << 29,
+ FlowHasBorderFitLines = 1LLU << 30,
+ FlowHasNonAutoLineBreak = 1LLU << 31,
+ FlowHasNonAutoTrailingWord = 1LLU << 32,
+ FlowHasSVGFont = 1LLU << 33,
+ FlowTextIsEmpty = 1LLU << 34,
FlowTextHasSoftHyphen = 1LLU << 35,
FlowTextHasDirectionCharacter = 1LLU << 36,
FlowIsMissingPrimaryFont = 1LLU << 37,
@@ -156,9 +156,6 @@
SET_REASON_AND_RETURN_IF_NEEDED(FlowHasJustifiedNonLatinText, reasons, includeReasons);
}
- // These would be easy to support.
- if (character == noBreakSpace)
- SET_REASON_AND_RETURN_IF_NEEDED(FlowTextHasNoBreakSpace, reasons, includeReasons);
if (character == softHyphen)
SET_REASON_AND_RETURN_IF_NEEDED(FlowTextHasSoftHyphen, reasons, includeReasons);
@@ -257,6 +254,8 @@
SET_REASON_AND_RETURN_IF_NEEDED(FlowHasBorderFitLines, reasons, includeReasons);
if (style.lineBreak() != LineBreakAuto)
SET_REASON_AND_RETURN_IF_NEEDED(FlowHasNonAutoLineBreak, reasons, includeReasons);
+ if (style.nbspMode() != NBNORMAL)
+ SET_REASON_AND_RETURN_IF_NEEDED(FlowHasWebKitNBSPMode, reasons, includeReasons);
#if ENABLE(CSS_TRAILING_WORD)
if (style.trailingWord() != TrailingWord::Auto)
SET_REASON_AND_RETURN_IF_NEEDED(FlowHasNonAutoTrailingWord, reasons, includeReasons);
@@ -930,6 +929,9 @@
case FlowHasOverflowVisible:
stream << "overflow: visible";
break;
+ case FlowHasWebKitNBSPMode:
+ stream << "-webkit-nbsp-mode: space";
+ break;
case FlowIsNotLTR:
stream << "dir is not LTR";
break;
@@ -984,9 +986,6 @@
case FlowHasSVGFont:
stream << "SVG font";
break;
- case FlowTextHasNoBreakSpace:
- stream << "No-break-space character";
- break;
case FlowTextHasSoftHyphen:
stream << "soft hyphen character";
break;