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 955 - toScaled() gives wrong values when a macro has drawn a new plot in an existing plot window
toScaled() gives wrong values when a macro has drawn a new plot in an existin...
Status: RESOLVED FIXED
Product: Fiji
Classification: Unclassified
Component: ImageJ1
unspecified
All All
: P5 normal
Assigned To: ImageJ Bugs Mailing List
Depends on:
Blocks:
 
Reported: 2014-11-07 03:12 CST by Johan Tolö
Modified: 2014-11-07 11:44 CST
1 user (show)

See Also:


Attachments
Patch to fix issue with a plot window not having updated calibration values set (623 bytes, patch)
2014-11-07 03:12 CST, Johan Tolö

Description Johan Tolö 2014-11-07 03:12:03 CST
Created attachment 220
Patch to fix issue with a plot window not having updated calibration values set

If a macro draws a new plot using Plot.create() in an existing plot window by
calling Plot.update(), a subsequent usage of toScaled for that plot will give
the wrong values. toScaled will scale its arguments using the properties of
the plot drawn when initially creating the plot window. This happens
completely without the user being aware.

The reason for this as far as I can tell is that using the Plot.update() macro
function calls the drawPlot() method of the plot window PlotWindow instance.
But this does not transfer the calibration data from the Plot to the
ImageProcessor of the PlotWindow instance. A patch that fixes this issue for
me is attached.
Comment 1 Wayne Rasband 2014-11-07 11:44:56 CST
This bug is fixed in the ImageJ 1.49k12 daily build. The commit can be viewed at <https://github.com/fiji/imagej1/commits/>.