• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Eclipse Source/Format is great!

 
Ranch Foreman
Posts: 854
7
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I just found the Source/Format in the Eclipse IDE editor.  It reminds me of the Beautify feature in FoxPro for windows.   I like it a lot.  
No question here.  Only happiness!
Thanks,
Kevin
 
Saloon Keeper
Posts: 10653
85
Eclipse IDE Firefox Browser MySQL Database VI Editor Java Windows ChatGPT
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
When you get to configuring your own style you'll see the power of it all. My personal preferences is to have a white space after an open paren and before a closing paren, as well as white space surrounding operators.

I also prefer
over
It's a matter of personal preference or whatever your development team decides. After I made a complete style with my prefered braces I then made a copy of it with everything the same except for the other brace style. This helps when I'm dealing with an audience that prefers the second style.
 
Rancher
Posts: 5008
38
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
If only PC editors positioned  a "Found" line at other than the top line.
My editor has a Find pairing { for a } >>> Cursor on } and press Ctrl and ] to position to the paring {
Now if the { is on a line below where the logic is, there needs to be further moving of the source to see the logic.
With { on the same line as the logic as in your first case, no further moving needs be done.

IMO I prefer the second
 
Bartender
Posts: 1868
81
Android IntelliJ IDE MySQL Database Chrome Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You may want to look into adding and using editorconfig to your IDE of choice.

http://editorconfig.org wrote:EditorConfig helps developers define and maintain consistent coding styles between different editors and IDEs.
The EditorConfig project consists of a file format for defining coding styles and a collection of text editor plugins that enable editors to read the file format and adhere to defined styles.
EditorConfig files are easily readable and they work nicely with version control systems.


You can read more about it here http://editorconfig.org/

There is a plugin for Eclipse, IntelliJ, Visual Studio and many other editors used by programmers.
With this everyone on your team sees everything the same way in the editor of choice.
 
kevin Abel
Ranch Foreman
Posts: 854
7
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Carey
Norm
Pete

I did not know the feature is modifiable to format code how I want.   I better stick to learning to code in java first and then learn the fun details.

Thanks,

Kevin
 
And then we all jump out and yell "surprise! we got you this tiny ad!"
a bit of art, as a gift, the permaculture playing cards
https://gardener-gift.com
reply
    Bookmark Topic Watch Topic
  • New Topic