Bug in the Log window menus of Fiji: "Clear" doesn't clear the log window but the selection in the active image window

Bug in the Log window menus of Fiji: “Edit - Clear” doesn’t clear the log window but the selection in the active image window.

1 Like

Sorry, I can’t reproduce the issue with an up-to-date Fiji on Windows 7 and Windows 10. I tried with both the Log window and the Console window, and the Edit > Clear menu command works as expected.

Please provide details about your system (OS, Java version, activated update sites etc.) and a recipe to reproduce the issue.

Ubuntu 16.04, Fiji updated to 2 days ago. Java 8.

1 Like

Hello Albert -

I can (nearly) reproduce this on “ubuntu 16.04 LTS” running “(Fiji Is
Just) ImageJ 2.0.0-rc-69/1.52i; Java 1.8.0_66 [64-bit];”.

I launch (a freshly updated) Fiji, and run the following jython script
from the script editor:

from ij import IJ
IJ.log ('a log message')

This opens the “Log” window with the above message in it. I then run
Edit > Clear from the Log-window menu bar. Instead of clearing
the Log window, this pops up a “Selection required” message box.

If, instead, I first create a new image (File > New > Image...)
and select a rectangle in it (with the Rectangle tool), then run the
IJ.log ('a log message') script, and finally run Edit > Clear,
I get the same result. That is, neither the Log window nor the image
selection is cleared, but again the “Selection required” message box
pops up.

Note, if I open the Console window, Window > Console, running
Edit > Clear from the Console-window menu bar works as expected.
The active-image selection isn’t cleared, and no “Selection required”
message box pops up. This is true whether the “Console” or “Log”
tab of the Console window is selected.

Thanks, mm

It can be confusing since there are two Edit>Clear commands. The one in the “ImageJ” window clears the selection in the active image. The one in the Log window (and tables) deletes the currently selected rows. If no rows are selected, it displays a misleading “Selection required” message.

With the latest daily build (1.52k42), the behavior of the Clear command in Log windows (and tables) has changed. Now, if there are no rows selected it deletes all the rows except when the window has the title “Results”. In that case, it runs the “Clear Results” command.

Hello Wayne -

I can confirm that this is what I was seeing. If I redo my test, but
explicitly select a row in the Log window , running Edit > Clear
from the Log-window menu does clear the selected row. The
“Selection required” message only pops up if no rows are selected.

I ran Help > Upgrade ImageJ... to upgrade to 1.52k42 and can
confirm that Edit > Clear now clears the Log window if no rows
are selected. (No popup message.)

I wonder then what Albert was seeing. I didn’t ever reproduce his
core issue where the active-image selection got cleared.

Thanks, mm

1 Like

Indeed what I saw was the same popup message and I wrongly inferred that it had to do with clearing a selection on an image.

Thanks very much for testing and properly reporting the issue, and thanks a lot Wayne for the fix! Clearing all rows when none are selected in the Log window makes perfect sense and is what I was expecting upon invoking the command.