Used internally.
(ImagePlus imp)
| 2806 | |
| 2807 | /** Used internally. */ |
| 2808 | public void copyAttributes(ImagePlus imp) { |
| 2809 | if (IJ.debugMode) IJ.log("copyAttributes: "+imp.getID()+" "+this.getID()+" "+imp+" "+this); |
| 2810 | if (imp==null || imp.getWindow()!=null) |
| 2811 | throw new IllegalArgumentException("Source image is null or displayed"); |
| 2812 | ID = imp.getID(); |
| 2813 | setTitle(imp.getTitle()); |
| 2814 | setCalibration(imp.getCalibration()); |
| 2815 | FileInfo fi = imp.getOriginalFileInfo(); |
| 2816 | if (fi!=null) |
| 2817 | setFileInfo(fi); |
| 2818 | Object info = imp.getProperty("Info"); |
| 2819 | if (info!=null) |
| 2820 | setProperty("Info", imp.getProperty("Info")); |
| 2821 | setProperties(imp.getPropertiesAsArray()); |
| 2822 | Object plot = imp.getProperty(Plot.PROPERTY_KEY); |
| 2823 | if (plot != null) |
| 2824 | setProperty(Plot.PROPERTY_KEY, plot); |
| 2825 | } |
| 2826 | |
| 2827 | /** Calls System.currentTimeMillis() to save the current |
| 2828 | time so it can be retrieved later using getStartTime() |
no test coverage detected