| Index: Source/core/css/resolver/StyleBuilderCustom.cpp
|
| diff --git a/Source/core/css/resolver/StyleBuilderCustom.cpp b/Source/core/css/resolver/StyleBuilderCustom.cpp
|
| index 37b4c59d9c461334cbe025447453b948fe0d738f..77c83708ee5027f0dbbdeb2c9772b72ebf84e22b 100644
|
| --- a/Source/core/css/resolver/StyleBuilderCustom.cpp
|
| +++ b/Source/core/css/resolver/StyleBuilderCustom.cpp
|
| @@ -295,6 +295,58 @@ void StyleBuilderFunctions::applyValueCSSPropertyFontWeight(StyleResolverState&
|
| }
|
| }
|
|
|
| +
|
| +void StyleBuilderFunctions::applyInitialCSSPropertyFontStretch(StyleResolverState& state)
|
| +{
|
| + state.fontBuilder().setStretch(FontStretchNormal);
|
| +}
|
| +
|
| +void StyleBuilderFunctions::applyInheritCSSPropertyFontStretch(StyleResolverState& state)
|
| +{
|
| + state.fontBuilder().setStretch(state.parentFontDescription().stretch());
|
| +}
|
| +
|
| +void StyleBuilderFunctions::applyValueCSSPropertyFontStretch(StyleResolverState& state, CSSValue* value)
|
| +{
|
| + if (!value->isPrimitiveValue())
|
| + return;
|
| + CSSPrimitiveValue* primitiveValue = toCSSPrimitiveValue(value);
|
| + switch (primitiveValue->getValueID()) {
|
| + case CSSValueInvalid:
|
| + ASSERT_NOT_REACHED();
|
| + break;
|
| + case CSSValueUltraCondensed:
|
| + state.fontBuilder().setStretch(FontStretchUltraCondensed);
|
| + break;
|
| + case CSSValueExtraCondensed:
|
| + state.fontBuilder().setStretch(FontStretchExtraCondensed);
|
| + break;
|
| + case CSSValueCondensed:
|
| + state.fontBuilder().setStretch(FontStretchCondensed);
|
| + break;
|
| + case CSSValueSemiCondensed:
|
| + state.fontBuilder().setStretch(FontStretchSemiCondensed);
|
| + break;
|
| + case CSSValueNormal:
|
| + state.fontBuilder().setStretch(FontStretchNormal);
|
| + break;
|
| + case CSSValueSemiExpanded:
|
| + state.fontBuilder().setStretch(FontStretchSemiExpanded);
|
| + break;
|
| + case CSSValueExpanded:
|
| + state.fontBuilder().setStretch(FontStretchExpanded);
|
| + break;
|
| + case CSSValueExtraExpanded:
|
| + state.fontBuilder().setStretch(FontStretchExtraExpanded);
|
| + break;
|
| + case CSSValueUltraExpanded:
|
| + state.fontBuilder().setStretch(FontStretchUltraExpanded);
|
| + break;
|
| + default:
|
| + return;
|
| + }
|
| +}
|
| +
|
| void StyleBuilderFunctions::applyValueCSSPropertyLineHeight(StyleResolverState& state, CSSValue* value)
|
| {
|
| if (!value->isPrimitiveValue())
|
| @@ -1510,7 +1562,6 @@ void StyleBuilder::oldApplyProperty(CSSPropertyID id, StyleResolverState& state,
|
| ASSERT(newId != id);
|
| return applyProperty(newId, state, value);
|
| }
|
| - case CSSPropertyFontStretch:
|
| case CSSPropertyPage:
|
| case CSSPropertyTextLineThroughColor:
|
| case CSSPropertyTextLineThroughMode:
|
| @@ -1804,6 +1855,7 @@ void StyleBuilder::oldApplyProperty(CSSPropertyID id, StyleResolverState& state,
|
| case CSSPropertyFloat:
|
| case CSSPropertyFontKerning:
|
| case CSSPropertyFontSize:
|
| + case CSSPropertyFontStretch:
|
| case CSSPropertyFontStyle:
|
| case CSSPropertyFontVariant:
|
| case CSSPropertyFontVariantLigatures:
|
|
|