Bug 125224 - [CSS Shapes] Shape images are now <image> types, not just URIs
Summary: [CSS Shapes] Shape images are now <image> types, not just URIs
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: CSS (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Hans Muller
URL:
Keywords:
Depends on:
Blocks: 124173
  Show dependency treegraph
 
Reported: 2013-12-04 08:08 PST by Hans Muller
Modified: 2014-01-14 10:12 PST (History)
17 users (show)

See Also:


Attachments
Patch (14.76 KB, patch)
2013-12-05 12:25 PST, Hans Muller
no flags Details | Formatted Diff | Diff
Patch (14.80 KB, patch)
2014-01-07 16:16 PST, Hans Muller
kling: review+
Details | Formatted Diff | Diff
Patch (16.79 KB, patch)
2014-01-14 09:41 PST, Hans Muller
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Hans Muller 2013-12-04 08:08:13 PST
The Shapes specification now defines shape-inside and shape-outside image values as <image> types, instead of just URIs.  See:

http://dev.w3.org/csswg/css-shapes/#shapes-from-image
http://dev.w3.org/csswg/css-images-3/#image-types
Comment 1 Hans Muller 2013-12-05 12:25:23 PST
Created attachment 218532 [details]
Patch

Added support for image-set valued shapes. Added an optional ResourceLoaderOptions parameter to CSSImageSetValue::cachedImageSet() to enable CORS-enabled fetch of images. This change is based on a similar patch for ordinary shape image values: https://bugs.webkit.org/show_bug.cgi?id=123114.
Comment 2 Andreas Kling 2013-12-19 09:41:54 PST
I'm not really sure who's the best person to review this patch. CC'ing a couple of candidates.
Comment 3 Hans Muller 2014-01-07 16:16:22 PST
Created attachment 220566 [details]
Patch

Resync'd with trunk.
Comment 4 Andreas Kling 2014-01-13 23:47:44 PST
Comment on attachment 220566 [details]
Patch

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

r=me

> LayoutTests/fast/shapes/shape-outside-floats/shape-outside-image-set.html:7
> +        /* The shape-outisde image's width is smaller than the float's width (120 < 150) to make it

Typo, shape-outside.

> Source/WebCore/rendering/shapes/Shape.cpp:256
> -    ASSERT(styleImage && styleImage->isCachedImage() && styleImage->cachedImage() && styleImage->cachedImage()->image());
> +    ASSERT(styleImage && styleImage->cachedImage() && styleImage->cachedImage()->hasImage());

These should be broken into separate assertions so you can immediately tell what went wrong.
It'd also be nicer if 'styleImage' were a reference, since we don't support it being null.
Comment 5 Hans Muller 2014-01-14 09:41:11 PST
Created attachment 221171 [details]
Patch

Made the suggested changes.
Comment 6 WebKit Commit Bot 2014-01-14 10:12:34 PST
Comment on attachment 221171 [details]
Patch

Clearing flags on attachment: 221171

Committed r161980: <http://trac.webkit.org/changeset/161980>
Comment 7 WebKit Commit Bot 2014-01-14 10:12:41 PST
All reviewed patches have been landed.  Closing bug.