At 5:11 PM +0100 9/23/10, Geoff Lane wrote:

Unfortunately, this doesn't give "proper" hanging indents. So I'm
guessing I need some way of setting tab stops and inserting a tab
after each para number; or some way of reinstating the "standard" LI
behaviour while retaining the legal-style numbering.

In theory you could do it with a combination of ::marker and CSS counters. In practice, nobody ever implemented ::marker. And I agree with the assertions made in the link from David H.'s post, that you want the numbering in the HTML source instead of auto-generated (at least for legal documents). Given that, however, you might be able to get away with a markup structure like this:

<li><span class="num">2.1.1.2</span> It shall be construed a crime against humanity to recover an ancient musical instrument from a secluded cave and subsequently play it in front of others.</li>

...and then float or position the classed 'span' next to the list item. I'd probably try positioning first, actually. Something along these lines:

   ol.legal li {position: relative; padding-left: 7em;}
   ol.legal li span.num {position: absolute; top: 0; left: -7em;}

The numbers there are just wild guesses, so adjust to taste; and I imagine there would be a bit more needed to fine-tune the placement and appearance of the numbers. But I think that basic approach should work for what you're trying to do.

--
Eric A. Meyer (http://meyerweb.com/eric/), List Chaperone
"CSS is much too interesting and elegant to be not taken seriously."
  -- Martina Kosloff (http://mako4css.com/)
______________________________________________________________________
css-discuss [[email protected]]
http://www.css-discuss.org/mailman/listinfo/css-d
List wiki/FAQ -- http://css-discuss.incutio.com/
List policies -- http://css-discuss.org/policies.html
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/

Reply via email to