Possible to change settings for CTRL + SHIFT + F in Eclipse?

25,088

Solution 1

You can configure your formatter options in "windows/Preferences/Java/Code Style/Formatter". Click on edit your profile. Here you have "line wrapping" options.

Solution 2

Set "Line width for preview window" option and "maximum line width" option in Preferences/Java/Code Style/Formatter. Before that you should create a new profile name instead of default profile name

Share:
25,088

Related videos on Youtube

3D-kreativ
Author by

3D-kreativ

merge delete

Updated on November 02, 2020

Comments

  • 3D-kreativ
    3D-kreativ about 2 years

    When I use the combinations of CTRL + SHIFT + F to format the code in Eclipse, I don't like when it brakes the lines like this:

    Toast.makeText(Activity_1.this, String.valueOf(numbersOfRows),
                    Toast.LENGTH_LONG).show();
    

    If I want to put comment signs like // in the beginning of the line, then I have to do the same on the second line otherwise I get an error!

    Is there a way to prevent braking rows like that?

Related