Re: list-item alignment in CSS

Thanks for the comments, Hakon. I've incorporated your suggestions
except...

> I'd say: "The background of the list-item marker should be that
> of the UL element, not the LI element."

What if the list-item marker hangs to the left of the UL element's
background or straddles the edge?

How about: "The background of the list-item marker should be
transparent such that the background of the underlying element shows
through."

As revised:
<LI>The left edge of this text block should be 40 pixels to the right
of the preceding paragraph's left edge because the paragraph has a left
margin of 0 and this element has a left margin of 40px.
<LI>The background color should extend all the way to the right margin
because this is a block-level element.
<LI>The background color should extend only to the edges of the text at
the left, top, and bottom, because there is no padding.
<LI>The background of the list-item marker should be transparent such
that the background of the underlying element shows through.
<LI>The list-item marker's horizontal position is undefined. Your
browser can put it wherever it wants to.
<LI>There should be a 6 pixel space between the element blocks because
there is a 6 pixel bottom margin on LI.

David Perrell

Received on Friday, 6 June 1997 20:17:37 UTC