Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Newcomers » Newcomers » Wrapping text (Is there an option for this in the editor ?)
icon5.gif  Wrapping text [message #652331] Thu, 03 February 2011 15:37 Go to next message
Roey  is currently offline Roey Friend
Messages: 16
Registered: April 2010
Junior Member
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,
Rolling Eyes
Re: Wrapping text [message #652334 is a reply to message #652331] Thu, 03 February 2011 15:42 Go to previous messageGo to next message
Animesh Kumar is currently offline Animesh KumarFriend
Messages: 79
Registered: September 2010
Location: Bangalore
Member
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 #652337 is a reply to message #652331] Thu, 03 February 2011 15:47 Go to previous messageGo to next message
Deepak Azad is currently offline Deepak AzadFriend
Messages: 543
Registered: July 2009
Senior Member
On 2/3/2011 9:07 PM, Roey Peretz wrote:
> 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,
> :roll:
See Window > Preferences > ... > Formatter > Line Wrapping > Maximum
line width
Re: Wrapping text [message #652345 is a reply to message #652337] Thu, 03 February 2011 16:11 Go to previous messageGo to next message
Roey  is currently offline Roey Friend
Messages: 16
Registered: April 2010
Junior Member
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
Rolling Eyes

[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 Go to previous messageGo to next message
Animesh Kumar is currently offline Animesh KumarFriend
Messages: 79
Registered: September 2010
Location: Bangalore
Member
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
Rolling Eyes

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 #652367 is a reply to message #652351] Thu, 03 February 2011 16:56 Go to previous messageGo to next message
Roey  is currently offline Roey Friend
Messages: 16
Registered: April 2010
Junior Member
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
Rolling Eyes

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.
Confused

[Updated on: Thu, 03 February 2011 16:57]

Report message to a moderator

Re: Wrapping text [message #652378 is a reply to message #652367] Thu, 03 February 2011 17:22 Go to previous messageGo to next message
Animesh Kumar is currently offline Animesh KumarFriend
Messages: 79
Registered: September 2010
Location: Bangalore
Member
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
Rolling Eyes

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.
Confused



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. Smile
Regards,
Animesh


Regards,
Animesh
icon14.gif  Re: Wrapping text [message #652393 is a reply to message #652378] Thu, 03 February 2011 18:00 Go to previous message
Roey  is currently offline Roey Friend
Messages: 16
Registered: April 2010
Junior Member
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
Rolling Eyes

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.
Confused



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. Smile
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
Smile
Previous Topic:Send Serialized data from Applet to Servlet and Ack from Servlet
Next Topic:Basic Export Question
Goto Forum:
  


Current Time: Fri Mar 29 06:08:53 GMT 2024

Powered by FUDForum. Page generated in 0.02996 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top