Skip to main content

Questions tagged [code-formatting]

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

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

There's a new-to-me Copy button on fenced code blocks on various stack exchange sites now. When pressed, it puts a copy of the code block to the client's clipboard, along with a couple lines of ...
Seth's user avatar
  • 987
0 votes
1 answer
68 views

In bio.SE, I use code blocks to type out genetic code and related things like sequence of numerical position of codons like in this answer. So in this answer, I've added the following code block 123 ...
Shayan's user avatar
  • 201
7 votes
1 answer
104 views

Suppose I have a section of text in the middle of a spoiler and I want to put some in a code block such that it is surrounded by the spoiler text on both sides: If I try >! something >! <pre&...
micsthepick's user avatar
10 votes
1 answer
214 views

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
14 votes
1 answer
361 views

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
5 votes
0 answers
109 views

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
77 views

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
9 votes
1 answer
146 views

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
51 views

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,234
5 votes
0 answers
103 views

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
-14 votes
1 answer
214 views

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
8 votes
0 answers
89 views

When posting a question or answer, there is a formatting help below the body textbox, which includes tips for how to format code, make text bold or italic, and quote text: However, the tips for ...
BeastOfCaerbannog's user avatar
2 votes
0 answers
129 views

I am getting this warning when proofreading a question: Your post appears to contain code that is not properly formatted as code. Please indent all code by 4 spaces using the code toolbar button or ...
Gideon's user avatar
  • 21
11 votes
1 answer
220 views

The new color scheme on the collapsible help section when adding a comment is very difficult to read for the highlighted sections. The new darker highlight does not have enough contrast with the black ...
Andrew's user avatar
  • 593
7 votes
1 answer
147 views

Editor note: While there's at least one other applicable tag, I'd like to leave it at four tags to allow for a status-* tag. In this blog post, there's an unusual use of a code block to quote LLM ...
cocomac's user avatar
  • 20.9k
12 votes
0 answers
90 views

When using the ” button to blockquote someone else's words (presumably also when using Ctrl+Q, if that wasn't the browser quit key), the quoted material is reflowed, by design. I don't particularly ...
Toby Speight's user avatar
3 votes
0 answers
62 views

Look at this: I think that overflow is due to the following CSS rule: code { white-space: pre-wrap; } Changing it to the following seems to fix the issue: code { white-space: break-spaces; } ...
Enlico's user avatar
  • 490
3 votes
1 answer
90 views

Signal Processing answer, normal vs preview: It's only toward the bottom of the post, yet it doesn't happen toward bottom of a much longer post. I confirmed it's also reproduced only with the ...
OverLordGoldDragon's user avatar
5 votes
0 answers
171 views

I am trying to post a question to Stack Overflow (and also relevant on a few other sites) but am met with the following message: Your post appears to contain code that is not properly formatted as ...
tmrgn's user avatar
  • 51
3 votes
0 answers
48 views

I posted a comment on Stack Overflow with the following text: @DougMaurer that command returns `Cmdlet Get-PackageProvider 1.4.8.1 PackageManagement` It ...
Timothy G.'s user avatar
  • 2,820
5 votes
0 answers
40 views

Here is a Reopen Votes review queue item, where the author added some code to the question. However, that is not displayed in the 'Inline' and 'Side-by-side' tabs, which just show some grammar ...
Glorfindel's user avatar
  • 270k
7 votes
1 answer
157 views

Since today, suddenly code no longer displays for me: The same happens for in-line code, also that in comments. However, I can select the code: and copy-paste it to a text editor. Is this a new bug? ...
Adriaan's user avatar
  • 1,903
7 votes
1 answer
158 views

I often use the syntax-highlighting feature of Stack Exchange in order to make my code easier to read. ```lang-python for k in range(0, 10): print(k) ``` for k in range(0, 10): print(k) ...
Toothpick Anemone's user avatar
6 votes
2 answers
140 views

A Stack Overflow post including the following: service1 has integration tests that needs to call the API on service2. ...or in its Markdown source: `service1` has integration tests that needs to ...
Arjan's user avatar
  • 28.3k
6 votes
0 answers
84 views

This answer taught me that highlighting a code block and clicking the curly brackets icons auto-formats the code block. Many developers, me included, are used to the comfort of format-on-save ...
Guy's user avatar
  • 185

1
2 3 4 5
20