NOTICE! This is a static HTML version of a legacy Fiji BugZilla bug.

The Fiji project now uses GitHub Issues for issue tracking.

Please file all new issues there.

Bug 685 - Weird Stitching UI behavior.
Weird Stitching UI behavior.
Status: RESOLVED MOVED
Product: Fiji
Classification: Unclassified
Component: Other
unspecified
All All
: P3 normal
Assigned To: ImageJ Bugs Mailing List
Depends on:
Blocks:
 
Reported: 2013-12-16 07:56 CST by Niko Ehrenfeuchter
Modified: 2014-01-08 12:20 CST
3 users (show)

See Also:

Description Niko Ehrenfeuchter 2013-12-16 07:56:21 CST
The stitching UI behaves very weird after being started by a macro command *once*.

Steps to reproduce (tested on Linux and Win7 x64):

* download a fresh copy of Fiji
* start
* run the stitcher via Plugins > Stitching > Grid/Collection stitching
* "normal" dialog comes up (notice the graphic representation of the selected settings)
* hit "Cancel"
* File > New > Script
* Language > ImageJ Macro
* enter 'run("Grid/Collection stitching");'
* hit "Run"
* dialog doesn't show the graphical representation, *AND* allows for invalid combinations of options (e.g. "Positions from file" and "Right & Down")

I could live with the temporary workaround of not calling the stitcher from a macro for a while, however after starting it using the above described command *once*, the behavior stays like this. I.e. you can't run it correctly from the Plugins menu anymore either.

Cheers
~Niko
Comment 1 Stephan Preibisch 2013-12-16 08:12:09 CST
In order to allow the macro recording to work, it shows a simpler version when called from a macro, this is on purpose, otherwise it would not work. Usually, it is supposed to be called with a lot of parameters so that it runs automatically.

However, when running the plugin afterwards from the menu, it still thinks that it is in plugin mode. The bug seems to be on the ImageJ/Fiji side, as the call

IJ.isMacro()

still returns true although it is called through the menu. Does anybody have an idea how this can happen?
Comment 2 Wayne Rasband 2013-12-16 13:22:33 CST
Stephan,

You could try using IJ.macroRunning() instead of IJ.isMacro(). Here is the source for these two methods:

  /** Returns true if the run(), open() or newImage() method is executing. */
  public static boolean macroRunning() {
    return macroRunning;
  }

  /** Returns true if a macro is running, or if the run(),
      open() or newImage() method is executing. */
  public static boolean isMacro() {
    return macroRunning || Interpreter.getInstance()!=null;
  }
Comment 3 Curtis Rueden 2014-01-08 12:20:09 CST
See https://github.com/fiji/Stitching/issues/1