I answered the following question yesterday        I've noticed that the syntax highlighting of the razor code is somewhat broken.   Is there anything that can be done about this?  I don't think that there's anything wrong with the syntax since it highlights nicely in visual studio and executes without error.  I've checked the following post but can't see anything that mentions razor views
1273
I noticed that sometimes my code gets highlighted in different colors when rendered.   What is syntax highlighting? How does it work? Why isn't my code being highlighted correctly? How do I report a bug or request a new language? How do I use syntax highlighting? What languages are currently available on Stack Exchange?
2293
Currently, Stack Exchange’s Markdown parser only allows four-space indents to represent code blocks:      // some code     // another line of code    and other Markdown implementations allow for an alternative syntax, that doesn’t require indenting each code line:  ``` // some code // another line of code ```   This is much more convenient to type out. It would be super useful if Stack Exchange could support this syntax.    By extension, this syntax also allow you to specify the source language right after the opening ```:  ```js // some code // another line of code ```   …which would then enable syntax highlighting for that specific language. Although it’s interesting metadata, I don’t think this feature is needed on Stack Overflow, as the syntax highlighting library works pretty well for various languages.  So, even if you would allow this syntax but ignore the ```language, this would greatly improve my productivity on Stack Exchange.  What do you think?  The moderators are currently collecting feedback regarding this feature, so please post a comment with your thoughts. Good idea? Bad idea? Don’t really care? What do you think are the benefits/drawbacks? Experiences? Let them know! Thanks!
123881
I want create my own IDE but I want a code editor that would syntax highlighting.  I want to embed it as a control into a WPF window.  Malcolm
120873
I don't know how long this has been happening, but I recently noticed what seems to be a regression: after clicking the "An edit has been made to this post" banner that appears when a question or an answer has been edited while you're viewing it, any code syntax highlighting or math formatting in the post fails to render.  Steps to reproduce:   Open a question with highlighted code or MathJax markup that is likely to get edited soon. (The  or  is a good place to find some.) Leave the question open until someone edits it and the "An edit has been made to this post" banner appears. (For efficiency, open several questions in separate tabs and wait a few minutes until one of them gets edited.) Click the banner. Observe that the question gets reloaded, but it loses any syntax highlighting or math formatting.   (The bug also occurs for edited answers, but those tend to be harder to find on demand.  Unfortunately, editing a post yourself while having it open in another tab doesn't seem to work, since the banner never appears in that case.)    FWIW, the cause of this bug appears to be a missing call to styleCode() (or equivalent code) in the reloadPosts function in realtime-se.js, as included in the  bundle. (In particular, running styleCode() from the browser JavaScript console after reloading the post restores the missing syntax highlighting.)  I'm pretty sure this used to work automatically, so I suspect this is a regression caused by some recent code reorganization.
16891
Problem  I want to explain C# programming language step by step using overlay in beamer.cls. But it does NOT works as shown in the following figure.  How to solve this problem?    Code Snippet  \documentclass[dvipsnames,cmyk]{beamer}  \usepackage{listings}  \begin{document}  \defverbatim[colored]\Lst{% \begin{lstlisting}[language={[Sharp]C}] using System; public delegate void Foo(object o); \uncover&lt;1&gt;{public class Foo} \uncover&lt;2&gt;{\{} \uncover&lt;3&gt;{public static void Main()} \end{lstlisting}}  \begin{frame}{MyListing} \Lst \end{frame}  \end{document}
37136
We've come to rename Markdown to Letdown in the  because it lets you down so often. I've now just found a pattern. It seems markdown . That is, this  Letdown can't cope with multi-line comments. Let's see code?  fails to display code marked as code, while this works  But code works.  Now, I think it would be Ok if you said chat messages shouldn't be multi-line. (Although I'd be a bit annoyed, because I like them.) But if so, please don't render them as multi-line (as is the case with comments), so we aren't tempted to use them.
116283
I am writing a long report, and I need to include some code I wrote. I would like my code to appear colorized, as can be seen in some text editors, but not by using the verbatim package.  I need to colorize two distinct languages:   Bash language (Java language)&lt;= Already have it, thanks!   Thank you in advance for your help.
18683
Frequently when I ask a question I have to include quite a bit of code for reference purposes.    It would be nice to be able to bold the important lines in the code.  For example this code:  &lt;DataTrigger Value="True"&gt;     &lt;DataTrigger.Binding&gt;         &lt;MultiBinding Converter="{StaticResource DisableWorkItemConverter}"&gt;             &lt;Binding ElementName="MainForm" Path="PickedWorkItemID"/&gt;             &lt;Binding Path="Id"/&gt;         &lt;/MultiBinding&gt;     &lt;/DataTrigger.Binding&gt;     &lt;Setter Property="IsEnabled" Value="False"/&gt;     &lt;Setter Property="IsSelected" Value="False"/&gt; &lt;/DataTrigger&gt;   Is not way long, but the important part (as seen in ) is the second to last line.  However, if I try to bold it, it ends up looking like this:  &lt;DataTrigger Value="True"&gt;     &lt;DataTrigger.Binding&gt;         &lt;MultiBinding Converter="{StaticResource DisableWorkItemConverter}"&gt;             &lt;Binding ElementName="MainForm" Path="PickedWorkItemID"/&gt;             &lt;Binding Path="Id"/&gt;         &lt;/MultiBinding&gt;     &lt;/DataTrigger.Binding&gt;     &lt;Setter Property="IsEnabled" Value="False"/&gt;     **&lt;Setter Property="IsSelected" Value="False"/&gt;** &lt;/DataTrigger&gt;   Not what I was going for.  It would be nice to be able to draw attention to specific lines of code when needed.    (One suggestion of a different color background sounds nice too (ie a yellow background to draw the eye to the relevant code.)  If there is some other way to bold in code please let me know.
104775
When editing really long code blocks (which should definitely be refactored anyway, but that's beyond the scope of this question), I often long for the ability to collapse statement blocks like one can collapse function blocks.  That is to say, it would be great if the minus icon appeared on the code outline for everything enclosed in braces.  It seems to appear for functions, classes, regions, namespaces, usings, but not for conditional or iterative blocks.  It would be fantastic if I could collapse things like ifs, switches, foreaches, that kind of thing!  Googling into that a bit, I discovered that apparently C++ outlining in VS allows this but C# outlining in VS does not.  I don't really get why.  Even notepad++ will so these collapses if I select the C# formatting, so I don't get why Visual Studio doesn't.  Does anyone know of a VS2008 add-in that will enable this behavior?  Or some sort of hidden setting for it?  Edited to add: inserting regions is of course an option and it did already occur to me, but quite frankly, I shouldn't have to wrap things in a region that are already wrapped in braces... if I was going to edit the existing code, I would just refactor it to have better separation of concern anyway. ("wrapping" with new methods instead of regions ;)
86351
In the  I see:    Is that what the help is supposed to say and look like? Because it doesn't make sense to me.  As animuson points out in a comment, all of the highlighted example text is being shifted to the very left of each line. The entire page is broken.
9736
I've posted a lot to StackOverflow, and I've noticed something kind of irritating with the formatting in writing questions and comments. If I need to put something inside a &lt; and a >, without spaces in the middle (like right there), it will think it's code and not show up, like this   (obviously it won't come up what I wrote there, or else this wouldn't be an issue, but if you open up the question to edit you can see what's written there.)  If I want it to show up, right now I have to add an extra set of brackets inside of the originals with a junk variable, like right &lt;here> (again, open in edit window to see).  This is really annoying when trying to show variables like lists that require those brackets, and I feel like the junk variables could confuse people looking at the edits. Is there a way to get around this formatting? Thanks!
83996
any latex code I want to view in TexWorks 0.4.5 r.1280 (Miktex 2.9) won't show the syntax highlighting. It compiles just fine but everything line is written in black. On very long documents the highlighting shows for several seconds then the program freezes for short and the highlighting disappears again. Windows compatibility modes did not improve the situation. Does anyone have an idea what's going wrong here?
24044
I followed the official step-by-step "Visual Studio Code and Unity" guide, but it seems I messed up something, because Intellisense doesn't see any Unity related stuff.  Like the MonoBehaviour class and its members (like .transform), or the Unity callbacks, like Start or Update.
99333
All the code boxes are appearing as 1 line to me. This:  #include &lt;stdio.h&gt;  int main() {     printf("Hello, world!\n");     return 0; }   Appears thus:  #include &lt;stdio.h&gt;  int main() {     printf("Hello, world!\n");     return 0; }   ...which is making the longer code posts harder to read. Someone posted a binary search tree, which was just impossible to read like that.  It appears correct in the preview as I write this.  Firefox 3.6.3, Gentoo Linux 2.6.32  Edit: To clarify: The correct version (with newlines) appears briefly on both Stack Overflow and Meta, but as soon as syntax highlighting is applied (which is almost instantly), then it collapses to 1 line.  This applies to the editor in the "edit question" part, but it seems to be a bit lazier about applying syntax highlighting. (It seems to do it when the box you type in loses focus, so as I'm typing this, it appears correctly, with no syntax highlighting, and when I un-focus the text area, a few moments later, it syntax highlights and collapses to 1 line.)
73051
Is syntax highlighting only applied to code after the post is posted?  // test code  for (int i = 1; i &lt; 4; i++) {    s = s + "abc" + 'd' }   Also, will the formatted blocks that were shown as being separate after each time I hit Enter be merged?
53438
I think I have entered a sequence of commands as a mistake and now a yellow line appears in top of my selection. I don't know what it is for or how to enable/disable it.  I have tried closing the editor but it keeps appearing.
6602
Reading the help center article on syntax highlighting, one of the paragraphs within it reads:     You can use either , like lang-cpp or lang-sql, or you can specify a tag, and the syntax highlighting language associated with this tag will be used:   Note the link in there, which goes to .  Problem is, a long time ago we removed the list of options from several questions/answers across meta Stack Exchange because it was a pain trying to keep all of them updated. It makes a lot more sense to just have one list that we keep updated, and the most logical place for that list was in the , which is where it now resides.  Can the link in the help center be updated to point directly to the list, rather than to a post that explains that the list has been moved?