Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Changing the size of the indentaton #85

Closed
danyaljj opened this issue Nov 11, 2015 · 2 comments
Closed

Changing the size of the indentaton #85

danyaljj opened this issue Nov 11, 2015 · 2 comments

Comments

@danyaljj
Copy link

So I got the Google java style from here:
https://github.com/google/styleguide/blob/gh-pages/eclipse-java-google-style.xml

And added to the formatter plugin. The outputs seemed like it is doing 2-space indentation. But I want 4-space indentation. I think I found the like which controls the indentation:

<setting id="org.eclipse.jdt.core.formatter.continuation_indentation" value="2"/>

Changed to:

<setting id="org.eclipse.jdt.core.formatter.continuation_indentation" value="4"/>

Ran the formatter:format again, but nothing changed. Am I doing something wrong?

@hazendaz
Copy link
Member

There is another setting you will also need to set to 4. That one is for line continuation. The other will control the rest. I forget the element name offhand.

Sent by Outlook for Android

On Tue, Nov 10, 2015 at 5:00 PM -0800, "Daniel Khashabi" notifications@github.com wrote:
So I got the Google java style from here:
https://github.com/google/styleguide/blob/gh-pages/eclipse-java-google-style.xml

And added to the formatter plugin. The outputs seemed like it is doing 2-space indentation. But I want 4-space indentation. I think I found the like which controls the indentation:

<setting id="org.eclipse.jdt.core.formatter.continuation_indentation" value="2"/>

Changed to:

<setting id="org.eclipse.jdt.core.formatter.continuation_indentation" value="4"/>

Ran the formatter:format again, but nothing changed. Am I doing something wrong?


Reply to this email directly or view it on GitHub:
#85

@hazendaz
Copy link
Member

@ danyaljj

This is the settings you need to enforce 4 spaces when using googles rules.

They have that set to 2. Try that, if it doesn't work, you could look at my build tools project which contains both 2 character and 4 character files for use. The 'build tools' works with 0.5.2 version of this code base. If you have any further issue, please feel free to re-open this.

com.github.hazendaz build-tools 1.1.2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants