Questions tagged [formatting]
For questions about the formatting on Stack Overflow; how to use it and when to use it.
124
questions
1
vote
0
answers
40
views
Table formatted correctly in preview, but not when question is posted [duplicate]
There appears to be a slight inconsistency in the rendering of tables in Markdown. If a table isn't preceded by an empty line, then the table is rendered properly in the draft editor, but not when the ...
2
votes
1
answer
126
views
HTML formatting inside highlighted code blocks is no longer supported - how can I fix my posts?
In the past, it used to be possible to apply rich text formatting to text inside code blocks, as long as the code block was formatted using the HTML <pre><code> elements. As an example, ...
2
votes
0
answers
200
views
Is having the ability to apply rich text formatting inside code blocks important?
For many years, it's been possible to apply rich text formatting to code blocks inside posts by formatting the code block using the HTML tags <pre><code> and using more HTML tags inside ...
2
votes
1
answer
267
views
Why would Stack Overflow code blocks (only) suddenly be displayed in italics?
Okay, it's not April 1st, so the new fonts must be serious. I'd like to express a like or dislike of the new fonts to those who decide such things without starting a flame war. Or is there an option ...
3
votes
0
answers
36
views
Table formatting: fit-to-content option?
Would it be possible to have tables which are sized to fit the contents, rather than using the full width available?
Something like this, but with the last column hidden.
Id
Name
Quest
Favourite ...
31
votes
2
answers
923
views
What causes new contributors to miss the last line in a code block and paste the image as a hyperlink?
I very often see new contributors asking questions like this:
function foo(){
return "bar";
}
enter image description here
I personally don't know how they get there, especially for the ...
-1
votes
1
answer
98
views
Multi-line quotes always show up in a single line [duplicate]
I expect the following quote to have 2 lines:
> line1
> line2
But it actually renders as a single line:
line1
line2
I assume this to be a bug since it defeats all my expectations of quoting ...
2
votes
0
answers
93
views
Is there an easier way to generate tables in posts?
I have seen a post on how to use table formatting inside Stack Overflow question posts. However, it seems to be really overwhelming to insert all the formatting for tables on your own by hand: once ...
91
votes
3
answers
2k
views
Should there be a warning for code containing bidirectional Unicode text?
Articles on the misuse of bidirectional text have been making the rounds recently. Put simply, this abuses the concept of bidirectional Unicode text to compile something different from what it ...
4
votes
0
answers
59
views
Is it possible to get the raw Markdown of a post in-browser without trying to edit it? [duplicate]
I'm writing some notes down for myself, and these notes involve citing parts of a Stack Overflow post with a lot of Markdown. Manually copying the text and pasting it into my notes does not preserve ...
4
votes
0
answers
165
views
Does the blog comments section support markdown?
I made a comment on the 'Privacy is an afterthought in the software lifecycle. That needs to change.' article and the formatting is very strange. I can't tell if I messed it up or if it just doesn't ...
2
votes
0
answers
82
views
Doesn't formatting <b> tags inside a <pre> tag [duplicate]
Sometimes I write answers within the <pre>...</pre> tag to get more control over formatting the answers. Usually, I do this with the code-snippets, which may be required some emphasis.
In ...
7
votes
1
answer
159
views
Can't figure out formatting error while posting this question [duplicate]
I get the error below while posting a question on Stack Overflow. I've looked up elsewhere, used Ctrl + K, and added extra lines after the heading, but I am still getting this error.
Your post ...
-24
votes
1
answer
206
views
Should we ban strikethrough formatting?
I often see answers that contain significant amounts of struck-through text, like this.
I understand why the authors have done it; it's often to indicate where they've since updated their answer and ...
10
votes
0
answers
97
views
Darker CSS for visited links on SO meta?
Depending on the context, previously visited links on Stack Overflow Meta can be quite tricky to spot.
Example - there are four in the image below - they're somewhat tricky to spot (for me, at least):
...
3
votes
0
answers
60
views
Is inline code formatting for comments broken? [duplicate]
Just noticed this today on this comment:
It seems that the formatting is broken, there are lots of whitespaces inside of the inline-code and the grey background is extending beyond the actual comment....
5
votes
0
answers
94
views
Why is the link formatting on my question not working as expected?
I just asked this question and it looks like the links aren't formatting properly.
I suspect the problem comes from the . at the end of the first url (even though it's part of it for real) but if not, ...
2
votes
0
answers
74
views
What kind of code format should I use for errors? [duplicate]
I was scrolling through Stack Overflow questions when I saw this one: Rscript Path Problem for exec() implementation R code in php
It's a beautifully structured question, except I find the way the ...
4
votes
0
answers
82
views
How is table with code formatted illegally? [duplicate]
Could someone please for the love of G tell me why this table is not formatted correctly?!!!!
Base (base)
Exponent (exp)
Math.pow(base, exp)
numeral(n).format('0[.]00e+0')
logFormatter(n, base)
10
-...
7
votes
1
answer
97
views
Not correctly formatted hyperlink
There seems to be some problem with the handling of links after <h1></h1>. It wasn't there some months ago. The problem is here and on the main site (I've noticed because I opened an old ...
33
votes
3
answers
1k
views
Using Keyboard Format for Product Names
I have seen people format product names with the keyboard format. ExcelO365 for example. I assumed this was the standard based the reputation of the people I saw doing this. Did I assume wrong?
-11
votes
3
answers
205
views
When is bolding considered unnecessary?
In the following example question, bolding was removed as unnecessary:
https://stackoverflow.com/posts/65685587/revisions
The bolding was added so that by just reading the bold part you get a feeling ...
6
votes
0
answers
75
views
Code block formatting looks OK in preview, wrong in main display
Note: The problem looks similar to this one and was indeed closed as a duplicate, but in that question the formatting in the preview is also wrong; here the preview is displayed correctly, but after ...
35
votes
4
answers
1k
views
Should we disapprove of uploading images of tables when asking a question?
Since the introduction of the table markdown should people still be using images of tables instead of the markdown? Or should we be enforcing the use of the new markdown? If we find a question that ...
9
votes
1
answer
90
views
Different table formatting in editor and outside
I came across this badly formatted answer and wanted to edit it to correct the formatting.
The table formatting is messed as can be seen:
However when I click edit, formatting is OK:
Is there ...
6
votes
0
answers
211
views
Comment code format overflow covered by job
I just found a overflowing comment. It is covered by a job box (Whatever it's called). If there was some code there, it could not be shown.
Can we change it to comment covering the job description? (...
39
votes
2
answers
1k
views
Significant reformatting of a question
I reformatted a part of a question to make it more readable. The difference is quite huge, it transforms inline code into blocks.
Is this kind of initiative discouraged, i.e. should we edit only "...
2
votes
1
answer
156
views
How to show plots in Stack Overflow questions [duplicate]
What is the best way to attach a plot, or a link to a plot (or image) to a Stack Overflow question? I have tried attaching as an image but to no avail. I believe there is a platform to do this. Does ...
5
votes
0
answers
68
views
How can I write a link in smaller font on main site?
I am attempting to write links in smaller font.
I know how to write text in small font.
However, if I try to insert a link, it doesn't turn blue on the main site. It seem to turn blue here: https://...
3
votes
0
answers
153
views
Format bug: edit → mark a text → click on **B** for bold or *I* for italic → start of the format change is slightly too late
If you click on edit, then mark a word, a line or multiple lines of text, then change the format e.g. to bold, the very first formatting change has a bug.
Reproducible example at least at my laptop ...
3
votes
0
answers
52
views
common mark migration breaks bullets formatting?
After migration to common mark formatting of the bullets is corrupted. Old formatting used 1 space for inner text but common mark uses 3 spaces. So after migration the bullets where not repaired at ...
1
vote
1
answer
140
views
Why does (only) the code formatting sometimes not work in a question/answer?
Usually, when selecting the code (of course, in edit mode) and pressing Ctrl+K, or {}, the selection is correctly formatted as code:
Sub Foo()
'Whatever in here...
End Sub
But sometimes, the ...
-10
votes
1
answer
103
views
Can we discuss the minimum 6-character requirement for editing a post?
I've fallen into this trap the past couple of days. The edits I couldn't make were:
add a tag to a post to help draw people to a post asking a specific question (I wanted to add the regex code to a ...
1
vote
0
answers
88
views
Bug: Interpreting C# code as incorrectly formatted code [duplicate]
When using the code format sometimes the color isn't correct.
For example, in this question the word CPerson Blue is blue instead of Black:
And the set is Blue, and get is Black:
This is a ...
15
votes
1
answer
142
views
List formatting is broken: neither bulleted nor numbered lists render in posts
I tried using - to add bullets, but it's not working.
e.g.
line1
line2
line3
I wrote it as such:
- line1
- line2
- line3
It's also missing from my previous posts. e.g. see here
This affects ...
13
votes
1
answer
280
views
What's the limit to how many emojis a question can have? [duplicate]
This question has "a lot" of emojis. It's clear that the user is trying to get attention with them.
Thanks for the interaction! I'm really hoping to get this solved.
What are the rules regarding ...
1
vote
0
answers
143
views
What is the recommended way to format the output of some code? [duplicate]
As per title, consider some code which produces some output to STDOUT, what is the recommended way of formatting it.
For example, in Python, you could write:
print('Hello World!')
which produces ...
3
votes
0
answers
44
views
How to format the data (questions/answers) on stackoverflow mobile site? [duplicate]
Its very difficult to format the data while working on stackoverflow mobile site. Somehow I used to manage it via adding spaces for code etc. But when theres a large complex data to be posted it ...
75
votes
1
answer
1k
views
Can we add a button "Format with Prettier" to the toolbar when editing posts?
Prettier supports formatting Markdown text and a bunch of languages. Can we add it as a button or format on save?
All the posts will have a unified look and feel, without the extra spaces, wrong ...
3
votes
0
answers
91
views
Feedback on the new ask question page - Formatting suggestions
I think you guys did a great job with the re-design of the ask question page. However there is this bit that I find can be improved.
There are currently three (or even 4) ways to format code:
...
1
vote
0
answers
49
views
Question format seems hidden [duplicate]
I just came through this question today. At first look, it seems too broad /unclear. So I choose the close vote.
After that, I thought that how SO allowed the user to ask a one-line question. So ...
9
votes
2
answers
774
views
Should unnecessary formatting (that serves to draw attention) be considered an antipattern?
I've noticed a pattern recently (though it's probably not new) of answers using formatting to grab attention. For example, this answer uses a H1 and a blockquote to make the answer really stand out. ...
-7
votes
0
answers
105
views
How do I properly hide preformatted text? [duplicate]
I know how to preformat text
This is preformatted
| . X . . |
| . X X X |
| . . X . |
And I know how to hide text
But I cannot figure out how to nicely combine the two.
The best I can do is this, ...
3
votes
0
answers
100
views
Blockwise indentation [duplicate]
When I paste code into the text editor, sometimes I have to indent multiple lines to make it look well. So I start to hit the space bar multiple times for each code line until the code is formatted ...
49
votes
5
answers
2k
views
How do I format an arrow key input?
As part of an edit, I'm adding <kbd> tags to various user keystrokes mentioned in a question. I can't figure out the proper way to handle arrow keys.
Left arrow?
<-?
Left?
All the options ...
26
votes
2
answers
738
views
Are backticks appropriate for emphasizing references to things that show up in code?
I've been following this "When should code formatting be used for non-code text?
" post for guidance on removing backticks when reviewing suggested edits as well as when forming my own questions and ...
2
votes
0
answers
54
views
Make the 'How to Format' box sticky/persistent
I was just writing a question and could not remember how to quote something. I did remember there usually is a box on the right giving me hints for things like this. The box wasn't visible however, ...
2
votes
1
answer
306
views
How to insert a wide table in a post? [duplicate]
How can I insert a 10 column table in cleaner format in a Stack Overflow question?
50
votes
3
answers
984
views
Should we make the {} button add ``` instead of four spaces?
I didn't know that the three backticks code fence feature was implemented until I asked this question.
This is a great new feature! I think the code block button in the editor (the {} button) should ...
8
votes
1
answer
2k
views
How can I post a question with sample output?
I'm trying to show a code block with sample output to clarify my question. I know how to add a code block (indenting with 4 space) but I can't figure out how to show the output.
import pandas as pd
...