Changeset 155511 in webkit


Ignore:
Timestamp:
Sep 11, 2013 1:43:21 AM (11 years ago)
Author:
rniwa@webkit.org
Message:

CSSProperty::isInheritedProperty is large
https://bugs.webkit.org/show_bug.cgi?id=121083

Reviewed by Sam Weinig.

Support [Inherited] option in makeprop.pl and generate CSSProperty::isInheritedProperty in CSSPropertyNames.cpp
using a lookup table. We can pack the table better by using bitfield in the future but I think boolean lookup
table is a good first cut.

Updated CSSPropertyNames.in and SVGCSSPropertyNames.in to use the new option and removed the old code from
CSSProperty.cpp.

  • css/CSSProperty.cpp:
  • css/CSSPropertyNames.in:
  • css/SVGCSSPropertyNames.in:
  • css/makeprop.pl:
Location:
trunk/Source/WebCore
Files:
5 edited

Legend:

Unmodified
Added
Removed
  • trunk/Source/WebCore/ChangeLog

    r155510 r155511  
     12013-09-10  Ryosuke Niwa  <rniwa@webkit.org>
     2
     3        CSSProperty::isInheritedProperty is large
     4        https://bugs.webkit.org/show_bug.cgi?id=121083
     5
     6        Reviewed by Sam Weinig.
     7
     8        Support [Inherited] option in makeprop.pl and generate CSSProperty::isInheritedProperty in CSSPropertyNames.cpp
     9        using a lookup table. We can pack the table better by using bitfield in the future but I think boolean lookup
     10        table is a good first cut.
     11
     12        Updated CSSPropertyNames.in and SVGCSSPropertyNames.in to use the new option and removed the old code from
     13        CSSProperty.cpp.
     14
     15        * css/CSSProperty.cpp:
     16        * css/CSSPropertyNames.in:
     17        * css/SVGCSSPropertyNames.in:
     18        * css/makeprop.pl:
     19
    1202013-09-11  Andreas Kling  <akling@apple.com>
    221
  • trunk/Source/WebCore/css/CSSProperty.cpp

    r155496 r155511  
    262262}
    263263
    264 bool CSSProperty::isInheritedProperty(CSSPropertyID propertyID)
    265 {
    266     switch (propertyID) {
    267     case CSSPropertyBorderCollapse:
    268     case CSSPropertyBorderSpacing:
    269     case CSSPropertyCaptionSide:
    270     case CSSPropertyColor:
    271     case CSSPropertyCursor:
    272     case CSSPropertyDirection:
    273     case CSSPropertyEmptyCells:
    274     case CSSPropertyFont:
    275     case CSSPropertyFontFamily:
    276     case CSSPropertyFontSize:
    277     case CSSPropertyFontStyle:
    278     case CSSPropertyFontVariant:
    279     case CSSPropertyFontWeight:
    280 #if ENABLE(CSS_IMAGE_ORIENTATION)
    281     case CSSPropertyImageOrientation:
    282 #endif
    283     case CSSPropertyImageRendering:
    284 #if ENABLE(CSS_IMAGE_RESOLUTION)
    285     case CSSPropertyImageResolution:
    286 #endif
    287     case CSSPropertyLetterSpacing:
    288     case CSSPropertyLineHeight:
    289     case CSSPropertyListStyle:
    290     case CSSPropertyListStyleImage:
    291     case CSSPropertyListStyleType:
    292     case CSSPropertyListStylePosition:
    293     case CSSPropertyOrphans:
    294     case CSSPropertyPointerEvents:
    295     case CSSPropertyQuotes:
    296     case CSSPropertyResize:
    297     case CSSPropertySpeak:
    298     case CSSPropertyTabSize:
    299     case CSSPropertyTextAlign:
    300     case CSSPropertyTextIndent:
    301     case CSSPropertyTextRendering:
    302     case CSSPropertyTextShadow:
    303     case CSSPropertyTextTransform:
    304 #if ENABLE(CSS_VARIABLES)
    305     case CSSPropertyVariable:
    306 #endif
    307     case CSSPropertyVisibility:
    308     case CSSPropertyWebkitAspectRatio:
    309     case CSSPropertyWebkitBorderHorizontalSpacing:
    310     case CSSPropertyWebkitBorderVerticalSpacing:
    311     case CSSPropertyWebkitBoxDirection:
    312     case CSSPropertyWebkitColorCorrection:
    313 #if ENABLE(CURSOR_VISIBILITY)
    314     case CSSPropertyWebkitCursorVisibility:
    315 #endif
    316     case CSSPropertyWebkitFontFeatureSettings:
    317     case CSSPropertyWebkitFontKerning:
    318     case CSSPropertyWebkitFontSmoothing:
    319     case CSSPropertyWebkitFontVariantLigatures:
    320     case CSSPropertyWebkitLocale:
    321     case CSSPropertyWebkitHighlight:
    322     case CSSPropertyWebkitHyphenateCharacter:
    323     case CSSPropertyWebkitHyphenateLimitAfter:
    324     case CSSPropertyWebkitHyphenateLimitBefore:
    325     case CSSPropertyWebkitHyphenateLimitLines:
    326     case CSSPropertyWebkitHyphens:
    327     case CSSPropertyWebkitLineAlign:
    328     case CSSPropertyWebkitLineBoxContain:
    329     case CSSPropertyWebkitLineBreak:
    330     case CSSPropertyWebkitLineGrid:
    331     case CSSPropertyWebkitLineSnap:
    332     case CSSPropertyWebkitNbspMode:
    333 #if ENABLE(ACCELERATED_OVERFLOW_SCROLLING)
    334     case CSSPropertyWebkitOverflowScrolling:
    335 #endif
    336     case CSSPropertyWebkitPrintColorAdjust:
    337     case CSSPropertyWebkitRtlOrdering:
    338     case CSSPropertyWebkitRubyPosition:
    339     case CSSPropertyWebkitTextCombine:
    340 #if ENABLE(CSS3_TEXT)
    341     case CSSPropertyWebkitTextAlignLast:
    342     case CSSPropertyWebkitTextJustify:
    343     case CSSPropertyWebkitTextUnderlinePosition:
    344 #endif // CSS3_TEXT
    345     case CSSPropertyWebkitTextDecorationsInEffect:
    346     case CSSPropertyWebkitTextEmphasis:
    347     case CSSPropertyWebkitTextEmphasisColor:
    348     case CSSPropertyWebkitTextEmphasisPosition:
    349     case CSSPropertyWebkitTextEmphasisStyle:
    350     case CSSPropertyWebkitTextFillColor:
    351     case CSSPropertyWebkitTextOrientation:
    352     case CSSPropertyWebkitTextSecurity:
    353 #if ENABLE(IOS_TEXT_AUTOSIZING)
    354     case CSSPropertyWebkitTextSizeAdjust:
    355 #endif
    356     case CSSPropertyWebkitTextStroke:
    357     case CSSPropertyWebkitTextStrokeColor:
    358     case CSSPropertyWebkitTextStrokeWidth:
    359     case CSSPropertyWebkitUserModify:
    360     case CSSPropertyWebkitUserSelect:
    361     case CSSPropertyWebkitWritingMode:
    362     case CSSPropertyWhiteSpace:
    363     case CSSPropertyWidows:
    364     case CSSPropertyWordBreak:
    365     case CSSPropertyWordSpacing:
    366     case CSSPropertyWordWrap:
    367 #if ENABLE(SVG)
    368     case CSSPropertyClipRule:
    369     case CSSPropertyColorInterpolation:
    370     case CSSPropertyColorInterpolationFilters:
    371     case CSSPropertyColorRendering:
    372     case CSSPropertyFill:
    373     case CSSPropertyFillOpacity:
    374     case CSSPropertyFillRule:
    375     case CSSPropertyGlyphOrientationHorizontal:
    376     case CSSPropertyGlyphOrientationVertical:
    377     case CSSPropertyKerning:
    378     case CSSPropertyMarker:
    379     case CSSPropertyMarkerEnd:
    380     case CSSPropertyMarkerMid:
    381     case CSSPropertyMarkerStart:
    382     case CSSPropertyStroke:
    383     case CSSPropertyStrokeDasharray:
    384     case CSSPropertyStrokeDashoffset:
    385     case CSSPropertyStrokeLinecap:
    386     case CSSPropertyStrokeLinejoin:
    387     case CSSPropertyStrokeMiterlimit:
    388     case CSSPropertyStrokeOpacity:
    389     case CSSPropertyStrokeWidth:
    390     case CSSPropertyShapeRendering:
    391     case CSSPropertyTextAnchor:
    392     case CSSPropertyWritingMode:
    393 #endif
    394 #if ENABLE(TOUCH_EVENTS)
    395     case CSSPropertyWebkitTapHighlightColor:
    396 #endif
    397         return true;
    398     case CSSPropertyDisplay:
    399     case CSSPropertyZoom:
    400     case CSSPropertyBackground:
    401     case CSSPropertyBackgroundAttachment:
    402     case CSSPropertyBackgroundClip:
    403     case CSSPropertyBackgroundColor:
    404     case CSSPropertyBackgroundImage:
    405     case CSSPropertyBackgroundOrigin:
    406     case CSSPropertyBackgroundPosition:
    407     case CSSPropertyBackgroundPositionX:
    408     case CSSPropertyBackgroundPositionY:
    409     case CSSPropertyBackgroundRepeat:
    410     case CSSPropertyBackgroundRepeatX:
    411     case CSSPropertyBackgroundRepeatY:
    412     case CSSPropertyBackgroundSize:
    413     case CSSPropertyBorder:
    414     case CSSPropertyBorderBottom:
    415     case CSSPropertyBorderBottomColor:
    416     case CSSPropertyBorderBottomLeftRadius:
    417     case CSSPropertyBorderBottomRightRadius:
    418     case CSSPropertyBorderBottomStyle:
    419     case CSSPropertyBorderBottomWidth:
    420     case CSSPropertyBorderColor:
    421     case CSSPropertyBorderImage:
    422     case CSSPropertyBorderImageOutset:
    423     case CSSPropertyBorderImageRepeat:
    424     case CSSPropertyBorderImageSlice:
    425     case CSSPropertyBorderImageSource:
    426     case CSSPropertyBorderImageWidth:
    427     case CSSPropertyBorderLeft:
    428     case CSSPropertyBorderLeftColor:
    429     case CSSPropertyBorderLeftStyle:
    430     case CSSPropertyBorderLeftWidth:
    431     case CSSPropertyBorderRadius:
    432     case CSSPropertyBorderRight:
    433     case CSSPropertyBorderRightColor:
    434     case CSSPropertyBorderRightStyle:
    435     case CSSPropertyBorderRightWidth:
    436     case CSSPropertyBorderStyle:
    437     case CSSPropertyBorderTop:
    438     case CSSPropertyBorderTopColor:
    439     case CSSPropertyBorderTopLeftRadius:
    440     case CSSPropertyBorderTopRightRadius:
    441     case CSSPropertyBorderTopStyle:
    442     case CSSPropertyBorderTopWidth:
    443     case CSSPropertyBorderWidth:
    444     case CSSPropertyBottom:
    445     case CSSPropertyBoxShadow:
    446     case CSSPropertyBoxSizing:
    447     case CSSPropertyClear:
    448     case CSSPropertyClip:
    449     case CSSPropertyContent:
    450     case CSSPropertyCounterIncrement:
    451     case CSSPropertyCounterReset:
    452     case CSSPropertyFloat:
    453     case CSSPropertyFontStretch:
    454 #if ENABLE(CSS_SHADERS)
    455     case CSSPropertyGeometry:
    456 #endif
    457     case CSSPropertyHeight:
    458     case CSSPropertyLeft:
    459     case CSSPropertyMargin:
    460     case CSSPropertyMarginBottom:
    461     case CSSPropertyMarginLeft:
    462     case CSSPropertyMarginRight:
    463     case CSSPropertyMarginTop:
    464     case CSSPropertyMaxHeight:
    465     case CSSPropertyMaxWidth:
    466     case CSSPropertyMinHeight:
    467     case CSSPropertyMinWidth:
    468     case CSSPropertyObjectFit:
    469     case CSSPropertyOpacity:
    470     case CSSPropertyOutline:
    471     case CSSPropertyOutlineColor:
    472     case CSSPropertyOutlineOffset:
    473     case CSSPropertyOutlineStyle:
    474     case CSSPropertyOutlineWidth:
    475     case CSSPropertyOverflow:
    476     case CSSPropertyOverflowWrap:
    477     case CSSPropertyOverflowX:
    478     case CSSPropertyOverflowY:
    479     case CSSPropertyPadding:
    480     case CSSPropertyPaddingBottom:
    481     case CSSPropertyPaddingLeft:
    482     case CSSPropertyPaddingRight:
    483     case CSSPropertyPaddingTop:
    484     case CSSPropertyPage:
    485     case CSSPropertyPageBreakAfter:
    486     case CSSPropertyPageBreakBefore:
    487     case CSSPropertyPageBreakInside:
    488     case CSSPropertyPosition:
    489     case CSSPropertyRight:
    490     case CSSPropertySize:
    491     case CSSPropertySrc:
    492     case CSSPropertyTableLayout:
    493     case CSSPropertyTextDecoration:
    494     case CSSPropertyTextLineThrough:
    495     case CSSPropertyTextLineThroughColor:
    496     case CSSPropertyTextLineThroughMode:
    497     case CSSPropertyTextLineThroughStyle:
    498     case CSSPropertyTextLineThroughWidth:
    499     case CSSPropertyTextOverflow:
    500     case CSSPropertyTextOverline:
    501     case CSSPropertyTextOverlineColor:
    502     case CSSPropertyTextOverlineMode:
    503     case CSSPropertyTextOverlineStyle:
    504     case CSSPropertyTextOverlineWidth:
    505     case CSSPropertyTextUnderline:
    506     case CSSPropertyTextUnderlineColor:
    507     case CSSPropertyTextUnderlineMode:
    508     case CSSPropertyTextUnderlineStyle:
    509     case CSSPropertyTextUnderlineWidth:
    510     case CSSPropertyTop:
    511     case CSSPropertyTransition:
    512     case CSSPropertyTransitionDelay:
    513     case CSSPropertyTransitionDuration:
    514     case CSSPropertyTransitionProperty:
    515     case CSSPropertyTransitionTimingFunction:
    516     case CSSPropertyUnicodeBidi:
    517     case CSSPropertyUnicodeRange:
    518     case CSSPropertyVerticalAlign:
    519     case CSSPropertyWidth:
    520     case CSSPropertyZIndex:
    521     case CSSPropertyWebkitAnimation:
    522     case CSSPropertyWebkitAnimationDelay:
    523     case CSSPropertyWebkitAnimationDirection:
    524     case CSSPropertyWebkitAnimationDuration:
    525     case CSSPropertyWebkitAnimationFillMode:
    526     case CSSPropertyWebkitAnimationIterationCount:
    527     case CSSPropertyWebkitAnimationName:
    528     case CSSPropertyWebkitAnimationPlayState:
    529     case CSSPropertyWebkitAnimationTimingFunction:
    530     case CSSPropertyWebkitAppearance:
    531     case CSSPropertyWebkitBackfaceVisibility:
    532     case CSSPropertyWebkitBackgroundBlendMode:
    533     case CSSPropertyWebkitBackgroundClip:
    534     case CSSPropertyWebkitBackgroundComposite:
    535     case CSSPropertyWebkitBackgroundOrigin:
    536     case CSSPropertyWebkitBackgroundSize:
    537     case CSSPropertyWebkitBorderAfter:
    538     case CSSPropertyWebkitBorderAfterColor:
    539     case CSSPropertyWebkitBorderAfterStyle:
    540     case CSSPropertyWebkitBorderAfterWidth:
    541     case CSSPropertyWebkitBorderBefore:
    542     case CSSPropertyWebkitBorderBeforeColor:
    543     case CSSPropertyWebkitBorderBeforeStyle:
    544     case CSSPropertyWebkitBorderBeforeWidth:
    545     case CSSPropertyWebkitBorderEnd:
    546     case CSSPropertyWebkitBorderEndColor:
    547     case CSSPropertyWebkitBorderEndStyle:
    548     case CSSPropertyWebkitBorderEndWidth:
    549     case CSSPropertyWebkitBorderFit:
    550     case CSSPropertyWebkitBorderImage:
    551     case CSSPropertyWebkitBorderRadius:
    552     case CSSPropertyWebkitBorderStart:
    553     case CSSPropertyWebkitBorderStartColor:
    554     case CSSPropertyWebkitBorderStartStyle:
    555     case CSSPropertyWebkitBorderStartWidth:
    556     case CSSPropertyWebkitBoxAlign:
    557 #if ENABLE(CSS_BOX_DECORATION_BREAK)
    558     case CSSPropertyWebkitBoxDecorationBreak:
    559 #endif
    560     case CSSPropertyWebkitBoxFlex:
    561     case CSSPropertyWebkitBoxFlexGroup:
    562     case CSSPropertyWebkitBoxLines:
    563     case CSSPropertyWebkitBoxOrdinalGroup:
    564     case CSSPropertyWebkitBoxOrient:
    565     case CSSPropertyWebkitBoxPack:
    566     case CSSPropertyWebkitBoxReflect:
    567     case CSSPropertyWebkitBoxShadow:
    568     case CSSPropertyWebkitClipPath:
    569     case CSSPropertyWebkitColumnAxis:
    570     case CSSPropertyWebkitColumnBreakAfter:
    571     case CSSPropertyWebkitColumnBreakBefore:
    572     case CSSPropertyWebkitColumnBreakInside:
    573     case CSSPropertyWebkitColumnCount:
    574     case CSSPropertyWebkitColumnGap:
    575     case CSSPropertyWebkitColumnProgression:
    576     case CSSPropertyWebkitColumnRule:
    577     case CSSPropertyWebkitColumnRuleColor:
    578     case CSSPropertyWebkitColumnRuleStyle:
    579     case CSSPropertyWebkitColumnRuleWidth:
    580     case CSSPropertyWebkitColumnSpan:
    581     case CSSPropertyWebkitColumnWidth:
    582     case CSSPropertyWebkitColumns:
    583 #if ENABLE(CSS_FILTERS)
    584     case CSSPropertyWebkitFilter:
    585 #endif
    586 #if ENABLE(CSS_COMPOSITING)
    587     case CSSPropertyWebkitBlendMode:
    588 #endif
    589     case CSSPropertyWebkitAlignContent:
    590     case CSSPropertyWebkitAlignItems:
    591     case CSSPropertyWebkitAlignSelf:
    592     case CSSPropertyWebkitFlex:
    593     case CSSPropertyWebkitFlexBasis:
    594     case CSSPropertyWebkitFlexDirection:
    595     case CSSPropertyWebkitFlexFlow:
    596     case CSSPropertyWebkitFlexGrow:
    597     case CSSPropertyWebkitFlexShrink:
    598     case CSSPropertyWebkitFlexWrap:
    599     case CSSPropertyWebkitJustifyContent:
    600     case CSSPropertyWebkitOrder:
    601     case CSSPropertyWebkitFontSizeDelta:
    602     case CSSPropertyWebkitGridAutoColumns:
    603     case CSSPropertyWebkitGridAutoFlow:
    604     case CSSPropertyWebkitGridAutoRows:
    605     case CSSPropertyWebkitGridColumnEnd:
    606     case CSSPropertyWebkitGridColumnStart:
    607     case CSSPropertyWebkitGridDefinitionColumns:
    608     case CSSPropertyWebkitGridDefinitionRows:
    609     case CSSPropertyWebkitGridRowEnd:
    610     case CSSPropertyWebkitGridRowStart:
    611     case CSSPropertyWebkitGridColumn:
    612     case CSSPropertyWebkitGridRow:
    613     case CSSPropertyWebkitLineClamp:
    614     case CSSPropertyWebkitLogicalWidth:
    615     case CSSPropertyWebkitLogicalHeight:
    616     case CSSPropertyWebkitMarginAfterCollapse:
    617     case CSSPropertyWebkitMarginBeforeCollapse:
    618     case CSSPropertyWebkitMarginBottomCollapse:
    619     case CSSPropertyWebkitMarginTopCollapse:
    620     case CSSPropertyWebkitMarginCollapse:
    621     case CSSPropertyWebkitMarginAfter:
    622     case CSSPropertyWebkitMarginBefore:
    623     case CSSPropertyWebkitMarginEnd:
    624     case CSSPropertyWebkitMarginStart:
    625     case CSSPropertyWebkitMarquee:
    626     case CSSPropertyWebkitMarqueeDirection:
    627     case CSSPropertyWebkitMarqueeIncrement:
    628     case CSSPropertyWebkitMarqueeRepetition:
    629     case CSSPropertyWebkitMarqueeSpeed:
    630     case CSSPropertyWebkitMarqueeStyle:
    631     case CSSPropertyWebkitMask:
    632     case CSSPropertyWebkitMaskBoxImage:
    633     case CSSPropertyWebkitMaskBoxImageOutset:
    634     case CSSPropertyWebkitMaskBoxImageRepeat:
    635     case CSSPropertyWebkitMaskBoxImageSlice:
    636     case CSSPropertyWebkitMaskBoxImageSource:
    637     case CSSPropertyWebkitMaskBoxImageWidth:
    638     case CSSPropertyWebkitMaskClip:
    639     case CSSPropertyWebkitMaskComposite:
    640     case CSSPropertyWebkitMaskImage:
    641     case CSSPropertyWebkitMaskOrigin:
    642     case CSSPropertyWebkitMaskPosition:
    643     case CSSPropertyWebkitMaskPositionX:
    644     case CSSPropertyWebkitMaskPositionY:
    645     case CSSPropertyWebkitMaskRepeat:
    646     case CSSPropertyWebkitMaskRepeatX:
    647     case CSSPropertyWebkitMaskRepeatY:
    648     case CSSPropertyWebkitMaskSize:
    649     case CSSPropertyWebkitMaskSourceType:
    650     case CSSPropertyWebkitMaxLogicalWidth:
    651     case CSSPropertyWebkitMaxLogicalHeight:
    652     case CSSPropertyWebkitMinLogicalWidth:
    653     case CSSPropertyWebkitMinLogicalHeight:
    654     case CSSPropertyWebkitPaddingAfter:
    655     case CSSPropertyWebkitPaddingBefore:
    656     case CSSPropertyWebkitPaddingEnd:
    657     case CSSPropertyWebkitPaddingStart:
    658     case CSSPropertyWebkitPerspective:
    659     case CSSPropertyWebkitPerspectiveOrigin:
    660     case CSSPropertyWebkitPerspectiveOriginX:
    661     case CSSPropertyWebkitPerspectiveOriginY:
    662 #if ENABLE(CSS3_TEXT)
    663     case CSSPropertyWebkitTextDecoration:
    664     case CSSPropertyWebkitTextDecorationLine:
    665     case CSSPropertyWebkitTextDecorationStyle:
    666     case CSSPropertyWebkitTextDecorationColor:
    667 #endif // CSS3_TEXT
    668     case CSSPropertyWebkitTransform:
    669     case CSSPropertyWebkitTransformOrigin:
    670     case CSSPropertyWebkitTransformOriginX:
    671     case CSSPropertyWebkitTransformOriginY:
    672     case CSSPropertyWebkitTransformOriginZ:
    673     case CSSPropertyWebkitTransformStyle:
    674     case CSSPropertyWebkitTransition:
    675     case CSSPropertyWebkitTransitionDelay:
    676     case CSSPropertyWebkitTransitionDuration:
    677     case CSSPropertyWebkitTransitionProperty:
    678     case CSSPropertyWebkitTransitionTimingFunction:
    679     case CSSPropertyWebkitUserDrag:
    680 #if ENABLE(CSS_REGIONS)
    681     case CSSPropertyWebkitFlowInto:
    682     case CSSPropertyWebkitFlowFrom:
    683     case CSSPropertyWebkitRegionBreakAfter:
    684     case CSSPropertyWebkitRegionBreakBefore:
    685     case CSSPropertyWebkitRegionBreakInside:
    686     case CSSPropertyWebkitRegionFragment:
    687 #endif
    688 #if ENABLE(CSS_EXCLUSIONS)
    689     case CSSPropertyWebkitWrapFlow:
    690     case CSSPropertyWebkitWrapThrough:
    691 #endif
    692 #if ENABLE(CSS_SHAPES)
    693     case CSSPropertyWebkitShapeMargin:
    694     case CSSPropertyWebkitShapePadding:
    695     case CSSPropertyWebkitShapeInside:
    696     case CSSPropertyWebkitShapeOutside:
    697 #endif
    698 #if ENABLE(CSS_SHADERS)
    699     case CSSPropertyMix:
    700     case CSSPropertyParameters:
    701 #endif
    702 #if ENABLE(SVG)
    703     case CSSPropertyClipPath:
    704     case CSSPropertyMask:
    705     case CSSPropertyMaskType:
    706     case CSSPropertyEnableBackground:
    707     case CSSPropertyFilter:
    708     case CSSPropertyFloodColor:
    709     case CSSPropertyFloodOpacity:
    710     case CSSPropertyLightingColor:
    711     case CSSPropertyStopColor:
    712     case CSSPropertyStopOpacity:
    713     case CSSPropertyColorProfile:
    714     case CSSPropertyAlignmentBaseline:
    715     case CSSPropertyBaselineShift:
    716     case CSSPropertyDominantBaseline:
    717     case CSSPropertyVectorEffect:
    718     case CSSPropertyBufferedRendering:
    719     case CSSPropertyWebkitSvgShadow:
    720 #endif
    721 #if ENABLE(DASHBOARD_SUPPORT)
    722     case CSSPropertyWebkitDashboardRegion:
    723 #endif
    724 #if ENABLE(DRAGGABLE_REGION)
    725     case CSSPropertyWebkitAppRegion:
    726 #endif
    727 #if ENABLE(CSS_DEVICE_ADAPTATION)
    728     case CSSPropertyMaxZoom:
    729     case CSSPropertyMinZoom:
    730     case CSSPropertyOrientation:
    731     case CSSPropertyUserZoom:
    732 #endif
    733         return false;
    734     case CSSPropertyInvalid:
    735         ASSERT_NOT_REACHED();
    736         return false;
    737     }
    738     ASSERT_NOT_REACHED();
    739     return false;
    740 }
    741 
    742264} // namespace WebCore
  • trunk/Source/WebCore/css/CSSPropertyNames.in

    r155496 r155511  
    1212// high-priority property names have to be listed first, to simplify the check
    1313// for applying them first.
    14 color
    15 direction
     14color [Inherited]
     15direction [Inherited]
    1616display
    17 font
    18 font-family
    19 font-size
    20 font-style
    21 font-variant
    22 font-weight
    23 text-rendering
    24 -webkit-font-feature-settings
    25 -webkit-font-kerning
    26 -webkit-font-smoothing
    27 -webkit-font-variant-ligatures
    28 -webkit-locale
    29 -webkit-text-orientation
     17font [Inherited]
     18font-family [Inherited]
     19font-size [Inherited]
     20font-style [Inherited]
     21font-variant [Inherited]
     22font-weight [Inherited]
     23text-rendering [Inherited]
     24-webkit-font-feature-settings [Inherited]
     25-webkit-font-kerning [Inherited]
     26-webkit-font-smoothing [Inherited]
     27-webkit-font-variant-ligatures [Inherited]
     28-webkit-locale [Inherited]
     29-webkit-text-orientation [Inherited]
    3030-epub-text-orientation = -webkit-text-orientation
    3131#if defined(ENABLE_IOS_TEXT_AUTOSIZING) && ENABLE_IOS_TEXT_AUTOSIZING
    32 -webkit-text-size-adjust
    33 #endif
    34 -webkit-writing-mode
     32-webkit-text-size-adjust [Inherited]
     33#endif
     34-webkit-writing-mode [Inherited]
    3535-epub-writing-mode = -webkit-writing-mode
    3636zoom
    3737
    3838// line height needs to be right after the above high-priority properties
    39 line-height
     39line-height [Inherited]
    4040
    4141// The remaining properties are listed in alphabetical order
     
    6262border-bottom-style
    6363border-bottom-width
    64 border-collapse
     64border-collapse [Inherited]
    6565border-color
    6666border-image
     
    7979border-right-style
    8080border-right-width
    81 border-spacing
     81border-spacing [Inherited]
    8282border-style
    8383border-top
     
    9595// -webkit-box-sizing worked in Safari 4 and earlier.
    9696-webkit-box-sizing = box-sizing
    97 caption-side
     97caption-side [Inherited]
    9898-epub-caption-side = caption-side
    9999clear
     
    103103counter-increment
    104104counter-reset
    105 cursor
     105cursor [Inherited]
    106106#if defined(ENABLE_CURSOR_VISIBILITY) && ENABLE_CURSOR_VISIBILITY
    107 -webkit-cursor-visibility
    108 #endif
    109 empty-cells
     107-webkit-cursor-visibility [Inherited]
     108#endif
     109empty-cells [Inherited]
    110110float
    111111font-stretch
     
    115115height
    116116#if defined(ENABLE_CSS_IMAGE_ORIENTATION) && ENABLE_CSS_IMAGE_ORIENTATION
    117 image-orientation
    118 #endif
    119 image-rendering
     117image-orientation [Inherited]
     118#endif
     119image-rendering [Inherited]
    120120#if defined(ENABLE_CSS_IMAGE_RESOLUTION) && ENABLE_CSS_IMAGE_RESOLUTION
    121 image-resolution
     121image-resolution [Inherited]
    122122#endif
    123123left
    124 letter-spacing
    125 list-style
    126 list-style-image
    127 list-style-position
    128 list-style-type
     124letter-spacing [Inherited]
     125list-style [Inherited]
     126list-style-image [Inherited]
     127list-style-position [Inherited]
     128list-style-type [Inherited]
    129129margin
    130130margin-bottom
     
    145145// and may be in use on some websites and widgets.
    146146-webkit-opacity = opacity
    147 orphans
     147orphans [Inherited]
    148148outline
    149149outline-color
     
    164164page-break-before
    165165page-break-inside
    166 pointer-events
     166pointer-events [Inherited]
    167167position
    168 quotes
    169 resize
     168quotes [Inherited]
     169resize [Inherited]
    170170right
    171171size
    172172src
    173 speak
     173speak [Inherited]
    174174table-layout
    175 tab-size
    176 text-align
     175tab-size [Inherited]
     176text-align [Inherited]
    177177text-decoration
    178 text-indent
     178text-indent [Inherited]
    179179text-line-through
    180180text-line-through-color
     
    188188text-overline-style
    189189text-overline-width
    190 text-shadow
    191 text-transform
     190text-shadow [Inherited]
     191text-transform [Inherited]
    192192-epub-text-transform = text-transform
    193193text-underline
     
    206206unicode-range
    207207vertical-align
    208 visibility
    209 white-space
    210 widows
     208visibility [Inherited]
     209white-space [Inherited]
     210widows [Inherited]
    211211width
    212 word-break
     212word-break [Inherited]
    213213-epub-word-break = word-break
    214 word-spacing
    215 word-wrap
     214word-spacing [Inherited]
     215word-wrap [Inherited]
    216216z-index
    217217-webkit-animation
     
    225225-webkit-animation-timing-function
    226226-webkit-appearance
    227 -webkit-aspect-ratio
     227-webkit-aspect-ratio [Inherited]
    228228-webkit-backface-visibility
    229229-webkit-background-blend-mode
     
    248248-webkit-border-end-width
    249249-webkit-border-fit
    250 -webkit-border-horizontal-spacing
     250-webkit-border-horizontal-spacing [Inherited]
    251251-webkit-border-image
    252252// -webkit-border-radius differs from border-radius only in the interpretation of
     
    258258-webkit-border-start-style
    259259-webkit-border-start-width
    260 -webkit-border-vertical-spacing
     260-webkit-border-vertical-spacing [Inherited]
    261261-webkit-box-align
    262 -webkit-box-direction
     262-webkit-box-direction [Inherited]
    263263-webkit-box-flex
    264264-webkit-box-flex-group
     
    269269-webkit-box-reflect
    270270-webkit-box-shadow
    271 -webkit-color-correction
     271-webkit-color-correction [Inherited]
    272272-webkit-column-axis
    273273-webkit-column-break-after
     
    316316-webkit-grid-row
    317317-webkit-grid-auto-flow
    318 -webkit-highlight
    319 -webkit-hyphenate-character
    320 -webkit-hyphenate-limit-after
    321 -webkit-hyphenate-limit-before
    322 -webkit-hyphenate-limit-lines
    323 -webkit-hyphens
     318-webkit-highlight [Inherited]
     319-webkit-hyphenate-character [Inherited]
     320-webkit-hyphenate-limit-after [Inherited]
     321-webkit-hyphenate-limit-before [Inherited]
     322-webkit-hyphenate-limit-lines [Inherited]
     323-webkit-hyphens [Inherited]
    324324-epub-hyphens = -webkit-hyphens
    325 -webkit-line-box-contain
    326 -webkit-line-align
    327 -webkit-line-break
     325-webkit-line-box-contain [Inherited]
     326-webkit-line-align [Inherited]
     327-webkit-line-break [Inherited]
    328328-webkit-line-clamp
    329 -webkit-line-grid
    330 -webkit-line-snap
     329-webkit-line-grid [Inherited]
     330-webkit-line-snap [Inherited]
    331331-webkit-logical-width
    332332-webkit-logical-height
     
    369369-webkit-min-logical-width
    370370-webkit-min-logical-height
    371 -webkit-nbsp-mode
     371-webkit-nbsp-mode [Inherited]
    372372-webkit-order
    373373-webkit-padding-after
     
    379379-webkit-perspective-origin-x
    380380-webkit-perspective-origin-y
    381 -webkit-print-color-adjust
    382 -webkit-rtl-ordering
    383 -webkit-ruby-position
    384 -webkit-text-combine
     381-webkit-print-color-adjust [Inherited]
     382-webkit-rtl-ordering [Inherited]
     383-webkit-ruby-position [Inherited]
     384-webkit-text-combine [Inherited]
    385385-epub-text-combine = -webkit-text-combine
    386386#if defined(ENABLE_CSS3_TEXT) && ENABLE_CSS3_TEXT
     
    389389-webkit-text-decoration-style
    390390-webkit-text-decoration-color
    391 -webkit-text-align-last
    392 -webkit-text-justify
    393 -webkit-text-underline-position
    394 #endif
    395 -webkit-text-decorations-in-effect
    396 -webkit-text-emphasis
     391-webkit-text-align-last [Inherited]
     392-webkit-text-justify [Inherited]
     393-webkit-text-underline-position [Inherited]
     394#endif
     395-webkit-text-decorations-in-effect [Inherited]
     396-webkit-text-emphasis [Inherited]
    397397-epub-text-emphasis = -webkit-text-emphasis
    398 -webkit-text-emphasis-color
     398-webkit-text-emphasis-color [Inherited]
    399399-epub-text-emphasis-color = -webkit-text-emphasis-color
    400 -webkit-text-emphasis-position
    401 -webkit-text-emphasis-style
     400-webkit-text-emphasis-position [Inherited]
     401-webkit-text-emphasis-style [Inherited]
    402402-epub-text-emphasis-style = -webkit-text-emphasis-style
    403 -webkit-text-fill-color
    404 -webkit-text-security
    405 -webkit-text-stroke
    406 -webkit-text-stroke-color
    407 -webkit-text-stroke-width
     403-webkit-text-fill-color [Inherited]
     404-webkit-text-security [Inherited]
     405-webkit-text-stroke [Inherited]
     406-webkit-text-stroke-color [Inherited]
     407-webkit-text-stroke-width [Inherited]
    408408-webkit-transform
    409409-webkit-transform-origin
     
    418418-webkit-transition-timing-function
    419419-webkit-user-drag
    420 -webkit-user-modify
    421 -webkit-user-select
     420-webkit-user-modify [Inherited]
     421-webkit-user-select [Inherited]
    422422#if defined(ENABLE_CSS_REGIONS) && ENABLE_CSS_REGIONS
    423423-webkit-flow-into
     
    445445#endif
    446446#if defined(ENABLE_TOUCH_EVENTS) && ENABLE_TOUCH_EVENTS
    447 -webkit-tap-highlight-color
     447-webkit-tap-highlight-color [Inherited]
    448448#endif
    449449#if defined(ENABLE_DASHBOARD_SUPPORT) && ENABLE_DASHBOARD_SUPPORT
     
    454454#endif
    455455#if defined(ENABLE_ACCELERATED_OVERFLOW_SCROLLING) && ENABLE_ACCELERATED_OVERFLOW_SCROLLING
    456 -webkit-overflow-scrolling
    457 #endif
     456-webkit-overflow-scrolling [Inherited]
     457#endif
  • trunk/Source/WebCore/css/SVGCSSPropertyNames.in

    r147348 r155511  
    88buffered-rendering
    99clip-path
    10 clip-rule
     10clip-rule [Inherited]
    1111mask
    1212// opacity
     
    1919stop-opacity
    2020// pointer-events
    21 color-interpolation
    22 color-interpolation-filters
     21color-interpolation [Inherited]
     22color-interpolation-filters [Inherited]
    2323color-profile
    24 color-rendering
    25 fill
    26 fill-opacity
    27 fill-rule
     24color-rendering [Inherited]
     25fill [Inherited]
     26fill-opacity [Inherited]
     27fill-rule [Inherited]
    2828//font-size-adjust
    2929//image-rendering
    30 marker
    31 marker-end
    32 marker-mid
    33 marker-start
     30marker [Inherited]
     31marker-end [Inherited]
     32marker-mid [Inherited]
     33marker-start [Inherited]
    3434mask-type
    35 shape-rendering
    36 stroke
    37 stroke-dasharray
    38 stroke-dashoffset
    39 stroke-linecap
    40 stroke-linejoin
    41 stroke-miterlimit
    42 stroke-opacity
    43 stroke-width
     35shape-rendering [Inherited]
     36stroke [Inherited]
     37stroke-dasharray [Inherited]
     38stroke-dashoffset [Inherited]
     39stroke-linecap [Inherited]
     40stroke-linejoin [Inherited]
     41stroke-miterlimit [Inherited]
     42stroke-opacity [Inherited]
     43stroke-width [Inherited]
    4444// text-rendering
    4545alignment-baseline
    4646baseline-shift
    4747dominant-baseline
    48 glyph-orientation-horizontal
    49 glyph-orientation-vertical
    50 kerning
    51 text-anchor
     48glyph-orientation-horizontal [Inherited]
     49glyph-orientation-vertical [Inherited]
     50kerning [Inherited]
     51text-anchor [Inherited]
    5252vector-effect
    53 writing-mode
     53writing-mode [Inherited]
    5454
    5555-webkit-svg-shadow
  • trunk/Source/WebCore/css/makeprop.pl

    r154259 r155511  
    3838my @duplicates = ();
    3939
     40my $numPredefinedProperties = 2;
    4041my @names = ();
     42my %nameIsInherited = {};
     43my %nameToId = {};
    4144my @aliases = ();
    4245foreach (@NAMES) {
     
    4548
    4649  # Input may use a different EOL sequence than $/, so avoid chomp.
     50  $_ =~ s/\s*\[(.+?)\]$//;
     51  my @options = ();
     52  if ($1) {
     53    @options = split(/\s*,\s*/, $1);
     54  }
     55
    4756  $_ =~ s/[\r\n]+$//g;
    4857  if (exists $namesHash{$_}) {
     
    5261  }
    5362  if ($_ =~ /=/) {
     63    if (@options) {
     64        die "Options are specified on an alias $_: ", join(", ", @options) . "\n";
     65    }
    5466    push @aliases, $_;
    5567  } else {
     68    $nameIsInherited{$_} = 0;
     69    foreach my $option (@options) {
     70      if ($option eq "Inherited") {
     71        $nameIsInherited{$_} = 1;
     72      }
     73    }
     74
     75    my $id = $_;
     76    $id =~ s/(^[^-])|-(.)/uc($1||$2)/ge;
     77    $nameToId{$_} = $id;
     78
    5679    push @names, $_;
    5780  }
     
    6790/* This file is automatically generated from CSSPropertyNames.in by makeprop, do not edit */
    6891#include "config.h"
     92#include \"CSSProperty.h\"
    6993#include \"CSSPropertyNames.h\"
    7094#include \"HashTools.h\"
     
    108132
    109133foreach my $name (@names) {
    110   my $id = $name;
    111   $id =~ s/(^[^-])|-(.)/uc($1||$2)/ge;
    112   print GPERF $name . ", CSSProperty" . $id . "\n";
     134  print GPERF $name . ", CSSProperty" . $nameToId{$name} . "\n";
    113135}
    114136
     
    116138  $alias =~ /^([^\s]*)[\s]*=[\s]*([^\s]*)/;
    117139  my $name = $1;
    118   my $id = $2;
    119   $id =~ s/(^[^-])|-(.)/uc($1||$2)/ge;
    120   print GPERF $name . ", CSSProperty" . $id . "\n";
     140  print GPERF $name . ", CSSProperty" . $nameToId{$2} . "\n";
    121141}
    122142
     
    183203}
    184204
     205bool isInheritedPropertyTable[numCSSProperties + $numPredefinedProperties] = {
     206    false, // CSSPropertyInvalid
     207    false, // CSSPropertyVariable
     208EOF
     209
     210foreach my $name (@names) {
     211  my $id = $nameToId{$name};
     212  my $value = $nameIsInherited{$name} ? "true " : "false";
     213  print GPERF "    $value, // CSSProperty$id\n";
     214}
     215
     216print GPERF<< "EOF";
     217};
     218
     219bool CSSProperty::isInheritedProperty(CSSPropertyID id)
     220{
     221    ASSERT(id >= 0 && id <= lastCSSProperty);
     222    ASSERT(id != CSSPropertyInvalid);
     223    return isInheritedPropertyTable[id];
     224}
     225
    185226} // namespace WebCore
    186227
     
    215256EOF
    216257
    217 my $first = 3;
    218 my $i = 3;
     258my $first = $numPredefinedProperties;
     259my $i = $numPredefinedProperties;
    219260my $maxLen = 0;
    220261foreach my $name (@names) {
    221   my $id = $name;
    222   $id =~ s/(^[^-])|-(.)/uc($1||$2)/ge;
    223   print HEADER "    CSSProperty" . $id . " = " . $i . ",\n";
     262  print HEADER "    CSSProperty" . $nameToId{$name} . " = " . $i . ",\n";
    224263  $i = $i + 1;
    225264  if (length($name) > $maxLen) {
Note: See TracChangeset for help on using the changeset viewer.