I thought this would be easy to achieve, but so far I haven\'t found solutions for comment/uncomment shortcut on both Java class editor
and jsf faceted we
CTRL + 7
does comment/uncomment in the Java Editor.
Source -> Remove Block Comment
link
An easier way is to press Ctrl + Shift + C, just like in Code::Blocks
For single line comment you can use Ctrl + / and for multiple line comment you can use Ctrl + Shift + / after selecting the lines you want to comment in java editor.
On Mac/OS X you can use ⌘ + / to comment out single lines or selected blocks.
Ctrl+/ to toggle "//" comments and Ctrl+Shift/ to toggle "/* */" comments. At least for Java, anyway - other tooling may have different shortcuts.
Ctrl+\ will remove a block of either comment, but won't add comments.
EDIT: It's Ctrl on a PC, but on a Mac the shortcuts may all be Cmd instead. I don't have a Mac myself, so can't easily check
Use
Ctrl + SHIFT + L which will open a list of all major shortcuts for eclipse.
For single line java code comment and uncomment : Ctrl + / (Forward Slash)
For multiple line java code comment : Ctrl + Shift + / (Forward Slash) and
Multiline uncomment : Ctrl + Shift + \ (Backslash)
For single line xhtml code comment/uncomment : Ctrl + Shift + c
For multiple line xhtml code comment : Ctrl + Shift + / (Forward Slash)
For multiple uncomment : Ctrl + Shift + \ (Backward Slash)
For Mac user it will be: ⌘ instead of Ctrl