From cf3acdc14833633e817f23833479bd1f9085441f Mon Sep 17 00:00:00 2001 From: Ms2ger Date: Thu, 8 Aug 2013 19:37:47 +0200 Subject: [PATCH] Backout changeset f2ac3d57b445 for insufficient review. --- content/smil/nsSMILCSSProperty.cpp | 1 + dom/imptests/editing/implementation.js | 3 +- layout/style/Declaration.cpp | 30 +++++++++++- layout/style/nsCSSParser.cpp | 13 +++-- layout/style/nsCSSPropList.h | 12 +++++ layout/style/nsCSSProps.cpp | 8 +++- layout/style/nsCSSProps.h | 1 + layout/style/nsComputedDOMStyle.cpp | 34 +++++++++++-- layout/style/nsComputedDOMStyle.h | 1 + layout/style/nsRuleNode.cpp | 5 ++ layout/style/nsStyleConsts.h | 4 ++ layout/style/nsStyleStruct.cpp | 1 + layout/style/nsStyleStruct.h | 1 + layout/style/test/property_database.js | 12 ++++- layout/style/test/test_bug652486.html | 66 +++++++++++++++----------- 15 files changed, 151 insertions(+), 41 deletions(-) diff --git a/content/smil/nsSMILCSSProperty.cpp b/content/smil/nsSMILCSSProperty.cpp index ac0cedf0bbb8..5caadeb75619 100644 --- a/content/smil/nsSMILCSSProperty.cpp +++ b/content/smil/nsSMILCSSProperty.cpp @@ -245,6 +245,7 @@ nsSMILCSSProperty::IsPropertyAnimatable(nsCSSProperty aPropID) case eCSSProperty_stroke_opacity: case eCSSProperty_stroke_width: case eCSSProperty_text_anchor: + case eCSSProperty_text_blink: case eCSSProperty_text_decoration: case eCSSProperty_text_decoration_line: case eCSSProperty_text_rendering: diff --git a/dom/imptests/editing/implementation.js b/dom/imptests/editing/implementation.js index c774c2cacf29..70440b75956f 100644 --- a/dom/imptests/editing/implementation.js +++ b/dom/imptests/editing/implementation.js @@ -1971,7 +1971,8 @@ function isSimpleModifiableElement(node) { if (["A", "FONT", "S", "SPAN", "STRIKE", "U"].indexOf(node.tagName) != -1 && node.hasAttribute("style") && (node.style.length == 1 - || (node.style.length == 3 + || (node.style.length == 4 + && "MozTextBlink" in node.style && "MozTextDecorationColor" in node.style && "MozTextDecorationLine" in node.style && "MozTextDecorationStyle" in node.style) diff --git a/layout/style/Declaration.cpp b/layout/style/Declaration.cpp index 24001e1733e3..9754a15a6bf9 100644 --- a/layout/style/Declaration.cpp +++ b/layout/style/Declaration.cpp @@ -682,7 +682,35 @@ Declaration::GetValue(nsCSSProperty aProperty, nsAString& aValue) const return; } - AppendValueToString(eCSSProperty_text_decoration_line, aValue); + const nsCSSValue *textBlink = + data->ValueFor(eCSSProperty_text_blink); + const nsCSSValue *decorationLine = + data->ValueFor(eCSSProperty_text_decoration_line); + + NS_ABORT_IF_FALSE(textBlink->GetUnit() == eCSSUnit_Enumerated, + nsPrintfCString("bad text-blink unit %d", + textBlink->GetUnit()).get()); + NS_ABORT_IF_FALSE(decorationLine->GetUnit() == eCSSUnit_Enumerated, + nsPrintfCString("bad text-decoration-line unit %d", + decorationLine->GetUnit()).get()); + + bool blinkNone = (textBlink->GetIntValue() == NS_STYLE_TEXT_BLINK_NONE); + bool lineNone = + (decorationLine->GetIntValue() == NS_STYLE_TEXT_DECORATION_LINE_NONE); + + if (blinkNone && lineNone) { + AppendValueToString(eCSSProperty_text_decoration_line, aValue); + } else { + if (!blinkNone) { + AppendValueToString(eCSSProperty_text_blink, aValue); + } + if (!lineNone) { + if (!aValue.IsEmpty()) { + aValue.Append(PRUnichar(' ')); + } + AppendValueToString(eCSSProperty_text_decoration_line, aValue); + } + } break; } case eCSSProperty_transition: { diff --git a/layout/style/nsCSSParser.cpp b/layout/style/nsCSSParser.cpp index 553bff7bff35..e319805bd3da 100644 --- a/layout/style/nsCSSParser.cpp +++ b/layout/style/nsCSSParser.cpp @@ -9555,7 +9555,7 @@ CSSParserImpl::ParseTextDecoration() return false; } - nsCSSValue line, style, color; + nsCSSValue blink, line, style, color; switch (value.GetUnit()) { case eCSSUnit_Enumerated: { // We shouldn't accept decoration line style and color via @@ -9567,6 +9567,7 @@ CSSParserImpl::ParseTextDecoration() int32_t intValue = value.GetIntValue(); if (intValue == eDecorationNone) { + blink.SetIntValue(NS_STYLE_TEXT_BLINK_NONE, eCSSUnit_Enumerated); line.SetIntValue(NS_STYLE_TEXT_DECORATION_LINE_NONE, eCSSUnit_Enumerated); break; @@ -9588,14 +9589,18 @@ CSSParserImpl::ParseTextDecoration() intValue |= newValue; } - line.SetIntValue(intValue, eCSSUnit_Enumerated); + blink.SetIntValue((intValue & eDecorationBlink) != 0 ? + NS_STYLE_TEXT_BLINK_BLINK : NS_STYLE_TEXT_BLINK_NONE, + eCSSUnit_Enumerated); + line.SetIntValue((intValue & ~eDecorationBlink), eCSSUnit_Enumerated); break; } default: - line = color = style = value; + blink = line = color = style = value; break; } + AppendValue(eCSSProperty_text_blink, blink); AppendValue(eCSSProperty_text_decoration_line, line); AppendValue(eCSSProperty_text_decoration_color, color); AppendValue(eCSSProperty_text_decoration_style, style); @@ -9613,7 +9618,7 @@ CSSParserImpl::ParseTextDecorationLine(nsCSSValue& aValue) // look for more keywords nsCSSValue keyword; int32_t index; - for (index = 0; index < 3; index++) { + for (index = 0; index < 2; index++) { if (ParseEnum(keyword, nsCSSProps::kTextDecorationLineKTable)) { int32_t newValue = keyword.GetIntValue(); if (newValue == NS_STYLE_TEXT_DECORATION_LINE_NONE || diff --git a/layout/style/nsCSSPropList.h b/layout/style/nsCSSPropList.h index 122571af8557..3c975905bd06 100644 --- a/layout/style/nsCSSPropList.h +++ b/layout/style/nsCSSPropList.h @@ -2745,6 +2745,18 @@ CSS_PROP_SHORTHAND( TextDecoration, CSS_PROPERTY_PARSE_FUNCTION, "") +CSS_PROP_TEXTRESET( + -moz-text-blink, + text_blink, + CSS_PROP_DOMPROP_PREFIXED(TextBlink), + CSS_PROPERTY_PARSE_VALUE | + CSS_PROPERTY_APPLIES_TO_FIRST_LETTER_AND_FIRST_LINE | + CSS_PROPERTY_APPLIES_TO_PLACEHOLDER, + "", + VARIANT_HK, + kTextBlinkKTable, + offsetof(nsStyleTextReset, mTextBlink), + eStyleAnimType_EnumU8) CSS_PROP_TEXTRESET( -moz-text-decoration-color, text_decoration_color, diff --git a/layout/style/nsCSSProps.cpp b/layout/style/nsCSSProps.cpp index e536673ba777..949624214e3b 100644 --- a/layout/style/nsCSSProps.cpp +++ b/layout/style/nsCSSProps.cpp @@ -1435,12 +1435,17 @@ const int32_t nsCSSProps::kTextAlignLastKTable[] = { eCSSKeyword_UNKNOWN,-1 }; +const int32_t nsCSSProps::kTextBlinkKTable[] = { + eCSSKeyword_none, NS_STYLE_TEXT_BLINK_NONE, + eCSSKeyword_blink, NS_STYLE_TEXT_BLINK_BLINK, + eCSSKeyword_UNKNOWN,-1 +}; + const int32_t nsCSSProps::kTextDecorationLineKTable[] = { eCSSKeyword_none, NS_STYLE_TEXT_DECORATION_LINE_NONE, eCSSKeyword_underline, NS_STYLE_TEXT_DECORATION_LINE_UNDERLINE, eCSSKeyword_overline, NS_STYLE_TEXT_DECORATION_LINE_OVERLINE, eCSSKeyword_line_through, NS_STYLE_TEXT_DECORATION_LINE_LINE_THROUGH, - eCSSKeyword_blink, NS_STYLE_TEXT_DECORATION_LINE_BLINK, eCSSKeyword__moz_anchor_decoration, NS_STYLE_TEXT_DECORATION_LINE_PREF_ANCHORS, eCSSKeyword_UNKNOWN,-1 }; @@ -2359,6 +2364,7 @@ static const nsCSSProperty gPaddingEndSubpropTable[] = { }; static const nsCSSProperty gTextDecorationSubpropTable[] = { + eCSSProperty_text_blink, eCSSProperty_text_decoration_color, eCSSProperty_text_decoration_line, eCSSProperty_text_decoration_style, diff --git a/layout/style/nsCSSProps.h b/layout/style/nsCSSProps.h index 1ab32afd7bce..91df871db0fa 100644 --- a/layout/style/nsCSSProps.h +++ b/layout/style/nsCSSProps.h @@ -529,6 +529,7 @@ public: static const int32_t kTableLayoutKTable[]; static const int32_t kTextAlignKTable[]; static const int32_t kTextAlignLastKTable[]; + static const int32_t kTextBlinkKTable[]; static const int32_t kTextDecorationLineKTable[]; static const int32_t kTextDecorationStyleKTable[]; static const int32_t kTextOverflowKTable[]; diff --git a/layout/style/nsComputedDOMStyle.cpp b/layout/style/nsComputedDOMStyle.cpp index 62dabbc49347..0724d9739822 100644 --- a/layout/style/nsComputedDOMStyle.cpp +++ b/layout/style/nsComputedDOMStyle.cpp @@ -2644,6 +2644,18 @@ nsComputedDOMStyle::DoGetTextAlignLast() return val; } +CSSValue* +nsComputedDOMStyle::DoGetMozTextBlink() +{ + nsROCSSPrimitiveValue* val = new nsROCSSPrimitiveValue; + + val->SetIdent( + nsCSSProps::ValueToKeywordEnum(StyleTextReset()->mTextBlink, + nsCSSProps::kTextBlinkKTable)); + + return val; +} + CSSValue* nsComputedDOMStyle::DoGetTextDecoration() { @@ -2674,14 +2686,25 @@ nsComputedDOMStyle::DoGetTextDecoration() // don't want these to appear in the computed style. line &= ~(NS_STYLE_TEXT_DECORATION_LINE_PREF_ANCHORS | NS_STYLE_TEXT_DECORATION_LINE_OVERRIDE_ALL); + uint8_t blink = textReset->mTextBlink; - if (line == NS_STYLE_TEXT_DECORATION_LINE_NONE) { + if (blink == NS_STYLE_TEXT_BLINK_NONE && + line == NS_STYLE_TEXT_DECORATION_LINE_NONE) { val->SetIdent(eCSSKeyword_none); } else { nsAutoString str; - nsStyleUtil::AppendBitmaskCSSValue(eCSSProperty_text_decoration_line, - line, NS_STYLE_TEXT_DECORATION_LINE_UNDERLINE, - NS_STYLE_TEXT_DECORATION_LINE_BLINK, str); + if (line != NS_STYLE_TEXT_DECORATION_LINE_NONE) { + nsStyleUtil::AppendBitmaskCSSValue(eCSSProperty_text_decoration_line, + line, NS_STYLE_TEXT_DECORATION_LINE_UNDERLINE, + NS_STYLE_TEXT_DECORATION_LINE_LINE_THROUGH, str); + } + if (blink != NS_STYLE_TEXT_BLINK_NONE) { + if (!str.IsEmpty()) { + str.Append(PRUnichar(' ')); + } + nsStyleUtil::AppendBitmaskCSSValue(eCSSProperty_text_blink, blink, + NS_STYLE_TEXT_BLINK_BLINK, NS_STYLE_TEXT_BLINK_BLINK, str); + } val->SetString(str); } @@ -2722,7 +2745,7 @@ nsComputedDOMStyle::DoGetTextDecorationLine() NS_STYLE_TEXT_DECORATION_LINE_OVERRIDE_ALL); nsStyleUtil::AppendBitmaskCSSValue(eCSSProperty_text_decoration_line, intValue, NS_STYLE_TEXT_DECORATION_LINE_UNDERLINE, - NS_STYLE_TEXT_DECORATION_LINE_BLINK, decorationLineString); + NS_STYLE_TEXT_DECORATION_LINE_LINE_THROUGH, decorationLineString); val->SetString(decorationLineString); } @@ -5117,6 +5140,7 @@ nsComputedDOMStyle::GetQueryablePropertyMap(uint32_t* aLength) COMPUTED_STYLE_MAP_ENTRY(stack_sizing, StackSizing), COMPUTED_STYLE_MAP_ENTRY(_moz_tab_size, TabSize), COMPUTED_STYLE_MAP_ENTRY(text_align_last, TextAlignLast), + COMPUTED_STYLE_MAP_ENTRY(text_blink, MozTextBlink), COMPUTED_STYLE_MAP_ENTRY(text_decoration_color, TextDecorationColor), COMPUTED_STYLE_MAP_ENTRY(text_decoration_line, TextDecorationLine), COMPUTED_STYLE_MAP_ENTRY(text_decoration_style, TextDecorationStyle), diff --git a/layout/style/nsComputedDOMStyle.h b/layout/style/nsComputedDOMStyle.h index dc77197daef9..a89feedf1a4b 100644 --- a/layout/style/nsComputedDOMStyle.h +++ b/layout/style/nsComputedDOMStyle.h @@ -307,6 +307,7 @@ private: mozilla::dom::CSSValue* DoGetLineHeight(); mozilla::dom::CSSValue* DoGetTextAlign(); mozilla::dom::CSSValue* DoGetTextAlignLast(); + mozilla::dom::CSSValue* DoGetMozTextBlink(); mozilla::dom::CSSValue* DoGetTextDecoration(); mozilla::dom::CSSValue* DoGetTextDecorationColor(); mozilla::dom::CSSValue* DoGetTextDecorationLine(); diff --git a/layout/style/nsRuleNode.cpp b/layout/style/nsRuleNode.cpp index eb8168ffe588..14191f9a64c5 100644 --- a/layout/style/nsRuleNode.cpp +++ b/layout/style/nsRuleNode.cpp @@ -4012,6 +4012,11 @@ nsRuleNode::ComputeTextResetData(void* aStartStruct, } } + // text-blink: enum, inherit, initial + SetDiscrete(*aRuleData->ValueForTextBlink(), text->mTextBlink, + canStoreInRuleTree, SETDSC_ENUMERATED, parentText->mTextBlink, + NS_STYLE_TEXT_BLINK_NONE, 0, 0, 0, 0); + // text-decoration-line: enum (bit field), inherit, initial const nsCSSValue* decorationLineValue = aRuleData->ValueForTextDecorationLine(); diff --git a/layout/style/nsStyleConsts.h b/layout/style/nsStyleConsts.h index 0b9c1c9d05bb..e025efa6738a 100644 --- a/layout/style/nsStyleConsts.h +++ b/layout/style/nsStyleConsts.h @@ -659,6 +659,10 @@ static inline mozilla::css::Side operator++(mozilla::css::Side& side, int) { // Note: make sure that the largest NS_STYLE_TEXT_ALIGN_* value is smaller than // the smallest NS_STYLE_VERTICAL_ALIGN_* value below! +// See nsStyleText +#define NS_STYLE_TEXT_BLINK_NONE 0 +#define NS_STYLE_TEXT_BLINK_BLINK 1 + // See nsStyleText, nsStyleFont #define NS_STYLE_TEXT_DECORATION_LINE_NONE 0 #define NS_STYLE_TEXT_DECORATION_LINE_UNDERLINE NS_FONT_DECORATION_UNDERLINE diff --git a/layout/style/nsStyleStruct.cpp b/layout/style/nsStyleStruct.cpp index 8e17deb2c448..00d1384e157b 100644 --- a/layout/style/nsStyleStruct.cpp +++ b/layout/style/nsStyleStruct.cpp @@ -2826,6 +2826,7 @@ nsStyleTextReset::nsStyleTextReset(void) { MOZ_COUNT_CTOR(nsStyleTextReset); mVerticalAlign.SetIntValue(NS_STYLE_VERTICAL_ALIGN_BASELINE, eStyleUnit_Enumerated); + mTextBlink = NS_STYLE_TEXT_BLINK_NONE; mTextDecorationLine = NS_STYLE_TEXT_DECORATION_LINE_NONE; mTextDecorationColor = NS_RGB(0,0,0); mTextDecorationStyle = diff --git a/layout/style/nsStyleStruct.h b/layout/style/nsStyleStruct.h index 0d986cc958dc..3a20336b141f 100644 --- a/layout/style/nsStyleStruct.h +++ b/layout/style/nsStyleStruct.h @@ -1281,6 +1281,7 @@ struct nsStyleTextReset { nsStyleCoord mVerticalAlign; // [reset] coord, percent, calc, enum (see nsStyleConsts.h) nsStyleTextOverflow mTextOverflow; // [reset] enum, string + uint8_t mTextBlink; // [reset] see nsStyleConsts.h uint8_t mTextDecorationLine; // [reset] see nsStyleConsts.h uint8_t mUnicodeBidi; // [reset] see nsStyleConsts.h protected: diff --git a/layout/style/test/property_database.js b/layout/style/test/property_database.js index f95023e74b7c..3eb4839b064b 100644 --- a/layout/style/test/property_database.js +++ b/layout/style/test/property_database.js @@ -3089,11 +3089,19 @@ var gCSSProperties = { other_values: [ "center", "justify", "start", "end", "left", "right" ], invalid_values: [] }, + "-moz-text-blink": { + domProp: "MozTextBlink", + inherited: false, + type: CSS_TYPE_LONGHAND, + initial_values: [ "none" ], + other_values: [ "blink" ], + invalid_values: [ "underline", "overline", "line-through", "none underline", "underline blink", "blink underline" ] + }, "text-decoration": { domProp: "textDecoration", inherited: false, type: CSS_TYPE_SHORTHAND_AND_LONGHAND, - subproperties: [ "-moz-text-decoration-color", "-moz-text-decoration-line", "-moz-text-decoration-style" ], + subproperties: [ "-moz-text-blink", "-moz-text-decoration-color", "-moz-text-decoration-line", "-moz-text-decoration-style" ], initial_values: [ "none" ], other_values: [ "underline", "overline", "line-through", "blink", "blink line-through underline", "underline overline line-through blink", "-moz-anchor-decoration", "blink -moz-anchor-decoration" ], invalid_values: [ "none none", "underline none", "none underline", "blink none", "none blink", "line-through blink line-through", "underline overline line-through blink none", "underline overline line-throuh blink blink", @@ -3113,7 +3121,7 @@ var gCSSProperties = { inherited: false, type: CSS_TYPE_LONGHAND, initial_values: [ "none" ], - other_values: [ "underline", "overline", "line-through", "blink", "blink line-through underline", "underline overline line-through blink", "-moz-anchor-decoration", "blink -moz-anchor-decoration" ], + other_values: [ "underline", "overline", "line-through", "line-through underline", "underline overline line-through", "-moz-anchor-decoration", "-moz-anchor-decoration" ], invalid_values: [ "none none", "underline none", "none underline", "line-through blink line-through", "underline overline line-through blink none", "underline overline line-throuh blink blink" ] }, "-moz-text-decoration-style": { diff --git a/layout/style/test/test_bug652486.html b/layout/style/test/test_bug652486.html index 65d53ac4409f..fafc95a33994 100644 --- a/layout/style/test/test_bug652486.html +++ b/layout/style/test/test_bug652486.html @@ -35,100 +35,106 @@ var tests = [ // When only text-decoration was specified, text-decoration should look like // a longhand property. { decoration: "none", - line: null, color: null, style: null, + blink: null, line: null, color: null, style: null, expectedValue: "none", expectedCSSValue: "none" }, { decoration: "underline", - line: null, color: null, style: null, + blink: null, line: null, color: null, style: null, expectedValue: "underline", expectedCSSValue: "underline" }, { decoration: "overline", - line: null, color: null, style: null, + blink: null, line: null, color: null, style: null, expectedValue: "overline", expectedCSSValue: "overline" }, { decoration: "line-through", - line: null, color: null, style: null, + blink: null, line: null, color: null, style: null, expectedValue: "line-through", expectedCSSValue: "line-through" }, { decoration: "blink", - line: null, color: null, style: null, + blink: null, line: null, color: null, style: null, expectedValue: "blink", expectedCSSValue: "blink" }, { decoration: "underline overline", - line: null, color: null, style: null, + blink: null, line: null, color: null, style: null, expectedValue: "underline overline", expectedCSSValue: "underline overline" }, { decoration: "underline line-through", - line: null, color: null, style: null, + blink: null, line: null, color: null, style: null, expectedValue: "underline line-through", expectedCSSValue: "underline line-through" }, { decoration: "blink underline", - line: null, color: null, style: null, + blink: null, line: null, color: null, style: null, expectedValue: "underline blink", expectedCSSValue: "underline blink" }, { decoration: "underline blink", - line: null, color: null, style: null, + blink: null, line: null, color: null, style: null, expectedValue: "underline blink", expectedCSSValue: "underline blink" }, // When only text-decoration-line or text-blink was specified, // text-decoration should look like a longhand property. { decoration: null, - line: "blink", color: null, style: null, + blink: "blink", line: null, color: null, style: null, expectedValue: "blink", expectedCSSValue: "blink" }, { decoration: null, - line: "underline", color: null, style: null, + blink: null, line: "underline", color: null, style: null, expectedValue: "underline", expectedCSSValue: "underline" }, { decoration: null, - line: "overline", color: null, style: null, + blink: null, line: "overline", color: null, style: null, expectedValue: "overline", expectedCSSValue: "overline" }, { decoration: null, - line: "line-through", color: null, style: null, + blink: null, line: "line-through", color: null, style: null, expectedValue: "line-through", expectedCSSValue: "line-through" }, { decoration: null, - line: "blink underline", color: null, style: null, + blink: "blink", line: "underline", color: null, style: null, expectedValue: "underline blink", expectedCSSValue: "underline blink" }, + { decoration: null, + blink: "none", line: "underline", color: null, style: null, + expectedValue: "underline", expectedCSSValue: "underline" }, + { decoration: null, + blink: "blink", line: "none", color: null, style: null, + expectedValue: "blink", expectedCSSValue: "blink" }, // When text-decoration-color isn't its initial value, // text-decoration should be a shorthand property. { decoration: "blink", - line: null, color: "rgb(0, 0, 0)", style: null, + blink: null, line: null, color: "rgb(0, 0, 0)", style: null, expectedValue: "", expectedCSSValue: null }, { decoration: "underline", - line: null, color: "black", style: null, + blink: null, line: null, color: "black", style: null, expectedValue: "", expectedCSSValue: null }, { decoration: "overline", - line: null, color: "#ff0000", style: null, + blink: null, line: null, color: "#ff0000", style: null, expectedValue: "", expectedCSSValue: null }, { decoration: "line-through", - line: null, color: "initial", style: null, + blink: null, line: null, color: "initial", style: null, expectedValue: "line-through", expectedCSSValue: "line-through" }, { decoration: "blink underline", - line: null, color: "currentColor", style: null, + blink: null, line: null, color: "currentColor", style: null, expectedValue: "underline blink", expectedCSSValue: "underline blink" }, { decoration: "underline line-through", - line: null, color: "-moz-use-text-color", style: null, + blink: null, line: null, color: "-moz-use-text-color", style: null, expectedValue: "underline line-through", expectedCSSValue: "underline line-through" }, // When text-decoration-style isn't its initial value, // text-decoration should be a shorthand property. { decoration: "blink", - line: null, color: null, style: "-moz-none", + blink: null, line: null, color: null, style: "-moz-none", expectedValue: "", expectedCSSValue: null }, { decoration: "underline", - line: null, color: null, style: "dotted", + blink: null, line: null, color: null, style: "dotted", expectedValue: "", expectedCSSValue: null }, { decoration: "overline", - line: null, color: null, style: "dashed", + blink: null, line: null, color: null, style: "dashed", expectedValue: "", expectedCSSValue: null }, { decoration: "line-through", - line: null, color: null, style: "double", + blink: null, line: null, color: null, style: "double", expectedValue: "", expectedCSSValue: null }, { decoration: "blink underline", - line: null, color: null, style: "wavy", + blink: null, line: null, color: null, style: "wavy", expectedValue: "", expectedCSSValue: null }, { decoration: "underline blink overline line-through", - line: null, color: null, style: "solid", + blink: null, line: null, color: null, style: "solid", expectedValue: "underline overline line-through blink", expectedCSSValue: "underline overline line-through blink" }, { decoration: "line-through overline underline", - line: null, color: null, style: "initial", + blink: null, line: null, color: null, style: "initial", expectedValue: "underline overline line-through", expectedCSSValue: "underline overline line-through" } ]; @@ -139,6 +145,9 @@ function makeDeclaration(aTest) if (aTest.decoration) { str += "text-decoration: " + aTest.decoration + "; "; } + if (aTest.blink) { + str += "-moz-text-blink: " + aTest.blink + "; "; + } if (aTest.color) { str += "-moz-text-decoration-color: " + aTest.color + "; "; } @@ -161,6 +170,9 @@ for (var i = 0; i < tests.length; ++i) { if (test.decoration) { $('t').style.textDecoration = test.decoration; } + if (test.blink) { + $('t').style.MozTextBlink = test.blink; + } if (test.color) { $('t').style.MozTextDecorationColor = test.color; }