What is meta? ×
Meta Stack Exchange is where users like you discuss bugs, features, and support issues that affect the software powering all 127 Stack Exchange communities.

Okay, so we've got Interface options for specifying language prettify implemented now, which is fantastic!

There's a little bitty problem, though: As it stands, this doesn't work right in previews.

For example, the preview for the text:

<!-- language: lang-css -->

     div#ads {
         display: none
     }

renders as if it were

<!-- language: lang-sh -->

     div#ads {
         display: none
     }

That is, instead of

 div#ads {
     display: none
 }

it renders as

 div#ads {
     display: none
 }

It would be really nice if this would be fixed, so we could make sure we were doing things right before hitting "post". (I'm also not sure if the tag-based defaults are honored in the preview, which would also be quite helpful for reasons which should be obvious.)

share|improve this question
    
I think the wording of this request should be generalized for any language hints. The problem is that it doesn't apply the hints in the editor preview, what is applied is determined by the language detector (as if it were lang-default). Is this what you guys are planning on doing @balpha? Applying the hints in the editor preview? –  Jeff Mercado May 19 '11 at 21:44
1  
@Jeff Yes -- that's what the request is about. CSS is just an example. –  balpha May 20 '11 at 6:26
1  
Most of this is done (will probably be deployed soon); only inferring the default highlighting when you change the question's tags isn't done yet. –  balpha May 23 '11 at 18:57
    
@balpha: I was under the impression preview didn't work and was frankly shocked today when it did! –  Rick Sladkey May 23 '11 at 22:01
1  
I did find one "bug" though. In preview, it looks correct if there is no blank line between the language hint line and the first line of code. But after hitting submit all the code is not code. To fix the blank line must be inserted. –  Rick Sladkey May 23 '11 at 22:04
    
@Rick: oh, yeah, I saw that even before this was implemented... maybe they ought to have written the Markdown renderer in Wasabi (so that the same code could be used for client and server) ;-P –  SamB May 24 '11 at 18:13
add comment

1 Answer

Most of this has been done for a while now; the only thing missing was inferring the highlighting language when you're writing/editing a question and editing its tags.

This final part will be working after the next build.

share|improve this answer
add comment

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .