[Webkit-unassigned] [Bug 149843] Backgrounds bleed out of natively rendered text fields

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Thu Oct 8 09:12:44 PDT 2015


https://bugs.webkit.org/show_bug.cgi?id=149843

--- Comment #4 from Said Abou-Hallawa <sabouhallawa at apple.com> ---
Comment on attachment 262666
  --> https://bugs.webkit.org/attachment.cgi?id=262666
Patch

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

> Source/WebCore/rendering/RenderBox.cpp:1336
> +    paintFillLayers(paintInfo, style().visitedDependentColor(CSSPropertyBackgroundColor), style().backgroundLayers(), adjustedBackgroundPaintRect(paintInfo.context(), paintRect), bleedAvoidance);

Should not we make paintBackground() itself virtual and make RenderTextControlSingleLine overrides it? I think RenderTextControlSingleLine:: paintBackground() will only have to make a copy of paintRect, adjust it using shrinkRectByOneDevicePixel() and then call the base class function paintBackground(). I think this approach is clearer since the sequence of calls goes from the derived class "RenderTextControlSingleLine::paintBackground()" to the base class "RenderBox::paintBackground()".  Your approach actually flows from the base class "RenderBox::paintBackground()" to the derived class "RenderTextControlSingleLine::adjustedBackgroundPaintRect" and then back to the base class again "RenderBox::paintBackground()"."RenderBox::paintBackground()".

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.webkit.org/pipermail/webkit-unassigned/attachments/20151008/ac2b8fa0/attachment-0001.html>


More information about the webkit-unassigned mailing list