[webkit-reviews] review requested: [Bug 6831] contentEditable outline darkens as caret moves : [Attachment 6386] better patch

bugzilla-request-daemon at opendarwin.org bugzilla-request-daemon at opendarwin.org
Fri Feb 10 05:54:49 PST 2006

Graham Dennis <Graham.Dennis at gmail.com> has asked Justin Garcia
<justin.garcia at apple.com> for review:
Bug 6831: contentEditable outline darkens as caret moves

Attachment 6386: better patch

------- Additional Comments from Graham Dennis <Graham.Dennis at gmail.com>
The correct way to fix this bug is to fix WebClipView and WKSetFocusRingStyle.
WKSetFocusRingStyle is a private function in libWebKitSystemInterface.a, but I
think I've managed to figure out how it works. The problem appears to be that
when the focus ring is drawn, WKSetFocusRingStyle sets the clip for the focus
ring to be the minimum enclosing rectangle for all the dirty rects. So the fix
is to set the focus ring clip for each of the dirty rects and draw the focus
ring for each dirty rect. To do this, I had to modify WKSetFocusRingStyle to
actually draw the focus ring, a function I have now called WKDrawFocusRing. At
the moment, the function is sitting in WebClipView.m, but as it calls private
AppKit and CoreGraphics code, it should probably be put into the
libWebKitSystemInterface.a file.

Some of the code in WKDrawFocusRing will need to be fixed as I didn't have some
of the function definitions or structure definitions needed. The patch does
work in its present state. I will attach my functionally equivalent source for
WKSetFocusRingStyle for comparison.

More information about the webkit-reviews mailing list