Skip to main content
The 2024 Developer Survey results are live! See the results

All Questions

Tagged with
0 votes
0 answers
397 views

PHP - PhpStorm - Code style reformat, keep if-statement in one line

I have a question about the code style of PhpStorm IDE. I am a fan of using braces for one line if statements but I can't get the settings right. When reformatting the code, everything between and ...
Bram Janssen's user avatar
  • 1,247
1 vote
1 answer
187 views

Clang format for banner style

An open-source project I contribute to uses banner style (also called Ratliff style). It looks like that: // In C for (i = 0; i < 10; i++) { if (i % 2 == 0) { doSomething(i); ...
ecstrema's user avatar
  • 652
0 votes
0 answers
31 views

Curly braces decrease scale on new line [duplicate]

In visual studio when using curly braces after loops or if or any other time they become very little in scale and I don't like it. This is happening after installing resharper but I have already ...
Chestera's user avatar
  • 677
15 votes
4 answers
12k views

Visual Studio Code> Python > Black formatting does not run on save

Although I seem to have configured both linitng and formatting properly, the linting runs but the black formatting does not. "python.linting.flake8Enabled": true, "python.linting.flake8Args":...
Stefan Frank's user avatar
0 votes
1 answer
83 views

How PhpStorm setting to use COMPACTED Allman same line after open braces style

I want the PHP format to stop putting a newline after the open left brace for classes,functions,if,do,while,for,foreach. class Foo { var $numbers = array("one", "two", "three", "four", "five", "...
ninjacoder99's user avatar
0 votes
1 answer
986 views

Eclipse java class insert new line after method annotation

When using eclipse to create a class and set a master class (extends X) or an interface (implements Y) it formats automatically when creating the class like this: public class class1 extends X { ...
kay's user avatar
  • 471
1 vote
1 answer
724 views

Is there a cross-IDE solution to hint at formatting (like indentation)?

Is there a common mechanism to hint at IDE formatting like indentation (xxx spaces or tabs), and if yes, how well is it supported ? I have seen something like that a while ago but I am unable to find ...
Christophe Roussy's user avatar
0 votes
2 answers
349 views

How can I automatically format C# line indentations like VB.NET

When I write something in VB.NET, the IDE automatically formats my line indents perfectly, I don't have to use the tab key at anytime. In C#, when I needed to edit a line of code, and I perhaps ...
tmighty's user avatar
  • 11.2k
0 votes
1 answer
786 views

IntelliJ - how to prevent from adding an empty space when pasting entire lines?

Having a multicursor turned on: When I use copy/cut (latter, in this example) shortcut, without any lines selected (just with the blinking cursor), I copy/cut the entire lines. After hitting Ctrl+X ...
Przemysław Długoszewski-Tamoń's user avatar
124 votes
6 answers
46k views

Enabling/Disabling IntelliJ's fancy ≠ (not equal to) operator

I witnessed this in the GOTO 2016 • Kotlin - Ready for Production conference by Hadi Hariri. In some of his code, what would normally look like: if (x != y) { /* do some stuff */ } Renders as: if (x ≠...
Anis LOUNIS aka AnixPasBesoin's user avatar
2 votes
1 answer
3k views

Intellij code format defaults for checkstyle

I enjoy clean, consistent code. I think teams should enforce this on their code bases. However, I want to spend 0 time fudging around with alphabetizing my imports, messing with tab/space characters, ...
Matt Broekhuis's user avatar
1 vote
1 answer
700 views

Microsoft Expression Web 4, blank space between lines of code

Every time I open my website to edit, there are more blank lines between my code. I delete the blank spaces (which takes forever) and close MEW4 and when I re-open it the next day, there are more ...
Nikki's user avatar
  • 11
0 votes
2 answers
75 views

Writing code without curly braces

I think curly braces are entirely redundant. Indentation alone should be enough to define codeblocks. Is there a way to set up Visual Studio or a different IDE so that indentation simply implies a ...
NounVerber's user avatar
1 vote
1 answer
97 views

Format C++ code with corresponding elements over multiple lines

I'm looking for a tool that makes out of the ugly block if ( str == "str" ) decorator["str"] = &Props::goodstr; else if ( str == "strM" ) decorator["strM"] = &Props::goodstrM; ...
Clawish's user avatar
  • 2,964
0 votes
2 answers
508 views

IntelliJ Idea: Align on Colon for Scala Case Class Members?

Is there a way to prevent Idea from reformatting multiline case class members? Intended result (position of the colon is not so important, but the alignment of the type annotations would be great) ...
sthzg's user avatar
  • 5,534

15 30 50 per page