Copy-paste image then copy-paste the macro from the scripter



Is it possible to copy paste a macro from the scripter after copying an image?

It seems that as soon as I copy an image (or a part of an image) using a macro or the Edit Menu or Ctrl+C, I can’t copy-paste the text of a macro from the scripter (in order to paste the macro in the Fiji status bar and debug it). In this case, if I try to paste the macro in the status bar, I get only the last copied image.

Is it normal (which would be very strange, IMHO) or is it a bug?




Dear @Fabien,

What exactly are you trying to achieve? Could you please be a bit more specific so that we can help you.



Hi Stefan,

thanks for your answer.

I would like to debug a macro in Fiji. So I copy the macro from the Script Editor and I paste it in the status bar in order to open the Clipboard and debug the macro step by step.

Unfortunately, if I copy an image with the macro before trying to copy-paste the macro in the status bar, when I paste in the status bas, I only paste the last copied image. It seems that the copy of the text of the macro is not taken in account.

If you want to try to get the same behavior :

  • open an image
  • write a macro in which you copy the image.
  • close the image and copy the text of the macro
  • paste it in the status bar.
  • the last copied image should be pasted and not the text of the macro.

I hope you will understand what I mean.




Dear @Fabien,

Thank you for your detailed explanation! I was able to reproduce the issue. When copying from the Script Editor, you are copying into the system’s clipboard. When copying an image, however, you are using an internal ImageJ clipboard (unless you use Edit > Copy to System) which takes precedence over the system’s clipboard. You can either use File > New > System Clipboard to get your desired behavior or use the shortcut Ctrl+Shift+V.


Thanks for your answer. That works!