Bug 125261 - Web Inspector: use only two decimals for opacity in rgba/hsla colors
Summary: Web Inspector: use only two decimals for opacity in rgba/hsla colors
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Web Inspector (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Antoine Quint
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-12-04 15:28 PST by Antoine Quint
Modified: 2013-12-04 16:14 PST (History)
5 users (show)

See Also:


Attachments
Patch (1.65 KB, patch)
2013-12-04 15:30 PST, Antoine Quint
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Antoine Quint 2013-12-04 15:28:36 PST
There is no need to serialize colors to use anything more accurate than two decimals for the alpha channel.
Comment 1 Antoine Quint 2013-12-04 15:30:04 PST
Created attachment 218465 [details]
Patch
Comment 2 Joseph Pecoraro 2013-12-04 15:45:58 PST
Comment on attachment 218465 [details]
Patch

r=me. I assume you didn't use Number.prototype.toFixed because that doesn't conveniently with non-floats. (e.g. 1.toFixed(2))
Comment 3 Antoine Quint 2013-12-04 15:51:58 PST
(In reply to comment #2)
> (From update of attachment 218465 [details])
> r=me. I assume you didn't use Number.prototype.toFixed because that doesn't conveniently with non-floats. (e.g. 1.toFixed(2))

That's right, I wanted 1.1 to display as 1.1 and not 1.10.
Comment 4 WebKit Commit Bot 2013-12-04 16:14:30 PST
Comment on attachment 218465 [details]
Patch

Clearing flags on attachment: 218465

Committed r160142: <http://trac.webkit.org/changeset/160142>
Comment 5 WebKit Commit Bot 2013-12-04 16:14:32 PST
All reviewed patches have been landed.  Closing bug.