I am working with Java. If I hit Ctrl+Shift+F in Eclipse Helios, it will auto format the entire file instead of the lines I edited. This becomes a nightmare at the time of check in when someone else uses a different style on the same file. Is there a way to tell eclipse to only format the touched lines in a file.
If you select a range of lines in the editor then the format is done just on that range, if there is nothing selected the whole file is formatted.
You can change the formatting style used in Preferences / Java / Code Style / Formatter.
You can control formatting and other actions done when saving a file in the Jova / Editor / Save Actions preferences.
Windows-Preferences-Java-Editor-Save Actions
Format only saved lines. However, if you hit Ctrl+shift+f i don't think there is a way that only edited lines will be saved.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With