Bug 63161 - Canvas in layer obscures overlapping span
Summary: Canvas in layer obscures overlapping span
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Canvas (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Matthew Delaney
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-06-22 11:29 PDT by Matthew Delaney
Modified: 2011-06-22 13:39 PDT (History)
2 users (show)

See Also:


Attachments
Patch (23.65 KB, patch)
2011-06-22 11:36 PDT, Matthew Delaney
no flags Details | Formatted Diff | Diff
Patch (19.64 KB, patch)
2011-06-22 12:34 PDT, Matthew Delaney
no flags Details | Formatted Diff | Diff
Patch (19.68 KB, patch)
2011-06-22 12:38 PDT, Matthew Delaney
no flags Details | Formatted Diff | Diff
Patch (19.92 KB, patch)
2011-06-22 13:24 PDT, Matthew Delaney
no flags Details | Formatted Diff | Diff
Patch (19.76 KB, patch)
2011-06-22 13:37 PDT, Matthew Delaney
oliver: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Matthew Delaney 2011-06-22 11:29:41 PDT
I'm attaching a patch with accompanying testcase that should show the span atop the canvas. Without the patch, if the canvas is in its own compositing layer then it will be incorrectly rendered atop the span.
Comment 1 Matthew Delaney 2011-06-22 11:36:02 PDT
Created attachment 98208 [details]
Patch
Comment 2 Simon Fraser (smfr) 2011-06-22 11:41:07 PDT
Comment on attachment 98208 [details]
Patch

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

> LayoutTests/compositing/layer-creation/spanOverlapsCanvas.html:34
> +    html, body {
> +    	width: 480px;
> +    	height: 640px;
> +    }
> +    body {
> +    	margin :0px;
> +    	padding: 0px;
> +    }
> +    #headerbar {
> +    	width: 200px;
> +    	height: 40px;
> +    	background-color: #333333;
> +    	position: absolute;
> +    }
> +    #testaction {
> +    	color: #FFFFFF;
> +    }

This CSS is weirdly indented.

> LayoutTests/compositing/layer-creation/spanOverlapsCanvas.html:38
> +	<div id="headerbar"><span id='testlabel'></span><span id='testaction'>This text should be visible.</a></div>

Please avoid text in the pixel output.

Also, avoid scrollbars in the pixel output.

I also think this could use layerTreeAsText(). However, you'll have to deal with different platforms having different results.
Comment 3 Matthew Delaney 2011-06-22 12:34:30 PDT
Created attachment 98214 [details]
Patch
Comment 4 Matthew Delaney 2011-06-22 12:37:06 PDT
Uggh, CSS is still junky indented. Fixing again now.
Comment 5 Matthew Delaney 2011-06-22 12:38:44 PDT
Created attachment 98218 [details]
Patch
Comment 6 Simon Fraser (smfr) 2011-06-22 13:05:47 PDT
Comment on attachment 98218 [details]
Patch

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

> LayoutTests/compositing/layer-creation/spanOverlapsCanvas.html:25
> +            background-color: #FF0000;

Please use green, not red (and use names, not hex values for common colors).
Comment 7 Matthew Delaney 2011-06-22 13:24:06 PDT
Created attachment 98229 [details]
Patch
Comment 8 Matthew Delaney 2011-06-22 13:28:32 PDT
Read that comment on color values backwards - definitely need more sleep...New patch it a second.
Comment 9 Matthew Delaney 2011-06-22 13:37:11 PDT
Created attachment 98232 [details]
Patch
Comment 10 Matthew Delaney 2011-06-22 13:39:05 PDT
Committed r89474: <http://trac.webkit.org/changeset/89474>