Re: [css-syntax] Defining "character"

Le 12/08/2013 15:16, Bjoern Hoehrmann a écrit :
> * Simon Sapin wrote:
>> 2. Have a normative definition near the beginning like this: "Within
>> this specification, the ambiguous term <dfn>character</dfn> is used as a
>> friendlier synonym for Unicode code point." This is what CSS Text does,
>> except that there "character" means grapheme cluster rather than code point.
>
> The term is not ambiguous if it is normatively defined. Do note that the
> surrogate code points are code points; if you do not want to include the
> surrogate code points, the term to use is usually Unicode Scalar Value.

I think it would be the right thing to do, but unfortunately it is 
possible to inject (CSS-unescaped) surrogates into CSS though JavaScript:


data:text/html,<style>body:before{}</style><script>document.styleSheets[0].cssRules[0].style.content="'-\ud834\udd1e-'"</script>


data:text/html,<style>body:before{}</style><script>document.styleSheets[0].cssRules[0].style.content="'-\ud834-\udd1e-'"</script>


-- 
Simon Sapin

Received on Monday, 12 August 2013 14:36:16 UTC