Skip to main content



      Home
Home » Language IDEs » Java Development Tools (JDT) » Formatter does not support Ratliff style(There is no option to indent closing braces)
Formatter does not support Ratliff style [message #1719835] Tue, 12 January 2016 09:04 Go to next message
Eclipse UserFriend
Our developers currently use jIndent in both Eclipse and Netbeans, and years and years of discussions and compromises lead us to use Ratliff- or banner-style ( en.wikipedia.org/wiki/Indent_style#Ratliff_style ) for brace placements in all languages used: C, perl, java, ruby

The managers want to save money and abolish jIndent and use the default formatters in the IDE and asked me to find where they fall short.

So far I have not spotted an option in NetbeansEclipse' java formatter to select indentation of the closing brace.

Did I miss it? Is there an option to get the NetbeansEclipse java formatter to do what we want?

if (c.isFoo ()) {

    if (c.isBar ())
        return; 

    String str = c.getActionDescription ();
    if ("ABORT".equals (str)) {
        process.abort ();
        LOG.info ("Process aborted");
        }
    else
        LOG.info ("Process will do " + str);
    }


Please don't answer if all you do is vent the opinion that you think that is a stupid style. You are entitled to have your own opinion and I agree that you may disagree with the required layout/style: end of argue. Note that it is not up to you to set developer-group rules. I'm just seeking the option to use this style, and jIndent is supporting that.

[Updated on: Wed, 13 January 2016 08:23] by Moderator

Re: Formatter does not support Ratliff style [message #1719838 is a reply to message #1719835] Tue, 12 January 2016 09:31 Go to previous messageGo to next message
Eclipse UserFriend
Quote:
So far I have not spotted an option in netbeans' java formatter to select indentation of the closing brace.

Did I miss it? Is there an option to get the netbeans java formatter to do what we want?


You are not asking netbeans questions in an Eclipse forum, are you? Smile
Re: Formatter does not support Ratliff style [message #1719840 is a reply to message #1719838] Tue, 12 January 2016 09:42 Go to previous messageGo to next message
Eclipse UserFriend
I asked the sme question about the netbeans formatter in the netbeans forum.

This question is about the Eclipse java formatter (but it is the same question)

Right. I see where I errored on the copy-paste and change. Lemme see if I can change that...
Found and changed. Thanks for spotting.

/me still hopes for a better answer

[Updated on: Tue, 12 January 2016 10:01] by Moderator

Re: Formatter does not support Ratliff style [message #1719860 is a reply to message #1719840] Tue, 12 January 2016 11:19 Go to previous message
Eclipse UserFriend
There's still a copy-paste error, but I can see past it.

The short answer is: I don't see an option to adjust the placement of closing braces.

Perhaps your management would consider allowing you to contribute such an option, since by doing so they can stop paying for jIndent (assuming there is some other solution for NetBeans).
Previous Topic:Update marker attributes while file being edited
Next Topic:Programmatically Rename and Move a Java Class
Goto Forum:
  


Current Time: Tue Jul 15 11:35:39 EDT 2025

Powered by FUDForum. Page generated in 0.11848 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top