WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
[patch]
Patch
bug-92000-20120727152604.patch (text/plain), 8.48 KB, created by
Bruno Abinader (history only)
on 2012-07-27 12:26:17 PDT
(
hide
)
Description:
Patch
Filename:
MIME Type:
Creator:
Bruno Abinader (history only)
Created:
2012-07-27 12:26:17 PDT
Size:
8.48 KB
patch
obsolete
>Subversion Revision: 123866 >diff --git a/Source/WebCore/ChangeLog b/Source/WebCore/ChangeLog >index e021d296d10db84cd83881303cb9825d218b3b84..5060cc231af97f16d2918c61b11a6f307004a005 100644 >--- a/Source/WebCore/ChangeLog >+++ b/Source/WebCore/ChangeLog >@@ -1,3 +1,44 @@ >+2012-07-27 Bruno de Oliveira Abinader <bruno.abinader@basyskom.com> >+ >+ [css3-text] Add support for "-webkit-text-decoration" using CSS3 spec >+ https://bugs.webkit.org/show_bug.cgi?id=92000 >+ >+ Reviewed by NOBODY (OOPS!). >+ >+ This patch implements the boilerplate for all "-webkit-text-decoration*" >+ properties. There is a discussion whether "text-decoration" is inherited or not >+ at W3C specification (both CSS2.1 and CSS3 draft), so I'm assuming the same >+ behavior as the original "text-decoration". However, its shorthands are not >+ inherited and are treated as such. >+ >+ It is important to notice that this "-webkit" prefixed implementation does not >+ affect both original "text-decoration" (defined by CSS2.1 spec) and >+ "-webkit-text-decorations-in-effect" behaviors. >+ >+ The original "text-decoration" specification can be found here: >+ http://www.w3.org/TR/CSS21/text.html#propdef-text-decoration >+ >+ And working draft for "-webkit-text-decoration" can be found here: >+ http://www.w3.org/TR/css3-text/#text-decoration >+ >+ Proper implementation of -line, -style and -color are handled in separate bugs >+ (see bugs 91638, 90959 and 90958, respectively). >+ >+ * css/CSSComputedStyleDeclaration.cpp: >+ (WebCore::CSSComputedStyleDeclaration::getPropertyCSSValue): >+ * css/CSSParser.cpp: >+ (WebCore::CSSParser::parseValue): >+ * css/CSSProperty.cpp: >+ (WebCore::CSSProperty::isInheritedProperty): >+ * css/CSSPropertyNames.in: >+ * css/StylePropertyShorthand.cpp: >+ (WebCore::webkitTextDecorationShorthand): >+ (WebCore): >+ * css/StylePropertyShorthand.h: >+ (WebCore): >+ * css/StyleResolver.cpp: >+ (WebCore::StyleResolver::collectMatchingRulesForList): >+ > 2012-07-27 Dominik Röttsches <dominik.rottsches@intel.com> > > [Cairo] Add complex font drawing using HarfbuzzNG >diff --git a/Source/WebCore/css/CSSComputedStyleDeclaration.cpp b/Source/WebCore/css/CSSComputedStyleDeclaration.cpp >index ae248ed097f61d605346c705d6564e0b3d287b58..0da0ad70eeb110f24abb187dcc76b21762b9a2a6 100644 >--- a/Source/WebCore/css/CSSComputedStyleDeclaration.cpp >+++ b/Source/WebCore/css/CSSComputedStyleDeclaration.cpp >@@ -2434,6 +2434,10 @@ PassRefPtr<CSSValue> CSSComputedStyleDeclaration::getPropertyCSSValue(CSSPropert > break; > > /* Unimplemented CSS 3 properties (including CSS3 shorthand properties) */ >+ case CSSPropertyWebkitTextDecoration: >+ case CSSPropertyWebkitTextDecorationLine: >+ case CSSPropertyWebkitTextDecorationStyle: >+ case CSSPropertyWebkitTextDecorationColor: > case CSSPropertyWebkitTextEmphasis: > case CSSPropertyTextLineThrough: > case CSSPropertyTextLineThroughColor: >diff --git a/Source/WebCore/css/CSSParser.cpp b/Source/WebCore/css/CSSParser.cpp >index c3ff2ab57a3ccd1cee10e8c2e8fcaefa2fd8ce81..19842478d0a3f6cf1069aabf997f3f18212eefa5 100644 >--- a/Source/WebCore/css/CSSParser.cpp >+++ b/Source/WebCore/css/CSSParser.cpp >@@ -2092,6 +2092,12 @@ bool CSSParser::parseValue(CSSPropertyID propId, bool important) > break; > } > >+ case CSSPropertyWebkitTextDecoration: >+ // <text-decoration-line> || <text-decoration-style> || <text-decoration-color> || blink >+ if (id != CSSValueBlink) >+ return parseShorthand(propId, webkitTextDecorationShorthand(), important); >+ break; >+ > case CSSPropertyTextDecoration: > case CSSPropertyWebkitTextDecorationsInEffect: > // none | [ underline || overline || line-through || blink ] | inherit >diff --git a/Source/WebCore/css/CSSProperty.cpp b/Source/WebCore/css/CSSProperty.cpp >index 8c82dc65a564e3b7e1d0be1437a9bd8974f9efe5..00000b645ff02f9b660567023c2572a32a299638 100644 >--- a/Source/WebCore/css/CSSProperty.cpp >+++ b/Source/WebCore/css/CSSProperty.cpp >@@ -339,6 +339,7 @@ bool CSSProperty::isInheritedProperty(CSSPropertyID propertyID) > case CSSPropertyWebkitPrintColorAdjust: > case CSSPropertyWebkitRtlOrdering: > case CSSPropertyWebkitTextCombine: >+ case CSSPropertyWebkitTextDecoration: > case CSSPropertyWebkitTextDecorationsInEffect: > case CSSPropertyWebkitTextEmphasis: > case CSSPropertyWebkitTextEmphasisColor: >@@ -633,6 +634,9 @@ bool CSSProperty::isInheritedProperty(CSSPropertyID propertyID) > case CSSPropertyWebkitPerspectiveOrigin: > case CSSPropertyWebkitPerspectiveOriginX: > case CSSPropertyWebkitPerspectiveOriginY: >+ case CSSPropertyWebkitTextDecorationLine: >+ case CSSPropertyWebkitTextDecorationStyle: >+ case CSSPropertyWebkitTextDecorationColor: > case CSSPropertyWebkitTransform: > case CSSPropertyWebkitTransformOrigin: > case CSSPropertyWebkitTransformOriginX: >diff --git a/Source/WebCore/css/CSSPropertyNames.in b/Source/WebCore/css/CSSPropertyNames.in >index 547907efb92c15af03aa63f2561c54321304708f..1530c8333bb5339a1579e515db4563d5f0d68e03 100644 >--- a/Source/WebCore/css/CSSPropertyNames.in >+++ b/Source/WebCore/css/CSSPropertyNames.in >@@ -351,6 +351,10 @@ z-index > -webkit-rtl-ordering > -webkit-text-combine > -epub-text-combine = -webkit-text-combine >+-webkit-text-decoration >+-webkit-text-decoration-line >+-webkit-text-decoration-style >+-webkit-text-decoration-color > -webkit-text-decorations-in-effect > -webkit-text-emphasis > -epub-text-emphasis = -webkit-text-emphasis >diff --git a/Source/WebCore/css/StylePropertyShorthand.cpp b/Source/WebCore/css/StylePropertyShorthand.cpp >index 045bd24f095aed4226045b833d77d5686e487b91..86c47a3c93196061d204679e1cf85aa50c8258c0 100644 >--- a/Source/WebCore/css/StylePropertyShorthand.cpp >+++ b/Source/WebCore/css/StylePropertyShorthand.cpp >@@ -383,6 +383,17 @@ const StylePropertyShorthand& webkitTextEmphasisShorthand() > return webkitTextEmphasisLonghands; > } > >+const StylePropertyShorthand& webkitTextDecorationShorthand() >+{ >+ static const CSSPropertyID textDecorationProperties[] = { >+ CSSPropertyWebkitTextDecorationLine, >+ CSSPropertyWebkitTextDecorationStyle, >+ CSSPropertyWebkitTextDecorationColor >+ }; >+ DEFINE_STATIC_LOCAL(StylePropertyShorthand, webkitTextDecorationLonghands, (textDecorationProperties, WTF_ARRAY_LENGTH(textDecorationProperties))); >+ return webkitTextDecorationLonghands; >+} >+ > const StylePropertyShorthand& webkitTextStrokeShorthand() > { > static const CSSPropertyID textStrokeProperties[] = { CSSPropertyWebkitTextStrokeWidth, CSSPropertyWebkitTextStrokeColor }; >diff --git a/Source/WebCore/css/StylePropertyShorthand.h b/Source/WebCore/css/StylePropertyShorthand.h >index ee331c732a6866176ed6597c5951b6e0937ae0c0..f4bd618247072c9b7c441f09df4eab6d6ee831d5 100644 >--- a/Source/WebCore/css/StylePropertyShorthand.h >+++ b/Source/WebCore/css/StylePropertyShorthand.h >@@ -96,6 +96,7 @@ const StylePropertyShorthand& webkitMaskShorthand(); > const StylePropertyShorthand& webkitMaskPositionShorthand(); > const StylePropertyShorthand& webkitMaskRepeatShorthand(); > const StylePropertyShorthand& webkitTextEmphasisShorthand(); >+const StylePropertyShorthand& webkitTextDecorationShorthand(); > const StylePropertyShorthand& webkitTextStrokeShorthand(); > const StylePropertyShorthand& webkitTransitionShorthand(); > const StylePropertyShorthand& webkitTransformOriginShorthand(); >diff --git a/Source/WebCore/css/StyleResolver.cpp b/Source/WebCore/css/StyleResolver.cpp >index 92b925ca2a1d115284fee4509cce8f92e948d221..a1f197588477b1fb9589d55612feb0c449bc481f 100644 >--- a/Source/WebCore/css/StyleResolver.cpp >+++ b/Source/WebCore/css/StyleResolver.cpp >@@ -4065,6 +4065,7 @@ void StyleResolver::applyProperty(CSSPropertyID id, CSSValue* value) > case CSSPropertyWebkitFontSizeDelta: > case CSSPropertyWebkitTextDecorationsInEffect: > case CSSPropertyWebkitTextStroke: >+ case CSSPropertyWebkitTextDecoration: > case CSSPropertyWebkitTextEmphasis: > return; > >@@ -4391,6 +4392,9 @@ void StyleResolver::applyProperty(CSSPropertyID id, CSSValue* value) > #endif > case CSSPropertyWebkitRtlOrdering: > case CSSPropertyWebkitTextCombine: >+ case CSSPropertyWebkitTextDecorationLine: >+ case CSSPropertyWebkitTextDecorationStyle: >+ case CSSPropertyWebkitTextDecorationColor: > case CSSPropertyWebkitTextEmphasisColor: > case CSSPropertyWebkitTextEmphasisPosition: > case CSSPropertyWebkitTextEmphasisStyle:
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Formatted Diff
|
Diff
Attachments on
bug 92000
:
153811
|
155021
|
155146
|
157234
|
158833
|
159137
|
159170
|
161695
|
161702
|
170667
|
170972
|
171241
|
179064
|
193065
|
204163
|
204164
|
204165
|
204166
|
204338
|
206613
|
206619
|
209114