Eclipse insertion of multiple comment lines
At present if I type "/*" and press enter I get the follwing .
/*
*
*/
Is there a setting somewere that allwos me to 开发者_Python百科make the default like this
/*
* TESTING
*/
thanks
Indeed there is! Assuming you want to change the Java code templates (though it's similar for other plugins too):
First, go to Window -> Preferences.
Then, Java -> Code Style -> Code Templates -> Comments.
Now that I have a better idea of what you are looking for, I think what you want is to define a custom code template.
Again, go to Window -> Preferences.
Then, Java -> Editor -> Templates. Create a new template.
Under name give it something like 'xxx' so you won't collide with other reserved words (unfortunately, anything with / or /* is reserved). For the pattern, just add the following:
/*
* TESTING
*/
Now, when you type 'xxx' then CTRL+<space> in the editor, it will replace it with your comment template.
See also: Eclipse Code Templates (pdf)
精彩评论