Skip to main content

Questions tagged [syntax-highlighting]

Filter by
Sorted by
Tagged with
6 votes
0 answers
157 views

What is going on with this site's syntax highlighting?

Inconsistent syntax highlighting for reg and powershell code (There is an intentional leading whitespace on code fence code for it to display correctly) This was posted on Meta SE on 2024.06.26 after ...
JW0914's user avatar
  • 8,610
4 votes
1 answer
74 views

VBA syntax highlighting

I recently posted two answers that contained VBA code. In one of them, the syntax is highlighted and in the other one, it isn't. Can anybody tell me why that is? I'd like it to be highlighted in both. ...
andrewb's user avatar
  • 429
3 votes
1 answer
93 views

Syntax highlighting for PowerShell is unavailable / inconsistent

On this question: Can LastAccessTime be set to an old timestamp using PowerShell? I have a code block in the question and in the answer. Both code blocks are defined by having their lines start with 4 ...
Jim's user avatar
  • 563
4 votes
0 answers
95 views

Request to create / enable syntax highlight for M language

We have increasing number of questions about power-query. It would be great to apply syntax highlight for M language code in questions.
Máté Juhász's user avatar
8 votes
1 answer
314 views

Powershell and Batch syntax highlighting not working logically

Syntax highlighting for both Powershell and Batch works if specified manually in an HTML comment, but not via a code block: Doesn't Work: (code block) ```bat ```powershell Works: (HTML comment) &...
JW0914's user avatar
  • 8,610
4 votes
0 answers
65 views

Why can't Superuser highlight Powershell syntax but SE Android App can?

In this answer I added a small Powershell script. In Firefox and Chromium, that code doesn't show syntax highlighting. I'm using latest Firefox and Chromium browsers and don't want to change it. ...
Biswapriyo's user avatar
  • 11.4k
0 votes
1 answer
31 views

Adding 'language-highlighting' tag to a question, necessary?

Consider this question. I provided an answer with a bash script. I did remember to add embedded Prettify language hints. The highlighting didn't get turned on. Then I found this post on Meta SE ...
pepoluan's user avatar
  • 1,300
5 votes
1 answer
105 views

Why is syntax highlighting different when added via tag or via <!-- language: lang-XXX -->

Take this answer where the tag VBA is used. The system recognizes the tag and automatically turns on syntax highlighting. So far so good. Today I answered another question where no syntax ...
nixda's user avatar
  • 27.4k
0 votes
0 answers
42 views

Why isn't shell syntax highlighting working? [duplicate]

I've been all over Meta Stack Overflow and the help pages, and frankly I'm just tired of looking now. I've tried <!-- language: shell --> and <!-- language: sh -->, but I can't seem to get ...
Blacklight Shining's user avatar
13 votes
2 answers
179 views

Can we activate syntax highlighting for code blocks based on the question's tags?

I think it is time to revisit the syntax highlighting question. There is a similar request that suggests using HTML comments to activate highlighting for specific posts. I would rather implement ...
terdon's user avatar
  • 53.9k
21 votes
1 answer
252 views

Make syntax highlighting possible to enable with prettify language codes

On Super User syntax highlighting is turned off. But there are questions on Super User where syntax highlighting can be helpful. Therefore I suggest that syntax highlighting is made possible to enable ...
N.N.'s user avatar
  • 1,379
16 votes
1 answer
201 views

Make "code / command"-background more visible

I write code or commands using "backticks". But on SuperUser, the background doesn't have much visual contrast, so if I write multiple commands separated with comma or a single word, it's hard to ...
Jonas's user avatar
  • 28.2k
8 votes
1 answer
104 views

Why is code highlighted in preview, but not in the actual post?

I'm editing my answer to this post and wonder why code blocks are highlighted in the editor's preview, but not in the answer itself. Is it a bug? I don't remember ever having seen code blocks ...
Pylsa's user avatar
  • 31.3k