Within our team, we have an eclipse formatter profile that we are using for some years. It seemed to work fine within Eclipse Neon, but today I discovered that the formatter is no longer "trimming" empty lines.
When using older versions of eclipse, running the formatter simply trims lines that only contain spaces. The line is still there, but the spaces are all gone after formatting.
I checked the formatter options; but I can't find a checkbox that would match.
For the record: I saw this, but using "trim on save" is a no go for me: very often I have to make subtle changes in files from other people; and I intentionally do not format those files; because the diff would be huge. And for the same reason, I don't want that "save" trims empty lines either. Before Neon, I would press ctrl-f on purpose; also to trim lines; now it doesn't have that effect any more.
Any idea where to fix that?
As the answer says in the linked question, you could do on save for only lines you have changed
Removing whitespace only from the lines I changed:
Preferences -> Java -> Editor -> Save Actions -> check "Perform the selected actions on save" -> check "Format source code" -> select "Format edited lines".