Re: [CSS21] Question on section 9.5.1 Positioning float: error in sentence

Le Dim 27 novembre 2011 6:46, Anton Prowse a écrit :
> On 08/11/2011 18:20, "Gérard Talbot" wrote:
>> Le Mar 8 novembre 2011 5:24, Anton Prowse a écrit :
>>> On 08/11/2011 01:55, "Gérard Talbot" wrote:
>>>> I've read the following sentence at least 20 times and I think there's
>>>> several small mistakes which can compromise comprehension.
>>>>
>>>> "
>>>> But in CSS 2.1, if, within the block formatting context, there is an
>>>> in-flow negative vertical margin such that the float's position is
>>>> above
>>>> the position it would be at were all such negative margins set to
>>>> zero,
>>>> the position of the float is undefined.
>>>> "
>>>> http://www.w3.org/TR/CSS21/visuren.html#floats
>>>>
>>>> I think such sentence should be stating instead
>>>>
>>>> "
>>>> But, in CSS 2.1, if, within the block formatting context, there is an
>>>> in-flow negative vertical margin such that the float's position is
>>>> above
>>>> the position it would be at if such negative vertical margin was set
>>>> to
>>>> zero, then the position of the float is undefined.
>>>> "
>>>
>
>>> Secondly, I think the sentence in the spec is a little strange but it's
>>> grammatically OK.  If "there is an" were replaced with "there is one or
>>> more" then the intent would be completely clear.
>>
>> I have read such sentence again (along with your explanation) and still
>> do
>> not feel that ordinary web authors are going to understand it like you
>> interpret it.
>
> I originally thought you were taking issue with the grammar of this
> sentence.  On reading your response and your original post again, I
> think you're actually asking what the sentence means conceptually. Sorry
> for misunderstanding you.

Anton :)

It's eventually both. If the sentence is long, tortuous, grammatically
difficult to figure out, then it affects the understanding of it, its
conceptual basis.

A testcase, I feel, always helps (or should always help) to illustrate the
issue, the relations involved in a sentence like that.

Issue 229: Floats effect on lines above placeholder
http://www.gtalbot.org/BrowserBugsSection/css21testsuite/testcase-for-issue-229.html


> I agree with you that the sentence doesn't work, editorially speaking. I
> raised this as a concern[1] on Issue 229.


Floats effect on lines above placeholder
http://wiki.csswg.org/spec/css2.1#issue-229


> If it intends to say that the
> position of a float is undefined when a source-preceding box has a
> negative vertical margin, then it should just say something like that.
> If, instead, it's trying to restrict the vertical margins under
> consideration in order to focus more closely on the specific issues of
> Issue 229 then it's flawed because it doesn't solve the problem as
> currently written.  (When the position of the float is calculated with
> the specified negative margins then at least Rule 6 needs to be ignored.)
>
> This will definitely need cleaning up in CSS3.
>
> [1] http://lists.w3.org/Archives/Public/www-style/2011Mar/0403.html


Anton,

Yes, I think you're right. It was trying to restrict negative margins in
such case but it was "fixed" with an "undefined" ruling call (which is
sort of a no-call) in CSS 2.1 and by "punting" this issue into CSS3
territory.

Gérard Talbot
-- 
CSS 2.1 Test suite RC6, March 23rd 2011
http://test.csswg.org/suites/css2.1/20110323/html4/toc.html

Contributions to CSS 2.1 test suite
http://www.gtalbot.org/BrowserBugsSection/css21testsuite/

Web authors' contributions to CSS 2.1 test suite
http://www.gtalbot.org/BrowserBugsSection/css21testsuite/web-authors-contributions-css21-testsuite.html

Received on Sunday, 27 November 2011 17:47:10 UTC