2
* Copyright (C) 2011 Google Inc. All rights reserved.
4
* Redistribution and use in source and binary forms, with or without
5
* modification, are permitted provided that the following conditions
7
* 1. Redistributions of source code must retain the above copyright
8
* notice, this list of conditions and the following disclaimer.
9
* 2. Redistributions in binary form must reproduce the above copyright
10
* notice, this list of conditions and the following disclaimer in the
11
* documentation and/or other materials provided with the distribution.
13
* THIS SOFTWARE IS PROVIDED BY APPLE INC. AND ITS CONTRIBUTORS ``AS IS'' AND ANY
14
* EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
15
* WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
16
* DISCLAIMED. IN NO EVENT SHALL APPLE INC. OR ITS CONTRIBUTORS BE LIABLE FOR ANY
17
* DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
18
* (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
19
* LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
20
* ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
21
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
22
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
26
#include "StyleBuilder.h"
28
#include "BasicShapeFunctions.h"
29
#include "BasicShapes.h"
30
#include "CSSAspectRatioValue.h"
31
#include "CSSCalculationValue.h"
32
#include "CSSCursorImageValue.h"
33
#include "CSSPrimitiveValueMappings.h"
34
#include "CSSToStyleMap.h"
35
#include "CSSValueList.h"
36
#include "ClipPathOperation.h"
37
#include "CursorList.h"
42
#include "RenderObject.h"
43
#include "RenderStyle.h"
44
#include "RenderView.h"
46
#include "StyleResolver.h"
47
#include <wtf/StdLibExtras.h>
48
#include <wtf/UnusedParam.h>
50
#if ENABLE(CSS_EXCLUSIONS)
51
#include "ExclusionShapeValue.h"
58
enum ExpandValueBehavior {SuppressValue = 0, ExpandValue};
59
template <ExpandValueBehavior expandValue, CSSPropertyID one = CSSPropertyInvalid, CSSPropertyID two = CSSPropertyInvalid, CSSPropertyID three = CSSPropertyInvalid, CSSPropertyID four = CSSPropertyInvalid, CSSPropertyID five = CSSPropertyInvalid>
60
class ApplyPropertyExpanding {
63
template <CSSPropertyID id>
64
static inline void applyInheritValue(CSSPropertyID propertyID, StyleResolver* styleResolver)
66
if (id == CSSPropertyInvalid)
69
const StyleBuilder& table = StyleBuilder::sharedStyleBuilder();
70
const PropertyHandler& handler = table.propertyHandler(id);
71
if (handler.isValid())
72
handler.applyInheritValue(propertyID, styleResolver);
75
static void applyInheritValue(CSSPropertyID propertyID, StyleResolver* styleResolver)
77
applyInheritValue<one>(propertyID, styleResolver);
78
applyInheritValue<two>(propertyID, styleResolver);
79
applyInheritValue<three>(propertyID, styleResolver);
80
applyInheritValue<four>(propertyID, styleResolver);
81
applyInheritValue<five>(propertyID, styleResolver);
84
template <CSSPropertyID id>
85
static inline void applyInitialValue(CSSPropertyID propertyID, StyleResolver* styleResolver)
87
if (id == CSSPropertyInvalid)
90
const StyleBuilder& table = StyleBuilder::sharedStyleBuilder();
91
const PropertyHandler& handler = table.propertyHandler(id);
92
if (handler.isValid())
93
handler.applyInitialValue(propertyID, styleResolver);
96
static void applyInitialValue(CSSPropertyID propertyID, StyleResolver* styleResolver)
98
applyInitialValue<one>(propertyID, styleResolver);
99
applyInitialValue<two>(propertyID, styleResolver);
100
applyInitialValue<three>(propertyID, styleResolver);
101
applyInitialValue<four>(propertyID, styleResolver);
102
applyInitialValue<five>(propertyID, styleResolver);
105
template <CSSPropertyID id>
106
static inline void applyValue(CSSPropertyID propertyID, StyleResolver* styleResolver, CSSValue* value)
108
if (id == CSSPropertyInvalid)
111
const StyleBuilder& table = StyleBuilder::sharedStyleBuilder();
112
const PropertyHandler& handler = table.propertyHandler(id);
113
if (handler.isValid())
114
handler.applyValue(propertyID, styleResolver, value);
117
static void applyValue(CSSPropertyID propertyID, StyleResolver* styleResolver, CSSValue* value)
122
applyValue<one>(propertyID, styleResolver, value);
123
applyValue<two>(propertyID, styleResolver, value);
124
applyValue<three>(propertyID, styleResolver, value);
125
applyValue<four>(propertyID, styleResolver, value);
126
applyValue<five>(propertyID, styleResolver, value);
128
static PropertyHandler createHandler() { return PropertyHandler(&applyInheritValue, &applyInitialValue, &applyValue); }
131
template <typename GetterType, GetterType (RenderStyle::*getterFunction)() const, typename SetterType, void (RenderStyle::*setterFunction)(SetterType), typename InitialType, InitialType (*initialFunction)()>
132
class ApplyPropertyDefaultBase {
134
static void setValue(RenderStyle* style, SetterType value) { (style->*setterFunction)(value); }
135
static GetterType value(RenderStyle* style) { return (style->*getterFunction)(); }
136
static InitialType initial() { return (*initialFunction)(); }
137
static void applyInheritValue(CSSPropertyID, StyleResolver* styleResolver) { setValue(styleResolver->style(), value(styleResolver->parentStyle())); }
138
static void applyInitialValue(CSSPropertyID, StyleResolver* styleResolver) { setValue(styleResolver->style(), initial()); }
139
static void applyValue(CSSPropertyID, StyleResolver*, CSSValue*) { }
140
static PropertyHandler createHandler() { return PropertyHandler(&applyInheritValue, &applyInitialValue, &applyValue); }
143
template <typename GetterType, GetterType (RenderStyle::*getterFunction)() const, typename SetterType, void (RenderStyle::*setterFunction)(SetterType), typename InitialType, InitialType (*initialFunction)()>
144
class ApplyPropertyDefault {
146
static void setValue(RenderStyle* style, SetterType value) { (style->*setterFunction)(value); }
147
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
149
if (value->isPrimitiveValue())
150
setValue(styleResolver->style(), *static_cast<CSSPrimitiveValue*>(value));
152
static PropertyHandler createHandler()
154
PropertyHandler handler = ApplyPropertyDefaultBase<GetterType, getterFunction, SetterType, setterFunction, InitialType, initialFunction>::createHandler();
155
return PropertyHandler(handler.inheritFunction(), handler.initialFunction(), &applyValue);
159
template <typename NumberType, NumberType (RenderStyle::*getterFunction)() const, void (RenderStyle::*setterFunction)(NumberType), NumberType (*initialFunction)(), int idMapsToMinusOne = CSSValueAuto>
160
class ApplyPropertyNumber {
162
static void setValue(RenderStyle* style, NumberType value) { (style->*setterFunction)(value); }
163
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
165
if (!value->isPrimitiveValue())
168
CSSPrimitiveValue* primitiveValue = static_cast<CSSPrimitiveValue*>(value);
169
if (primitiveValue->getIdent() == idMapsToMinusOne)
170
setValue(styleResolver->style(), -1);
172
setValue(styleResolver->style(), primitiveValue->getValue<NumberType>(CSSPrimitiveValue::CSS_NUMBER));
174
static PropertyHandler createHandler()
176
PropertyHandler handler = ApplyPropertyDefaultBase<NumberType, getterFunction, NumberType, setterFunction, NumberType, initialFunction>::createHandler();
177
return PropertyHandler(handler.inheritFunction(), handler.initialFunction(), &applyValue);
181
template <StyleImage* (RenderStyle::*getterFunction)() const, void (RenderStyle::*setterFunction)(PassRefPtr<StyleImage>), StyleImage* (*initialFunction)(), CSSPropertyID property>
182
class ApplyPropertyStyleImage {
184
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value) { (styleResolver->style()->*setterFunction)(styleResolver->styleImage(property, value)); }
185
static PropertyHandler createHandler()
187
PropertyHandler handler = ApplyPropertyDefaultBase<StyleImage*, getterFunction, PassRefPtr<StyleImage>, setterFunction, StyleImage*, initialFunction>::createHandler();
188
return PropertyHandler(handler.inheritFunction(), handler.initialFunction(), &applyValue);
192
enum AutoValueType {Number = 0, ComputeLength};
193
template <typename T, T (RenderStyle::*getterFunction)() const, void (RenderStyle::*setterFunction)(T), bool (RenderStyle::*hasAutoFunction)() const, void (RenderStyle::*setAutoFunction)(), AutoValueType valueType = Number, int autoIdentity = CSSValueAuto>
194
class ApplyPropertyAuto {
196
static void setValue(RenderStyle* style, T value) { (style->*setterFunction)(value); }
197
static T value(RenderStyle* style) { return (style->*getterFunction)(); }
198
static bool hasAuto(RenderStyle* style) { return (style->*hasAutoFunction)(); }
199
static void setAuto(RenderStyle* style) { (style->*setAutoFunction)(); }
201
static void applyInheritValue(CSSPropertyID, StyleResolver* styleResolver)
203
if (hasAuto(styleResolver->parentStyle()))
204
setAuto(styleResolver->style());
206
setValue(styleResolver->style(), value(styleResolver->parentStyle()));
209
static void applyInitialValue(CSSPropertyID, StyleResolver* styleResolver) { setAuto(styleResolver->style()); }
211
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
213
if (!value->isPrimitiveValue())
216
CSSPrimitiveValue* primitiveValue = static_cast<CSSPrimitiveValue*>(value);
217
if (primitiveValue->getIdent() == autoIdentity)
218
setAuto(styleResolver->style());
219
else if (valueType == Number)
220
setValue(styleResolver->style(), *primitiveValue);
221
else if (valueType == ComputeLength)
222
setValue(styleResolver->style(), primitiveValue->computeLength<T>(styleResolver->style(), styleResolver->rootElementStyle(), styleResolver->style()->effectiveZoom()));
225
static PropertyHandler createHandler() { return PropertyHandler(&applyInheritValue, &applyInitialValue, &applyValue); }
228
class ApplyPropertyClip {
230
static Length convertToLength(StyleResolver* styleResolver, CSSPrimitiveValue* value)
232
return value->convertToLength<FixedIntegerConversion | PercentConversion | FractionConversion | AutoConversion>(styleResolver->style(), styleResolver->rootElementStyle(), styleResolver->style()->effectiveZoom());
235
static void applyInheritValue(CSSPropertyID propertyID, StyleResolver* styleResolver)
237
RenderStyle* parentStyle = styleResolver->parentStyle();
238
if (!parentStyle->hasClip())
239
return applyInitialValue(propertyID, styleResolver);
240
styleResolver->style()->setClip(parentStyle->clipTop(), parentStyle->clipRight(), parentStyle->clipBottom(), parentStyle->clipLeft());
241
styleResolver->style()->setHasClip(true);
244
static void applyInitialValue(CSSPropertyID, StyleResolver* styleResolver)
246
styleResolver->style()->setClip(Length(), Length(), Length(), Length());
247
styleResolver->style()->setHasClip(false);
250
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
252
if (!value->isPrimitiveValue())
255
CSSPrimitiveValue* primitiveValue = static_cast<CSSPrimitiveValue*>(value);
257
if (Rect* rect = primitiveValue->getRectValue()) {
258
Length top = convertToLength(styleResolver, rect->top());
259
Length right = convertToLength(styleResolver, rect->right());
260
Length bottom = convertToLength(styleResolver, rect->bottom());
261
Length left = convertToLength(styleResolver, rect->left());
262
styleResolver->style()->setClip(top, right, bottom, left);
263
styleResolver->style()->setHasClip(true);
264
} else if (primitiveValue->getIdent() == CSSValueAuto) {
265
styleResolver->style()->setClip(Length(), Length(), Length(), Length());
266
styleResolver->style()->setHasClip(false);
270
static PropertyHandler createHandler() { return PropertyHandler(&applyInheritValue, &applyInitialValue, &applyValue); }
273
enum ColorInherit {NoInheritFromParent = 0, InheritFromParent};
274
Color defaultInitialColor();
275
Color defaultInitialColor() { return Color(); }
276
template <ColorInherit inheritColorFromParent,
277
Color (RenderStyle::*getterFunction)() const,
278
void (RenderStyle::*setterFunction)(const Color&),
279
void (RenderStyle::*visitedLinkSetterFunction)(const Color&),
280
Color (RenderStyle::*defaultFunction)() const,
281
Color (*initialFunction)() = &defaultInitialColor>
282
class ApplyPropertyColor {
284
static void applyInheritValue(CSSPropertyID, StyleResolver* styleResolver)
286
// Visited link style can never explicitly inherit from parent visited link style so no separate getters are needed.
287
Color color = (styleResolver->parentStyle()->*getterFunction)();
288
applyColorValue(styleResolver, color.isValid() ? color : (styleResolver->parentStyle()->*defaultFunction)());
291
static void applyInitialValue(CSSPropertyID, StyleResolver* styleResolver)
293
applyColorValue(styleResolver, initialFunction());
296
static void applyValue(CSSPropertyID propertyID, StyleResolver* styleResolver, CSSValue* value)
298
if (!value->isPrimitiveValue())
301
CSSPrimitiveValue* primitiveValue = static_cast<CSSPrimitiveValue*>(value);
302
if (inheritColorFromParent && primitiveValue->getIdent() == CSSValueCurrentcolor)
303
applyInheritValue(propertyID, styleResolver);
305
if (styleResolver->applyPropertyToRegularStyle())
306
(styleResolver->style()->*setterFunction)(styleResolver->colorFromPrimitiveValue(primitiveValue));
307
if (styleResolver->applyPropertyToVisitedLinkStyle())
308
(styleResolver->style()->*visitedLinkSetterFunction)(styleResolver->colorFromPrimitiveValue(primitiveValue, /* forVisitedLink */ true));
312
static void applyColorValue(StyleResolver* styleResolver, const Color& color)
314
if (styleResolver->applyPropertyToRegularStyle())
315
(styleResolver->style()->*setterFunction)(color);
316
if (styleResolver->applyPropertyToVisitedLinkStyle())
317
(styleResolver->style()->*visitedLinkSetterFunction)(color);
320
static PropertyHandler createHandler() { return PropertyHandler(&applyInheritValue, &applyInitialValue, &applyValue); }
323
template <TextDirection (RenderStyle::*getterFunction)() const, void (RenderStyle::*setterFunction)(TextDirection), TextDirection (*initialFunction)()>
324
class ApplyPropertyDirection {
326
static void applyValue(CSSPropertyID propertyID, StyleResolver* styleResolver, CSSValue* value)
328
ApplyPropertyDefault<TextDirection, getterFunction, TextDirection, setterFunction, TextDirection, initialFunction>::applyValue(propertyID, styleResolver, value);
329
Element* element = styleResolver->element();
330
if (element && styleResolver->element() == element->document()->documentElement())
331
element->document()->setDirectionSetOnDocumentElement(true);
334
static PropertyHandler createHandler()
336
PropertyHandler handler = ApplyPropertyDefault<TextDirection, getterFunction, TextDirection, setterFunction, TextDirection, initialFunction>::createHandler();
337
return PropertyHandler(handler.inheritFunction(), handler.initialFunction(), &applyValue);
341
enum LengthAuto { AutoDisabled = 0, AutoEnabled };
342
enum LengthLegacyIntrinsic { LegacyIntrinsicDisabled = 0, LegacyIntrinsicEnabled };
343
enum LengthIntrinsic { IntrinsicDisabled = 0, IntrinsicEnabled };
344
enum LengthNone { NoneDisabled = 0, NoneEnabled };
345
enum LengthUndefined { UndefinedDisabled = 0, UndefinedEnabled };
346
template <Length (RenderStyle::*getterFunction)() const,
347
void (RenderStyle::*setterFunction)(Length),
348
Length (*initialFunction)(),
349
LengthAuto autoEnabled = AutoDisabled,
350
LengthLegacyIntrinsic legacyIntrinsicEnabled = LegacyIntrinsicDisabled,
351
LengthIntrinsic intrinsicEnabled = IntrinsicDisabled,
352
LengthNone noneEnabled = NoneDisabled,
353
LengthUndefined noneUndefined = UndefinedDisabled>
354
class ApplyPropertyLength {
356
static void setValue(RenderStyle* style, Length value) { (style->*setterFunction)(value); }
357
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
359
if (!value->isPrimitiveValue())
362
CSSPrimitiveValue* primitiveValue = static_cast<CSSPrimitiveValue*>(value);
363
if (noneEnabled && primitiveValue->getIdent() == CSSValueNone) {
365
setValue(styleResolver->style(), Length(Undefined));
367
setValue(styleResolver->style(), Length());
369
if (legacyIntrinsicEnabled) {
370
if (primitiveValue->getIdent() == CSSValueIntrinsic)
371
setValue(styleResolver->style(), Length(Intrinsic));
372
else if (primitiveValue->getIdent() == CSSValueMinIntrinsic)
373
setValue(styleResolver->style(), Length(MinIntrinsic));
375
if (intrinsicEnabled) {
376
if (primitiveValue->getIdent() == CSSValueWebkitMinContent)
377
setValue(styleResolver->style(), Length(MinContent));
378
else if (primitiveValue->getIdent() == CSSValueWebkitMaxContent)
379
setValue(styleResolver->style(), Length(MaxContent));
380
else if (primitiveValue->getIdent() == CSSValueWebkitFillAvailable)
381
setValue(styleResolver->style(), Length(FillAvailable));
382
else if (primitiveValue->getIdent() == CSSValueWebkitFitContent)
383
setValue(styleResolver->style(), Length(FitContent));
386
if (autoEnabled && primitiveValue->getIdent() == CSSValueAuto)
387
setValue(styleResolver->style(), Length());
388
else if (primitiveValue->isLength()) {
389
Length length = primitiveValue->computeLength<Length>(styleResolver->style(), styleResolver->rootElementStyle(), styleResolver->style()->effectiveZoom());
390
length.setQuirk(primitiveValue->isQuirkValue());
391
setValue(styleResolver->style(), length);
392
} else if (primitiveValue->isPercentage())
393
setValue(styleResolver->style(), Length(primitiveValue->getDoubleValue(), Percent));
394
else if (primitiveValue->isCalculatedPercentageWithLength())
395
setValue(styleResolver->style(), Length(primitiveValue->cssCalcValue()->toCalcValue(styleResolver->style(), styleResolver->rootElementStyle(), styleResolver->style()->effectiveZoom())));
396
else if (primitiveValue->isViewportPercentageLength())
397
setValue(styleResolver->style(), primitiveValue->viewportPercentageLength());
400
static PropertyHandler createHandler()
402
PropertyHandler handler = ApplyPropertyDefaultBase<Length, getterFunction, Length, setterFunction, Length, initialFunction>::createHandler();
403
return PropertyHandler(handler.inheritFunction(), handler.initialFunction(), &applyValue);
407
enum StringIdentBehavior { NothingMapsToNull = 0, MapNoneToNull, MapAutoToNull };
408
template <StringIdentBehavior identBehavior, const AtomicString& (RenderStyle::*getterFunction)() const, void (RenderStyle::*setterFunction)(const AtomicString&), const AtomicString& (*initialFunction)()>
409
class ApplyPropertyString {
411
static void setValue(RenderStyle* style, const AtomicString& value) { (style->*setterFunction)(value); }
412
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
414
if (!value->isPrimitiveValue())
416
CSSPrimitiveValue* primitiveValue = static_cast<CSSPrimitiveValue*>(value);
417
if ((identBehavior == MapNoneToNull && primitiveValue->getIdent() == CSSValueNone)
418
|| (identBehavior == MapAutoToNull && primitiveValue->getIdent() == CSSValueAuto))
419
setValue(styleResolver->style(), nullAtom);
421
setValue(styleResolver->style(), primitiveValue->getStringValue());
423
static PropertyHandler createHandler()
425
PropertyHandler handler = ApplyPropertyDefaultBase<const AtomicString&, getterFunction, const AtomicString&, setterFunction, const AtomicString&, initialFunction>::createHandler();
426
return PropertyHandler(handler.inheritFunction(), handler.initialFunction(), &applyValue);
430
template <LengthSize (RenderStyle::*getterFunction)() const, void (RenderStyle::*setterFunction)(LengthSize), LengthSize (*initialFunction)()>
431
class ApplyPropertyBorderRadius {
433
static void setValue(RenderStyle* style, LengthSize value) { (style->*setterFunction)(value); }
434
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
436
if (!value->isPrimitiveValue())
439
CSSPrimitiveValue* primitiveValue = static_cast<CSSPrimitiveValue*>(value);
440
Pair* pair = primitiveValue->getPairValue();
441
if (!pair || !pair->first() || !pair->second())
446
if (pair->first()->isPercentage())
447
radiusWidth = Length(pair->first()->getDoubleValue(), Percent);
448
else if (pair->first()->isViewportPercentageLength())
449
radiusWidth = pair->first()->viewportPercentageLength();
450
else if (pair->first()->isCalculatedPercentageWithLength()) {
451
// FIXME calc(): http://webkit.org/b/16662
455
radiusWidth = pair->first()->computeLength<Length>(styleResolver->style(), styleResolver->rootElementStyle(), styleResolver->style()->effectiveZoom());
456
if (pair->second()->isPercentage())
457
radiusHeight = Length(pair->second()->getDoubleValue(), Percent);
458
else if (pair->second()->isViewportPercentageLength())
459
radiusHeight = pair->second()->viewportPercentageLength();
460
else if (pair->second()->isCalculatedPercentageWithLength()) {
461
// FIXME calc(): http://webkit.org/b/16662
465
radiusHeight = pair->second()->computeLength<Length>(styleResolver->style(), styleResolver->rootElementStyle(), styleResolver->style()->effectiveZoom());
466
int width = radiusWidth.value();
467
int height = radiusHeight.value();
468
if (width < 0 || height < 0)
471
radiusHeight = radiusWidth; // Null out the other value.
473
radiusWidth = radiusHeight; // Null out the other value.
475
LengthSize size(radiusWidth, radiusHeight);
476
setValue(styleResolver->style(), size);
478
static PropertyHandler createHandler()
480
PropertyHandler handler = ApplyPropertyDefaultBase<LengthSize, getterFunction, LengthSize, setterFunction, LengthSize, initialFunction>::createHandler();
481
return PropertyHandler(handler.inheritFunction(), handler.initialFunction(), &applyValue);
485
template <typename T>
486
struct FillLayerAccessorTypes {
492
struct FillLayerAccessorTypes<StyleImage*> {
493
typedef PassRefPtr<StyleImage> Setter;
494
typedef StyleImage* Getter;
497
template <typename T,
498
CSSPropertyID propertyId,
499
EFillLayerType fillLayerType,
500
FillLayer* (RenderStyle::*accessLayersFunction)(),
501
const FillLayer* (RenderStyle::*layersFunction)() const,
502
bool (FillLayer::*testFunction)() const,
503
typename FillLayerAccessorTypes<T>::Getter (FillLayer::*getFunction)() const,
504
void (FillLayer::*setFunction)(typename FillLayerAccessorTypes<T>::Setter),
505
void (FillLayer::*clearFunction)(),
506
typename FillLayerAccessorTypes<T>::Getter (*initialFunction)(EFillLayerType),
507
void (CSSToStyleMap::*mapFillFunction)(CSSPropertyID, FillLayer*, CSSValue*)>
508
class ApplyPropertyFillLayer {
510
static void applyInheritValue(CSSPropertyID, StyleResolver* styleResolver)
512
FillLayer* currChild = (styleResolver->style()->*accessLayersFunction)();
513
FillLayer* prevChild = 0;
514
const FillLayer* currParent = (styleResolver->parentStyle()->*layersFunction)();
515
while (currParent && (currParent->*testFunction)()) {
517
/* Need to make a new layer.*/
518
currChild = new FillLayer(fillLayerType);
519
prevChild->setNext(currChild);
521
(currChild->*setFunction)((currParent->*getFunction)());
522
prevChild = currChild;
523
currChild = prevChild->next();
524
currParent = currParent->next();
528
/* Reset any remaining layers to not have the property set. */
529
(currChild->*clearFunction)();
530
currChild = currChild->next();
534
static void applyInitialValue(CSSPropertyID, StyleResolver* styleResolver)
536
FillLayer* currChild = (styleResolver->style()->*accessLayersFunction)();
537
(currChild->*setFunction)((*initialFunction)(fillLayerType));
538
for (currChild = currChild->next(); currChild; currChild = currChild->next())
539
(currChild->*clearFunction)();
542
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
544
FillLayer* currChild = (styleResolver->style()->*accessLayersFunction)();
545
FillLayer* prevChild = 0;
546
if (value->isValueList()
547
#if ENABLE(CSS_IMAGE_SET)
548
&& !value->isImageSetValue()
551
/* Walk each value and put it into a layer, creating new layers as needed. */
552
CSSValueList* valueList = static_cast<CSSValueList*>(value);
553
for (unsigned int i = 0; i < valueList->length(); i++) {
555
/* Need to make a new layer to hold this value */
556
currChild = new FillLayer(fillLayerType);
557
prevChild->setNext(currChild);
559
(styleResolver->styleMap()->*mapFillFunction)(propertyId, currChild, valueList->itemWithoutBoundsCheck(i));
560
prevChild = currChild;
561
currChild = currChild->next();
564
(styleResolver->styleMap()->*mapFillFunction)(propertyId, currChild, value);
565
currChild = currChild->next();
568
/* Reset all remaining layers to not have the property set. */
569
(currChild->*clearFunction)();
570
currChild = currChild->next();
574
static PropertyHandler createHandler() { return PropertyHandler(&applyInheritValue, &applyInitialValue, &applyValue); }
577
enum ComputeLengthNormal {NormalDisabled = 0, NormalEnabled};
578
enum ComputeLengthThickness {ThicknessDisabled = 0, ThicknessEnabled};
579
enum ComputeLengthSVGZoom {SVGZoomDisabled = 0, SVGZoomEnabled};
580
template <typename T,
581
T (RenderStyle::*getterFunction)() const,
582
void (RenderStyle::*setterFunction)(T),
583
T (*initialFunction)(),
584
ComputeLengthNormal normalEnabled = NormalDisabled,
585
ComputeLengthThickness thicknessEnabled = ThicknessDisabled,
586
ComputeLengthSVGZoom svgZoomEnabled = SVGZoomDisabled>
587
class ApplyPropertyComputeLength {
589
static void setValue(RenderStyle* style, T value) { (style->*setterFunction)(value); }
590
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
592
// note: CSSPropertyLetter/WordSpacing right now sets to zero if it's not a primitive value for some reason...
593
if (!value->isPrimitiveValue())
596
CSSPrimitiveValue* primitiveValue = static_cast<CSSPrimitiveValue*>(value);
598
int ident = primitiveValue->getIdent();
600
if (normalEnabled && ident == CSSValueNormal) {
602
} else if (thicknessEnabled && ident == CSSValueThin) {
604
} else if (thicknessEnabled && ident == CSSValueMedium) {
606
} else if (thicknessEnabled && ident == CSSValueThick) {
608
} else if (ident == CSSValueInvalid) {
609
float zoom = (svgZoomEnabled && styleResolver->useSVGZoomRules()) ? 1.0f : styleResolver->style()->effectiveZoom();
611
// Any original result that was >= 1 should not be allowed to fall below 1.
612
// This keeps border lines from vanishing.
613
length = primitiveValue->computeLength<T>(styleResolver->style(), styleResolver->rootElementStyle(), 1.0);
614
T zoomedLength = length * zoom;
615
if (zoom < 1.0f && zoomedLength < 1.0 && length >= 1.0)
618
length = zoomedLength;
621
ASSERT_NOT_REACHED();
625
setValue(styleResolver->style(), length);
627
static PropertyHandler createHandler()
629
PropertyHandler handler = ApplyPropertyDefaultBase<T, getterFunction, T, setterFunction, T, initialFunction>::createHandler();
630
return PropertyHandler(handler.inheritFunction(), handler.initialFunction(), &applyValue);
634
template <typename T, T (FontDescription::*getterFunction)() const, void (FontDescription::*setterFunction)(T), T initialValue>
635
class ApplyPropertyFont {
637
static void applyInheritValue(CSSPropertyID, StyleResolver* styleResolver)
639
FontDescription fontDescription = styleResolver->fontDescription();
640
(fontDescription.*setterFunction)((styleResolver->parentFontDescription().*getterFunction)());
641
styleResolver->setFontDescription(fontDescription);
644
static void applyInitialValue(CSSPropertyID, StyleResolver* styleResolver)
646
FontDescription fontDescription = styleResolver->fontDescription();
647
(fontDescription.*setterFunction)(initialValue);
648
styleResolver->setFontDescription(fontDescription);
651
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
653
if (!value->isPrimitiveValue())
655
CSSPrimitiveValue* primitiveValue = static_cast<CSSPrimitiveValue*>(value);
656
FontDescription fontDescription = styleResolver->fontDescription();
657
(fontDescription.*setterFunction)(*primitiveValue);
658
styleResolver->setFontDescription(fontDescription);
661
static PropertyHandler createHandler() { return PropertyHandler(&applyInheritValue, &applyInitialValue, &applyValue); }
664
class ApplyPropertyFontSize {
666
// When the CSS keyword "larger" is used, this function will attempt to match within the keyword
667
// table, and failing that, will simply multiply by 1.2.
668
static float largerFontSize(float size)
670
// FIXME: Figure out where we fall in the size ranges (xx-small to xxx-large) and scale up to
671
// the next size level.
675
// Like the previous function, but for the keyword "smaller".
676
static float smallerFontSize(float size)
678
// FIXME: Figure out where we fall in the size ranges (xx-small to xxx-large) and scale down to
679
// the next size level.
683
static void applyInheritValue(CSSPropertyID, StyleResolver* styleResolver)
685
float size = styleResolver->parentStyle()->fontDescription().specifiedSize();
690
FontDescription fontDescription = styleResolver->style()->fontDescription();
691
fontDescription.setKeywordSize(styleResolver->parentStyle()->fontDescription().keywordSize());
692
styleResolver->setFontSize(fontDescription, size);
693
styleResolver->setFontDescription(fontDescription);
697
static void applyInitialValue(CSSPropertyID, StyleResolver* styleResolver)
699
FontDescription fontDescription = styleResolver->style()->fontDescription();
700
float size = styleResolver->fontSizeForKeyword(styleResolver->document(), CSSValueMedium, fontDescription.useFixedDefaultSize());
705
fontDescription.setKeywordSize(CSSValueMedium - CSSValueXxSmall + 1);
706
styleResolver->setFontSize(fontDescription, size);
707
styleResolver->setFontDescription(fontDescription);
711
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
713
if (!value->isPrimitiveValue())
716
CSSPrimitiveValue* primitiveValue = static_cast<CSSPrimitiveValue*>(value);
718
FontDescription fontDescription = styleResolver->style()->fontDescription();
719
fontDescription.setKeywordSize(0);
720
float parentSize = 0;
721
bool parentIsAbsoluteSize = false;
724
if (styleResolver->parentStyle()) {
725
parentSize = styleResolver->parentStyle()->fontDescription().specifiedSize();
726
parentIsAbsoluteSize = styleResolver->parentStyle()->fontDescription().isAbsoluteSize();
729
if (int ident = primitiveValue->getIdent()) {
730
// Keywords are being used.
732
case CSSValueXxSmall:
738
case CSSValueXxLarge:
739
case CSSValueWebkitXxxLarge:
740
size = styleResolver->fontSizeForKeyword(styleResolver->document(), ident, fontDescription.useFixedDefaultSize());
741
fontDescription.setKeywordSize(ident - CSSValueXxSmall + 1);
744
size = largerFontSize(parentSize);
746
case CSSValueSmaller:
747
size = smallerFontSize(parentSize);
753
fontDescription.setIsAbsoluteSize(parentIsAbsoluteSize && (ident == CSSValueLarger || ident == CSSValueSmaller));
755
fontDescription.setIsAbsoluteSize(parentIsAbsoluteSize
756
|| !(primitiveValue->isPercentage() || primitiveValue->isFontRelativeLength()));
757
if (primitiveValue->isLength())
758
size = primitiveValue->computeLength<float>(styleResolver->parentStyle(), styleResolver->rootElementStyle(), 1.0, true);
759
else if (primitiveValue->isPercentage())
760
size = (primitiveValue->getFloatValue() * parentSize) / 100.0f;
761
else if (primitiveValue->isCalculatedPercentageWithLength())
762
size = primitiveValue->cssCalcValue()->toCalcValue(styleResolver->parentStyle(), styleResolver->rootElementStyle())->evaluate(parentSize);
763
else if (primitiveValue->isViewportPercentageLength())
764
size = valueForLength(primitiveValue->viewportPercentageLength(), 0, styleResolver->document()->renderView());
772
// Overly large font sizes will cause crashes on some platforms (such as Windows).
773
// Cap font size here to make sure that doesn't happen.
774
size = min(1000000.0f, size);
776
styleResolver->setFontSize(fontDescription, size);
777
styleResolver->setFontDescription(fontDescription);
781
static PropertyHandler createHandler() { return PropertyHandler(&applyInheritValue, &applyInitialValue, &applyValue); }
784
class ApplyPropertyFontWeight {
786
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
788
if (!value->isPrimitiveValue())
790
CSSPrimitiveValue* primitiveValue = static_cast<CSSPrimitiveValue*>(value);
791
FontDescription fontDescription = styleResolver->fontDescription();
792
switch (primitiveValue->getIdent()) {
793
case CSSValueInvalid:
794
ASSERT_NOT_REACHED();
797
fontDescription.setWeight(fontDescription.bolderWeight());
799
case CSSValueLighter:
800
fontDescription.setWeight(fontDescription.lighterWeight());
803
fontDescription.setWeight(*primitiveValue);
805
styleResolver->setFontDescription(fontDescription);
807
static PropertyHandler createHandler()
809
PropertyHandler handler = ApplyPropertyFont<FontWeight, &FontDescription::weight, &FontDescription::setWeight, FontWeightNormal>::createHandler();
810
return PropertyHandler(handler.inheritFunction(), handler.initialFunction(), &applyValue);
814
class ApplyPropertyFontVariantLigatures {
816
static void applyInheritValue(CSSPropertyID, StyleResolver* styleResolver)
818
const FontDescription& parentFontDescription = styleResolver->parentFontDescription();
819
FontDescription fontDescription = styleResolver->fontDescription();
821
fontDescription.setCommonLigaturesState(parentFontDescription.commonLigaturesState());
822
fontDescription.setDiscretionaryLigaturesState(parentFontDescription.discretionaryLigaturesState());
823
fontDescription.setHistoricalLigaturesState(parentFontDescription.historicalLigaturesState());
825
styleResolver->setFontDescription(fontDescription);
828
static void applyInitialValue(CSSPropertyID, StyleResolver* styleResolver)
830
FontDescription fontDescription = styleResolver->fontDescription();
832
fontDescription.setCommonLigaturesState(FontDescription::NormalLigaturesState);
833
fontDescription.setDiscretionaryLigaturesState(FontDescription::NormalLigaturesState);
834
fontDescription.setHistoricalLigaturesState(FontDescription::NormalLigaturesState);
836
styleResolver->setFontDescription(fontDescription);
839
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
841
FontDescription::LigaturesState commonLigaturesState = FontDescription::NormalLigaturesState;
842
FontDescription::LigaturesState discretionaryLigaturesState = FontDescription::NormalLigaturesState;
843
FontDescription::LigaturesState historicalLigaturesState = FontDescription::NormalLigaturesState;
845
if (value->isValueList()) {
846
CSSValueList* valueList = static_cast<CSSValueList*>(value);
847
for (size_t i = 0; i < valueList->length(); ++i) {
848
CSSValue* item = valueList->itemWithoutBoundsCheck(i);
849
ASSERT(item->isPrimitiveValue());
850
if (item->isPrimitiveValue()) {
851
CSSPrimitiveValue* primitiveValue = static_cast<CSSPrimitiveValue*>(item);
852
switch (primitiveValue->getIdent()) {
853
case CSSValueNoCommonLigatures:
854
commonLigaturesState = FontDescription::DisabledLigaturesState;
856
case CSSValueCommonLigatures:
857
commonLigaturesState = FontDescription::EnabledLigaturesState;
859
case CSSValueNoDiscretionaryLigatures:
860
discretionaryLigaturesState = FontDescription::DisabledLigaturesState;
862
case CSSValueDiscretionaryLigatures:
863
discretionaryLigaturesState = FontDescription::EnabledLigaturesState;
865
case CSSValueNoHistoricalLigatures:
866
historicalLigaturesState = FontDescription::DisabledLigaturesState;
868
case CSSValueHistoricalLigatures:
869
historicalLigaturesState = FontDescription::EnabledLigaturesState;
872
ASSERT_NOT_REACHED();
880
ASSERT(value->isPrimitiveValue());
881
ASSERT(static_cast<CSSPrimitiveValue*>(value)->getIdent() == CSSValueNormal);
885
FontDescription fontDescription = styleResolver->fontDescription();
886
fontDescription.setCommonLigaturesState(commonLigaturesState);
887
fontDescription.setDiscretionaryLigaturesState(discretionaryLigaturesState);
888
fontDescription.setHistoricalLigaturesState(historicalLigaturesState);
889
styleResolver->setFontDescription(fontDescription);
892
static PropertyHandler createHandler()
894
return PropertyHandler(&applyInheritValue, &applyInitialValue, &applyValue);
898
enum BorderImageType { BorderImage = 0, BorderMask };
899
template <BorderImageType borderImageType,
900
CSSPropertyID property,
901
const NinePieceImage& (RenderStyle::*getterFunction)() const,
902
void (RenderStyle::*setterFunction)(const NinePieceImage&)>
903
class ApplyPropertyBorderImage {
905
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
907
NinePieceImage image;
908
if (borderImageType == BorderMask)
909
image.setMaskDefaults();
910
styleResolver->styleMap()->mapNinePieceImage(property, value, image);
911
(styleResolver->style()->*setterFunction)(image);
914
static PropertyHandler createHandler()
916
PropertyHandler handler = ApplyPropertyDefaultBase<const NinePieceImage&, getterFunction, const NinePieceImage&, setterFunction, NinePieceImage, &RenderStyle::initialNinePieceImage>::createHandler();
917
return PropertyHandler(handler.inheritFunction(), handler.initialFunction(), &applyValue);
921
enum BorderImageModifierType { Outset, Repeat, Slice, Width };
922
template <BorderImageType type, BorderImageModifierType modifier>
923
class ApplyPropertyBorderImageModifier {
925
static inline const NinePieceImage& getValue(RenderStyle* style) { return type == BorderImage ? style->borderImage() : style->maskBoxImage(); }
926
static inline void setValue(RenderStyle* style, const NinePieceImage& value) { return type == BorderImage ? style->setBorderImage(value) : style->setMaskBoxImage(value); }
928
static void applyInheritValue(CSSPropertyID, StyleResolver* styleResolver)
930
NinePieceImage image(getValue(styleResolver->style()));
933
image.copyOutsetFrom(getValue(styleResolver->parentStyle()));
936
image.copyRepeatFrom(getValue(styleResolver->parentStyle()));
939
image.copyImageSlicesFrom(getValue(styleResolver->parentStyle()));
942
image.copyBorderSlicesFrom(getValue(styleResolver->parentStyle()));
945
setValue(styleResolver->style(), image);
948
static void applyInitialValue(CSSPropertyID, StyleResolver* styleResolver)
950
NinePieceImage image(getValue(styleResolver->style()));
953
image.setOutset(LengthBox(0));
956
image.setHorizontalRule(StretchImageRule);
957
image.setVerticalRule(StretchImageRule);
960
// Masks have a different initial value for slices. Preserve the value of 0 for backwards compatibility.
961
image.setImageSlices(type == BorderImage ? LengthBox(Length(100, Percent), Length(100, Percent), Length(100, Percent), Length(100, Percent)) : LengthBox());
962
image.setFill(false);
965
// Masks have a different initial value for widths. They use an 'auto' value rather than trying to fit to the border.
966
image.setBorderSlices(type == BorderImage ? LengthBox(Length(1, Relative), Length(1, Relative), Length(1, Relative), Length(1, Relative)) : LengthBox());
969
setValue(styleResolver->style(), image);
972
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
974
NinePieceImage image(getValue(styleResolver->style()));
977
image.setOutset(styleResolver->styleMap()->mapNinePieceImageQuad(value));
980
styleResolver->styleMap()->mapNinePieceImageRepeat(value, image);
983
styleResolver->styleMap()->mapNinePieceImageSlice(value, image);
986
image.setBorderSlices(styleResolver->styleMap()->mapNinePieceImageQuad(value));
989
setValue(styleResolver->style(), image);
992
static PropertyHandler createHandler() { return PropertyHandler(&applyInheritValue, &applyInitialValue, &applyValue); }
995
template <CSSPropertyID id, StyleImage* (RenderStyle::*getterFunction)() const, void (RenderStyle::*setterFunction)(PassRefPtr<StyleImage>), StyleImage* (*initialFunction)()>
996
class ApplyPropertyBorderImageSource {
998
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value) { (styleResolver->style()->*setterFunction)(styleResolver->styleImage(id, value)); }
999
static PropertyHandler createHandler()
1001
PropertyHandler handler = ApplyPropertyDefaultBase<StyleImage*, getterFunction, PassRefPtr<StyleImage>, setterFunction, StyleImage*, initialFunction>::createHandler();
1002
return PropertyHandler(handler.inheritFunction(), handler.initialFunction(), &applyValue);
1006
enum CounterBehavior {Increment = 0, Reset};
1007
template <CounterBehavior counterBehavior>
1008
class ApplyPropertyCounter {
1010
static void emptyFunction(CSSPropertyID, StyleResolver*) { }
1011
static void applyInheritValue(CSSPropertyID, StyleResolver* styleResolver)
1013
CounterDirectiveMap& map = styleResolver->style()->accessCounterDirectives();
1014
CounterDirectiveMap& parentMap = styleResolver->parentStyle()->accessCounterDirectives();
1016
typedef CounterDirectiveMap::iterator Iterator;
1017
Iterator end = parentMap.end();
1018
for (Iterator it = parentMap.begin(); it != end; ++it) {
1019
CounterDirectives& directives = map.add(it->key, CounterDirectives()).iterator->value;
1020
if (counterBehavior == Reset) {
1021
directives.inheritReset(it->value);
1023
directives.inheritIncrement(it->value);
1027
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
1029
if (!value->isValueList())
1032
CSSValueList* list = static_cast<CSSValueList*>(value);
1034
CounterDirectiveMap& map = styleResolver->style()->accessCounterDirectives();
1035
typedef CounterDirectiveMap::iterator Iterator;
1037
Iterator end = map.end();
1038
for (Iterator it = map.begin(); it != end; ++it)
1039
if (counterBehavior == Reset)
1040
it->value.clearReset();
1042
it->value.clearIncrement();
1044
int length = list ? list->length() : 0;
1045
for (int i = 0; i < length; ++i) {
1046
CSSValue* currValue = list->itemWithoutBoundsCheck(i);
1047
if (!currValue->isPrimitiveValue())
1050
Pair* pair = static_cast<CSSPrimitiveValue*>(currValue)->getPairValue();
1051
if (!pair || !pair->first() || !pair->second())
1054
AtomicString identifier = static_cast<CSSPrimitiveValue*>(pair->first())->getStringValue();
1055
int value = static_cast<CSSPrimitiveValue*>(pair->second())->getIntValue();
1056
CounterDirectives& directives = map.add(identifier, CounterDirectives()).iterator->value;
1057
if (counterBehavior == Reset) {
1058
directives.setResetValue(value);
1060
directives.addIncrementValue(value);
1064
static PropertyHandler createHandler() { return PropertyHandler(&applyInheritValue, &emptyFunction, &applyValue); }
1068
class ApplyPropertyCursor {
1070
static void applyInheritValue(CSSPropertyID, StyleResolver* styleResolver)
1072
styleResolver->style()->setCursor(styleResolver->parentStyle()->cursor());
1073
styleResolver->style()->setCursorList(styleResolver->parentStyle()->cursors());
1076
static void applyInitialValue(CSSPropertyID, StyleResolver* styleResolver)
1078
styleResolver->style()->clearCursorList();
1079
styleResolver->style()->setCursor(RenderStyle::initialCursor());
1082
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
1084
styleResolver->style()->clearCursorList();
1085
if (value->isValueList()) {
1086
CSSValueList* list = static_cast<CSSValueList*>(value);
1087
int len = list->length();
1088
styleResolver->style()->setCursor(CURSOR_AUTO);
1089
for (int i = 0; i < len; i++) {
1090
CSSValue* item = list->itemWithoutBoundsCheck(i);
1091
if (item->isCursorImageValue()) {
1092
CSSCursorImageValue* image = static_cast<CSSCursorImageValue*>(item);
1093
if (image->updateIfSVGCursorIsUsed(styleResolver->element())) // Elements with SVG cursors are not allowed to share style.
1094
styleResolver->style()->setUnique();
1095
styleResolver->style()->addCursor(styleResolver->cachedOrPendingFromValue(CSSPropertyCursor, image), image->hotSpot());
1096
} else if (item->isPrimitiveValue()) {
1097
CSSPrimitiveValue* primitiveValue = static_cast<CSSPrimitiveValue*>(item);
1098
if (primitiveValue->isIdent())
1099
styleResolver->style()->setCursor(*primitiveValue);
1102
} else if (value->isPrimitiveValue()) {
1103
CSSPrimitiveValue* primitiveValue = static_cast<CSSPrimitiveValue*>(value);
1104
if (primitiveValue->isIdent() && styleResolver->style()->cursor() != ECursor(*primitiveValue))
1105
styleResolver->style()->setCursor(*primitiveValue);
1109
static PropertyHandler createHandler() { return PropertyHandler(&applyInheritValue, &applyInitialValue, &applyValue); }
1112
class ApplyPropertyTextAlign {
1114
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
1116
if (!value->isPrimitiveValue())
1119
CSSPrimitiveValue* primitiveValue = static_cast<CSSPrimitiveValue*>(value);
1121
if (primitiveValue->getIdent() != CSSValueWebkitMatchParent)
1122
styleResolver->style()->setTextAlign(*primitiveValue);
1123
else if (styleResolver->parentStyle()->textAlign() == TASTART)
1124
styleResolver->style()->setTextAlign(styleResolver->parentStyle()->isLeftToRightDirection() ? LEFT : RIGHT);
1125
else if (styleResolver->parentStyle()->textAlign() == TAEND)
1126
styleResolver->style()->setTextAlign(styleResolver->parentStyle()->isLeftToRightDirection() ? RIGHT : LEFT);
1128
styleResolver->style()->setTextAlign(styleResolver->parentStyle()->textAlign());
1130
static PropertyHandler createHandler()
1132
PropertyHandler handler = ApplyPropertyDefaultBase<ETextAlign, &RenderStyle::textAlign, ETextAlign, &RenderStyle::setTextAlign, ETextAlign, &RenderStyle::initialTextAlign>::createHandler();
1133
return PropertyHandler(handler.inheritFunction(), handler.initialFunction(), &applyValue);
1137
class ApplyPropertyTextDecoration {
1139
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
1141
ETextDecoration t = RenderStyle::initialTextDecoration();
1142
for (CSSValueListIterator i(value); i.hasMore(); i.advance()) {
1143
CSSValue* item = i.value();
1144
ASSERT(item->isPrimitiveValue());
1145
t |= *static_cast<CSSPrimitiveValue*>(item);
1147
styleResolver->style()->setTextDecoration(t);
1149
static PropertyHandler createHandler()
1151
PropertyHandler handler = ApplyPropertyDefaultBase<ETextDecoration, &RenderStyle::textDecoration, ETextDecoration, &RenderStyle::setTextDecoration, ETextDecoration, &RenderStyle::initialTextDecoration>::createHandler();
1152
return PropertyHandler(handler.inheritFunction(), handler.initialFunction(), &applyValue);
1156
class ApplyPropertyLineHeight {
1158
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
1160
if (!value->isPrimitiveValue())
1163
CSSPrimitiveValue* primitiveValue = static_cast<CSSPrimitiveValue*>(value);
1166
if (primitiveValue->getIdent() == CSSValueNormal)
1167
lineHeight = RenderStyle::initialLineHeight();
1168
else if (primitiveValue->isLength()) {
1169
double multiplier = styleResolver->style()->effectiveZoom();
1170
if (styleResolver->style()->textSizeAdjust()) {
1171
if (Frame* frame = styleResolver->document()->frame())
1172
multiplier *= frame->textZoomFactor();
1174
lineHeight = primitiveValue->computeLength<Length>(styleResolver->style(), styleResolver->rootElementStyle(), multiplier);
1175
} else if (primitiveValue->isPercentage()) {
1176
// FIXME: percentage should not be restricted to an integer here.
1177
lineHeight = Length((styleResolver->style()->fontSize() * primitiveValue->getIntValue()) / 100, Fixed);
1178
} else if (primitiveValue->isNumber()) {
1179
// FIXME: number and percentage values should produce the same type of Length (ie. Fixed or Percent).
1180
lineHeight = Length(primitiveValue->getDoubleValue() * 100.0, Percent);
1181
} else if (primitiveValue->isViewportPercentageLength())
1182
lineHeight = primitiveValue->viewportPercentageLength();
1185
styleResolver->style()->setLineHeight(lineHeight);
1187
static PropertyHandler createHandler()
1189
PropertyHandler handler = ApplyPropertyDefaultBase<Length, &RenderStyle::specifiedLineHeight, Length, &RenderStyle::setLineHeight, Length, &RenderStyle::initialLineHeight>::createHandler();
1190
return PropertyHandler(handler.inheritFunction(), handler.initialFunction(), &applyValue);
1194
class ApplyPropertyPageSize {
1196
static Length mmLength(double mm) { return CSSPrimitiveValue::create(mm, CSSPrimitiveValue::CSS_MM)->computeLength<Length>(0, 0); }
1197
static Length inchLength(double inch) { return CSSPrimitiveValue::create(inch, CSSPrimitiveValue::CSS_IN)->computeLength<Length>(0, 0); }
1198
static bool getPageSizeFromName(CSSPrimitiveValue* pageSizeName, CSSPrimitiveValue* pageOrientation, Length& width, Length& height)
1200
DEFINE_STATIC_LOCAL(Length, a5Width, (mmLength(148)));
1201
DEFINE_STATIC_LOCAL(Length, a5Height, (mmLength(210)));
1202
DEFINE_STATIC_LOCAL(Length, a4Width, (mmLength(210)));
1203
DEFINE_STATIC_LOCAL(Length, a4Height, (mmLength(297)));
1204
DEFINE_STATIC_LOCAL(Length, a3Width, (mmLength(297)));
1205
DEFINE_STATIC_LOCAL(Length, a3Height, (mmLength(420)));
1206
DEFINE_STATIC_LOCAL(Length, b5Width, (mmLength(176)));
1207
DEFINE_STATIC_LOCAL(Length, b5Height, (mmLength(250)));
1208
DEFINE_STATIC_LOCAL(Length, b4Width, (mmLength(250)));
1209
DEFINE_STATIC_LOCAL(Length, b4Height, (mmLength(353)));
1210
DEFINE_STATIC_LOCAL(Length, letterWidth, (inchLength(8.5)));
1211
DEFINE_STATIC_LOCAL(Length, letterHeight, (inchLength(11)));
1212
DEFINE_STATIC_LOCAL(Length, legalWidth, (inchLength(8.5)));
1213
DEFINE_STATIC_LOCAL(Length, legalHeight, (inchLength(14)));
1214
DEFINE_STATIC_LOCAL(Length, ledgerWidth, (inchLength(11)));
1215
DEFINE_STATIC_LOCAL(Length, ledgerHeight, (inchLength(17)));
1220
switch (pageSizeName->getIdent()) {
1241
case CSSValueLetter:
1242
width = letterWidth;
1243
height = letterHeight;
1247
height = legalHeight;
1249
case CSSValueLedger:
1250
width = ledgerWidth;
1251
height = ledgerHeight;
1257
if (pageOrientation) {
1258
switch (pageOrientation->getIdent()) {
1259
case CSSValueLandscape:
1260
std::swap(width, height);
1262
case CSSValuePortrait:
1272
static void applyInheritValue(CSSPropertyID, StyleResolver*) { }
1273
static void applyInitialValue(CSSPropertyID, StyleResolver*) { }
1274
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
1276
styleResolver->style()->resetPageSizeType();
1279
PageSizeType pageSizeType = PAGE_SIZE_AUTO;
1280
CSSValueListInspector inspector(value);
1281
switch (inspector.length()) {
1283
// <length>{2} | <page-size> <orientation>
1284
if (!inspector.first()->isPrimitiveValue() || !inspector.second()->isPrimitiveValue())
1286
CSSPrimitiveValue* first = static_cast<CSSPrimitiveValue*>(inspector.first());
1287
CSSPrimitiveValue* second = static_cast<CSSPrimitiveValue*>(inspector.second());
1288
if (first->isLength()) {
1290
if (!second->isLength())
1292
width = first->computeLength<Length>(styleResolver->style(), styleResolver->rootElementStyle());
1293
height = second->computeLength<Length>(styleResolver->style(), styleResolver->rootElementStyle());
1295
// <page-size> <orientation>
1296
// The value order is guaranteed. See CSSParser::parseSizeParameter.
1297
if (!getPageSizeFromName(first, second, width, height))
1300
pageSizeType = PAGE_SIZE_RESOLVED;
1304
// <length> | auto | <page-size> | [ portrait | landscape]
1305
if (!inspector.first()->isPrimitiveValue())
1307
CSSPrimitiveValue* primitiveValue = static_cast<CSSPrimitiveValue*>(inspector.first());
1308
if (primitiveValue->isLength()) {
1310
pageSizeType = PAGE_SIZE_RESOLVED;
1311
width = height = primitiveValue->computeLength<Length>(styleResolver->style(), styleResolver->rootElementStyle());
1313
switch (primitiveValue->getIdent()) {
1317
pageSizeType = PAGE_SIZE_AUTO;
1319
case CSSValuePortrait:
1320
pageSizeType = PAGE_SIZE_AUTO_PORTRAIT;
1322
case CSSValueLandscape:
1323
pageSizeType = PAGE_SIZE_AUTO_LANDSCAPE;
1327
pageSizeType = PAGE_SIZE_RESOLVED;
1328
if (!getPageSizeFromName(primitiveValue, 0, width, height))
1337
styleResolver->style()->setPageSizeType(pageSizeType);
1338
styleResolver->style()->setPageSize(LengthSize(width, height));
1340
static PropertyHandler createHandler() { return PropertyHandler(&applyInheritValue, &applyInitialValue, &applyValue); }
1343
class ApplyPropertyTextEmphasisStyle {
1345
static void applyInheritValue(CSSPropertyID, StyleResolver* styleResolver)
1347
styleResolver->style()->setTextEmphasisFill(styleResolver->parentStyle()->textEmphasisFill());
1348
styleResolver->style()->setTextEmphasisMark(styleResolver->parentStyle()->textEmphasisMark());
1349
styleResolver->style()->setTextEmphasisCustomMark(styleResolver->parentStyle()->textEmphasisCustomMark());
1352
static void applyInitialValue(CSSPropertyID, StyleResolver* styleResolver)
1354
styleResolver->style()->setTextEmphasisFill(RenderStyle::initialTextEmphasisFill());
1355
styleResolver->style()->setTextEmphasisMark(RenderStyle::initialTextEmphasisMark());
1356
styleResolver->style()->setTextEmphasisCustomMark(RenderStyle::initialTextEmphasisCustomMark());
1359
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
1361
if (value->isValueList()) {
1362
CSSValueList* list = static_cast<CSSValueList*>(value);
1363
ASSERT(list->length() == 2);
1364
if (list->length() != 2)
1366
for (unsigned i = 0; i < 2; ++i) {
1367
CSSValue* item = list->itemWithoutBoundsCheck(i);
1368
if (!item->isPrimitiveValue())
1371
CSSPrimitiveValue* value = static_cast<CSSPrimitiveValue*>(item);
1372
if (value->getIdent() == CSSValueFilled || value->getIdent() == CSSValueOpen)
1373
styleResolver->style()->setTextEmphasisFill(*value);
1375
styleResolver->style()->setTextEmphasisMark(*value);
1377
styleResolver->style()->setTextEmphasisCustomMark(nullAtom);
1381
if (!value->isPrimitiveValue())
1383
CSSPrimitiveValue* primitiveValue = static_cast<CSSPrimitiveValue*>(value);
1385
if (primitiveValue->isString()) {
1386
styleResolver->style()->setTextEmphasisFill(TextEmphasisFillFilled);
1387
styleResolver->style()->setTextEmphasisMark(TextEmphasisMarkCustom);
1388
styleResolver->style()->setTextEmphasisCustomMark(primitiveValue->getStringValue());
1392
styleResolver->style()->setTextEmphasisCustomMark(nullAtom);
1394
if (primitiveValue->getIdent() == CSSValueFilled || primitiveValue->getIdent() == CSSValueOpen) {
1395
styleResolver->style()->setTextEmphasisFill(*primitiveValue);
1396
styleResolver->style()->setTextEmphasisMark(TextEmphasisMarkAuto);
1398
styleResolver->style()->setTextEmphasisFill(TextEmphasisFillFilled);
1399
styleResolver->style()->setTextEmphasisMark(*primitiveValue);
1403
static PropertyHandler createHandler() { return PropertyHandler(&applyInheritValue, &applyInitialValue, &applyValue); }
1406
template <typename T,
1407
T (Animation::*getterFunction)() const,
1408
void (Animation::*setterFunction)(T),
1409
bool (Animation::*testFunction)() const,
1410
void (Animation::*clearFunction)(),
1411
T (*initialFunction)(),
1412
void (CSSToStyleMap::*mapFunction)(Animation*, CSSValue*),
1413
AnimationList* (RenderStyle::*animationGetterFunction)(),
1414
const AnimationList* (RenderStyle::*immutableAnimationGetterFunction)() const>
1415
class ApplyPropertyAnimation {
1417
static void setValue(Animation* animation, T value) { (animation->*setterFunction)(value); }
1418
static T value(const Animation* animation) { return (animation->*getterFunction)(); }
1419
static bool test(const Animation* animation) { return (animation->*testFunction)(); }
1420
static void clear(Animation* animation) { (animation->*clearFunction)(); }
1421
static T initial() { return (*initialFunction)(); }
1422
static void map(StyleResolver* styleResolver, Animation* animation, CSSValue* value) { (styleResolver->styleMap()->*mapFunction)(animation, value); }
1423
static AnimationList* accessAnimations(RenderStyle* style) { return (style->*animationGetterFunction)(); }
1424
static const AnimationList* animations(RenderStyle* style) { return (style->*immutableAnimationGetterFunction)(); }
1426
static void applyInheritValue(CSSPropertyID, StyleResolver* styleResolver)
1428
AnimationList* list = accessAnimations(styleResolver->style());
1429
const AnimationList* parentList = animations(styleResolver->parentStyle());
1430
size_t i = 0, parentSize = parentList ? parentList->size() : 0;
1431
for ( ; i < parentSize && test(parentList->animation(i)); ++i) {
1432
if (list->size() <= i)
1433
list->append(Animation::create());
1434
setValue(list->animation(i), value(parentList->animation(i)));
1435
list->animation(i)->setAnimationMode(parentList->animation(i)->animationMode());
1438
/* Reset any remaining animations to not have the property set. */
1439
for ( ; i < list->size(); ++i)
1440
clear(list->animation(i));
1443
static void applyInitialValue(CSSPropertyID propertyID, StyleResolver* styleResolver)
1445
AnimationList* list = accessAnimations(styleResolver->style());
1446
if (list->isEmpty())
1447
list->append(Animation::create());
1448
setValue(list->animation(0), initial());
1449
if (propertyID == CSSPropertyWebkitTransitionProperty)
1450
list->animation(0)->setAnimationMode(Animation::AnimateAll);
1451
for (size_t i = 1; i < list->size(); ++i)
1452
clear(list->animation(i));
1455
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
1457
AnimationList* list = accessAnimations(styleResolver->style());
1458
size_t childIndex = 0;
1459
if (value->isValueList()) {
1460
/* Walk each value and put it into an animation, creating new animations as needed. */
1461
for (CSSValueListIterator i = value; i.hasMore(); i.advance()) {
1462
if (childIndex <= list->size())
1463
list->append(Animation::create());
1464
map(styleResolver, list->animation(childIndex), i.value());
1468
if (list->isEmpty())
1469
list->append(Animation::create());
1470
map(styleResolver, list->animation(childIndex), value);
1473
for ( ; childIndex < list->size(); ++childIndex) {
1474
/* Reset all remaining animations to not have the property set. */
1475
clear(list->animation(childIndex));
1479
static PropertyHandler createHandler() { return PropertyHandler(&applyInheritValue, &applyInitialValue, &applyValue); }
1482
class ApplyPropertyOutlineStyle {
1484
static void applyInheritValue(CSSPropertyID propertyID, StyleResolver* styleResolver)
1486
ApplyPropertyDefaultBase<OutlineIsAuto, &RenderStyle::outlineStyleIsAuto, OutlineIsAuto, &RenderStyle::setOutlineStyleIsAuto, OutlineIsAuto, &RenderStyle::initialOutlineStyleIsAuto>::applyInheritValue(propertyID, styleResolver);
1487
ApplyPropertyDefaultBase<EBorderStyle, &RenderStyle::outlineStyle, EBorderStyle, &RenderStyle::setOutlineStyle, EBorderStyle, &RenderStyle::initialBorderStyle>::applyInheritValue(propertyID, styleResolver);
1490
static void applyInitialValue(CSSPropertyID propertyID, StyleResolver* styleResolver)
1492
ApplyPropertyDefaultBase<OutlineIsAuto, &RenderStyle::outlineStyleIsAuto, OutlineIsAuto, &RenderStyle::setOutlineStyleIsAuto, OutlineIsAuto, &RenderStyle::initialOutlineStyleIsAuto>::applyInitialValue(propertyID, styleResolver);
1493
ApplyPropertyDefaultBase<EBorderStyle, &RenderStyle::outlineStyle, EBorderStyle, &RenderStyle::setOutlineStyle, EBorderStyle, &RenderStyle::initialBorderStyle>::applyInitialValue(propertyID, styleResolver);
1496
static void applyValue(CSSPropertyID propertyID, StyleResolver* styleResolver, CSSValue* value)
1498
ApplyPropertyDefault<OutlineIsAuto, &RenderStyle::outlineStyleIsAuto, OutlineIsAuto, &RenderStyle::setOutlineStyleIsAuto, OutlineIsAuto, &RenderStyle::initialOutlineStyleIsAuto>::applyValue(propertyID, styleResolver, value);
1499
ApplyPropertyDefault<EBorderStyle, &RenderStyle::outlineStyle, EBorderStyle, &RenderStyle::setOutlineStyle, EBorderStyle, &RenderStyle::initialBorderStyle>::applyValue(propertyID, styleResolver, value);
1502
static PropertyHandler createHandler() { return PropertyHandler(&applyInheritValue, &applyInitialValue, &applyValue); }
1505
class ApplyPropertyResize {
1507
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
1509
if (!value->isPrimitiveValue())
1512
CSSPrimitiveValue* primitiveValue = static_cast<CSSPrimitiveValue*>(value);
1514
EResize r = RESIZE_NONE;
1515
switch (primitiveValue->getIdent()) {
1519
if (Settings* settings = styleResolver->document()->settings())
1520
r = settings->textAreasAreResizable() ? RESIZE_BOTH : RESIZE_NONE;
1523
r = *primitiveValue;
1525
styleResolver->style()->setResize(r);
1528
static PropertyHandler createHandler()
1530
PropertyHandler handler = ApplyPropertyDefaultBase<EResize, &RenderStyle::resize, EResize, &RenderStyle::setResize, EResize, &RenderStyle::initialResize>::createHandler();
1531
return PropertyHandler(handler.inheritFunction(), handler.initialFunction(), &applyValue);
1535
class ApplyPropertyVerticalAlign {
1537
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
1539
if (!value->isPrimitiveValue())
1542
CSSPrimitiveValue* primitiveValue = static_cast<CSSPrimitiveValue*>(value);
1544
if (primitiveValue->getIdent())
1545
return styleResolver->style()->setVerticalAlign(*primitiveValue);
1547
styleResolver->style()->setVerticalAlignLength(primitiveValue->convertToLength<FixedIntegerConversion | PercentConversion | CalculatedConversion | ViewportPercentageConversion>(styleResolver->style(), styleResolver->rootElementStyle(), styleResolver->style()->effectiveZoom()));
1550
static PropertyHandler createHandler()
1552
PropertyHandler handler = ApplyPropertyDefaultBase<EVerticalAlign, &RenderStyle::verticalAlign, EVerticalAlign, &RenderStyle::setVerticalAlign, EVerticalAlign, &RenderStyle::initialVerticalAlign>::createHandler();
1553
return PropertyHandler(handler.inheritFunction(), handler.initialFunction(), &applyValue);
1557
class ApplyPropertyAspectRatio {
1559
static void applyInheritValue(CSSPropertyID, StyleResolver* styleResolver)
1561
if (!styleResolver->parentStyle()->hasAspectRatio())
1563
styleResolver->style()->setHasAspectRatio(true);
1564
styleResolver->style()->setAspectRatioDenominator(styleResolver->parentStyle()->aspectRatioDenominator());
1565
styleResolver->style()->setAspectRatioNumerator(styleResolver->parentStyle()->aspectRatioNumerator());
1568
static void applyInitialValue(CSSPropertyID, StyleResolver* styleResolver)
1570
styleResolver->style()->setHasAspectRatio(RenderStyle::initialHasAspectRatio());
1571
styleResolver->style()->setAspectRatioDenominator(RenderStyle::initialAspectRatioDenominator());
1572
styleResolver->style()->setAspectRatioNumerator(RenderStyle::initialAspectRatioNumerator());
1575
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
1577
if (!value->isAspectRatioValue()) {
1578
styleResolver->style()->setHasAspectRatio(false);
1581
CSSAspectRatioValue* aspectRatioValue = static_cast<CSSAspectRatioValue*>(value);
1582
styleResolver->style()->setHasAspectRatio(true);
1583
styleResolver->style()->setAspectRatioDenominator(aspectRatioValue->denominatorValue());
1584
styleResolver->style()->setAspectRatioNumerator(aspectRatioValue->numeratorValue());
1587
static PropertyHandler createHandler()
1589
return PropertyHandler(&applyInheritValue, &applyInitialValue, &applyValue);
1593
class ApplyPropertyZoom {
1595
static void resetEffectiveZoom(StyleResolver* styleResolver)
1597
// Reset the zoom in effect. This allows the setZoom method to accurately compute a new zoom in effect.
1598
styleResolver->setEffectiveZoom(styleResolver->parentStyle() ? styleResolver->parentStyle()->effectiveZoom() : RenderStyle::initialZoom());
1602
static void applyInheritValue(CSSPropertyID, StyleResolver* styleResolver)
1604
resetEffectiveZoom(styleResolver);
1605
styleResolver->setZoom(styleResolver->parentStyle()->zoom());
1608
static void applyInitialValue(CSSPropertyID, StyleResolver* styleResolver)
1610
resetEffectiveZoom(styleResolver);
1611
styleResolver->setZoom(RenderStyle::initialZoom());
1614
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
1616
ASSERT(value->isPrimitiveValue());
1617
CSSPrimitiveValue* primitiveValue = static_cast<CSSPrimitiveValue*>(value);
1619
if (primitiveValue->getIdent() == CSSValueNormal) {
1620
resetEffectiveZoom(styleResolver);
1621
styleResolver->setZoom(RenderStyle::initialZoom());
1622
} else if (primitiveValue->getIdent() == CSSValueReset) {
1623
styleResolver->setEffectiveZoom(RenderStyle::initialZoom());
1624
styleResolver->setZoom(RenderStyle::initialZoom());
1625
} else if (primitiveValue->getIdent() == CSSValueDocument) {
1626
float docZoom = styleResolver->rootElementStyle() ? styleResolver->rootElementStyle()->zoom() : RenderStyle::initialZoom();
1627
styleResolver->setEffectiveZoom(docZoom);
1628
styleResolver->setZoom(docZoom);
1629
} else if (primitiveValue->isPercentage()) {
1630
resetEffectiveZoom(styleResolver);
1631
if (float percent = primitiveValue->getFloatValue())
1632
styleResolver->setZoom(percent / 100.0f);
1633
} else if (primitiveValue->isNumber()) {
1634
resetEffectiveZoom(styleResolver);
1635
if (float number = primitiveValue->getFloatValue())
1636
styleResolver->setZoom(number);
1640
static PropertyHandler createHandler()
1642
return PropertyHandler(&applyInheritValue, &applyInitialValue, &applyValue);
1646
class ApplyPropertyDisplay {
1648
static inline bool isValidDisplayValue(StyleResolver* styleResolver, EDisplay displayPropertyValue)
1651
if (styleResolver->element() && styleResolver->element()->isSVGElement() && styleResolver->style()->styleType() == NOPSEUDO)
1652
return (displayPropertyValue == INLINE || displayPropertyValue == BLOCK || displayPropertyValue == NONE);
1654
UNUSED_PARAM(styleResolver);
1655
UNUSED_PARAM(displayPropertyValue);
1660
static void applyInheritValue(CSSPropertyID, StyleResolver* styleResolver)
1662
EDisplay display = styleResolver->parentStyle()->display();
1663
if (!isValidDisplayValue(styleResolver, display))
1665
styleResolver->style()->setDisplay(display);
1668
static void applyInitialValue(CSSPropertyID, StyleResolver* styleResolver)
1670
styleResolver->style()->setDisplay(RenderStyle::initialDisplay());
1673
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
1675
if (!value->isPrimitiveValue())
1678
EDisplay display = *static_cast<CSSPrimitiveValue*>(value);
1680
if (!isValidDisplayValue(styleResolver, display))
1683
styleResolver->style()->setDisplay(display);
1686
static PropertyHandler createHandler()
1688
return PropertyHandler(&applyInheritValue, &applyInitialValue, &applyValue);
1692
template <ClipPathOperation* (RenderStyle::*getterFunction)() const, void (RenderStyle::*setterFunction)(PassRefPtr<ClipPathOperation>), ClipPathOperation* (*initialFunction)()>
1693
class ApplyPropertyClipPath {
1695
static void setValue(RenderStyle* style, PassRefPtr<ClipPathOperation> value) { (style->*setterFunction)(value); }
1696
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
1698
if (value->isPrimitiveValue()) {
1699
CSSPrimitiveValue* primitiveValue = static_cast<CSSPrimitiveValue*>(value);
1700
if (primitiveValue->getIdent() == CSSValueNone)
1701
setValue(styleResolver->style(), 0);
1702
else if (primitiveValue->isShape()) {
1703
setValue(styleResolver->style(), ShapeClipPathOperation::create(basicShapeForValue(styleResolver, primitiveValue->getShapeValue())));
1706
else if (primitiveValue->primitiveType() == CSSPrimitiveValue::CSS_URI) {
1707
String cssURLValue = primitiveValue->getStringValue();
1708
KURL url = styleResolver->document()->completeURL(cssURLValue);
1709
// FIXME: It doesn't work with forward or external SVG references (see https://bugs.webkit.org/show_bug.cgi?id=90405)
1710
setValue(styleResolver->style(), ReferenceClipPathOperation::create(cssURLValue, url.fragmentIdentifier()));
1715
static PropertyHandler createHandler()
1717
PropertyHandler handler = ApplyPropertyDefaultBase<ClipPathOperation*, getterFunction, PassRefPtr<ClipPathOperation>, setterFunction, ClipPathOperation*, initialFunction>::createHandler();
1718
return PropertyHandler(handler.inheritFunction(), handler.initialFunction(), &applyValue);
1722
#if ENABLE(CSS_EXCLUSIONS)
1723
template <ExclusionShapeValue* (RenderStyle::*getterFunction)() const, void (RenderStyle::*setterFunction)(PassRefPtr<ExclusionShapeValue>), ExclusionShapeValue* (*initialFunction)()>
1724
class ApplyPropertyExclusionShape {
1726
static void setValue(RenderStyle* style, PassRefPtr<ExclusionShapeValue> value) { (style->*setterFunction)(value); }
1727
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
1729
if (value->isPrimitiveValue()) {
1730
CSSPrimitiveValue* primitiveValue = static_cast<CSSPrimitiveValue*>(value);
1731
if (primitiveValue->getIdent() == CSSValueAuto)
1732
setValue(styleResolver->style(), 0);
1733
// FIXME Bug 102571: Layout for the value 'outside-shape' is not yet implemented
1734
else if (primitiveValue->getIdent() == CSSValueOutsideShape)
1735
setValue(styleResolver->style(), ExclusionShapeValue::createOutsideValue());
1736
else if (primitiveValue->isShape()) {
1737
RefPtr<ExclusionShapeValue> shape = ExclusionShapeValue::createShapeValue(basicShapeForValue(styleResolver, primitiveValue->getShapeValue()));
1738
setValue(styleResolver->style(), shape.release());
1742
static PropertyHandler createHandler()
1744
PropertyHandler handler = ApplyPropertyDefaultBase<ExclusionShapeValue*, getterFunction, PassRefPtr<ExclusionShapeValue>, setterFunction, ExclusionShapeValue*, initialFunction>::createHandler();
1745
return PropertyHandler(handler.inheritFunction(), handler.initialFunction(), &applyValue);
1750
#if ENABLE(CSS_IMAGE_RESOLUTION)
1751
class ApplyPropertyImageResolution {
1753
static void applyInheritValue(CSSPropertyID propertyID, StyleResolver* styleResolver)
1755
ApplyPropertyDefaultBase<ImageResolutionSource, &RenderStyle::imageResolutionSource, ImageResolutionSource, &RenderStyle::setImageResolutionSource, ImageResolutionSource, &RenderStyle::initialImageResolutionSource>::applyInheritValue(propertyID, styleResolver);
1756
ApplyPropertyDefaultBase<ImageResolutionSnap, &RenderStyle::imageResolutionSnap, ImageResolutionSnap, &RenderStyle::setImageResolutionSnap, ImageResolutionSnap, &RenderStyle::initialImageResolutionSnap>::applyInheritValue(propertyID, styleResolver);
1757
ApplyPropertyDefaultBase<float, &RenderStyle::imageResolution, float, &RenderStyle::setImageResolution, float, &RenderStyle::initialImageResolution>::applyInheritValue(propertyID, styleResolver);
1760
static void applyInitialValue(CSSPropertyID propertyID, StyleResolver* styleResolver)
1762
ApplyPropertyDefaultBase<ImageResolutionSource, &RenderStyle::imageResolutionSource, ImageResolutionSource, &RenderStyle::setImageResolutionSource, ImageResolutionSource, &RenderStyle::initialImageResolutionSource>::applyInitialValue(propertyID, styleResolver);
1763
ApplyPropertyDefaultBase<ImageResolutionSnap, &RenderStyle::imageResolutionSnap, ImageResolutionSnap, &RenderStyle::setImageResolutionSnap, ImageResolutionSnap, &RenderStyle::initialImageResolutionSnap>::applyInitialValue(propertyID, styleResolver);
1764
ApplyPropertyDefaultBase<float, &RenderStyle::imageResolution, float, &RenderStyle::setImageResolution, float, &RenderStyle::initialImageResolution>::applyInitialValue(propertyID, styleResolver);
1767
static void applyValue(CSSPropertyID, StyleResolver* styleResolver, CSSValue* value)
1769
if (!value->isValueList())
1771
CSSValueList* valueList = static_cast<CSSValueList*>(value);
1772
ImageResolutionSource source = RenderStyle::initialImageResolutionSource();
1773
ImageResolutionSnap snap = RenderStyle::initialImageResolutionSnap();
1774
double resolution = RenderStyle::initialImageResolution();
1775
for (size_t i = 0; i < valueList->length(); i++) {
1776
CSSValue* item = valueList->itemWithoutBoundsCheck(i);
1777
if (!item->isPrimitiveValue())
1779
CSSPrimitiveValue* primitiveValue = static_cast<CSSPrimitiveValue*>(item);
1780
if (primitiveValue->getIdent() == CSSValueFromImage)
1781
source = ImageResolutionFromImage;
1782
else if (primitiveValue->getIdent() == CSSValueSnap)
1783
snap = ImageResolutionSnapPixels;
1785
resolution = primitiveValue->getDoubleValue(CSSPrimitiveValue::CSS_DPPX);
1787
styleResolver->style()->setImageResolutionSource(source);
1788
styleResolver->style()->setImageResolutionSnap(snap);
1789
styleResolver->style()->setImageResolution(resolution);
1792
static PropertyHandler createHandler()
1794
return PropertyHandler(&applyInheritValue, &applyInitialValue, &applyValue);
1799
const StyleBuilder& StyleBuilder::sharedStyleBuilder()
1801
DEFINE_STATIC_LOCAL(StyleBuilder, styleBuilderInstance, ());
1802
return styleBuilderInstance;
1805
StyleBuilder::StyleBuilder()
1807
for (int i = 0; i < numCSSProperties; ++i)
1808
m_propertyMap[i] = PropertyHandler();
1810
// Please keep CSS property list in alphabetical order.
1811
setPropertyHandler(CSSPropertyBackgroundAttachment, ApplyPropertyFillLayer<EFillAttachment, CSSPropertyBackgroundAttachment, BackgroundFillLayer, &RenderStyle::accessBackgroundLayers, &RenderStyle::backgroundLayers, &FillLayer::isAttachmentSet, &FillLayer::attachment, &FillLayer::setAttachment, &FillLayer::clearAttachment, &FillLayer::initialFillAttachment, &CSSToStyleMap::mapFillAttachment>::createHandler());
1812
setPropertyHandler(CSSPropertyBackgroundClip, ApplyPropertyFillLayer<EFillBox, CSSPropertyBackgroundClip, BackgroundFillLayer, &RenderStyle::accessBackgroundLayers, &RenderStyle::backgroundLayers, &FillLayer::isClipSet, &FillLayer::clip, &FillLayer::setClip, &FillLayer::clearClip, &FillLayer::initialFillClip, &CSSToStyleMap::mapFillClip>::createHandler());
1813
setPropertyHandler(CSSPropertyBackgroundColor, ApplyPropertyColor<NoInheritFromParent, &RenderStyle::backgroundColor, &RenderStyle::setBackgroundColor, &RenderStyle::setVisitedLinkBackgroundColor, &RenderStyle::invalidColor>::createHandler());
1814
setPropertyHandler(CSSPropertyBackgroundImage, ApplyPropertyFillLayer<StyleImage*, CSSPropertyBackgroundImage, BackgroundFillLayer, &RenderStyle::accessBackgroundLayers, &RenderStyle::backgroundLayers, &FillLayer::isImageSet, &FillLayer::image, &FillLayer::setImage, &FillLayer::clearImage, &FillLayer::initialFillImage, &CSSToStyleMap::mapFillImage>::createHandler());
1815
setPropertyHandler(CSSPropertyBackgroundOrigin, ApplyPropertyFillLayer<EFillBox, CSSPropertyBackgroundOrigin, BackgroundFillLayer, &RenderStyle::accessBackgroundLayers, &RenderStyle::backgroundLayers, &FillLayer::isOriginSet, &FillLayer::origin, &FillLayer::setOrigin, &FillLayer::clearOrigin, &FillLayer::initialFillOrigin, &CSSToStyleMap::mapFillOrigin>::createHandler());
1816
setPropertyHandler(CSSPropertyBackgroundPosition, ApplyPropertyExpanding<SuppressValue, CSSPropertyBackgroundPositionX, CSSPropertyBackgroundPositionY>::createHandler());
1817
setPropertyHandler(CSSPropertyBackgroundPositionX, ApplyPropertyFillLayer<Length, CSSPropertyBackgroundPositionX, BackgroundFillLayer, &RenderStyle::accessBackgroundLayers, &RenderStyle::backgroundLayers, &FillLayer::isXPositionSet, &FillLayer::xPosition, &FillLayer::setXPosition, &FillLayer::clearXPosition, &FillLayer::initialFillXPosition, &CSSToStyleMap::mapFillXPosition>::createHandler());
1818
setPropertyHandler(CSSPropertyBackgroundPositionY, ApplyPropertyFillLayer<Length, CSSPropertyBackgroundPositionY, BackgroundFillLayer, &RenderStyle::accessBackgroundLayers, &RenderStyle::backgroundLayers, &FillLayer::isYPositionSet, &FillLayer::yPosition, &FillLayer::setYPosition, &FillLayer::clearYPosition, &FillLayer::initialFillYPosition, &CSSToStyleMap::mapFillYPosition>::createHandler());
1819
setPropertyHandler(CSSPropertyBackgroundRepeat, ApplyPropertyExpanding<SuppressValue, CSSPropertyBackgroundRepeatX, CSSPropertyBackgroundRepeatY>::createHandler());
1820
setPropertyHandler(CSSPropertyBackgroundRepeatX, ApplyPropertyFillLayer<EFillRepeat, CSSPropertyBackgroundRepeatX, BackgroundFillLayer, &RenderStyle::accessBackgroundLayers, &RenderStyle::backgroundLayers, &FillLayer::isRepeatXSet, &FillLayer::repeatX, &FillLayer::setRepeatX, &FillLayer::clearRepeatX, &FillLayer::initialFillRepeatX, &CSSToStyleMap::mapFillRepeatX>::createHandler());
1821
setPropertyHandler(CSSPropertyBackgroundRepeatY, ApplyPropertyFillLayer<EFillRepeat, CSSPropertyBackgroundRepeatY, BackgroundFillLayer, &RenderStyle::accessBackgroundLayers, &RenderStyle::backgroundLayers, &FillLayer::isRepeatYSet, &FillLayer::repeatY, &FillLayer::setRepeatY, &FillLayer::clearRepeatY, &FillLayer::initialFillRepeatY, &CSSToStyleMap::mapFillRepeatY>::createHandler());
1822
setPropertyHandler(CSSPropertyBackgroundSize, ApplyPropertyFillLayer<FillSize, CSSPropertyBackgroundSize, BackgroundFillLayer, &RenderStyle::accessBackgroundLayers, &RenderStyle::backgroundLayers, &FillLayer::isSizeSet, &FillLayer::size, &FillLayer::setSize, &FillLayer::clearSize, &FillLayer::initialFillSize, &CSSToStyleMap::mapFillSize>::createHandler());
1823
setPropertyHandler(CSSPropertyBorder, ApplyPropertyExpanding<SuppressValue, CSSPropertyBorderStyle, CSSPropertyBorderWidth, CSSPropertyBorderColor>::createHandler());
1824
setPropertyHandler(CSSPropertyBorderBottom, ApplyPropertyExpanding<SuppressValue, CSSPropertyBorderBottomColor, CSSPropertyBorderBottomStyle, CSSPropertyBorderBottomWidth>::createHandler());
1825
setPropertyHandler(CSSPropertyBorderBottomColor, ApplyPropertyColor<NoInheritFromParent, &RenderStyle::borderBottomColor, &RenderStyle::setBorderBottomColor, &RenderStyle::setVisitedLinkBorderBottomColor, &RenderStyle::color>::createHandler());
1826
setPropertyHandler(CSSPropertyBorderBottomLeftRadius, ApplyPropertyBorderRadius<&RenderStyle::borderBottomLeftRadius, &RenderStyle::setBorderBottomLeftRadius, &RenderStyle::initialBorderRadius>::createHandler());
1827
setPropertyHandler(CSSPropertyBorderBottomRightRadius, ApplyPropertyBorderRadius<&RenderStyle::borderBottomRightRadius, &RenderStyle::setBorderBottomRightRadius, &RenderStyle::initialBorderRadius>::createHandler());
1828
setPropertyHandler(CSSPropertyBorderBottomStyle, ApplyPropertyDefault<EBorderStyle, &RenderStyle::borderBottomStyle, EBorderStyle, &RenderStyle::setBorderBottomStyle, EBorderStyle, &RenderStyle::initialBorderStyle>::createHandler());
1829
setPropertyHandler(CSSPropertyBorderBottomWidth, ApplyPropertyComputeLength<unsigned, &RenderStyle::borderBottomWidth, &RenderStyle::setBorderBottomWidth, &RenderStyle::initialBorderWidth, NormalDisabled, ThicknessEnabled>::createHandler());
1830
setPropertyHandler(CSSPropertyBorderCollapse, ApplyPropertyDefault<EBorderCollapse, &RenderStyle::borderCollapse, EBorderCollapse, &RenderStyle::setBorderCollapse, EBorderCollapse, &RenderStyle::initialBorderCollapse>::createHandler());
1831
setPropertyHandler(CSSPropertyBorderColor, ApplyPropertyExpanding<SuppressValue, CSSPropertyBorderTopColor, CSSPropertyBorderRightColor, CSSPropertyBorderBottomColor, CSSPropertyBorderLeftColor>::createHandler());
1832
setPropertyHandler(CSSPropertyBorderImage, ApplyPropertyExpanding<SuppressValue, CSSPropertyBorderImageSource, CSSPropertyBorderImageSlice, CSSPropertyBorderImageWidth, CSSPropertyBorderImageOutset, CSSPropertyBorderImageRepeat>::createHandler());
1833
setPropertyHandler(CSSPropertyBorderImageOutset, ApplyPropertyBorderImageModifier<BorderImage, Outset>::createHandler());
1834
setPropertyHandler(CSSPropertyBorderImageRepeat, ApplyPropertyBorderImageModifier<BorderImage, Repeat>::createHandler());
1835
setPropertyHandler(CSSPropertyBorderImageSlice, ApplyPropertyBorderImageModifier<BorderImage, Slice>::createHandler());
1836
setPropertyHandler(CSSPropertyBorderImageSource, ApplyPropertyBorderImageSource<CSSPropertyBorderImageSource, &RenderStyle::borderImageSource, &RenderStyle::setBorderImageSource, &RenderStyle::initialBorderImageSource>::createHandler());
1837
setPropertyHandler(CSSPropertyBorderImageWidth, ApplyPropertyBorderImageModifier<BorderImage, Width>::createHandler());
1838
setPropertyHandler(CSSPropertyBorderLeft, ApplyPropertyExpanding<SuppressValue, CSSPropertyBorderLeftColor, CSSPropertyBorderLeftStyle, CSSPropertyBorderLeftWidth>::createHandler());
1839
setPropertyHandler(CSSPropertyBorderLeftColor, ApplyPropertyColor<NoInheritFromParent, &RenderStyle::borderLeftColor, &RenderStyle::setBorderLeftColor, &RenderStyle::setVisitedLinkBorderLeftColor, &RenderStyle::color>::createHandler());
1840
setPropertyHandler(CSSPropertyBorderLeftStyle, ApplyPropertyDefault<EBorderStyle, &RenderStyle::borderLeftStyle, EBorderStyle, &RenderStyle::setBorderLeftStyle, EBorderStyle, &RenderStyle::initialBorderStyle>::createHandler());
1841
setPropertyHandler(CSSPropertyBorderLeftWidth, ApplyPropertyComputeLength<unsigned, &RenderStyle::borderLeftWidth, &RenderStyle::setBorderLeftWidth, &RenderStyle::initialBorderWidth, NormalDisabled, ThicknessEnabled>::createHandler());
1842
setPropertyHandler(CSSPropertyBorderRadius, ApplyPropertyExpanding<ExpandValue, CSSPropertyBorderTopLeftRadius, CSSPropertyBorderTopRightRadius, CSSPropertyBorderBottomLeftRadius, CSSPropertyBorderBottomRightRadius>::createHandler());
1843
setPropertyHandler(CSSPropertyBorderRight, ApplyPropertyExpanding<SuppressValue, CSSPropertyBorderRightColor, CSSPropertyBorderRightStyle, CSSPropertyBorderRightWidth>::createHandler());
1844
setPropertyHandler(CSSPropertyBorderRightColor, ApplyPropertyColor<NoInheritFromParent, &RenderStyle::borderRightColor, &RenderStyle::setBorderRightColor, &RenderStyle::setVisitedLinkBorderRightColor, &RenderStyle::color>::createHandler());
1845
setPropertyHandler(CSSPropertyBorderRightStyle, ApplyPropertyDefault<EBorderStyle, &RenderStyle::borderRightStyle, EBorderStyle, &RenderStyle::setBorderRightStyle, EBorderStyle, &RenderStyle::initialBorderStyle>::createHandler());
1846
setPropertyHandler(CSSPropertyBorderRightWidth, ApplyPropertyComputeLength<unsigned, &RenderStyle::borderRightWidth, &RenderStyle::setBorderRightWidth, &RenderStyle::initialBorderWidth, NormalDisabled, ThicknessEnabled>::createHandler());
1847
setPropertyHandler(CSSPropertyBorderSpacing, ApplyPropertyExpanding<SuppressValue, CSSPropertyWebkitBorderHorizontalSpacing, CSSPropertyWebkitBorderVerticalSpacing>::createHandler());
1848
setPropertyHandler(CSSPropertyBorderStyle, ApplyPropertyExpanding<SuppressValue, CSSPropertyBorderTopStyle, CSSPropertyBorderRightStyle, CSSPropertyBorderBottomStyle, CSSPropertyBorderLeftStyle>::createHandler());
1849
setPropertyHandler(CSSPropertyBorderTop, ApplyPropertyExpanding<SuppressValue, CSSPropertyBorderTopColor, CSSPropertyBorderTopStyle, CSSPropertyBorderTopWidth>::createHandler());
1850
setPropertyHandler(CSSPropertyBorderTopColor, ApplyPropertyColor<NoInheritFromParent, &RenderStyle::borderTopColor, &RenderStyle::setBorderTopColor, &RenderStyle::setVisitedLinkBorderTopColor, &RenderStyle::color>::createHandler());
1851
setPropertyHandler(CSSPropertyBorderTopLeftRadius, ApplyPropertyBorderRadius<&RenderStyle::borderTopLeftRadius, &RenderStyle::setBorderTopLeftRadius, &RenderStyle::initialBorderRadius>::createHandler());
1852
setPropertyHandler(CSSPropertyBorderTopRightRadius, ApplyPropertyBorderRadius<&RenderStyle::borderTopRightRadius, &RenderStyle::setBorderTopRightRadius, &RenderStyle::initialBorderRadius>::createHandler());
1853
setPropertyHandler(CSSPropertyBorderTopStyle, ApplyPropertyDefault<EBorderStyle, &RenderStyle::borderTopStyle, EBorderStyle, &RenderStyle::setBorderTopStyle, EBorderStyle, &RenderStyle::initialBorderStyle>::createHandler());
1854
setPropertyHandler(CSSPropertyBorderTopWidth, ApplyPropertyComputeLength<unsigned, &RenderStyle::borderTopWidth, &RenderStyle::setBorderTopWidth, &RenderStyle::initialBorderWidth, NormalDisabled, ThicknessEnabled>::createHandler());
1855
setPropertyHandler(CSSPropertyBorderWidth, ApplyPropertyExpanding<SuppressValue, CSSPropertyBorderTopWidth, CSSPropertyBorderRightWidth, CSSPropertyBorderBottomWidth, CSSPropertyBorderLeftWidth>::createHandler());
1856
setPropertyHandler(CSSPropertyBottom, ApplyPropertyLength<&RenderStyle::bottom, &RenderStyle::setBottom, &RenderStyle::initialOffset, AutoEnabled>::createHandler());
1857
setPropertyHandler(CSSPropertyBoxSizing, ApplyPropertyDefault<EBoxSizing, &RenderStyle::boxSizing, EBoxSizing, &RenderStyle::setBoxSizing, EBoxSizing, &RenderStyle::initialBoxSizing>::createHandler());
1858
setPropertyHandler(CSSPropertyCaptionSide, ApplyPropertyDefault<ECaptionSide, &RenderStyle::captionSide, ECaptionSide, &RenderStyle::setCaptionSide, ECaptionSide, &RenderStyle::initialCaptionSide>::createHandler());
1859
setPropertyHandler(CSSPropertyClear, ApplyPropertyDefault<EClear, &RenderStyle::clear, EClear, &RenderStyle::setClear, EClear, &RenderStyle::initialClear>::createHandler());
1860
setPropertyHandler(CSSPropertyClip, ApplyPropertyClip::createHandler());
1861
setPropertyHandler(CSSPropertyColor, ApplyPropertyColor<InheritFromParent, &RenderStyle::color, &RenderStyle::setColor, &RenderStyle::setVisitedLinkColor, &RenderStyle::invalidColor, RenderStyle::initialColor>::createHandler());
1862
setPropertyHandler(CSSPropertyCounterIncrement, ApplyPropertyCounter<Increment>::createHandler());
1863
setPropertyHandler(CSSPropertyCounterReset, ApplyPropertyCounter<Reset>::createHandler());
1864
setPropertyHandler(CSSPropertyCursor, ApplyPropertyCursor::createHandler());
1865
setPropertyHandler(CSSPropertyDirection, ApplyPropertyDirection<&RenderStyle::direction, &RenderStyle::setDirection, RenderStyle::initialDirection>::createHandler());
1866
setPropertyHandler(CSSPropertyDisplay, ApplyPropertyDisplay::createHandler());
1867
setPropertyHandler(CSSPropertyEmptyCells, ApplyPropertyDefault<EEmptyCell, &RenderStyle::emptyCells, EEmptyCell, &RenderStyle::setEmptyCells, EEmptyCell, &RenderStyle::initialEmptyCells>::createHandler());
1868
setPropertyHandler(CSSPropertyFloat, ApplyPropertyDefault<EFloat, &RenderStyle::floating, EFloat, &RenderStyle::setFloating, EFloat, &RenderStyle::initialFloating>::createHandler());
1869
setPropertyHandler(CSSPropertyFontSize, ApplyPropertyFontSize::createHandler());
1870
setPropertyHandler(CSSPropertyFontStyle, ApplyPropertyFont<FontItalic, &FontDescription::italic, &FontDescription::setItalic, FontItalicOff>::createHandler());
1871
setPropertyHandler(CSSPropertyFontVariant, ApplyPropertyFont<FontSmallCaps, &FontDescription::smallCaps, &FontDescription::setSmallCaps, FontSmallCapsOff>::createHandler());
1872
setPropertyHandler(CSSPropertyFontWeight, ApplyPropertyFontWeight::createHandler());
1873
setPropertyHandler(CSSPropertyHeight, ApplyPropertyLength<&RenderStyle::height, &RenderStyle::setHeight, &RenderStyle::initialSize, AutoEnabled, LegacyIntrinsicEnabled, IntrinsicDisabled, NoneDisabled, UndefinedDisabled>::createHandler());
1874
#if ENABLE(CSS_IMAGE_ORIENTATION)
1875
setPropertyHandler(CSSPropertyImageOrientation, ApplyPropertyDefault<ImageOrientationEnum, &RenderStyle::imageOrientation, ImageOrientationEnum, &RenderStyle::setImageOrientation, ImageOrientationEnum, &RenderStyle::initialImageOrientation>::createHandler());
1877
setPropertyHandler(CSSPropertyImageRendering, ApplyPropertyDefault<EImageRendering, &RenderStyle::imageRendering, EImageRendering, &RenderStyle::setImageRendering, EImageRendering, &RenderStyle::initialImageRendering>::createHandler());
1878
#if ENABLE(CSS_IMAGE_RESOLUTION)
1879
setPropertyHandler(CSSPropertyImageResolution, ApplyPropertyImageResolution::createHandler());
1881
setPropertyHandler(CSSPropertyLeft, ApplyPropertyLength<&RenderStyle::left, &RenderStyle::setLeft, &RenderStyle::initialOffset, AutoEnabled>::createHandler());
1882
setPropertyHandler(CSSPropertyLetterSpacing, ApplyPropertyComputeLength<int, &RenderStyle::letterSpacing, &RenderStyle::setLetterSpacing, &RenderStyle::initialLetterWordSpacing, NormalEnabled, ThicknessDisabled, SVGZoomEnabled>::createHandler());
1883
setPropertyHandler(CSSPropertyLineHeight, ApplyPropertyLineHeight::createHandler());
1884
setPropertyHandler(CSSPropertyListStyle, ApplyPropertyExpanding<SuppressValue, CSSPropertyListStyleType, CSSPropertyListStyleImage, CSSPropertyListStylePosition>::createHandler());
1885
setPropertyHandler(CSSPropertyListStyleImage, ApplyPropertyStyleImage<&RenderStyle::listStyleImage, &RenderStyle::setListStyleImage, &RenderStyle::initialListStyleImage, CSSPropertyListStyleImage>::createHandler());
1886
setPropertyHandler(CSSPropertyListStylePosition, ApplyPropertyDefault<EListStylePosition, &RenderStyle::listStylePosition, EListStylePosition, &RenderStyle::setListStylePosition, EListStylePosition, &RenderStyle::initialListStylePosition>::createHandler());
1887
setPropertyHandler(CSSPropertyListStyleType, ApplyPropertyDefault<EListStyleType, &RenderStyle::listStyleType, EListStyleType, &RenderStyle::setListStyleType, EListStyleType, &RenderStyle::initialListStyleType>::createHandler());
1888
setPropertyHandler(CSSPropertyMargin, ApplyPropertyExpanding<SuppressValue, CSSPropertyMarginTop, CSSPropertyMarginRight, CSSPropertyMarginBottom, CSSPropertyMarginLeft>::createHandler());
1889
setPropertyHandler(CSSPropertyMarginBottom, ApplyPropertyLength<&RenderStyle::marginBottom, &RenderStyle::setMarginBottom, &RenderStyle::initialMargin, AutoEnabled>::createHandler());
1890
setPropertyHandler(CSSPropertyMarginLeft, ApplyPropertyLength<&RenderStyle::marginLeft, &RenderStyle::setMarginLeft, &RenderStyle::initialMargin, AutoEnabled>::createHandler());
1891
setPropertyHandler(CSSPropertyMarginRight, ApplyPropertyLength<&RenderStyle::marginRight, &RenderStyle::setMarginRight, &RenderStyle::initialMargin, AutoEnabled>::createHandler());
1892
setPropertyHandler(CSSPropertyMarginTop, ApplyPropertyLength<&RenderStyle::marginTop, &RenderStyle::setMarginTop, &RenderStyle::initialMargin, AutoEnabled>::createHandler());
1893
setPropertyHandler(CSSPropertyMaxHeight, ApplyPropertyLength<&RenderStyle::maxHeight, &RenderStyle::setMaxHeight, &RenderStyle::initialMaxSize, AutoEnabled, LegacyIntrinsicEnabled, IntrinsicDisabled, NoneEnabled, UndefinedEnabled>::createHandler());
1894
setPropertyHandler(CSSPropertyMaxWidth, ApplyPropertyLength<&RenderStyle::maxWidth, &RenderStyle::setMaxWidth, &RenderStyle::initialMaxSize, AutoEnabled, LegacyIntrinsicEnabled, IntrinsicEnabled, NoneEnabled, UndefinedEnabled>::createHandler());
1895
setPropertyHandler(CSSPropertyMinHeight, ApplyPropertyLength<&RenderStyle::minHeight, &RenderStyle::setMinHeight, &RenderStyle::initialMinSize, AutoEnabled, LegacyIntrinsicEnabled, IntrinsicDisabled>::createHandler());
1896
setPropertyHandler(CSSPropertyMinWidth, ApplyPropertyLength<&RenderStyle::minWidth, &RenderStyle::setMinWidth, &RenderStyle::initialMinSize, AutoEnabled, LegacyIntrinsicEnabled, IntrinsicEnabled>::createHandler());
1897
setPropertyHandler(CSSPropertyOpacity, ApplyPropertyDefault<float, &RenderStyle::opacity, float, &RenderStyle::setOpacity, float, &RenderStyle::initialOpacity>::createHandler());
1898
setPropertyHandler(CSSPropertyOrphans, ApplyPropertyDefault<short, &RenderStyle::orphans, short, &RenderStyle::setOrphans, short, &RenderStyle::initialOrphans>::createHandler());
1899
setPropertyHandler(CSSPropertyOutline, ApplyPropertyExpanding<SuppressValue, CSSPropertyOutlineWidth, CSSPropertyOutlineColor, CSSPropertyOutlineStyle>::createHandler());
1900
setPropertyHandler(CSSPropertyOutlineColor, ApplyPropertyColor<NoInheritFromParent, &RenderStyle::outlineColor, &RenderStyle::setOutlineColor, &RenderStyle::setVisitedLinkOutlineColor, &RenderStyle::color>::createHandler());
1901
setPropertyHandler(CSSPropertyOutlineOffset, ApplyPropertyComputeLength<int, &RenderStyle::outlineOffset, &RenderStyle::setOutlineOffset, &RenderStyle::initialOutlineOffset>::createHandler());
1902
setPropertyHandler(CSSPropertyOutlineStyle, ApplyPropertyOutlineStyle::createHandler());
1903
setPropertyHandler(CSSPropertyOutlineWidth, ApplyPropertyComputeLength<unsigned short, &RenderStyle::outlineWidth, &RenderStyle::setOutlineWidth, &RenderStyle::initialOutlineWidth, NormalDisabled, ThicknessEnabled>::createHandler());
1904
setPropertyHandler(CSSPropertyOverflow, ApplyPropertyExpanding<ExpandValue, CSSPropertyOverflowX, CSSPropertyOverflowY>::createHandler());
1905
setPropertyHandler(CSSPropertyOverflowWrap, ApplyPropertyDefault<EOverflowWrap, &RenderStyle::overflowWrap, EOverflowWrap, &RenderStyle::setOverflowWrap, EOverflowWrap, &RenderStyle::initialOverflowWrap>::createHandler());
1906
setPropertyHandler(CSSPropertyOverflowX, ApplyPropertyDefault<EOverflow, &RenderStyle::overflowX, EOverflow, &RenderStyle::setOverflowX, EOverflow, &RenderStyle::initialOverflowX>::createHandler());
1907
setPropertyHandler(CSSPropertyOverflowY, ApplyPropertyDefault<EOverflow, &RenderStyle::overflowY, EOverflow, &RenderStyle::setOverflowY, EOverflow, &RenderStyle::initialOverflowY>::createHandler());
1908
setPropertyHandler(CSSPropertyPadding, ApplyPropertyExpanding<SuppressValue, CSSPropertyPaddingTop, CSSPropertyPaddingRight, CSSPropertyPaddingBottom, CSSPropertyPaddingLeft>::createHandler());
1909
setPropertyHandler(CSSPropertyPaddingBottom, ApplyPropertyLength<&RenderStyle::paddingBottom, &RenderStyle::setPaddingBottom, &RenderStyle::initialPadding>::createHandler());
1910
setPropertyHandler(CSSPropertyPaddingLeft, ApplyPropertyLength<&RenderStyle::paddingLeft, &RenderStyle::setPaddingLeft, &RenderStyle::initialPadding>::createHandler());
1911
setPropertyHandler(CSSPropertyPaddingRight, ApplyPropertyLength<&RenderStyle::paddingRight, &RenderStyle::setPaddingRight, &RenderStyle::initialPadding>::createHandler());
1912
setPropertyHandler(CSSPropertyPaddingTop, ApplyPropertyLength<&RenderStyle::paddingTop, &RenderStyle::setPaddingTop, &RenderStyle::initialPadding>::createHandler());
1913
setPropertyHandler(CSSPropertyPageBreakAfter, ApplyPropertyDefault<EPageBreak, &RenderStyle::pageBreakAfter, EPageBreak, &RenderStyle::setPageBreakAfter, EPageBreak, &RenderStyle::initialPageBreak>::createHandler());
1914
setPropertyHandler(CSSPropertyPageBreakBefore, ApplyPropertyDefault<EPageBreak, &RenderStyle::pageBreakBefore, EPageBreak, &RenderStyle::setPageBreakBefore, EPageBreak, &RenderStyle::initialPageBreak>::createHandler());
1915
setPropertyHandler(CSSPropertyPageBreakInside, ApplyPropertyDefault<EPageBreak, &RenderStyle::pageBreakInside, EPageBreak, &RenderStyle::setPageBreakInside, EPageBreak, &RenderStyle::initialPageBreak>::createHandler());
1916
setPropertyHandler(CSSPropertyPointerEvents, ApplyPropertyDefault<EPointerEvents, &RenderStyle::pointerEvents, EPointerEvents, &RenderStyle::setPointerEvents, EPointerEvents, &RenderStyle::initialPointerEvents>::createHandler());
1917
setPropertyHandler(CSSPropertyPosition, ApplyPropertyDefault<EPosition, &RenderStyle::position, EPosition, &RenderStyle::setPosition, EPosition, &RenderStyle::initialPosition>::createHandler());
1918
setPropertyHandler(CSSPropertyResize, ApplyPropertyResize::createHandler());
1919
setPropertyHandler(CSSPropertyRight, ApplyPropertyLength<&RenderStyle::right, &RenderStyle::setRight, &RenderStyle::initialOffset, AutoEnabled>::createHandler());
1920
setPropertyHandler(CSSPropertySize, ApplyPropertyPageSize::createHandler());
1921
setPropertyHandler(CSSPropertySpeak, ApplyPropertyDefault<ESpeak, &RenderStyle::speak, ESpeak, &RenderStyle::setSpeak, ESpeak, &RenderStyle::initialSpeak>::createHandler());
1922
setPropertyHandler(CSSPropertyTableLayout, ApplyPropertyDefault<ETableLayout, &RenderStyle::tableLayout, ETableLayout, &RenderStyle::setTableLayout, ETableLayout, &RenderStyle::initialTableLayout>::createHandler());
1923
setPropertyHandler(CSSPropertyTabSize, ApplyPropertyDefault<unsigned, &RenderStyle::tabSize, unsigned, &RenderStyle::setTabSize, unsigned, &RenderStyle::initialTabSize>::createHandler());
1924
setPropertyHandler(CSSPropertyTextAlign, ApplyPropertyTextAlign::createHandler());
1925
setPropertyHandler(CSSPropertyTextDecoration, ApplyPropertyTextDecoration::createHandler());
1926
#if ENABLE(CSS3_TEXT)
1927
setPropertyHandler(CSSPropertyWebkitTextDecorationLine, ApplyPropertyTextDecoration::createHandler());
1928
setPropertyHandler(CSSPropertyWebkitTextDecorationStyle, ApplyPropertyDefault<TextDecorationStyle, &RenderStyle::textDecorationStyle, TextDecorationStyle, &RenderStyle::setTextDecorationStyle, TextDecorationStyle, &RenderStyle::initialTextDecorationStyle>::createHandler());
1929
setPropertyHandler(CSSPropertyWebkitTextAlignLast, ApplyPropertyDefault<ETextAlignLast, &RenderStyle::textAlignLast, ETextAlignLast, &RenderStyle::setTextAlignLast, ETextAlignLast, &RenderStyle::initialTextAlignLast>::createHandler());
1931
setPropertyHandler(CSSPropertyTextIndent, ApplyPropertyLength<&RenderStyle::textIndent, &RenderStyle::setTextIndent, &RenderStyle::initialTextIndent>::createHandler());
1932
setPropertyHandler(CSSPropertyTextOverflow, ApplyPropertyDefault<TextOverflow, &RenderStyle::textOverflow, TextOverflow, &RenderStyle::setTextOverflow, TextOverflow, &RenderStyle::initialTextOverflow>::createHandler());
1933
setPropertyHandler(CSSPropertyTextRendering, ApplyPropertyFont<TextRenderingMode, &FontDescription::textRenderingMode, &FontDescription::setTextRenderingMode, AutoTextRendering>::createHandler());
1934
setPropertyHandler(CSSPropertyTextTransform, ApplyPropertyDefault<ETextTransform, &RenderStyle::textTransform, ETextTransform, &RenderStyle::setTextTransform, ETextTransform, &RenderStyle::initialTextTransform>::createHandler());
1935
setPropertyHandler(CSSPropertyTop, ApplyPropertyLength<&RenderStyle::top, &RenderStyle::setTop, &RenderStyle::initialOffset, AutoEnabled>::createHandler());
1936
setPropertyHandler(CSSPropertyUnicodeBidi, ApplyPropertyDefault<EUnicodeBidi, &RenderStyle::unicodeBidi, EUnicodeBidi, &RenderStyle::setUnicodeBidi, EUnicodeBidi, &RenderStyle::initialUnicodeBidi>::createHandler());
1937
setPropertyHandler(CSSPropertyVerticalAlign, ApplyPropertyVerticalAlign::createHandler());
1938
setPropertyHandler(CSSPropertyVisibility, ApplyPropertyDefault<EVisibility, &RenderStyle::visibility, EVisibility, &RenderStyle::setVisibility, EVisibility, &RenderStyle::initialVisibility>::createHandler());
1939
setPropertyHandler(CSSPropertyWebkitAnimationDelay, ApplyPropertyAnimation<double, &Animation::delay, &Animation::setDelay, &Animation::isDelaySet, &Animation::clearDelay, &Animation::initialAnimationDelay, &CSSToStyleMap::mapAnimationDelay, &RenderStyle::accessAnimations, &RenderStyle::animations>::createHandler());
1940
setPropertyHandler(CSSPropertyWebkitAnimationDirection, ApplyPropertyAnimation<Animation::AnimationDirection, &Animation::direction, &Animation::setDirection, &Animation::isDirectionSet, &Animation::clearDirection, &Animation::initialAnimationDirection, &CSSToStyleMap::mapAnimationDirection, &RenderStyle::accessAnimations, &RenderStyle::animations>::createHandler());
1941
setPropertyHandler(CSSPropertyWebkitAnimationDuration, ApplyPropertyAnimation<double, &Animation::duration, &Animation::setDuration, &Animation::isDurationSet, &Animation::clearDuration, &Animation::initialAnimationDuration, &CSSToStyleMap::mapAnimationDuration, &RenderStyle::accessAnimations, &RenderStyle::animations>::createHandler());
1942
setPropertyHandler(CSSPropertyWebkitAnimationFillMode, ApplyPropertyAnimation<unsigned, &Animation::fillMode, &Animation::setFillMode, &Animation::isFillModeSet, &Animation::clearFillMode, &Animation::initialAnimationFillMode, &CSSToStyleMap::mapAnimationFillMode, &RenderStyle::accessAnimations, &RenderStyle::animations>::createHandler());
1943
setPropertyHandler(CSSPropertyWebkitAnimationIterationCount, ApplyPropertyAnimation<double, &Animation::iterationCount, &Animation::setIterationCount, &Animation::isIterationCountSet, &Animation::clearIterationCount, &Animation::initialAnimationIterationCount, &CSSToStyleMap::mapAnimationIterationCount, &RenderStyle::accessAnimations, &RenderStyle::animations>::createHandler());
1944
setPropertyHandler(CSSPropertyWebkitAnimationName, ApplyPropertyAnimation<const String&, &Animation::name, &Animation::setName, &Animation::isNameSet, &Animation::clearName, &Animation::initialAnimationName, &CSSToStyleMap::mapAnimationName, &RenderStyle::accessAnimations, &RenderStyle::animations>::createHandler());
1945
setPropertyHandler(CSSPropertyWebkitAnimationPlayState, ApplyPropertyAnimation<EAnimPlayState, &Animation::playState, &Animation::setPlayState, &Animation::isPlayStateSet, &Animation::clearPlayState, &Animation::initialAnimationPlayState, &CSSToStyleMap::mapAnimationPlayState, &RenderStyle::accessAnimations, &RenderStyle::animations>::createHandler());
1946
setPropertyHandler(CSSPropertyWebkitAnimationTimingFunction, ApplyPropertyAnimation<const PassRefPtr<TimingFunction>, &Animation::timingFunction, &Animation::setTimingFunction, &Animation::isTimingFunctionSet, &Animation::clearTimingFunction, &Animation::initialAnimationTimingFunction, &CSSToStyleMap::mapAnimationTimingFunction, &RenderStyle::accessAnimations, &RenderStyle::animations>::createHandler());
1947
setPropertyHandler(CSSPropertyWebkitAppearance, ApplyPropertyDefault<ControlPart, &RenderStyle::appearance, ControlPart, &RenderStyle::setAppearance, ControlPart, &RenderStyle::initialAppearance>::createHandler());
1948
setPropertyHandler(CSSPropertyWebkitAspectRatio, ApplyPropertyAspectRatio::createHandler());
1949
setPropertyHandler(CSSPropertyWebkitBackfaceVisibility, ApplyPropertyDefault<EBackfaceVisibility, &RenderStyle::backfaceVisibility, EBackfaceVisibility, &RenderStyle::setBackfaceVisibility, EBackfaceVisibility, &RenderStyle::initialBackfaceVisibility>::createHandler());
1950
setPropertyHandler(CSSPropertyWebkitBackgroundClip, CSSPropertyBackgroundClip);
1951
setPropertyHandler(CSSPropertyWebkitBackgroundComposite, ApplyPropertyFillLayer<CompositeOperator, CSSPropertyWebkitBackgroundComposite, BackgroundFillLayer, &RenderStyle::accessBackgroundLayers, &RenderStyle::backgroundLayers, &FillLayer::isCompositeSet, &FillLayer::composite, &FillLayer::setComposite, &FillLayer::clearComposite, &FillLayer::initialFillComposite, &CSSToStyleMap::mapFillComposite>::createHandler());
1952
setPropertyHandler(CSSPropertyWebkitBackgroundOrigin, CSSPropertyBackgroundOrigin);
1953
setPropertyHandler(CSSPropertyWebkitBackgroundSize, CSSPropertyBackgroundSize);
1954
#if ENABLE(CSS_COMPOSITING)
1955
setPropertyHandler(CSSPropertyWebkitBlendMode, ApplyPropertyDefault<BlendMode, &RenderStyle::blendMode, BlendMode, &RenderStyle::setBlendMode, BlendMode, &RenderStyle::initialBlendMode>::createHandler());
1957
setPropertyHandler(CSSPropertyWebkitBorderFit, ApplyPropertyDefault<EBorderFit, &RenderStyle::borderFit, EBorderFit, &RenderStyle::setBorderFit, EBorderFit, &RenderStyle::initialBorderFit>::createHandler());
1958
setPropertyHandler(CSSPropertyWebkitBorderHorizontalSpacing, ApplyPropertyComputeLength<short, &RenderStyle::horizontalBorderSpacing, &RenderStyle::setHorizontalBorderSpacing, &RenderStyle::initialHorizontalBorderSpacing>::createHandler());
1959
setPropertyHandler(CSSPropertyWebkitBorderImage, ApplyPropertyBorderImage<BorderImage, CSSPropertyWebkitBorderImage, &RenderStyle::borderImage, &RenderStyle::setBorderImage>::createHandler());
1960
setPropertyHandler(CSSPropertyWebkitBorderRadius, CSSPropertyBorderRadius);
1961
setPropertyHandler(CSSPropertyWebkitBorderVerticalSpacing, ApplyPropertyComputeLength<short, &RenderStyle::verticalBorderSpacing, &RenderStyle::setVerticalBorderSpacing, &RenderStyle::initialVerticalBorderSpacing>::createHandler());
1962
setPropertyHandler(CSSPropertyWebkitBoxAlign, ApplyPropertyDefault<EBoxAlignment, &RenderStyle::boxAlign, EBoxAlignment, &RenderStyle::setBoxAlign, EBoxAlignment, &RenderStyle::initialBoxAlign>::createHandler());
1963
#if ENABLE(CSS_BOX_DECORATION_BREAK)
1964
setPropertyHandler(CSSPropertyWebkitBoxDecorationBreak, ApplyPropertyDefault<EBoxDecorationBreak, &RenderStyle::boxDecorationBreak, EBoxDecorationBreak, &RenderStyle::setBoxDecorationBreak, EBoxDecorationBreak, &RenderStyle::initialBoxDecorationBreak>::createHandler());
1966
setPropertyHandler(CSSPropertyWebkitBoxDirection, ApplyPropertyDefault<EBoxDirection, &RenderStyle::boxDirection, EBoxDirection, &RenderStyle::setBoxDirection, EBoxDirection, &RenderStyle::initialBoxDirection>::createHandler());
1967
setPropertyHandler(CSSPropertyWebkitBoxFlex, ApplyPropertyDefault<float, &RenderStyle::boxFlex, float, &RenderStyle::setBoxFlex, float, &RenderStyle::initialBoxFlex>::createHandler());
1968
setPropertyHandler(CSSPropertyWebkitBoxFlexGroup, ApplyPropertyDefault<unsigned int, &RenderStyle::boxFlexGroup, unsigned int, &RenderStyle::setBoxFlexGroup, unsigned int, &RenderStyle::initialBoxFlexGroup>::createHandler());
1969
setPropertyHandler(CSSPropertyWebkitBoxLines, ApplyPropertyDefault<EBoxLines, &RenderStyle::boxLines, EBoxLines, &RenderStyle::setBoxLines, EBoxLines, &RenderStyle::initialBoxLines>::createHandler());
1970
setPropertyHandler(CSSPropertyWebkitBoxOrdinalGroup, ApplyPropertyDefault<unsigned int, &RenderStyle::boxOrdinalGroup, unsigned int, &RenderStyle::setBoxOrdinalGroup, unsigned int, &RenderStyle::initialBoxOrdinalGroup>::createHandler());
1971
setPropertyHandler(CSSPropertyWebkitBoxOrient, ApplyPropertyDefault<EBoxOrient, &RenderStyle::boxOrient, EBoxOrient, &RenderStyle::setBoxOrient, EBoxOrient, &RenderStyle::initialBoxOrient>::createHandler());
1972
setPropertyHandler(CSSPropertyWebkitBoxPack, ApplyPropertyDefault<EBoxPack, &RenderStyle::boxPack, EBoxPack, &RenderStyle::setBoxPack, EBoxPack, &RenderStyle::initialBoxPack>::createHandler());
1973
setPropertyHandler(CSSPropertyWebkitColorCorrection, ApplyPropertyDefault<ColorSpace, &RenderStyle::colorSpace, ColorSpace, &RenderStyle::setColorSpace, ColorSpace, &RenderStyle::initialColorSpace>::createHandler());
1974
setPropertyHandler(CSSPropertyWebkitColumnAxis, ApplyPropertyDefault<ColumnAxis, &RenderStyle::columnAxis, ColumnAxis, &RenderStyle::setColumnAxis, ColumnAxis, &RenderStyle::initialColumnAxis>::createHandler());
1975
setPropertyHandler(CSSPropertyWebkitColumnBreakAfter, ApplyPropertyDefault<EPageBreak, &RenderStyle::columnBreakAfter, EPageBreak, &RenderStyle::setColumnBreakAfter, EPageBreak, &RenderStyle::initialPageBreak>::createHandler());
1976
setPropertyHandler(CSSPropertyWebkitColumnBreakBefore, ApplyPropertyDefault<EPageBreak, &RenderStyle::columnBreakBefore, EPageBreak, &RenderStyle::setColumnBreakBefore, EPageBreak, &RenderStyle::initialPageBreak>::createHandler());
1977
setPropertyHandler(CSSPropertyWebkitColumnBreakInside, ApplyPropertyDefault<EPageBreak, &RenderStyle::columnBreakInside, EPageBreak, &RenderStyle::setColumnBreakInside, EPageBreak, &RenderStyle::initialPageBreak>::createHandler());
1978
setPropertyHandler(CSSPropertyWebkitColumnCount, ApplyPropertyAuto<unsigned short, &RenderStyle::columnCount, &RenderStyle::setColumnCount, &RenderStyle::hasAutoColumnCount, &RenderStyle::setHasAutoColumnCount>::createHandler());
1979
setPropertyHandler(CSSPropertyWebkitColumnGap, ApplyPropertyAuto<float, &RenderStyle::columnGap, &RenderStyle::setColumnGap, &RenderStyle::hasNormalColumnGap, &RenderStyle::setHasNormalColumnGap, ComputeLength, CSSValueNormal>::createHandler());
1980
setPropertyHandler(CSSPropertyWebkitColumnProgression, ApplyPropertyDefault<ColumnProgression, &RenderStyle::columnProgression, ColumnProgression, &RenderStyle::setColumnProgression, ColumnProgression, &RenderStyle::initialColumnProgression>::createHandler());
1981
setPropertyHandler(CSSPropertyWebkitColumnRuleColor, ApplyPropertyColor<NoInheritFromParent, &RenderStyle::columnRuleColor, &RenderStyle::setColumnRuleColor, &RenderStyle::setVisitedLinkColumnRuleColor, &RenderStyle::color>::createHandler());
1982
setPropertyHandler(CSSPropertyWebkitColumnRuleWidth, ApplyPropertyComputeLength<unsigned short, &RenderStyle::columnRuleWidth, &RenderStyle::setColumnRuleWidth, &RenderStyle::initialColumnRuleWidth, NormalDisabled, ThicknessEnabled>::createHandler());
1983
setPropertyHandler(CSSPropertyWebkitColumns, ApplyPropertyExpanding<SuppressValue, CSSPropertyWebkitColumnWidth, CSSPropertyWebkitColumnCount>::createHandler());
1984
setPropertyHandler(CSSPropertyWebkitColumnSpan, ApplyPropertyDefault<ColumnSpan, &RenderStyle::columnSpan, ColumnSpan, &RenderStyle::setColumnSpan, ColumnSpan, &RenderStyle::initialColumnSpan>::createHandler());
1985
setPropertyHandler(CSSPropertyWebkitColumnRuleStyle, ApplyPropertyDefault<EBorderStyle, &RenderStyle::columnRuleStyle, EBorderStyle, &RenderStyle::setColumnRuleStyle, EBorderStyle, &RenderStyle::initialBorderStyle>::createHandler());
1986
setPropertyHandler(CSSPropertyWebkitColumnWidth, ApplyPropertyAuto<float, &RenderStyle::columnWidth, &RenderStyle::setColumnWidth, &RenderStyle::hasAutoColumnWidth, &RenderStyle::setHasAutoColumnWidth, ComputeLength>::createHandler());
1987
setPropertyHandler(CSSPropertyWebkitAlignContent, ApplyPropertyDefault<EAlignContent, &RenderStyle::alignContent, EAlignContent, &RenderStyle::setAlignContent, EAlignContent, &RenderStyle::initialAlignContent>::createHandler());
1988
setPropertyHandler(CSSPropertyWebkitAlignItems, ApplyPropertyDefault<EAlignItems, &RenderStyle::alignItems, EAlignItems, &RenderStyle::setAlignItems, EAlignItems, &RenderStyle::initialAlignItems>::createHandler());
1989
setPropertyHandler(CSSPropertyWebkitAlignSelf, ApplyPropertyDefault<EAlignItems, &RenderStyle::alignSelf, EAlignItems, &RenderStyle::setAlignSelf, EAlignItems, &RenderStyle::initialAlignSelf>::createHandler());
1990
setPropertyHandler(CSSPropertyWebkitFlex, ApplyPropertyExpanding<SuppressValue, CSSPropertyWebkitFlexGrow, CSSPropertyWebkitFlexShrink, CSSPropertyWebkitFlexBasis>::createHandler());
1991
setPropertyHandler(CSSPropertyWebkitFlexBasis, ApplyPropertyLength<&RenderStyle::flexBasis, &RenderStyle::setFlexBasis, &RenderStyle::initialFlexBasis, AutoEnabled>::createHandler());
1992
setPropertyHandler(CSSPropertyWebkitFlexDirection, ApplyPropertyDefault<EFlexDirection, &RenderStyle::flexDirection, EFlexDirection, &RenderStyle::setFlexDirection, EFlexDirection, &RenderStyle::initialFlexDirection>::createHandler());
1993
setPropertyHandler(CSSPropertyWebkitFlexFlow, ApplyPropertyExpanding<SuppressValue, CSSPropertyWebkitFlexDirection, CSSPropertyWebkitFlexWrap>::createHandler());
1994
setPropertyHandler(CSSPropertyWebkitFlexGrow, ApplyPropertyDefault<float, &RenderStyle::flexGrow, float, &RenderStyle::setFlexGrow, float, &RenderStyle::initialFlexGrow>::createHandler());
1995
setPropertyHandler(CSSPropertyWebkitFlexShrink, ApplyPropertyDefault<float, &RenderStyle::flexShrink, float, &RenderStyle::setFlexShrink, float, &RenderStyle::initialFlexShrink>::createHandler());
1996
setPropertyHandler(CSSPropertyWebkitFlexWrap, ApplyPropertyDefault<EFlexWrap, &RenderStyle::flexWrap, EFlexWrap, &RenderStyle::setFlexWrap, EFlexWrap, &RenderStyle::initialFlexWrap>::createHandler());
1997
setPropertyHandler(CSSPropertyWebkitJustifyContent, ApplyPropertyDefault<EJustifyContent, &RenderStyle::justifyContent, EJustifyContent, &RenderStyle::setJustifyContent, EJustifyContent, &RenderStyle::initialJustifyContent>::createHandler());
1998
setPropertyHandler(CSSPropertyWebkitOrder, ApplyPropertyDefault<int, &RenderStyle::order, int, &RenderStyle::setOrder, int, &RenderStyle::initialOrder>::createHandler());
1999
#if ENABLE(CSS_REGIONS)
2000
setPropertyHandler(CSSPropertyWebkitFlowFrom, ApplyPropertyString<MapNoneToNull, &RenderStyle::regionThread, &RenderStyle::setRegionThread, &RenderStyle::initialRegionThread>::createHandler());
2001
setPropertyHandler(CSSPropertyWebkitFlowInto, ApplyPropertyString<MapNoneToNull, &RenderStyle::flowThread, &RenderStyle::setFlowThread, &RenderStyle::initialFlowThread>::createHandler());
2003
setPropertyHandler(CSSPropertyWebkitFontKerning, ApplyPropertyFont<FontDescription::Kerning, &FontDescription::kerning, &FontDescription::setKerning, FontDescription::AutoKerning>::createHandler());
2004
setPropertyHandler(CSSPropertyWebkitFontSmoothing, ApplyPropertyFont<FontSmoothingMode, &FontDescription::fontSmoothing, &FontDescription::setFontSmoothing, AutoSmoothing>::createHandler());
2005
setPropertyHandler(CSSPropertyWebkitFontVariantLigatures, ApplyPropertyFontVariantLigatures::createHandler());
2006
setPropertyHandler(CSSPropertyWebkitHighlight, ApplyPropertyString<MapNoneToNull, &RenderStyle::highlight, &RenderStyle::setHighlight, &RenderStyle::initialHighlight>::createHandler());
2007
setPropertyHandler(CSSPropertyWebkitHyphenateCharacter, ApplyPropertyString<MapAutoToNull, &RenderStyle::hyphenationString, &RenderStyle::setHyphenationString, &RenderStyle::initialHyphenationString>::createHandler());
2008
setPropertyHandler(CSSPropertyWebkitHyphenateLimitAfter, ApplyPropertyNumber<short, &RenderStyle::hyphenationLimitAfter, &RenderStyle::setHyphenationLimitAfter, &RenderStyle::initialHyphenationLimitAfter>::createHandler());
2009
setPropertyHandler(CSSPropertyWebkitHyphenateLimitBefore, ApplyPropertyNumber<short, &RenderStyle::hyphenationLimitBefore, &RenderStyle::setHyphenationLimitBefore, &RenderStyle::initialHyphenationLimitBefore>::createHandler());
2010
setPropertyHandler(CSSPropertyWebkitHyphenateLimitLines, ApplyPropertyNumber<short, &RenderStyle::hyphenationLimitLines, &RenderStyle::setHyphenationLimitLines, &RenderStyle::initialHyphenationLimitLines, CSSValueNoLimit>::createHandler());
2011
setPropertyHandler(CSSPropertyWebkitHyphens, ApplyPropertyDefault<Hyphens, &RenderStyle::hyphens, Hyphens, &RenderStyle::setHyphens, Hyphens, &RenderStyle::initialHyphens>::createHandler());
2012
setPropertyHandler(CSSPropertyWebkitLineAlign, ApplyPropertyDefault<LineAlign, &RenderStyle::lineAlign, LineAlign, &RenderStyle::setLineAlign, LineAlign, &RenderStyle::initialLineAlign>::createHandler());
2013
setPropertyHandler(CSSPropertyWebkitLineBreak, ApplyPropertyDefault<LineBreak, &RenderStyle::lineBreak, LineBreak, &RenderStyle::setLineBreak, LineBreak, &RenderStyle::initialLineBreak>::createHandler());
2014
setPropertyHandler(CSSPropertyWebkitLineClamp, ApplyPropertyDefault<const LineClampValue&, &RenderStyle::lineClamp, LineClampValue, &RenderStyle::setLineClamp, LineClampValue, &RenderStyle::initialLineClamp>::createHandler());
2015
setPropertyHandler(CSSPropertyWebkitLineGrid, ApplyPropertyString<MapNoneToNull, &RenderStyle::lineGrid, &RenderStyle::setLineGrid, &RenderStyle::initialLineGrid>::createHandler());
2016
setPropertyHandler(CSSPropertyWebkitLineSnap, ApplyPropertyDefault<LineSnap, &RenderStyle::lineSnap, LineSnap, &RenderStyle::setLineSnap, LineSnap, &RenderStyle::initialLineSnap>::createHandler());
2017
setPropertyHandler(CSSPropertyWebkitMarginAfterCollapse, ApplyPropertyDefault<EMarginCollapse, &RenderStyle::marginAfterCollapse, EMarginCollapse, &RenderStyle::setMarginAfterCollapse, EMarginCollapse, &RenderStyle::initialMarginAfterCollapse>::createHandler());
2018
setPropertyHandler(CSSPropertyWebkitMarginBeforeCollapse, ApplyPropertyDefault<EMarginCollapse, &RenderStyle::marginBeforeCollapse, EMarginCollapse, &RenderStyle::setMarginBeforeCollapse, EMarginCollapse, &RenderStyle::initialMarginBeforeCollapse>::createHandler());
2019
setPropertyHandler(CSSPropertyWebkitMarginBottomCollapse, CSSPropertyWebkitMarginAfterCollapse);
2020
setPropertyHandler(CSSPropertyWebkitMarginCollapse, ApplyPropertyExpanding<SuppressValue, CSSPropertyWebkitMarginBeforeCollapse, CSSPropertyWebkitMarginAfterCollapse>::createHandler());
2021
setPropertyHandler(CSSPropertyWebkitMarginTopCollapse, CSSPropertyWebkitMarginBeforeCollapse);
2022
setPropertyHandler(CSSPropertyWebkitMarqueeDirection, ApplyPropertyDefault<EMarqueeDirection, &RenderStyle::marqueeDirection, EMarqueeDirection, &RenderStyle::setMarqueeDirection, EMarqueeDirection, &RenderStyle::initialMarqueeDirection>::createHandler());
2023
setPropertyHandler(CSSPropertyWebkitMarqueeStyle, ApplyPropertyDefault<EMarqueeBehavior, &RenderStyle::marqueeBehavior, EMarqueeBehavior, &RenderStyle::setMarqueeBehavior, EMarqueeBehavior, &RenderStyle::initialMarqueeBehavior>::createHandler());
2024
setPropertyHandler(CSSPropertyWebkitMaskBoxImage, ApplyPropertyBorderImage<BorderMask, CSSPropertyWebkitMaskBoxImage, &RenderStyle::maskBoxImage, &RenderStyle::setMaskBoxImage>::createHandler());
2025
setPropertyHandler(CSSPropertyWebkitMaskBoxImageOutset, ApplyPropertyBorderImageModifier<BorderMask, Outset>::createHandler());
2026
setPropertyHandler(CSSPropertyWebkitMaskBoxImageRepeat, ApplyPropertyBorderImageModifier<BorderMask, Repeat>::createHandler());
2027
setPropertyHandler(CSSPropertyWebkitMaskBoxImageSlice, ApplyPropertyBorderImageModifier<BorderMask, Slice>::createHandler());
2028
setPropertyHandler(CSSPropertyWebkitMaskBoxImageSource, ApplyPropertyBorderImageSource<CSSPropertyWebkitMaskBoxImageSource, &RenderStyle::maskBoxImageSource, &RenderStyle::setMaskBoxImageSource, &RenderStyle::initialMaskBoxImageSource>::createHandler());
2029
setPropertyHandler(CSSPropertyWebkitMaskBoxImageWidth, ApplyPropertyBorderImageModifier<BorderMask, Width>::createHandler());
2030
setPropertyHandler(CSSPropertyWebkitMaskClip, ApplyPropertyFillLayer<EFillBox, CSSPropertyWebkitMaskClip, MaskFillLayer, &RenderStyle::accessMaskLayers, &RenderStyle::maskLayers, &FillLayer::isClipSet, &FillLayer::clip, &FillLayer::setClip, &FillLayer::clearClip, &FillLayer::initialFillClip, &CSSToStyleMap::mapFillClip>::createHandler());
2031
setPropertyHandler(CSSPropertyWebkitMaskComposite, ApplyPropertyFillLayer<CompositeOperator, CSSPropertyWebkitMaskComposite, MaskFillLayer, &RenderStyle::accessMaskLayers, &RenderStyle::maskLayers, &FillLayer::isCompositeSet, &FillLayer::composite, &FillLayer::setComposite, &FillLayer::clearComposite, &FillLayer::initialFillComposite, &CSSToStyleMap::mapFillComposite>::createHandler());
2032
setPropertyHandler(CSSPropertyWebkitMaskImage, ApplyPropertyFillLayer<StyleImage*, CSSPropertyWebkitMaskImage, MaskFillLayer, &RenderStyle::accessMaskLayers, &RenderStyle::maskLayers, &FillLayer::isImageSet, &FillLayer::image, &FillLayer::setImage, &FillLayer::clearImage, &FillLayer::initialFillImage, &CSSToStyleMap::mapFillImage>::createHandler());
2033
setPropertyHandler(CSSPropertyWebkitMaskOrigin, ApplyPropertyFillLayer<EFillBox, CSSPropertyWebkitMaskOrigin, MaskFillLayer, &RenderStyle::accessMaskLayers, &RenderStyle::maskLayers, &FillLayer::isOriginSet, &FillLayer::origin, &FillLayer::setOrigin, &FillLayer::clearOrigin, &FillLayer::initialFillOrigin, &CSSToStyleMap::mapFillOrigin>::createHandler());
2034
setPropertyHandler(CSSPropertyWebkitMaskPosition, ApplyPropertyExpanding<SuppressValue, CSSPropertyWebkitMaskPositionX, CSSPropertyWebkitMaskPositionY>::createHandler());
2035
setPropertyHandler(CSSPropertyWebkitMaskPositionX, ApplyPropertyFillLayer<Length, CSSPropertyWebkitMaskPositionX, MaskFillLayer, &RenderStyle::accessMaskLayers, &RenderStyle::maskLayers, &FillLayer::isXPositionSet, &FillLayer::xPosition, &FillLayer::setXPosition, &FillLayer::clearXPosition, &FillLayer::initialFillXPosition, &CSSToStyleMap::mapFillXPosition>::createHandler());
2036
setPropertyHandler(CSSPropertyWebkitMaskPositionY, ApplyPropertyFillLayer<Length, CSSPropertyWebkitMaskPositionY, MaskFillLayer, &RenderStyle::accessMaskLayers, &RenderStyle::maskLayers, &FillLayer::isYPositionSet, &FillLayer::yPosition, &FillLayer::setYPosition, &FillLayer::clearYPosition, &FillLayer::initialFillYPosition, &CSSToStyleMap::mapFillYPosition>::createHandler());
2037
setPropertyHandler(CSSPropertyWebkitMaskRepeat, ApplyPropertyExpanding<SuppressValue, CSSPropertyBackgroundRepeatX, CSSPropertyBackgroundRepeatY>::createHandler());
2038
setPropertyHandler(CSSPropertyWebkitMaskRepeatX, ApplyPropertyFillLayer<EFillRepeat, CSSPropertyWebkitMaskRepeatX, MaskFillLayer, &RenderStyle::accessMaskLayers, &RenderStyle::maskLayers, &FillLayer::isRepeatXSet, &FillLayer::repeatX, &FillLayer::setRepeatX, &FillLayer::clearRepeatX, &FillLayer::initialFillRepeatX, &CSSToStyleMap::mapFillRepeatX>::createHandler());
2039
setPropertyHandler(CSSPropertyWebkitMaskRepeatY, ApplyPropertyFillLayer<EFillRepeat, CSSPropertyWebkitMaskRepeatY, MaskFillLayer, &RenderStyle::accessMaskLayers, &RenderStyle::maskLayers, &FillLayer::isRepeatYSet, &FillLayer::repeatY, &FillLayer::setRepeatY, &FillLayer::clearRepeatY, &FillLayer::initialFillRepeatY, &CSSToStyleMap::mapFillRepeatY>::createHandler());
2040
setPropertyHandler(CSSPropertyWebkitMaskSize, ApplyPropertyFillLayer<FillSize, CSSPropertyWebkitMaskSize, MaskFillLayer, &RenderStyle::accessMaskLayers, &RenderStyle::maskLayers, &FillLayer::isSizeSet, &FillLayer::size, &FillLayer::setSize, &FillLayer::clearSize, &FillLayer::initialFillSize, &CSSToStyleMap::mapFillSize>::createHandler());
2041
setPropertyHandler(CSSPropertyWebkitNbspMode, ApplyPropertyDefault<ENBSPMode, &RenderStyle::nbspMode, ENBSPMode, &RenderStyle::setNBSPMode, ENBSPMode, &RenderStyle::initialNBSPMode>::createHandler());
2042
setPropertyHandler(CSSPropertyWebkitPerspectiveOrigin, ApplyPropertyExpanding<SuppressValue, CSSPropertyWebkitPerspectiveOriginX, CSSPropertyWebkitPerspectiveOriginY>::createHandler());
2043
setPropertyHandler(CSSPropertyWebkitPerspectiveOriginX, ApplyPropertyLength<&RenderStyle::perspectiveOriginX, &RenderStyle::setPerspectiveOriginX, &RenderStyle::initialPerspectiveOriginX>::createHandler());
2044
setPropertyHandler(CSSPropertyWebkitPerspectiveOriginY, ApplyPropertyLength<&RenderStyle::perspectiveOriginY, &RenderStyle::setPerspectiveOriginY, &RenderStyle::initialPerspectiveOriginY>::createHandler());
2045
setPropertyHandler(CSSPropertyWebkitPrintColorAdjust, ApplyPropertyDefault<PrintColorAdjust, &RenderStyle::printColorAdjust, PrintColorAdjust, &RenderStyle::setPrintColorAdjust, PrintColorAdjust, &RenderStyle::initialPrintColorAdjust>::createHandler());
2046
#if ENABLE(CSS_REGIONS)
2047
setPropertyHandler(CSSPropertyWebkitRegionBreakAfter, ApplyPropertyDefault<EPageBreak, &RenderStyle::regionBreakAfter, EPageBreak, &RenderStyle::setRegionBreakAfter, EPageBreak, &RenderStyle::initialPageBreak>::createHandler());
2048
setPropertyHandler(CSSPropertyWebkitRegionBreakBefore, ApplyPropertyDefault<EPageBreak, &RenderStyle::regionBreakBefore, EPageBreak, &RenderStyle::setRegionBreakBefore, EPageBreak, &RenderStyle::initialPageBreak>::createHandler());
2049
setPropertyHandler(CSSPropertyWebkitRegionBreakInside, ApplyPropertyDefault<EPageBreak, &RenderStyle::regionBreakInside, EPageBreak, &RenderStyle::setRegionBreakInside, EPageBreak, &RenderStyle::initialPageBreak>::createHandler());
2050
setPropertyHandler(CSSPropertyWebkitRegionOverflow, ApplyPropertyDefault<RegionOverflow, &RenderStyle::regionOverflow, RegionOverflow, &RenderStyle::setRegionOverflow, RegionOverflow, &RenderStyle::initialRegionOverflow>::createHandler());
2052
setPropertyHandler(CSSPropertyWebkitRtlOrdering, ApplyPropertyDefault<Order, &RenderStyle::rtlOrdering, Order, &RenderStyle::setRTLOrdering, Order, &RenderStyle::initialRTLOrdering>::createHandler());
2053
setPropertyHandler(CSSPropertyWebkitRubyPosition, ApplyPropertyDefault<RubyPosition, &RenderStyle::rubyPosition, RubyPosition, &RenderStyle::setRubyPosition, RubyPosition, &RenderStyle::initialRubyPosition>::createHandler());
2054
setPropertyHandler(CSSPropertyWebkitTextCombine, ApplyPropertyDefault<TextCombine, &RenderStyle::textCombine, TextCombine, &RenderStyle::setTextCombine, TextCombine, &RenderStyle::initialTextCombine>::createHandler());
2055
setPropertyHandler(CSSPropertyWebkitTextEmphasisColor, ApplyPropertyColor<NoInheritFromParent, &RenderStyle::textEmphasisColor, &RenderStyle::setTextEmphasisColor, &RenderStyle::setVisitedLinkTextEmphasisColor, &RenderStyle::color>::createHandler());
2056
setPropertyHandler(CSSPropertyWebkitTextEmphasisPosition, ApplyPropertyDefault<TextEmphasisPosition, &RenderStyle::textEmphasisPosition, TextEmphasisPosition, &RenderStyle::setTextEmphasisPosition, TextEmphasisPosition, &RenderStyle::initialTextEmphasisPosition>::createHandler());
2057
setPropertyHandler(CSSPropertyWebkitTextEmphasisStyle, ApplyPropertyTextEmphasisStyle::createHandler());
2058
setPropertyHandler(CSSPropertyWebkitTextFillColor, ApplyPropertyColor<NoInheritFromParent, &RenderStyle::textFillColor, &RenderStyle::setTextFillColor, &RenderStyle::setVisitedLinkTextFillColor, &RenderStyle::color>::createHandler());
2059
setPropertyHandler(CSSPropertyWebkitTextOrientation, ApplyPropertyFont<TextOrientation, &FontDescription::textOrientation, &FontDescription::setTextOrientation, TextOrientationVerticalRight>::createHandler());
2060
setPropertyHandler(CSSPropertyWebkitTextSecurity, ApplyPropertyDefault<ETextSecurity, &RenderStyle::textSecurity, ETextSecurity, &RenderStyle::setTextSecurity, ETextSecurity, &RenderStyle::initialTextSecurity>::createHandler());
2061
setPropertyHandler(CSSPropertyWebkitTextStrokeColor, ApplyPropertyColor<NoInheritFromParent, &RenderStyle::textStrokeColor, &RenderStyle::setTextStrokeColor, &RenderStyle::setVisitedLinkTextStrokeColor, &RenderStyle::color>::createHandler());
2062
setPropertyHandler(CSSPropertyWebkitTransformOrigin, ApplyPropertyExpanding<SuppressValue, CSSPropertyWebkitTransformOriginX, CSSPropertyWebkitTransformOriginY, CSSPropertyWebkitTransformOriginZ>::createHandler());
2063
setPropertyHandler(CSSPropertyWebkitTransformOriginX, ApplyPropertyLength<&RenderStyle::transformOriginX, &RenderStyle::setTransformOriginX, &RenderStyle::initialTransformOriginX>::createHandler());
2064
setPropertyHandler(CSSPropertyWebkitTransformOriginY, ApplyPropertyLength<&RenderStyle::transformOriginY, &RenderStyle::setTransformOriginY, &RenderStyle::initialTransformOriginY>::createHandler());
2065
setPropertyHandler(CSSPropertyWebkitTransformOriginZ, ApplyPropertyComputeLength<float, &RenderStyle::transformOriginZ, &RenderStyle::setTransformOriginZ, &RenderStyle::initialTransformOriginZ>::createHandler());
2066
setPropertyHandler(CSSPropertyWebkitTransformStyle, ApplyPropertyDefault<ETransformStyle3D, &RenderStyle::transformStyle3D, ETransformStyle3D, &RenderStyle::setTransformStyle3D, ETransformStyle3D, &RenderStyle::initialTransformStyle3D>::createHandler());
2067
setPropertyHandler(CSSPropertyWebkitTransitionDelay, ApplyPropertyAnimation<double, &Animation::delay, &Animation::setDelay, &Animation::isDelaySet, &Animation::clearDelay, &Animation::initialAnimationDelay, &CSSToStyleMap::mapAnimationDelay, &RenderStyle::accessTransitions, &RenderStyle::transitions>::createHandler());
2068
setPropertyHandler(CSSPropertyWebkitTransitionDuration, ApplyPropertyAnimation<double, &Animation::duration, &Animation::setDuration, &Animation::isDurationSet, &Animation::clearDuration, &Animation::initialAnimationDuration, &CSSToStyleMap::mapAnimationDuration, &RenderStyle::accessTransitions, &RenderStyle::transitions>::createHandler());
2069
setPropertyHandler(CSSPropertyWebkitTransitionProperty, ApplyPropertyAnimation<CSSPropertyID, &Animation::property, &Animation::setProperty, &Animation::isPropertySet, &Animation::clearProperty, &Animation::initialAnimationProperty, &CSSToStyleMap::mapAnimationProperty, &RenderStyle::accessTransitions, &RenderStyle::transitions>::createHandler());
2070
setPropertyHandler(CSSPropertyWebkitTransitionTimingFunction, ApplyPropertyAnimation<const PassRefPtr<TimingFunction>, &Animation::timingFunction, &Animation::setTimingFunction, &Animation::isTimingFunctionSet, &Animation::clearTimingFunction, &Animation::initialAnimationTimingFunction, &CSSToStyleMap::mapAnimationTimingFunction, &RenderStyle::accessTransitions, &RenderStyle::transitions>::createHandler());
2071
setPropertyHandler(CSSPropertyWebkitUserDrag, ApplyPropertyDefault<EUserDrag, &RenderStyle::userDrag, EUserDrag, &RenderStyle::setUserDrag, EUserDrag, &RenderStyle::initialUserDrag>::createHandler());
2072
setPropertyHandler(CSSPropertyWebkitUserModify, ApplyPropertyDefault<EUserModify, &RenderStyle::userModify, EUserModify, &RenderStyle::setUserModify, EUserModify, &RenderStyle::initialUserModify>::createHandler());
2073
setPropertyHandler(CSSPropertyWebkitUserSelect, ApplyPropertyDefault<EUserSelect, &RenderStyle::userSelect, EUserSelect, &RenderStyle::setUserSelect, EUserSelect, &RenderStyle::initialUserSelect>::createHandler());
2074
setPropertyHandler(CSSPropertyWebkitClipPath, ApplyPropertyClipPath<&RenderStyle::clipPath, &RenderStyle::setClipPath, &RenderStyle::initialClipPath>::createHandler());
2076
#if ENABLE(CSS_EXCLUSIONS)
2077
setPropertyHandler(CSSPropertyWebkitWrap, ApplyPropertyExpanding<SuppressValue, CSSPropertyWebkitWrapFlow, CSSPropertyWebkitShapeMargin, CSSPropertyWebkitShapePadding>::createHandler());
2078
setPropertyHandler(CSSPropertyWebkitWrapFlow, ApplyPropertyDefault<WrapFlow, &RenderStyle::wrapFlow, WrapFlow, &RenderStyle::setWrapFlow, WrapFlow, &RenderStyle::initialWrapFlow>::createHandler());
2079
setPropertyHandler(CSSPropertyWebkitShapeMargin, ApplyPropertyLength<&RenderStyle::shapeMargin, &RenderStyle::setShapeMargin, &RenderStyle::initialShapeMargin>::createHandler());
2080
setPropertyHandler(CSSPropertyWebkitShapePadding, ApplyPropertyLength<&RenderStyle::shapePadding, &RenderStyle::setShapePadding, &RenderStyle::initialShapePadding>::createHandler());
2081
setPropertyHandler(CSSPropertyWebkitWrapThrough, ApplyPropertyDefault<WrapThrough, &RenderStyle::wrapThrough, WrapThrough, &RenderStyle::setWrapThrough, WrapThrough, &RenderStyle::initialWrapThrough>::createHandler());
2082
setPropertyHandler(CSSPropertyWebkitShapeInside, ApplyPropertyExclusionShape<&RenderStyle::shapeInside, &RenderStyle::setShapeInside, &RenderStyle::initialShapeInside>::createHandler());
2083
setPropertyHandler(CSSPropertyWebkitShapeOutside, ApplyPropertyExclusionShape<&RenderStyle::shapeOutside, &RenderStyle::setShapeOutside, &RenderStyle::initialShapeOutside>::createHandler());
2085
setPropertyHandler(CSSPropertyWhiteSpace, ApplyPropertyDefault<EWhiteSpace, &RenderStyle::whiteSpace, EWhiteSpace, &RenderStyle::setWhiteSpace, EWhiteSpace, &RenderStyle::initialWhiteSpace>::createHandler());
2086
setPropertyHandler(CSSPropertyWidows, ApplyPropertyDefault<short, &RenderStyle::widows, short, &RenderStyle::setWidows, short, &RenderStyle::initialWidows>::createHandler());
2087
setPropertyHandler(CSSPropertyWidth, ApplyPropertyLength<&RenderStyle::width, &RenderStyle::setWidth, &RenderStyle::initialSize, AutoEnabled, LegacyIntrinsicEnabled, IntrinsicEnabled, NoneDisabled, UndefinedDisabled>::createHandler());
2088
setPropertyHandler(CSSPropertyWordBreak, ApplyPropertyDefault<EWordBreak, &RenderStyle::wordBreak, EWordBreak, &RenderStyle::setWordBreak, EWordBreak, &RenderStyle::initialWordBreak>::createHandler());
2089
setPropertyHandler(CSSPropertyWordSpacing, ApplyPropertyComputeLength<int, &RenderStyle::wordSpacing, &RenderStyle::setWordSpacing, &RenderStyle::initialLetterWordSpacing, NormalEnabled, ThicknessDisabled, SVGZoomEnabled>::createHandler());
2090
// UAs must treat 'word-wrap' as an alternate name for the 'overflow-wrap' property. So using the same handlers.
2091
setPropertyHandler(CSSPropertyWordWrap, ApplyPropertyDefault<EOverflowWrap, &RenderStyle::overflowWrap, EOverflowWrap, &RenderStyle::setOverflowWrap, EOverflowWrap, &RenderStyle::initialOverflowWrap>::createHandler());
2092
setPropertyHandler(CSSPropertyZIndex, ApplyPropertyAuto<int, &RenderStyle::zIndex, &RenderStyle::setZIndex, &RenderStyle::hasAutoZIndex, &RenderStyle::setHasAutoZIndex>::createHandler());
2093
setPropertyHandler(CSSPropertyZoom, ApplyPropertyZoom::createHandler());