Chromium Code Reviews
Help | Chromium Project | Gerrit Changes | Sign in
(13)

Issue 1173663003: BoxBorderPainter should use computed color alpha (Closed)

Created:
4 years, 10 months ago by f(malita)
Modified:
4 years, 10 months ago
Reviewers:
chrishtr, pdr., fs
CC:
blink-reviews, blink-reviews-paint_chromium.org, blink-reviews-style_chromium.org, dshwang, slimming-paint-reviews_chromium.org
Target Ref:
refs/heads/master
Project:
blink
Visibility:
Public.

Description

BoxBorderPainter should use computed color alpha BoxBorderPainter makes paint-time transparency decisions based on the BorderEdge::isTransparent field, which is initialized using BorderValue::isTransparent() logic. But BorderValue::isTransparent() doesn't return accurate results for 'currentColor' border color values (style not fully resolved?), so we can end up with BorderEdges for which isTransparent == false && color.alpha() == 0. This breaks BoxBorderPainter's invariants. Since BorderEdge is used for painting purposes, tracking an explicit isTransparent attribute is redundant to start with: we already have a fully resolved color. Let's just kill this shady isTransparent thing. R=fs@opera.com,chrishtr@chromium.org,pdr@chromium.org BUG=498673 Committed: https://src.chromium.org/viewvc/blink?view=rev&revision=196886

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+28 lines, -15 lines) Patch
A LayoutTests/fast/borders/transparent-currentcolor-crash.html View 1 chunk +22 lines, -0 lines 0 comments Download
A + LayoutTests/fast/borders/transparent-currentcolor-crash-expected.txt View 0 chunks +-1 lines, --1 lines 0 comments Download
M Source/core/paint/BoxBorderPainter.cpp View 1 chunk +2 lines, -0 lines 0 comments Download
M Source/core/style/BorderEdge.h View 2 chunks +1 line, -2 lines 0 comments Download
M Source/core/style/BorderEdge.cpp View 5 chunks +4 lines, -6 lines 0 comments Download
M Source/core/style/ComputedStyle.h View 1 chunk +0 lines, -4 lines 0 comments Download
M Source/core/style/ComputedStyle.cpp View 1 chunk +0 lines, -4 lines 0 comments Download

Messages

Total messages: 5 (1 generated)
f(malita)
The reason why isTransparent is unreliable: https://code.google.com/p/chromium/codesearch#chromium/src/third_party/WebKit/Source/core/style/BorderValue.h&l=53
4 years, 10 months ago (2015-06-10 16:05:57 UTC) #1
chrishtr
lgtm
4 years, 10 months ago (2015-06-10 18:01:16 UTC) #3
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-cq-status.appspot.com/patch-status/1173663003/1
4 years, 10 months ago (2015-06-10 18:01:34 UTC) #4
commit-bot: I haz the power
4 years, 10 months ago (2015-06-10 18:04:42 UTC) #5
Message was sent while issue was closed.
Committed patchset #1 (id:1) as
https://src.chromium.org/viewvc/blink?view=rev&revision=196886

Powered by Google App Engine
This is Rietveld 408576698