On Feb 9, 2011, at 8:29 AM, weakish wrote:

> Consider this code span: `grep '    '`.  All implementations listed on
> [babelmark](http://babelmark.bobtfish.net) just simply wrap it as:
> 
>    <code>grep '    '</code>
> 
> Viewed in browsers, the above code is equivalent to:
> 
>    <code>grep ' '</code>

I couldn’t reproduce this at first, but I was only doing a preview in TextMate. 
When I checked a couple of browsers, I saw what you mean. This is the CSS that 
TextMate uses.

    code, pre {
      word-wrap: break-word;
      white-space: pre;
      white-space: pre-wrap;
      white-space: -moz-pre-wrap;
      white-space: -o-pre-wrap;
    }

That can be used to preserve the space in contexts where you have control and 
are defining CSS rules. Of course it doesn’t solve the problem across the board.

-- 
Rob McBroom
<http://www.skurfer.com/>

_______________________________________________
Markdown-Discuss mailing list
[email protected]
http://six.pairlist.net/mailman/listinfo/markdown-discuss

Reply via email to