[css3-text] Placement of letter-spacing (was: Couple of word-spacing issues)

On Thu, 29 Sep 2011 22:27:11 +0200, fantasai  
<fantasai.lists@inkedblade.net> wrote:

>> (though the behavior specified in css3-text seems a bit strange and  
>> underdefined
>> and deviates from current implementations).
>
> Not sure I follow?

OK, I'm starting a new thread since this is a new issue and not about  
word-spacing.

http://dev.w3.org/csswg/css3-text/#letter-spacing
"At element boundaries, the letter spacing is given by and rendered within  
the innermost element that /contains/ the boundary."

I guess what I found a bit strange was mainly that the spacing between two  
characters belonging to two separate element could depend on the  
properties of a third element. E.g. between "d" and "e" in example XIII.

Current implementations show spacing after "b" within the first box here:

<style>span { border: 1px solid; letter-spacing: 1em }</style>
<div><span>ab</span><span>cd</span></div>

(They actually also show spacing after "d", even though that's "at the end  
of a line".) Don't know how much this matters for compatibility though.

<div><span>ab</span><span></span><span>cd</span></div>

But now what? Between "b" and "c" there are now /two/ boundaries that are  
contained by the div.

-- 
Øyvind Stenhaug
Core Norway, Opera Software ASA

Received on Friday, 30 September 2011 10:31:58 UTC