Wrapping text [message #652331] |
Thu, 03 February 2011 15:37 |
|
Hi,
In order to read the some source code well I've enlarged the font size to 14 , In a "heavy" code I often need to scroll the bottom bar to the right in order to see long code lines.
Is there an option in the editor (in this case I'm talking about the Java perspective) that the text will be wrapped up to be in the size of the window code ?
Thanks,
|
|
|
Re: Wrapping text [message #652334 is a reply to message #652331] |
Thu, 03 February 2011 15:42 |
|
Go to Source-> Format or use shorcut key Ctrl+ Shift + F. That does the word wrap. I guess that should help.
Regards,
Animesh
Regards,
Animesh
|
|
|
|
Re: Wrapping text [message #652345 is a reply to message #652337] |
Thu, 03 February 2011 16:11 |
|
Deepak Azad wrote on Thu, 03 February 2011 10:47 |
See Window > Preferences > ... > Formatter > Line Wrapping > Maximum
line width
|
Listen this only applies for the Ant's XML editor.
When I go to "Window > Preferences > Java > Code style > Formatter" there is no option to wrap text or to set "Maximum line width (characters)"
Thanks
[Updated on: Thu, 03 February 2011 16:12] Report message to a moderator
|
|
|
Re: Wrapping text [message #652351 is a reply to message #652345] |
Thu, 03 February 2011 16:19 |
|
Roey Peretz wrote on Thu, 03 February 2011 21:41 | Deepak Azad wrote on Thu, 03 February 2011 10:47 |
See Window > Preferences > ... > Formatter > Line Wrapping > Maximum
line width
|
Listen this only applies for the Ant's XML editor.
When I go to "Window > Preferences > Java > Code style > Formatter" there is no option to wrap text or to set "Maximum line width (characters)"
Thanks
|
Hi,
This option is available for Java also. In Java-> Code Style -> Formatter-> Under Active Profile, Click New and for the option "Initialize Setting with the following profile" you can choose whichever built in profile you want to use and then you will get another dialog which will have a tab for Line Wrapping. You can set your value there.
You can just check the availability of this feature by clicking Edit for built in Profiles, but you cannot change anything there for built in Profiles.
Regards,
Animesh
[Updated on: Thu, 03 February 2011 16:36] Report message to a moderator
|
|
|
|
Re: Wrapping text [message #652378 is a reply to message #652367] |
Thu, 03 February 2011 17:22 |
|
Roey Peretz wrote on Thu, 03 February 2011 22:26 | Animesh Kumar wrote on Thu, 03 February 2011 11:19 | Roey Peretz wrote on Thu, 03 February 2011 21:41 | Deepak Azad wrote on Thu, 03 February 2011 10:47 |
See Window > Preferences > ... > Formatter > Line Wrapping > Maximum
line width
|
Listen this only applies for the Ant's XML editor.
When I go to "Window > Preferences > Java > Code style > Formatter" there is no option to wrap text or to set "Maximum line width (characters)"
Thanks
|
Hi,
This option is available for Java also. In Java-> Code Style -> Formatter-> Under Active Profile, Click New and for the option "Initialize Setting with the following profile" you can choose whichever built in profile you want to use and then you will get another dialog which will have a tab for Line Wrapping. You can set your value there.
You can just check the availability of this feature by clicking Edit for built in Profiles, but you cannot change anything there for built in Profiles.
|
Where is "Initialize Setting with the following profile" option ?
I've created new profile in "Window > Preferences > Java > Code style > Formatter" called MyForm I've edited it to "wrap text whenever necessary" pressed OK then Apply then another OK and nothing happens.
It is my active profile in the Java editor.
When I press Ctrl+Shift+F it doesn't format the code as I defined in MyForm.
|
Have you changed the Line Wrapping Policy in Line Wrap Tab for each element in the List Box. Try Changing it for:-
Constructors ,Methods Declaration, Function Calls, Expressions, and Statements to "Wrap all elements, every element on a new line". I tried this using font size 14 and Maximum Line Width 40 and it worked for me. It should work for you also.
Regards,
Animesh
Regards,
Animesh
|
|
|
Re: Wrapping text [message #652393 is a reply to message #652378] |
Thu, 03 February 2011 18:00 |
|
Animesh Kumar wrote on Thu, 03 February 2011 12:22 | Roey Peretz wrote on Thu, 03 February 2011 22:26 | Animesh Kumar wrote on Thu, 03 February 2011 11:19 | Roey Peretz wrote on Thu, 03 February 2011 21:41 | Deepak Azad wrote on Thu, 03 February 2011 10:47 |
See Window > Preferences > ... > Formatter > Line Wrapping > Maximum
line width
|
Listen this only applies for the Ant's XML editor.
When I go to "Window > Preferences > Java > Code style > Formatter" there is no option to wrap text or to set "Maximum line width (characters)"
Thanks
|
Hi,
This option is available for Java also. In Java-> Code Style -> Formatter-> Under Active Profile, Click New and for the option "Initialize Setting with the following profile" you can choose whichever built in profile you want to use and then you will get another dialog which will have a tab for Line Wrapping. You can set your value there.
You can just check the availability of this feature by clicking Edit for built in Profiles, but you cannot change anything there for built in Profiles.
|
Where is "Initialize Setting with the following profile" option ?
I've created new profile in "Window > Preferences > Java > Code style > Formatter" called MyForm I've edited it to "wrap text whenever necessary" pressed OK then Apply then another OK and nothing happens.
It is my active profile in the Java editor.
When I press Ctrl+Shift+F it doesn't format the code as I defined in MyForm.
|
Have you changed the Line Wrapping Policy in Line Wrap Tab for each element in the List Box. Try Changing it for:-
Constructors ,Methods Declaration, Function Calls, Expressions, and Statements to "Wrap all elements, every element on a new line". I tried this using font size 14 and Maximum Line Width 40 and it worked for me. It should work for you also.
Regards,
Animesh
|
At last...the answer was "Window > Preferences > Java > Code style > Formatter > Configure Project Specific Settings..."
And then select a project from the list press OK and activate MyForm on it...
THNX ALOT my dear friend
|
|
|
Powered by
FUDForum. Page generated in 0.02996 seconds