W3C home > Mailing lists > Public > www-style@w3.org > February 2013

Re: [css3-exclusions] Resolving shape-inside for inline content

From: Bear Travis <betravis@adobe.com>
Date: Mon, 25 Feb 2013 10:53:02 -0800
To: Mihnea-Vlad Ovidenie <mihnea@adobe.com>
CC: "www-style@w3.org" <www-style@w3.org>, Alan Stearns <stearns@adobe.com>, Zoltan Horvath <zhorvath@adobe.com>, Bem Jones-Bey <bjonesbe@adobe.com>, Hans Muller <hmuller@adobe.com>
Message-ID: <CD50F104.1AE20%betravis@adobe.com>
Hi Mihnea,

I think the intersection of the shapes is a valid approach. What I do wonder is if this is more of a use case, or an error/edge case. If the latter, it might be more useful to define something simple (like only 1 shape inside at a time), if the former, then the intersection behavior may be more desirable.

-Bear

From: Mihnea-Vlad Ovidenie <mihnea@adobe.com<mailto:mihnea@adobe.com>>
Date: Monday, February 25, 2013 7:01 AM
To: Bear Travis <betravis@adobe.com<mailto:betravis@adobe.com>>
Cc: "www-style@w3.org<mailto:www-style@w3.org>" <www-style@w3.org<mailto:www-style@w3.org>>, Alan Stearns <stearns@adobe.com<mailto:stearns@adobe.com>>, Zoltan Horvath <zhorvath@adobe.com<mailto:zhorvath@adobe.com>>, Bem Jones-Bey <bjonesbe@adobe.com<mailto:bjonesbe@adobe.com>>, Hans Muller <hmuller@adobe.com<mailto:hmuller@adobe.com>>
Subject: Re: [css3-exclusions] Resolving shape-inside for inline content

Hi Bear,

On Feb 22, 2013, at 12:27 PM, Bear Travis <betravis@adobe.com<mailto:betravis@adobe.com>> wrote:

Hi All,

I'm trying to understand which shape-inside should be used when there are multiple shapes applied to the content.

As I understand it, a shape-inside on a block can affect all descendant inline content. A common example would be:
<div style='shape-inside: circle(50%, 50%, 50%)'>
  <p>text</p>
  <p>text</p>
</div>

I couldn't find the exact wording, but I believe these [1][2] are the relevant areas of the specification.

My question is, if child blocks also have a shape-inside set (the paragraphs in the above example), which shape-inside should be used? To me, it seems like the shape-inside from the most immediate ancestor should be used.


I would expect to use an intersection between the shapes, in this case the intersection between the shape defined on the outer div (circle) and the shape defined on the first paragraph.
Is the above option worth considering from your point of view?

This also comes into play when shape-inside is set on regions. For example, if the flow content and region both have a shape-inside set, which should be respected? The flow content shape-inside seems like the most immediate to me in this case.

Both of these are probably edge cases, but it would be useful to understand the expected behavior.

-Bear

[1] http://dev.w3.org/csswg/css3-exclusions/#declaring-shapes
[2] http://dev.w3.org/csswg/css3-exclusions/#shape-inside-property

Cheers,
Mihnea
Received on Monday, 25 February 2013 18:53:29 GMT

This archive was generated by hypermail 2.3.1 : Tuesday, 26 March 2013 17:21:06 GMT