code-formatting Questions

2

Solved

I created this solution: ; use like this: ; (/* content ... */ <default-return>) ; or ; (/* content ... */) => #f (define-syntax /* (syntax-rules (*/) ((/* body ... */) #f) ((/* body ....
Poulson asked 17/9, 2010 at 1:51

3

Is IDEA or one of its plugins capable of aligning code to special characters? I mean so that the code Map( 'name -> "Peter", 'age -> 27, 'company -> "Foobar" ) is transformed to Ma...
Laster asked 21/2, 2013 at 11:43

4

Solved

In a html file, there is some code used custom template-language: <script type="text/javascript"> function ($scope, JsRoutes) { $scope.rows = [ ${"#{list rows, as: 'row', separator: ','}"...
Commensurate asked 24/12, 2012 at 10:38

2

Solved

I'm running Eclipse 3.7.2 on Windows 7 professional. If I type a method declaration like this: private void processCode(String codename, boolean doSomethingElse, int num_of_repeats){ } Then h...
Billings asked 11/9, 2013 at 14:35

3

I've been customizing my formatting desires using ReSharper for code clean-up. So far I've been able to make the clean-up rules match my coding style within:      ReSharper...
Jive asked 16/9, 2010 at 14:47

2

Solved

Is there any way to tell the gradle idea plugin to use a custom code style xml when generating the project's files? I can always copy the xml into "~/Library/Preferences/IntelliJIdea13/codestyles"...

6

Solved

I'm familiar with printing time difference in milliseconds: long time = System.currentTimeMillis(); //do something that takes some time... long completedIn = System.currentTimeMillis() - time; ...
Clemente asked 24/4, 2010 at 12:39

2

Solved

DDL gets especially ugly. Is there any option of SQL auto-indenting for Notepad++? I've tried to do it in Eclipse, but the code doesn't react to auto-indent.
Cheka asked 24/10, 2011 at 3:29

4

I'm using Eclipse combined with EPIC to write my Perl code. I configured EPIC to use Perltidy with "-pbp" (perl best practices style) to format my code. This doesn't work well when using Method::S...
Gormless asked 9/10, 2010 at 6:33

2

Solved

I tried: ALT + SHIFT + F CTRL + K, CTRL + D CTRL + K, CTRL + F Also when I search for format via CTRL + SHIFT + P, there are no search results.
Crispi asked 26/12, 2016 at 9:56

2

Solved

One Feature I miss from Eclipse are Save Actions for autoformatting. Any way to have the same in Netbeans?
Hymnist asked 31/3, 2010 at 5:38

14

Solved

When doing a code review for a colleague today I saw a peculiar thing. He had surrounded his new code with curly braces like this: Constructor::Constructor() { // Existing code { // New code: d...
Absorptance asked 14/3, 2012 at 14:39

3

Solved

Due ESLint I found a rule newline-before-return about empty line before return statements. But did not see a rule about empty line before the first statement in function. F.e.: function (a) { va...
Wylde asked 23/8, 2016 at 10:33

2

Solved

My problem is, when I comment out a line using Ctrl + /, // comment and then auto-format the code, // comment the comment will still contain whitespaces after the "//" that I wouldn't want ...
Bijou asked 20/8, 2015 at 9:11

0

yapf formatter can wrap long lines in the code inside parentheses in the expression in the list comprehension: threads = [threading.Thread( target=worker, args=[q], daemon=True) for _ in range(wo...
Starstarboard asked 29/10, 2016 at 15:35

2

Solved

I'm trying to align some assignments to improve readability, but each time I paste something, Visual Studio 2013 automatically removes the extra spaces before the =. For example, this: static cla...
Monarchal asked 3/3, 2015 at 14:44

1

How can I get Intellij format my Scala class definition like this: sealed class Traffic( private[this] val javaTraffic: Traffic.JavaTraffic, private[this] val sanitizer: Sanitizer) extends Seri...
Hetaera asked 3/12, 2015 at 22:7

2

Does intellij have an option to align javascript variable declarations like so var x = "x", yyyy = "y"; Note that the = are aligned neatly. I can't find an option to do that....worse, if I do ...
Durstin asked 9/11, 2011 at 16:33

6

I want to format code in a freshly created Android application. I messed up the code in this manner: private static final int AUTO_HIDE_DELAY_MILLIS = 3000; I want to format it with Ctrl + Alt ...
Iulus asked 14/3, 2014 at 16:58

2

Solved

I am looking for a way to reformat code of entire project, which is available for individual files via code -> reformat code.
Carvel asked 26/7, 2016 at 12:54

6

Solved

Often the number of arguments passed to a function can be large. Consider the following case: calculate(dataManager.getLastUpdate().getNumberOfChildren(), dataManager.getLastUpdate().getNumberOfP...
Cocci asked 16/5, 2011 at 21:1

1

Solved

When I split arguments onto multiple lines in IntelliJ, it puts the argument at a slight indent from the line above. For example: ClassName.staticMethod(argument1, argument2, argument3); Quick...
Someway asked 13/7, 2016 at 14:43

1

Solved

When enabling the formatting option "align fields in columns" all member fields get aligned, like this: int member1 = 1; int member2WithLongName = 2; int member3 = 3; String member4 = "asdf";...
Leaguer asked 1/7, 2015 at 18:39

4

When editing Java files, if I'm at the end of the line and I type the Enter key, it starts the next line properly indented 4 columns, to match the line above. That's OK but it's indenting with a ta...

2

Android Studio doesn't put all methods in one line when using code folding, and it's rather annoying, because I cannot tell the difference. I don't know why one method can be put in one line, and w...

© 2022 - 2024 — McMap. All rights reserved.