Sergix / JTerm

A terminal written in Java for cross-platform compatibility and usage.
https://sergix.github.io/projects/jterm
GNU General Public License v3.0
52 stars 32 forks source link

Which code conventions to use? #126

Open tzuntar opened 5 years ago

tzuntar commented 5 years ago

Which code conventions to use?

I want to improve the code base quality a bit and have noticed that the conventions used are somewhat inconsistent. Sometimes the project style conventions are used but often the standard Java ones are used as well, especially when it comes to whitespace and the position of curly brackets. Which code conventions are to be used?

Also, which doc comments are preferred? The ones in SourceStyleGuide.md or JavaDoc?

Sergix commented 5 years ago

Hmm... use JavaDoc. I'm trying to remember why I even wrote the style guide in the first place since I ended up using JavaDoc 90% of the time anyways. Sorry for the confusion.

Sergix commented 5 years ago

I'll leave this open until the spec file is removed and the README is updated.

tzuntar commented 5 years ago

OK, thanks for clarification. What about whitespace and curly brackets? Should I use the default "Java" style

private int something() {
    doSomething();
}

or follow the style guide, i.e.

private int something()
{
    doSomething();
}
Sergix commented 5 years ago

Java style. 👍🏼