[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [Newsgroup Home]
[news.eclipse.newcomer] Re: Suggestion: improvement of java line/block commenting in eclipse

In article <fh6tdk$khs$1@xxxxxxxxxxxxxxxxx>, thomas2@xxxxxxxxx says...
> I don't really know if this is the right place to post improvement 
> suggestions for eclipse :).
> 
> S1. When using // in front of a line that denotes a block of java code 
> automatically change the commenting to block commenting and surround the 
> code. The change would happen instantly when I type the second /.

I would hope this would be configurable. I often don't want to comment 
out the entire structured section, just the initiation line and 1 or 2 
lines inside it.


> 
> S2. When deleting a top block comment remove the bottom one 
> automatically. The auto-removal of the / and */ would happen instantly 
> when removing the * in /*.

This one I agree with.

 
> These two implementations would probably save an massive amount of time 
> for many java developers.

Maybe if they had key bindings for them; I wouldn't want it to be 
automatic, though.

> 
> See examples below.
> 
> Thanks
> Thomas
> 
> Example 1 (S1):
> -Source
>      for( int i = 0; i < 10; i++ )
>      {
>         ... some code ...
>      }	
> -Before
> //    for( int i = 0; i < 10; i++ )
>      {
>         ... some code ...
>      }	
> -After
> /*
>      for( int i = 0; i < 10; i++ )
>      {
>         ... some code ...
>      }	
> */
> 
> Example 2 (S1):
> -Source
>      canvas.getCamera().setFrustumPerspective( 45.0f,
>                                                aspect,
>                                                1,
>                                                10000 );
> -Before
> //    canvas.getCamera().setFrustumPerspective( 45.0f,
>                                                aspect,
>                                                1,
>                                                10000 );
> -After

-- 
Remove the ns_ from if replying by e-mail (but keep posts in the 
newsgroups if possible).