Skip to main content

Questions tagged [code-formatting]

For questions about making code appear correctly in questions, answers and comments.

10 votes
1 answer
160 views

Code block usability issues in Stacks Editor

Some issues with the new Stacks Editor's code block usage: Had to make it a GIF to upload here but the video is supposed to stop when I press the discard button and click the off-screen confirm box. ...
user5127's user avatar
  • 189
11 votes
1 answer
161 views

Use tag formatting on /help/whats-meta

At the bottom of What is "meta"? How does it work? is a section on required tags. It uses code formatting for these tags: Because meta-discussion sites are different and serve multiple ...
bobble's user avatar
  • 13.7k
14 votes
1 answer
320 views

when typing code, backslashes are automatically inserted

Today I noticed the first time, that when I post an answer and enter code (by prefixing the line using 4 spaces), and my code contains a backslash or an asterisk, these characters are then prefixed by ...
user1934428's user avatar
3 votes
0 answers
51 views

Unable to make syntax highlighting working [duplicate]

Disclaimer: I'm more a reader than a contributor on Stackoverflow, so I may have missed something obvious for you all. I've posted this question (about some typescript issue), and added the Typescript ...
Zoddo's user avatar
  • 139
6 votes
0 answers
95 views

Arrow key navigation broken in code blocks in Stacks Editor

Steps to reproduce: Select the WYSIWYG mode of the new Stacks Editor create a code block add some text below the code block put your cursor into the code block press the down arrow key This will ...
Mad Scientist's user avatar
11 votes
0 answers
76 views

Can code-blocks get line-numbers? [duplicate]

I was peeking at a question that included two full scripts and an error message that referenced a particular line. I copy-pasted the code into VS Code to see the line numbers, but it would be ...
Xbox One's user avatar
  • 211
0 votes
0 answers
46 views

When user highlights more than 1 line of code and pressed 'code sample', make it a code block [duplicate]

When I enter multiple lines of code and then press 'code sample' or ctrl+k, the method of formatting is that it all automatically gets indented. However, I propose that any multi-line code should ...
Kovy Jacob's user avatar
9 votes
1 answer
128 views

The Stacks Editor messes up code formatting

I’ve started a new question on Stack Overflow and the Wizard form was shown to me. This uses the Stacks Editor. When I use the code icon to format blocks of code, it adds single back-ticks instead of ...
Michael Freidgeim's user avatar
2 votes
0 answers
93 views

Issues with the “Question Wizard” [closed]

I’ve started a new question on StackOverflow and the wizard form was shown for me.(I never saw it before) I’ve noticed 3 issues. When I used code icon to format block on code, it added single back-...
Michael Freidgeim's user avatar
2 votes
0 answers
50 views

Extremely long inline code in comments overflows right sidebar [duplicate]

It's egregious e.g. when the viewport exceeds the 1180px's boundary, however it acts erraticly at many viewport sizes. Ubuntu 24.04.1 / Google Chrome 129.0.6668.58. I can't reproduce it on Firefox 130....
kos's user avatar
  • 2,224
3 votes
0 answers
66 views

Workaround for bug causing \ before dollar signs to be rendered as \\\ on MathJax enabled sites?

As the title says, a single \ in a code block is being rendered as \\\ if preceding a $. This seems to be the same bug reported here, but since it hasn't been fixed, I am asking for a workaround. ...
terdon's user avatar
  • 26.3k
5 votes
0 answers
93 views

Stacks Editor says plain text, but code formatting isn't plain text

Stacks Editor says plain text, but code formatting isn't plain text: Screenshot taken on https://meta.stackexchange.com/ Markdown: > **To create a reviewers' Custom Max Papers after having run ...
Franck Dernoncourt's user avatar
1 vote
0 answers
46 views

Cannot paste into SE code blocks when Editing, breaks text editor and Markdown preview

There seems to be something wrong with the text editor when editing code inside ``` code blocks. I've noticed this when editing questions. Copy code from my IDE Edit a question Highlight all of the ...
pkamb's user avatar
  • 4,930
-14 votes
1 answer
188 views

Sharing code and images efficiently

Let me assume I would like to share a particular image that contains certain simplifications. I don't want to directly paste it to make the question short, simple, and straightforward. So, the best ...
KNVCSG's user avatar
  • 1
3 votes
1 answer
126 views

Post formatting is not accurate for numbered lists of code blocks. Is this a bug?

Compare the way this list looks in the post versus the screenshot of the preview: text: 1. { label: `Baz ${x ? n1 : n2}`, kind: "B", } satisfies B, 1. { label: `Baz ${x ? n1 : n2}` ...
Daniel Kaplan's user avatar

15 30 50 per page
1
2 3 4 5
50