Friday, June 4, 2010

Automated String Escaping in Eclipse

When having to paste text into a String in Eclipse which includes quotes, line breaks etc. nearly everyone does it manually. However, Eclipse actually comes with a feature which does this automatically for you. But for some weird reason it turned off.

You can turn it on under Window / Preferences / Java / Editor / Typing / Escape text when pasting into string literal.

No comments: