Previous Message
Next Message

ADMIN: Double space after a period

Sent by Eric A. Meyer on 17 October 2006 15:03


Pardon me,

    I'd just like to step in here to point out that css-discuss is not 
for arguments about typographical preferences.  It exists to help 
people understand how to use CSS to do what they want to do, or else 
to understand why it's difficult or impossible to do so.  There have 
been some suggestions for Chris, which he is now free to take or 
leave.  Telling him that what he wants is wrong doesn't help anyone.
    (And yes, this is true for everything.  Even if someone says "I 
want to prevent the user from changing the text size", it does no 
good to tell them they're wrong to want that.  It does a world of 
good to explain why that isn't in any way possible, because then they 
learn something about the medium.)
    The people who suggested 'white-space: pre' were on to something, 
but as others pointed out, that prevents any word-wrapping.  So what 
Chris really needs is a setting that preserves whitespace while 
allowing word-wrapping.  Et voila:

    p {white-space: pre-wrap;}

This combines the whitespace preservation of a 'pre' element with the 
word-wrapping of a non-'pre' element.  See 
http://www.w3.org/TR/CSS21/text.html#propdef-white-space for somewhat 
confusing details.  Or, if you have a copy, hit up pages 151-152 of 
the second edition of my O'Reilly book.  The table on page 152 is 
missing a value ('pre-line') but that's something I hope will be 
corrected in the forthcoming third edition.
    As for browser support, here's a test page:

    http://meyerweb.com/eric/css/tests/white-space.html

The verdict: pretty much nobody supports it, so it's a great idea but 
is currently of no practical value.  So we're left with the 
suggestions that were seen earlier in the thread, most of which 
involve structural hacking of one type or another.
    Let's keep things moving in the direction of finding solutions, or 
else drop the thread.  Thank you.

-- 
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-REMOVED]]
http://www.css-discuss.org/mailman/listinfo/css-d
IE7b2 testing hub -- http://css-discuss.incutio.com/?page=IE7
List wiki/FAQ -- http://css-discuss.incutio.com/
Supported by evolt.org -- http://www.evolt.org/help_support_evolt/
Previous Message
Next Message

Message thread: