wood burning stoves
The moose likes IDEs, Version Control and other tools and the fly likes Eclipse 3.0 Formatting Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

JavaRanch » Java Forums » Engineering » IDEs, Version Control and other tools
Bookmark "Eclipse 3.0 Formatting" Watch "Eclipse 3.0 Formatting" New topic

Eclipse 3.0 Formatting

Bharat Ruparel
Ranch Hand

Joined: Jul 30, 2003
Posts: 493
I am using Eclipse 3.0 to write Java code. Our source is under Rational ClearCase on a Sun Solaris machine. We have a number of developers who use "only " EMacs. Whereas a few like me use Eclipse.
My Eclipse project uses "linked folders" and directly accesses the Java source stored on the Sun machine controlled by ClearCase.
I am having a devil of time resolving the formatting inconsistencies between myself and the EMacs developers. The spacing and formatting of the source code as it appears on their EMacs editors is significanty different than mine under Eclipse. Is there an easy way to assure that at least my code appears to them as formatted as it does to me under Eclipse?

Lasse Koskela

Joined: Jan 23, 2002
Posts: 11962
I suspect that this difference in formatting is caused by your IDE and their IDE's having different settings for tab width? I don't know whether Emacs allows setting tab width like Eclipse does, though, but it would be weird if it didn't.

Author of Test Driven (2007) and Effective Unit Testing (2013) [Blog] [HowToAskQuestionsOnJavaRanch]
Mark Spritzler

Joined: Feb 05, 2001
Posts: 17271

Lasse, I am kind of on your wavelength. Meaning that the Tabs in the EMACs were converted to spaces, where they stay tabs in Eclipse, or vice-a-versa.

If you both have tabs set to 4 spaces, and if one converts tabs to spaces that it converts it to 4 spaces.

You find this kind of formatting issues, even in MS Word.


Perfect World Programming, LLC - Two Laptop Bag - Tube Organizer
How to Ask Questions the Smart Way FAQ
I’ve looked at a lot of different solutions, and in my humble opinion Aspose is the way to go. Here’s the link: http://aspose.com
subject: Eclipse 3.0 Formatting
It's not a secret anymore!