- From: Peter Moulder <peter.moulder@monash.edu>
- Date: Fri, 08 Oct 2010 08:57:00 +1100
- To: www-style list <www-style@w3.org>
On Thu, Oct 07, 2010 at 08:26:41AM -0700, Simon Fraser wrote: > I made a change last night in WebKit to have a run of > <whitespace><punc>character<whitespace><punc> be treated as :first-letter > (where <whitespace> includes non-breaking spaces, and <punc> is the > categories noted in the spec). > > An issue I did not handle is how newlines in that whitespace are treated, > particularly if "white-space: pre" is applied. I think Simon means "A bug I did not correct", but I'll be explicit just in case: the spec seems quite clear that :first-letter must only select the first letter on the first line. (E.g. "The first letter must occur on the first formatted line." and the example in the same paragraph.) The spec is not clear whether any selected following punctuation must be on the first line or not, and a literal reading might be that the following punctuation is not required to be on the first line. For that matter, a literal reading of the spec is that all following punctuation should be included, whether or not preceded by non-selected characters. I propose that it be made clear that it's restricted to the first line, and only include *immediately* following punctuation (or punctuation and Unicode whitespace characters, if we so decide; but presumably excluding any whitespace after the last selected non-whitespace character). I've already indicated some misgivings about including following punctuation, in that Le Monde seems not to include following apostrophes in first-letter styling. A hypothetical (though I expect rare) example where we really don't want to include following punctuation after space is if that following punctuation is an opening bracket of some kind. A hyphen or dash should also not be selected (though selecting would not as harmful as in the opening parenthesis example). This counts as a (weak, assuming the harmful cases are rare) argument not to allow whitespace after the first letter/digit when deciding how much to select. I would expect existing practice not to include the closing ‘»’ in first-letter styling in languages that space their quotation marks. Take that with a grain of salt given that I'm an English speaker, but it does seem that stylized huge guillemets in French (when quoting a whole speech for example) are more likely to be on a separate line than the corresponding huge quotation marks one sometimes sees in English (which are more likely to be placed such that the block of quoted text appears roughly where a same-size-as-the-quotation-marks letter would appear). pjrm.
Received on Thursday, 7 October 2010 21:57:32 UTC