Bug 16318

Summary: Insufficient repaint issues with html embedded in foreignObject
Product: WebKit Reporter: Oliver Hunt <oliver>
Component: SVGAssignee: Nobody <webkit-unassigned>
Status: RESOLVED FIXED    
Severity: Major CC: bdakin, eric, krit, zimmermann
Priority: P2 Keywords: InRadar
Version: 528+ (Nightly build)   
Hardware: Mac   
OS: All   
URL: http://starkravingfinkle.org/blog/wp-content/uploads/2007/07/foreignobject-text.svg
Attachments:
Description Flags
Patch
none
Patch
none
Patch mitz: review+

Description Oliver Hunt 2007-12-05 20:48:30 PST
If you play around with the selected text in the linked example there are frequent repaint errors
Comment 1 David Kilzer (:ddkilzer) 2007-12-06 08:18:51 PST
<rdar://problem/5632991>
Comment 2 Eric Seidel (no email) 2007-12-15 03:00:38 PST
I think the way to fix this is to implement a
bool RenderSVGBlock::absolutePosition(int& xPos, int& yPos, bool fixed) const
function which is absoluteTransform() aware.

Comment 3 Oliver Hunt 2010-01-20 13:06:30 PST
Created attachment 47055 [details]
Patch
Comment 4 Eric Seidel (no email) 2010-01-20 13:34:24 PST
Yay!  Thanks for fixing.
Comment 5 Oliver Hunt 2010-01-20 13:37:25 PST
Committed r53561: <http://trac.webkit.org/changeset/53561>
Comment 6 Oliver Hunt 2010-01-20 13:38:10 PST
Committed r53561 -- only partial fix, selection for list markers is still borked
Comment 7 Oliver Hunt 2010-01-20 13:50:11 PST
Committed r53562: <http://trac.webkit.org/changeset/53562>
Comment 8 Oliver Hunt 2010-01-20 16:26:27 PST
Created attachment 47076 [details]
Patch
Comment 9 Oliver Hunt 2010-01-20 20:45:20 PST
Created attachment 47096 [details]
Patch
Comment 10 mitz 2010-01-20 21:00:32 PST
Comment on attachment 47096 [details]
Patch

> +IntRect RenderListMarker::localSelectionRect()
> +{
> +    InlineBox* box = inlineBoxWrapper();
> +    if (!box)
> +        return IntRect();
> +    RootInlineBox* root = box->root();
> +    if (!root)
> +        return IntRect();

No need to null-check root.

> +    IntRect localSelectionRect();

You should use this new function in selectionRectForRepaint() too instead of having duplicated code.

r=me but please do ^ if possible.
Comment 11 Oliver Hunt 2010-01-20 21:36:51 PST
Committed r53603: <http://trac.webkit.org/changeset/53603>