Toggle commenting out IJM code in script editor


Is there a way to quickly comment/uncomment IJ1 macro code in the script editor, similar to insert your favourite IDE here (usually Cmd + / or Cmd + Shift + C or Cmd + 7)?

Edit: I realise it is possible with other languages (e.g. JavaScript) using Cmd + /.
My original question still stands…


1 Like


You are correct that the comment/uncomment shortcuts do not apply to the IJ1 Macro code. I posted in one of the open issues for the Script Editor on github to ask if such functionality can be extended to the IJ1 Macro language (linking there to this forum thread).

1 Like

The fact that this shortcut did not work with the ImageJ macro language was a bug in the Script Editor’s IJ1 macro language plugin. Now fixed. Run Help › Update… to get the new version.


Thank you, @etadobson! :+1:'d.

1 Like

The new version of the Script Editor works as I hoped. Thank you @ctrueden!


Hi all,

I just chatted with a colleague and it appears that this issue still persists on Windows computers with German keyboards (because the / sits on the 7 key). Can we add the short-cut CTRL+7 for commenting blocks? If yes, where in the code could one add a keyboard-shortcut? I can’t find the place in the code where this is done…

Thanks for your support!