W3C home > Mailing lists > Public > www-style@w3.org > September 2010

Re: "Line" pseudo-element required to control indentation of pre-formatted text?

From: fantasai <fantasai.lists@inkedblade.net>
Date: Wed, 22 Sep 2010 02:58:44 -0700
Message-ID: <4C99D354.5010904@inkedblade.net>
To: David Chambers <david.chambers.05@gmail.com>
CC: www-style@w3.org
On 09/21/2010 05:16 AM, David Chambers wrote:
> I recently wondered whether it's possible to style a block of text
> *contained within a single element* such that wrapped lines are
> indented.

Good question. A :line pseudo-element is a bit overkill for solving
this problem (and unlikely to get much traction, given how difficult
:first-line is to spec and implement). But, I'm pretty sure we could
solve your problem with better options for the text-indent property!


   pre {
     text-indent: 2em hanging each-line;

We already have "text-indent: 2em hanging" proposed in CSS3 Text.

Received on Wednesday, 22 September 2010 09:59:20 UTC

This archive was generated by hypermail 2.4.0 : Friday, 17 January 2020 22:49:47 UTC