Bug 100119

Summary: Web Inspector: [Styles] Handle non-parsedOk properties as inactive ones
Product: WebKit Reporter: Alexander Pavlov (apavlov) <apavlov>
Component: Web Inspector (Deprecated)Assignee: Alexander Pavlov (apavlov) <apavlov>
Status: RESOLVED FIXED    
Severity: Normal CC: apavlov, joepeck, keishi, loislo, pfeldman, pmuellr, timothy, vsevik, web-inspector-bugs, webkit.review.bot, yurys
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: All   
OS: All   
Attachments:
Description Flags
Patch
none
Patch
none
Patch
none
Patch for landing none

Description Alexander Pavlov (apavlov) 2012-10-23 06:48:12 PDT
This will help fix the display of matched and computed styles.

Patch to follow.
Comment 1 Alexander Pavlov (apavlov) 2012-10-23 07:08:36 PDT
For this snippet:

body {
  text-align: left;
  text-align: bar;
  text-align: justify;
}

"text-align: bar" is non-parsedOk (has an exclamation mark) but does not have a strike-through.

Also, all of these properties will be shown as active in the computed trace, hence the user confusion.
Comment 2 Alexander Pavlov (apavlov) 2012-10-23 07:15:17 PDT
Created attachment 170156 [details]
Patch
Comment 3 Pavel Feldman 2012-10-23 08:41:26 PDT
Comment on attachment 170156 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=170156&action=review

> Source/WebCore/inspector/InspectorStyleSheet.cpp:533
> +                    CSSPropertyID propertyId = cssPropertyID(name);

We already have this code on the front-end, why having it here as well?
Comment 4 Alexander Pavlov (apavlov) 2012-10-24 03:04:21 PDT
As agreed offline, this change will be coded in the front-end instead.
Comment 5 Alexander Pavlov (apavlov) 2012-10-24 03:14:32 PDT
Created attachment 170354 [details]
Patch
Comment 6 Alexander Pavlov (apavlov) 2012-10-26 08:22:55 PDT
Created attachment 170932 [details]
Patch
Comment 7 Vsevolod Vlasov 2012-10-26 08:28:46 PDT
Comment on attachment 170932 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=170932&action=review

> Source/WebCore/inspector/front-end/StylesSidebarPane.js:1465
> +                    if (property.inactive || !property.parsedOk || section.isPropertyOverloaded(property.name))

I would add not-parsed-ok class to the rule that is setting line-through decoration instead.

> Source/WebCore/inspector/front-end/StylesSidebarPane.js:1955
> +        if (this.property.inactive || !this.parsedOk)

ditto
Comment 8 Alexander Pavlov (apavlov) 2012-10-29 00:51:07 PDT
Created attachment 171170 [details]
Patch for landing
Comment 9 WebKit Review Bot 2012-10-29 01:30:56 PDT
Comment on attachment 171170 [details]
Patch for landing

Clearing flags on attachment: 171170

Committed r132768: <http://trac.webkit.org/changeset/132768>
Comment 10 WebKit Review Bot 2012-10-29 01:31:00 PDT
All reviewed patches have been landed.  Closing bug.