Bug 119809

Summary: [CSS Shapes] Add support for shape-outside image values
Product: WebKit Reporter: Hans Muller <giles_joplin>
Component: CSSAssignee: Hans Muller <giles_joplin>
Status: RESOLVED FIXED    
Severity: Normal CC: commit-queue, esprehn+autocc, glenn, kondapallykalyan
Priority: P2    
Version: 528+ (Nightly build)   
Hardware: Unspecified   
OS: Unspecified   
Bug Depends on:    
Bug Blocks: 116348    
Attachments:
Description Flags
Patch
achicu: review+
Patch. none

Description Hans Muller 2013-08-14 11:49:01 PDT
See http://dev.w3.org/csswg/css-shapes/#shapes-from-image
Comment 1 Hans Muller 2013-08-14 17:40:41 PDT
Created attachment 208777 [details]
Patch

Added minimal support for shape-outside image values. A new method that computes the excluded intervals for a horizontal line segment was added to the RasterIntervals class. The stub RasterShape getExcludedIntervals() method has been replaced by one that uses the new method.

Image shapes are represented by a RasterIntervals object, which just encapsulates a Region object. The new getExcludedIntervals() method computes the excluded intervals for a horizontal line segment between y1 and y2. To find the excluded intervals we vertically expand each of the image shape Region's rectangles that fall within the line  segment, so that they begin at y1 and have height = y2 - y1. The union of the expanded rectangles produces a new Region whose horizontal projection defines the excluded intervals.
Comment 2 Alexandru Chiculita 2013-08-15 12:32:12 PDT
Comment on attachment 208777 [details]
Patch

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

r=me

> LayoutTests/fast/shapes/shape-outside-floats/shape-outside-floats-image-001-expected.html:24
> +  <div id="content">

nit: this node doesn't end. This repeats in all the html files.
Comment 3 Hans Muller 2013-08-15 12:39:25 PDT
Created attachment 208839 [details]
Patch.

Corrected the tests.
Comment 4 WebKit Commit Bot 2013-08-15 16:44:26 PDT
The commit-queue encountered the following flaky tests while processing attachment 208839 [details]:

http/tests/navigation/ping-cross-origin-from-https.html bug 51314 (authors: japhet@chromium.org and rniwa@webkit.org)
The commit-queue is continuing to process your patch.
Comment 5 WebKit Commit Bot 2013-08-15 16:46:15 PDT
Comment on attachment 208839 [details]
Patch.

Clearing flags on attachment: 208839

Committed r154152: <http://trac.webkit.org/changeset/154152>
Comment 6 WebKit Commit Bot 2013-08-15 16:46:17 PDT
All reviewed patches have been landed.  Closing bug.