Questions tagged [reformat]
119 questions
1390
votes
16 answers
How do I reformat HTML code using Sublime Text 2?
I've got some poorly-formatted HTML code that I'd like to reformat. Is there a command that will automatically reformat HTML code in Sublime Text 2 so it looks better and is easier to read?

Ravi Ram
- 24,078
- 21
- 82
- 113
174
votes
16 answers
How enable auto-format code for Intellij IDEA?
Is it possible in Intellij IDEA after typing ';' or press 'Enter' happened formatting of this string?
For instance,
to:
a+b=10;
after:
a + b = 10;
Or only possible option: Code > Reformat Code...?
Thank you!

0x131313
- 2,107
- 2
- 15
- 18
149
votes
13 answers
reformat in vim for a nice column layout
I have this dataset in a csv file
1.33570301776, 3.61194e-06, 7.24503e-06, -9.91572e-06, 1.25098e-05, 0.0102828, 0.010352, 0.0102677, 0.0103789, 0.00161604, 0.00167978, 0.00159998, 0.00182596, 0.0019804, 0.0133687, 0.010329, 0.00163437, 0.00191202,…

Stefano Borini
- 138,652
- 96
- 297
- 431
133
votes
5 answers
Remove trailing whitespace on save in IntelliJ IDEA 12
Is it possible to remove trailing whitespace automatically on save in IntelliJ IDEA? I know there are some workarounds, for example, using git to trim the whitespace on commit.
Maybe this question is a duplicate of this one, but i hope this can be…

klingt.net
- 2,019
- 3
- 18
- 19
59
votes
4 answers
Java/Groovy - simple date reformatting
I'm new to Java/Groovy development and I have a simple string that I would like to reformat, however I get an 'Unparseable date' error when I attempt to run the following:
import java.text.SimpleDateFormat
import java.util.Date
String oldDate
Date…

DC Guy
- 593
- 1
- 4
- 4
18
votes
24 answers
How to convince management that reformatting the entire Java code base is safe
How would one go about proving to management that a batch reformat of all .java files in a large code base (to place the code in compliance with the company's coding standards) is safe and will not affect functionality.
The answers would have to…

jtsampson
- 218
- 1
- 11
16
votes
2 answers
PHPStorm reformat - how do I disable removing spaces in empty lines?
When reformatting a file, phpstorm replaces empty lines with whitespace to just empty lines, e.g. ^[tab][tab]$ to ^$. How do I disable this?

Fluffy
- 27,504
- 41
- 151
- 234
10
votes
3 answers
MBRFormat does not appear to be a valid volume name for its file system
I am using macOS Mojave 10.14.6. I am trying to re-format my USB to FAT.
I am getting this error MBRFormat does not appear to be a valid volume name for its file system. What does it mean and how to fix it?
Why does file system says "None"?
root$…

leopoodle
- 2,110
- 7
- 24
- 36
10
votes
1 answer
IntelliJ IDEA 12 Keep Blank Lines
I have this code:
private int a;
private int b;
private int c;
But when I reformat it with IntelliJ, it changes to this:
private int a;
private int b;
private int c;
How would I allow it to keep the blank lines?
But this code:
private boolean…

Ramus
- 250
- 1
- 2
- 10
10
votes
3 answers
How to reformat multi-line comments in Eclipse PDT?
In Eclipse PDT, Ctrl-Shift-F reformats code. However, it doesn't modify comments at all. Is there some way to reformat ragged multi-line comments to 80 characters per line (or whatever)?
i.e. convert
// We took a breezy excursion and
// gathered…

mjs
- 63,493
- 27
- 91
- 122
9
votes
2 answers
How can you intercept pasting into a NSTextView to remove unsupported formatting?
I'm trying to create a simple NSTextView-based window for simple WYSIWYG editing. However, I only want to allow certain types of formatting (e.g. Bold, Italic, Underline and a single heading type but no colors or different fonts.)
The issue is if I…

Mark A. Donohoe
- 28,442
- 25
- 137
- 286
8
votes
7 answers
Fast algorithm for polar -> cartesian conversion
I have an image on a polar grid. This image should be transformed into a cartesian grid, but the only algorithm I know of is really slow for this. Now I use the cartesian grid, for each point I find the r and theta values, and then I look in two…

martiert
- 1,636
- 2
- 18
- 23
7
votes
1 answer
How to get the "Reformat code" function out of IntelliJ IDEA?
I love the "Reformat code..." (Ctrl+Alt+L) function of IntelliJ IDEA.
Now I have a lot of XML files to look through. What I am doing now is, I open a xml file, select all, copy and paste into a xml file opened by IntelliJ IDEA, then use the…

John
- 842
- 1
- 8
- 12
5
votes
1 answer
when using vim-latex gq causes overhangs in captions
When I am editing a LaTeX file using Vim-LaTeX and want to reformat a section of text that is in a \caption{} I get overhangs or underhangs - I am not sure what to call them. I first select the text in the caption then use "gq" to reformat it. …

Shawn
- 179
- 1
- 15
4
votes
3 answers
Reformatting data using Access + Subquery
I'm trying to reformat data in MS Access as the number of rows exceeds what Excel can do. However, this is my first attempt with subqueries, and could do with some assistance in what I should be doing.
I have data that looks like the following:
t,…

James
- 41
- 3