temporarily remove ij_source
authorarthur <arthur@2c67d6c2-4361-4cd7-bd83-1149b1926c9b>
Thu, 15 Dec 2011 18:05:00 +0000 (18:05 +0000)
committerarthur <arthur@2c67d6c2-4361-4cd7-bd83-1149b1926c9b>
Thu, 15 Dec 2011 18:05:00 +0000 (18:05 +0000)
git-svn-id: https://valelab.ucsf.edu/svn/3rdpartypublic@94 2c67d6c2-4361-4cd7-bd83-1149b1926c9b

653 files changed:
sourceext/ij_source/.gitignore [deleted file]
sourceext/ij_source/Fakefile [deleted file]
sourceext/ij_source/IJ_Props.txt [deleted file]
sourceext/ij_source/MANIFEST.MF [deleted file]
sourceext/ij_source/Makefile [deleted file]
sourceext/ij_source/aREADME.txt [deleted file]
sourceext/ij_source/applet.html [deleted file]
sourceext/ij_source/compile.bat [deleted file]
sourceext/ij_source/compile.sh [deleted file]
sourceext/ij_source/ij/CommandListener.java [deleted file]
sourceext/ij_source/ij/CompositeImage.java [deleted file]
sourceext/ij_source/ij/Executer.java [deleted file]
sourceext/ij_source/ij/IJ.java [deleted file]
sourceext/ij_source/ij/IJEventListener.java [deleted file]
sourceext/ij_source/ij/ImageJ.java [deleted file]
sourceext/ij_source/ij/ImageJApplet.java [deleted file]
sourceext/ij_source/ij/ImageListener.java [deleted file]
sourceext/ij_source/ij/ImagePlus.java [deleted file]
sourceext/ij_source/ij/ImageStack.java [deleted file]
sourceext/ij_source/ij/LookUpTable.java [deleted file]
sourceext/ij_source/ij/Macro.java [deleted file]
sourceext/ij_source/ij/Menus.java [deleted file]
sourceext/ij_source/ij/Prefs.java [deleted file]
sourceext/ij_source/ij/RecentOpener.java [deleted file]
sourceext/ij_source/ij/SocketListener.java [deleted file]
sourceext/ij_source/ij/Undo.java [deleted file]
sourceext/ij_source/ij/VirtualStack.java [deleted file]
sourceext/ij_source/ij/WindowManager.java [deleted file]
sourceext/ij_source/ij/gui/Arrow.java [deleted file]
sourceext/ij_source/ij/gui/ColorChooser.java [deleted file]
sourceext/ij_source/ij/gui/DialogListener.java [deleted file]
sourceext/ij_source/ij/gui/FreehandRoi.java [deleted file]
sourceext/ij_source/ij/gui/GUI.java [deleted file]
sourceext/ij_source/ij/gui/GenericDialog.java [deleted file]
sourceext/ij_source/ij/gui/HTMLDialog.java [deleted file]
sourceext/ij_source/ij/gui/HistogramWindow.java [deleted file]
sourceext/ij_source/ij/gui/ImageCanvas.java [deleted file]
sourceext/ij_source/ij/gui/ImageLayout.java [deleted file]
sourceext/ij_source/ij/gui/ImageRoi.java [deleted file]
sourceext/ij_source/ij/gui/ImageWindow.java [deleted file]
sourceext/ij_source/ij/gui/Line.java [deleted file]
sourceext/ij_source/ij/gui/MessageDialog.java [deleted file]
sourceext/ij_source/ij/gui/MultiLineLabel.java [deleted file]
sourceext/ij_source/ij/gui/NewImage.java [deleted file]
sourceext/ij_source/ij/gui/NonBlockingGenericDialog.java [deleted file]
sourceext/ij_source/ij/gui/OvalRoi.java [deleted file]
sourceext/ij_source/ij/gui/Overlay.java [deleted file]
sourceext/ij_source/ij/gui/Plot.java [deleted file]
sourceext/ij_source/ij/gui/PlotWindow.java [deleted file]
sourceext/ij_source/ij/gui/PointRoi.java [deleted file]
sourceext/ij_source/ij/gui/PolygonRoi.java [deleted file]
sourceext/ij_source/ij/gui/ProfilePlot.java [deleted file]
sourceext/ij_source/ij/gui/ProgressBar.java [deleted file]
sourceext/ij_source/ij/gui/Roi.java [deleted file]
sourceext/ij_source/ij/gui/RoiBrush.java [deleted file]
sourceext/ij_source/ij/gui/RoiProperties.java [deleted file]
sourceext/ij_source/ij/gui/SaveChangesDialog.java [deleted file]
sourceext/ij_source/ij/gui/ScrollbarWithLabel.java [deleted file]
sourceext/ij_source/ij/gui/ShapeRoi.java [deleted file]
sourceext/ij_source/ij/gui/StackWindow.java [deleted file]
sourceext/ij_source/ij/gui/TextRoi.java [deleted file]
sourceext/ij_source/ij/gui/Toolbar.java [deleted file]
sourceext/ij_source/ij/gui/TrimmedButton.java [deleted file]
sourceext/ij_source/ij/gui/WaitForUserDialog.java [deleted file]
sourceext/ij_source/ij/gui/Wand.java [deleted file]
sourceext/ij_source/ij/gui/YesNoCancelDialog.java [deleted file]
sourceext/ij_source/ij/io/BitBuffer.java [deleted file]
sourceext/ij_source/ij/io/DirectoryChooser.java [deleted file]
sourceext/ij_source/ij/io/FileInfo.java [deleted file]
sourceext/ij_source/ij/io/FileOpener.java [deleted file]
sourceext/ij_source/ij/io/FileSaver.java [deleted file]
sourceext/ij_source/ij/io/ImageReader.java [deleted file]
sourceext/ij_source/ij/io/ImageWriter.java [deleted file]
sourceext/ij_source/ij/io/ImportDialog.java [deleted file]
sourceext/ij_source/ij/io/OpenDialog.java [deleted file]
sourceext/ij_source/ij/io/Opener.java [deleted file]
sourceext/ij_source/ij/io/PluginClassLoader.java [deleted file]
sourceext/ij_source/ij/io/PluginInstaller.java [deleted file]
sourceext/ij_source/ij/io/RandomAccessStream.java [deleted file]
sourceext/ij_source/ij/io/RoiDecoder.java [deleted file]
sourceext/ij_source/ij/io/RoiEncoder.java [deleted file]
sourceext/ij_source/ij/io/SaveDialog.java [deleted file]
sourceext/ij_source/ij/io/TextEncoder.java [deleted file]
sourceext/ij_source/ij/io/TiffDecoder.java [deleted file]
sourceext/ij_source/ij/io/TiffEncoder.java [deleted file]
sourceext/ij_source/ij/macro/ExtensionDescriptor.java [deleted file]
sourceext/ij_source/ij/macro/FunctionFinder.java [deleted file]
sourceext/ij_source/ij/macro/Functions.java [deleted file]
sourceext/ij_source/ij/macro/Interpreter.java [deleted file]
sourceext/ij_source/ij/macro/MacroConstants.java [deleted file]
sourceext/ij_source/ij/macro/MacroExtension.java [deleted file]
sourceext/ij_source/ij/macro/MacroRunner.java [deleted file]
sourceext/ij_source/ij/macro/Program.java [deleted file]
sourceext/ij_source/ij/macro/ReturnException.java [deleted file]
sourceext/ij_source/ij/macro/Symbol.java [deleted file]
sourceext/ij_source/ij/macro/Tokenizer.java [deleted file]
sourceext/ij_source/ij/macro/Variable.java [deleted file]
sourceext/ij_source/ij/measure/Calibration.java [deleted file]
sourceext/ij_source/ij/measure/CurveFitter.java [deleted file]
sourceext/ij_source/ij/measure/Measurements.java [deleted file]
sourceext/ij_source/ij/measure/ResultsTable.java [deleted file]
sourceext/ij_source/ij/measure/SplineFitter.java [deleted file]
sourceext/ij_source/ij/plugin/AVI_Reader.java [deleted file]
sourceext/ij_source/ij/plugin/AboutBox.java [deleted file]
sourceext/ij_source/ij/plugin/Animator.java [deleted file]
sourceext/ij_source/ij/plugin/ArrowToolOptions.java [deleted file]
sourceext/ij_source/ij/plugin/BMP_Reader.java [deleted file]
sourceext/ij_source/ij/plugin/BMP_Writer.java [deleted file]
sourceext/ij_source/ij/plugin/BatchConverter.java [deleted file]
sourceext/ij_source/ij/plugin/BatchMeasure.java [deleted file]
sourceext/ij_source/ij/plugin/BatchProcesser.java [deleted file]
sourceext/ij_source/ij/plugin/BrowserLauncher.java [deleted file]
sourceext/ij_source/ij/plugin/CanvasResizer.java [deleted file]
sourceext/ij_source/ij/plugin/ClassChecker.java [deleted file]
sourceext/ij_source/ij/plugin/Clipboard.java [deleted file]
sourceext/ij_source/ij/plugin/Colors.java [deleted file]
sourceext/ij_source/ij/plugin/CommandFinder.java [deleted file]
sourceext/ij_source/ij/plugin/CommandLister.java [deleted file]
sourceext/ij_source/ij/plugin/Commands.java [deleted file]
sourceext/ij_source/ij/plugin/Compiler.java [deleted file]
sourceext/ij_source/ij/plugin/CompositeConverter.java [deleted file]
sourceext/ij_source/ij/plugin/Concatenator.java [deleted file]
sourceext/ij_source/ij/plugin/ContrastEnhancer.java [deleted file]
sourceext/ij_source/ij/plugin/ControlPanel.java [deleted file]
sourceext/ij_source/ij/plugin/Converter.java [deleted file]
sourceext/ij_source/ij/plugin/DICOM.java [deleted file]
sourceext/ij_source/ij/plugin/DICOM_Sorter.java [deleted file]
sourceext/ij_source/ij/plugin/Distribution.java [deleted file]
sourceext/ij_source/ij/plugin/DragAndDrop.java [deleted file]
sourceext/ij_source/ij/plugin/Duplicator.java [deleted file]
sourceext/ij_source/ij/plugin/FFT.java [deleted file]
sourceext/ij_source/ij/plugin/FFTMath.java [deleted file]
sourceext/ij_source/ij/plugin/FITS_Reader.java [deleted file]
sourceext/ij_source/ij/plugin/FITS_Writer.java [deleted file]
sourceext/ij_source/ij/plugin/FileInfoVirtualStack.java [deleted file]
sourceext/ij_source/ij/plugin/FolderOpener.java [deleted file]
sourceext/ij_source/ij/plugin/GelAnalyzer.java [deleted file]
sourceext/ij_source/ij/plugin/GifWriter.java [deleted file]
sourceext/ij_source/ij/plugin/GroupedZProjector.java [deleted file]
sourceext/ij_source/ij/plugin/Histogram.java [deleted file]
sourceext/ij_source/ij/plugin/Hotkeys.java [deleted file]
sourceext/ij_source/ij/plugin/HyperStackConverter.java [deleted file]
sourceext/ij_source/ij/plugin/HyperStackReducer.java [deleted file]
sourceext/ij_source/ij/plugin/ImageCalculator.java [deleted file]
sourceext/ij_source/ij/plugin/ImageJ_Updater.java [deleted file]
sourceext/ij_source/ij/plugin/ImagesToStack.java [deleted file]
sourceext/ij_source/ij/plugin/Installer.java [deleted file]
sourceext/ij_source/ij/plugin/JavaProperties.java [deleted file]
sourceext/ij_source/ij/plugin/JpegWriter.java [deleted file]
sourceext/ij_source/ij/plugin/LUT_Editor.java [deleted file]
sourceext/ij_source/ij/plugin/ListVirtualStack.java [deleted file]
sourceext/ij_source/ij/plugin/LutLoader.java [deleted file]
sourceext/ij_source/ij/plugin/MacroInstaller.java [deleted file]
sourceext/ij_source/ij/plugin/Macro_Runner.java [deleted file]
sourceext/ij_source/ij/plugin/MeasurementsWriter.java [deleted file]
sourceext/ij_source/ij/plugin/Memory.java [deleted file]
sourceext/ij_source/ij/plugin/MemoryMonitor.java [deleted file]
sourceext/ij_source/ij/plugin/MontageMaker.java [deleted file]
sourceext/ij_source/ij/plugin/NewPlugin.java [deleted file]
sourceext/ij_source/ij/plugin/NextImageOpener.java [deleted file]
sourceext/ij_source/ij/plugin/Options.java [deleted file]
sourceext/ij_source/ij/plugin/Orthogonal_Views.java [deleted file]
sourceext/ij_source/ij/plugin/OverlayCommands.java [deleted file]
sourceext/ij_source/ij/plugin/PGM_Reader.java [deleted file]
sourceext/ij_source/ij/plugin/PNG_Writer.java [deleted file]
sourceext/ij_source/ij/plugin/PNM_Writer.java [deleted file]
sourceext/ij_source/ij/plugin/PlugIn.java [deleted file]
sourceext/ij_source/ij/plugin/ProxySettings.java [deleted file]
sourceext/ij_source/ij/plugin/RGBStackConverter.java [deleted file]
sourceext/ij_source/ij/plugin/RGBStackMerge.java [deleted file]
sourceext/ij_source/ij/plugin/RandomOvals.txt [deleted file]
sourceext/ij_source/ij/plugin/Raw.java [deleted file]
sourceext/ij_source/ij/plugin/Resizer.java [deleted file]
sourceext/ij_source/ij/plugin/RoiReader.java [deleted file]
sourceext/ij_source/ij/plugin/ScaleBar.java [deleted file]
sourceext/ij_source/ij/plugin/Scaler.java [deleted file]
sourceext/ij_source/ij/plugin/ScreenGrabber.java [deleted file]
sourceext/ij_source/ij/plugin/Selection.java [deleted file]
sourceext/ij_source/ij/plugin/SimpleCommands.java [deleted file]
sourceext/ij_source/ij/plugin/Slicer.java [deleted file]
sourceext/ij_source/ij/plugin/SpecifyROI.java [deleted file]
sourceext/ij_source/ij/plugin/StackCombiner.java [deleted file]
sourceext/ij_source/ij/plugin/StackEditor.java [deleted file]
sourceext/ij_source/ij/plugin/StackInserter.java [deleted file]
sourceext/ij_source/ij/plugin/StackMaker.java [deleted file]
sourceext/ij_source/ij/plugin/StackReverser.java [deleted file]
sourceext/ij_source/ij/plugin/StackWriter.java [deleted file]
sourceext/ij_source/ij/plugin/Straightener.java [deleted file]
sourceext/ij_source/ij/plugin/SubstackMaker.java [deleted file]
sourceext/ij_source/ij/plugin/SurfacePlotter.java [deleted file]
sourceext/ij_source/ij/plugin/TextFileReader.java [deleted file]
sourceext/ij_source/ij/plugin/TextReader.java [deleted file]
sourceext/ij_source/ij/plugin/TextWriter.java [deleted file]
sourceext/ij_source/ij/plugin/ThreadLister.java [deleted file]
sourceext/ij_source/ij/plugin/Thresholder.java [deleted file]
sourceext/ij_source/ij/plugin/Timer.java [deleted file]
sourceext/ij_source/ij/plugin/URLOpener.java [deleted file]
sourceext/ij_source/ij/plugin/WandToolOptions.java [deleted file]
sourceext/ij_source/ij/plugin/WindowOrganizer.java [deleted file]
sourceext/ij_source/ij/plugin/XYCoordinates.java [deleted file]
sourceext/ij_source/ij/plugin/ZProjector.java [deleted file]
sourceext/ij_source/ij/plugin/Zoom.java [deleted file]
sourceext/ij_source/ij/plugin/filter/AVI_Writer.java [deleted file]
sourceext/ij_source/ij/plugin/filter/Analyzer.java [deleted file]
sourceext/ij_source/ij/plugin/filter/BackgroundSubtracter.java [deleted file]
sourceext/ij_source/ij/plugin/filter/Benchmark.java [deleted file]
sourceext/ij_source/ij/plugin/filter/Binary.java [deleted file]
sourceext/ij_source/ij/plugin/filter/CalibrationBar.java [deleted file]
sourceext/ij_source/ij/plugin/filter/Calibrator.java [deleted file]
sourceext/ij_source/ij/plugin/filter/Convolver.java [deleted file]
sourceext/ij_source/ij/plugin/filter/Duplicater.java [deleted file]
sourceext/ij_source/ij/plugin/filter/EDM.java [deleted file]
sourceext/ij_source/ij/plugin/filter/ExtendedPlugInFilter.java [deleted file]
sourceext/ij_source/ij/plugin/filter/FFTCustomFilter.java [deleted file]
sourceext/ij_source/ij/plugin/filter/FFTFilter.java [deleted file]
sourceext/ij_source/ij/plugin/filter/Filler.java [deleted file]
sourceext/ij_source/ij/plugin/filter/Filters.java [deleted file]
sourceext/ij_source/ij/plugin/filter/FractalBoxCounter.java [deleted file]
sourceext/ij_source/ij/plugin/filter/GaussianBlur.java [deleted file]
sourceext/ij_source/ij/plugin/filter/ImageMath.java [deleted file]
sourceext/ij_source/ij/plugin/filter/ImageProperties.java [deleted file]
sourceext/ij_source/ij/plugin/filter/Info.java [deleted file]
sourceext/ij_source/ij/plugin/filter/LineGraphAnalyzer.java [deleted file]
sourceext/ij_source/ij/plugin/filter/LutApplier.java [deleted file]
sourceext/ij_source/ij/plugin/filter/LutViewer.java [deleted file]
sourceext/ij_source/ij/plugin/filter/MaximumFinder.java [deleted file]
sourceext/ij_source/ij/plugin/filter/ParticleAnalyzer.java [deleted file]
sourceext/ij_source/ij/plugin/filter/PlugInFilter.java [deleted file]
sourceext/ij_source/ij/plugin/filter/PlugInFilterRunner.java [deleted file]
sourceext/ij_source/ij/plugin/filter/Printer.java [deleted file]
sourceext/ij_source/ij/plugin/filter/Profiler.java [deleted file]
sourceext/ij_source/ij/plugin/filter/Projector.java [deleted file]
sourceext/ij_source/ij/plugin/filter/RGBStackSplitter.java [deleted file]
sourceext/ij_source/ij/plugin/filter/RankFilters.java [deleted file]
sourceext/ij_source/ij/plugin/filter/Resizer.java [deleted file]
sourceext/ij_source/ij/plugin/filter/RoiWriter.java [deleted file]
sourceext/ij_source/ij/plugin/filter/Rotator.java [deleted file]
sourceext/ij_source/ij/plugin/filter/SaltAndPepper.java [deleted file]
sourceext/ij_source/ij/plugin/filter/ScaleDialog.java [deleted file]
sourceext/ij_source/ij/plugin/filter/Shadows.java [deleted file]
sourceext/ij_source/ij/plugin/filter/StackLabeler.java [deleted file]
sourceext/ij_source/ij/plugin/filter/ThresholdToSelection.java [deleted file]
sourceext/ij_source/ij/plugin/filter/Transformer.java [deleted file]
sourceext/ij_source/ij/plugin/filter/Translator.java [deleted file]
sourceext/ij_source/ij/plugin/filter/UnsharpMask.java [deleted file]
sourceext/ij_source/ij/plugin/filter/Writer.java [deleted file]
sourceext/ij_source/ij/plugin/filter/XYWriter.java [deleted file]
sourceext/ij_source/ij/plugin/filter/ZAxisProfiler.java [deleted file]
sourceext/ij_source/ij/plugin/frame/Channels.java [deleted file]
sourceext/ij_source/ij/plugin/frame/ColorPicker.java [deleted file]
sourceext/ij_source/ij/plugin/frame/ColorThresholder.java [deleted file]
sourceext/ij_source/ij/plugin/frame/ContrastAdjuster.java [deleted file]
sourceext/ij_source/ij/plugin/frame/Editor.java [deleted file]
sourceext/ij_source/ij/plugin/frame/Fitter.java [deleted file]
sourceext/ij_source/ij/plugin/frame/Fonts.java [deleted file]
sourceext/ij_source/ij/plugin/frame/LineWidthAdjuster.java [deleted file]
sourceext/ij_source/ij/plugin/frame/PasteController.java [deleted file]
sourceext/ij_source/ij/plugin/frame/PlugInFrame.java [deleted file]
sourceext/ij_source/ij/plugin/frame/Recorder.java [deleted file]
sourceext/ij_source/ij/plugin/frame/RoiManager.java [deleted file]
sourceext/ij_source/ij/plugin/frame/ThresholdAdjuster.java [deleted file]
sourceext/ij_source/ij/process/AutoThresholder.java [deleted file]
sourceext/ij_source/ij/process/BinaryProcessor.java [deleted file]
sourceext/ij_source/ij/process/Blitter.java [deleted file]
sourceext/ij_source/ij/process/ByteBlitter.java [deleted file]
sourceext/ij_source/ij/process/ByteProcessor.java [deleted file]
sourceext/ij_source/ij/process/ByteStatistics.java [deleted file]
sourceext/ij_source/ij/process/ColorBlitter.java [deleted file]
sourceext/ij_source/ij/process/ColorProcessor.java [deleted file]
sourceext/ij_source/ij/process/ColorStatistics.java [deleted file]
sourceext/ij_source/ij/process/DownsizeTable.java [deleted file]
sourceext/ij_source/ij/process/EllipseFitter.java [deleted file]
sourceext/ij_source/ij/process/FHT.java [deleted file]
sourceext/ij_source/ij/process/FloatBlitter.java [deleted file]
sourceext/ij_source/ij/process/FloatPolygon.java [deleted file]
sourceext/ij_source/ij/process/FloatProcessor.java [deleted file]
sourceext/ij_source/ij/process/FloatStatistics.java [deleted file]
sourceext/ij_source/ij/process/FloodFiller.java [deleted file]
sourceext/ij_source/ij/process/ImageConverter.java [deleted file]
sourceext/ij_source/ij/process/ImageProcessor.java [deleted file]
sourceext/ij_source/ij/process/ImageStatistics.java [deleted file]
sourceext/ij_source/ij/process/LUT.java [deleted file]
sourceext/ij_source/ij/process/MedianCut.java [deleted file]
sourceext/ij_source/ij/process/PolygonFiller.java [deleted file]
sourceext/ij_source/ij/process/ShortBlitter.java [deleted file]
sourceext/ij_source/ij/process/ShortProcessor.java [deleted file]
sourceext/ij_source/ij/process/ShortStatistics.java [deleted file]
sourceext/ij_source/ij/process/StackConverter.java [deleted file]
sourceext/ij_source/ij/process/StackProcessor.java [deleted file]
sourceext/ij_source/ij/process/StackStatistics.java [deleted file]
sourceext/ij_source/ij/process/TypeConverter.java [deleted file]
sourceext/ij_source/ij/text/TextCanvas.java [deleted file]
sourceext/ij_source/ij/text/TextPanel.java [deleted file]
sourceext/ij_source/ij/text/TextWindow.java [deleted file]
sourceext/ij_source/ij/util/Java2.java [deleted file]
sourceext/ij_source/ij/util/StringSorter.java [deleted file]
sourceext/ij_source/ij/util/Tools.java [deleted file]
sourceext/ij_source/images/about.jpg [deleted file]
sourceext/ij_source/images/microscope.gif [deleted file]
sourceext/ij_source/macros/AddParticles.txt [deleted file]
sourceext/ij_source/macros/ConvertStackToBinary.txt [deleted file]
sourceext/ij_source/macros/EnlargeSelection.txt [deleted file]
sourceext/ij_source/macros/HyperStackMaker.txt [deleted file]
sourceext/ij_source/macros/ImportResultsTable.txt [deleted file]
sourceext/ij_source/macros/MakeSelectionBand.txt [deleted file]
sourceext/ij_source/macros/MoveSelection.txt [deleted file]
sourceext/ij_source/macros/PropagateMinAndMax.txt [deleted file]
sourceext/ij_source/macros/RotateSelection.txt [deleted file]
sourceext/ij_source/macros/Search.txt [deleted file]
sourceext/ij_source/macros/Stack Tools.txt [deleted file]
sourceext/ij_source/macros/StartupMacros.txt [deleted file]
sourceext/ij_source/macros/TimeStamp.ijm [deleted file]
sourceext/ij_source/macros/functions.html [deleted file]
sourceext/ij_source/plugins/JavaScriptEvaluator.class [deleted file]
sourceext/ij_source/plugins/JavaScriptEvaluator.source [deleted file]
sourceext/ij_source/plugins/MacAdapter.class [deleted file]
sourceext/ij_source/plugins/MacAdapter.source [deleted file]
sourceext/ij_source/plugins/MacClipboard.class [deleted file]
sourceext/ij_source/plugins/MacClipboard.source [deleted file]
sourceext/ij_source/policy [deleted file]
sourceext/ij_source/release-notes.html [deleted file]
sourceext/ij_source/run_appletviewer.bat [deleted file]
sourceext/imagej/.gitignore [new file with mode: 0644]
sourceext/imagej/Fakefile [new file with mode: 0644]
sourceext/imagej/IJ_Props.txt [new file with mode: 0644]
sourceext/imagej/MANIFEST.MF [new file with mode: 0644]
sourceext/imagej/Makefile [new file with mode: 0644]
sourceext/imagej/aREADME.txt [new file with mode: 0644]
sourceext/imagej/applet.html [new file with mode: 0644]
sourceext/imagej/build.xml [new file with mode: 0644]
sourceext/imagej/compile.bat [new file with mode: 0644]
sourceext/imagej/compile.sh [new file with mode: 0755]
sourceext/imagej/ij/CommandListener.java [new file with mode: 0644]
sourceext/imagej/ij/CompositeImage.java [new file with mode: 0644]
sourceext/imagej/ij/Executer.java [new file with mode: 0644]
sourceext/imagej/ij/IJ.java [new file with mode: 0644]
sourceext/imagej/ij/IJEventListener.java [new file with mode: 0644]
sourceext/imagej/ij/ImageJ.java [new file with mode: 0644]
sourceext/imagej/ij/ImageJApplet.java [new file with mode: 0644]
sourceext/imagej/ij/ImageListener.java [new file with mode: 0644]
sourceext/imagej/ij/ImagePlus.java [new file with mode: 0644]
sourceext/imagej/ij/ImageStack.java [new file with mode: 0644]
sourceext/imagej/ij/LookUpTable.java [new file with mode: 0644]
sourceext/imagej/ij/Macro.java [new file with mode: 0644]
sourceext/imagej/ij/Menus.java [new file with mode: 0644]
sourceext/imagej/ij/Prefs.java [new file with mode: 0644]
sourceext/imagej/ij/RecentOpener.java [new file with mode: 0644]
sourceext/imagej/ij/SocketListener.java [new file with mode: 0644]
sourceext/imagej/ij/Undo.java [new file with mode: 0644]
sourceext/imagej/ij/VirtualStack.java [new file with mode: 0644]
sourceext/imagej/ij/WindowManager.java [new file with mode: 0644]
sourceext/imagej/ij/gui/Arrow.java [new file with mode: 0644]
sourceext/imagej/ij/gui/ColorChooser.java [new file with mode: 0644]
sourceext/imagej/ij/gui/DialogListener.java [new file with mode: 0644]
sourceext/imagej/ij/gui/EllipseRoi.java [new file with mode: 0644]
sourceext/imagej/ij/gui/FreehandRoi.java [new file with mode: 0644]
sourceext/imagej/ij/gui/GUI.java [new file with mode: 0644]
sourceext/imagej/ij/gui/GenericDialog.java [new file with mode: 0644]
sourceext/imagej/ij/gui/HTMLDialog.java [new file with mode: 0644]
sourceext/imagej/ij/gui/HistogramWindow.java [new file with mode: 0644]
sourceext/imagej/ij/gui/ImageCanvas.java [new file with mode: 0644]
sourceext/imagej/ij/gui/ImageLayout.java [new file with mode: 0644]
sourceext/imagej/ij/gui/ImageRoi.java [new file with mode: 0644]
sourceext/imagej/ij/gui/ImageWindow.java [new file with mode: 0644]
sourceext/imagej/ij/gui/Line.java [new file with mode: 0644]
sourceext/imagej/ij/gui/MessageDialog.java [new file with mode: 0644]
sourceext/imagej/ij/gui/MultiLineLabel.java [new file with mode: 0644]
sourceext/imagej/ij/gui/NewImage.java [new file with mode: 0644]
sourceext/imagej/ij/gui/NonBlockingGenericDialog.java [new file with mode: 0644]
sourceext/imagej/ij/gui/OvalRoi.java [new file with mode: 0644]
sourceext/imagej/ij/gui/Overlay.java [new file with mode: 0644]
sourceext/imagej/ij/gui/Plot.java [new file with mode: 0644]
sourceext/imagej/ij/gui/PlotWindow.java [new file with mode: 0644]
sourceext/imagej/ij/gui/PointRoi.java [new file with mode: 0644]
sourceext/imagej/ij/gui/PolygonRoi.java [new file with mode: 0644]
sourceext/imagej/ij/gui/ProfilePlot.java [new file with mode: 0644]
sourceext/imagej/ij/gui/ProgressBar.java [new file with mode: 0644]
sourceext/imagej/ij/gui/Roi.java [new file with mode: 0644]
sourceext/imagej/ij/gui/RoiBrush.java [new file with mode: 0644]
sourceext/imagej/ij/gui/RoiProperties.java [new file with mode: 0644]
sourceext/imagej/ij/gui/SaveChangesDialog.java [new file with mode: 0644]
sourceext/imagej/ij/gui/ScrollbarWithLabel.java [new file with mode: 0644]
sourceext/imagej/ij/gui/ShapeRoi.java [new file with mode: 0644]
sourceext/imagej/ij/gui/StackWindow.java [new file with mode: 0644]
sourceext/imagej/ij/gui/TextRoi.java [new file with mode: 0644]
sourceext/imagej/ij/gui/Toolbar.java [new file with mode: 0644]
sourceext/imagej/ij/gui/TrimmedButton.java [new file with mode: 0644]
sourceext/imagej/ij/gui/WaitForUserDialog.java [new file with mode: 0644]
sourceext/imagej/ij/gui/Wand.java [new file with mode: 0644]
sourceext/imagej/ij/gui/YesNoCancelDialog.java [new file with mode: 0644]
sourceext/imagej/ij/io/BitBuffer.java [new file with mode: 0644]
sourceext/imagej/ij/io/DirectoryChooser.java [new file with mode: 0644]
sourceext/imagej/ij/io/FileInfo.java [new file with mode: 0644]
sourceext/imagej/ij/io/FileOpener.java [new file with mode: 0644]
sourceext/imagej/ij/io/FileSaver.java [new file with mode: 0644]
sourceext/imagej/ij/io/ImageReader.java [new file with mode: 0644]
sourceext/imagej/ij/io/ImageWriter.java [new file with mode: 0644]
sourceext/imagej/ij/io/ImportDialog.java [new file with mode: 0644]
sourceext/imagej/ij/io/OpenDialog.java [new file with mode: 0644]
sourceext/imagej/ij/io/Opener.java [new file with mode: 0644]
sourceext/imagej/ij/io/PluginClassLoader.java [new file with mode: 0644]
sourceext/imagej/ij/io/PluginInstaller.java [new file with mode: 0644]
sourceext/imagej/ij/io/RandomAccessStream.java [new file with mode: 0644]
sourceext/imagej/ij/io/RoiDecoder.java [new file with mode: 0644]
sourceext/imagej/ij/io/RoiEncoder.java [new file with mode: 0644]
sourceext/imagej/ij/io/SaveDialog.java [new file with mode: 0644]
sourceext/imagej/ij/io/TextEncoder.java [new file with mode: 0644]
sourceext/imagej/ij/io/TiffDecoder.java [new file with mode: 0644]
sourceext/imagej/ij/io/TiffEncoder.java [new file with mode: 0644]
sourceext/imagej/ij/macro/ExtensionDescriptor.java [new file with mode: 0644]
sourceext/imagej/ij/macro/FunctionFinder.java [new file with mode: 0644]
sourceext/imagej/ij/macro/Functions.java [new file with mode: 0644]
sourceext/imagej/ij/macro/Interpreter.java [new file with mode: 0644]
sourceext/imagej/ij/macro/MacroConstants.java [new file with mode: 0644]
sourceext/imagej/ij/macro/MacroExtension.java [new file with mode: 0644]
sourceext/imagej/ij/macro/MacroRunner.java [new file with mode: 0644]
sourceext/imagej/ij/macro/Program.java [new file with mode: 0644]
sourceext/imagej/ij/macro/ReturnException.java [new file with mode: 0644]
sourceext/imagej/ij/macro/Symbol.java [new file with mode: 0644]
sourceext/imagej/ij/macro/Tokenizer.java [new file with mode: 0644]
sourceext/imagej/ij/macro/Variable.java [new file with mode: 0644]
sourceext/imagej/ij/measure/Calibration.java [new file with mode: 0644]
sourceext/imagej/ij/measure/CurveFitter.java [new file with mode: 0644]
sourceext/imagej/ij/measure/Measurements.java [new file with mode: 0644]
sourceext/imagej/ij/measure/ResultsTable.java [new file with mode: 0644]
sourceext/imagej/ij/measure/SplineFitter.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/AVI_Reader.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/AboutBox.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/Animator.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/ArrowToolOptions.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/BMP_Reader.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/BMP_Writer.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/BatchConverter.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/BatchMeasure.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/BatchProcesser.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/BrowserLauncher.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/CanvasResizer.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/ChannelSplitter.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/ClassChecker.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/Clipboard.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/Colors.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/CommandFinder.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/CommandLister.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/Commands.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/Compiler.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/CompositeConverter.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/Concatenator.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/ContrastEnhancer.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/ControlPanel.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/Converter.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/DICOM.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/Distribution.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/DragAndDrop.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/Duplicator.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/EventListener.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/FFT.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/FFTMath.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/FITS_Reader.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/FITS_Writer.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/FileInfoVirtualStack.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/FolderOpener.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/GelAnalyzer.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/GifWriter.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/GroupedZProjector.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/Histogram.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/Hotkeys.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/HyperStackConverter.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/HyperStackReducer.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/ImageCalculator.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/ImageJ_Updater.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/ImagesToStack.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/Installer.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/JavaProperties.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/JpegWriter.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/LUT_Editor.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/ListVirtualStack.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/LutLoader.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/MacroInstaller.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/Macro_Runner.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/MeasurementsWriter.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/Memory.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/MontageMaker.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/NewPlugin.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/NextImageOpener.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/Options.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/Orthogonal_Views.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/OverlayCommands.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/OverlayLabels.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/PGM_Reader.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/PNG_Writer.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/PNM_Writer.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/PlugIn.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/Projector.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/ProxySettings.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/RGBStackConverter.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/RGBStackMerge.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/RandomOvals.txt [new file with mode: 0644]
sourceext/imagej/ij/plugin/Raw.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/RectToolOptions.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/Resizer.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/RoiReader.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/ScaleBar.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/Scaler.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/ScreenGrabber.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/Selection.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/SimpleCommands.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/Slicer.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/SpecifyROI.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/StackCombiner.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/StackEditor.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/StackInserter.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/StackMaker.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/StackReducer.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/StackReverser.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/StackWriter.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/Straightener.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/SubstackMaker.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/SurfacePlotter.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/TextFileReader.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/TextReader.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/TextWriter.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/ThreadLister.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/Thresholder.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/Timer.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/URLOpener.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/WandToolOptions.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/WindowOrganizer.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/XYCoordinates.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/XY_Reader.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/ZProjector.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/Zoom.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/AVI_Writer.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/Analyzer.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/BackgroundSubtracter.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/Benchmark.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/Binary.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/CalibrationBar.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/Calibrator.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/Convolver.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/Duplicater.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/EDM.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/ExtendedPlugInFilter.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/FFTCustomFilter.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/FFTFilter.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/Filler.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/Filters.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/FractalBoxCounter.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/GaussianBlur.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/ImageMath.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/ImageProperties.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/Info.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/LineGraphAnalyzer.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/LutApplier.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/LutViewer.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/MaximumFinder.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/ParticleAnalyzer.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/PlugInFilter.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/PlugInFilterRunner.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/Printer.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/Profiler.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/RGBStackSplitter.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/RankFilters.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/Resizer.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/RoiWriter.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/Rotator.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/SaltAndPepper.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/ScaleDialog.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/Shadows.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/StackLabeler.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/ThresholdToSelection.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/Transformer.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/Translator.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/UnsharpMask.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/Writer.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/XYWriter.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/filter/ZAxisProfiler.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/frame/Channels.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/frame/ColorPicker.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/frame/ColorThresholder.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/frame/ContrastAdjuster.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/frame/Editor.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/frame/Fitter.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/frame/Fonts.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/frame/LineWidthAdjuster.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/frame/MemoryMonitor.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/frame/PasteController.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/frame/PlugInFrame.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/frame/Recorder.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/frame/RoiManager.java [new file with mode: 0644]
sourceext/imagej/ij/plugin/frame/ThresholdAdjuster.java [new file with mode: 0644]
sourceext/imagej/ij/process/AutoThresholder.java [new file with mode: 0644]
sourceext/imagej/ij/process/BinaryProcessor.java [new file with mode: 0644]
sourceext/imagej/ij/process/Blitter.java [new file with mode: 0644]
sourceext/imagej/ij/process/ByteBlitter.java [new file with mode: 0644]
sourceext/imagej/ij/process/ByteProcessor.java [new file with mode: 0644]
sourceext/imagej/ij/process/ByteStatistics.java [new file with mode: 0644]
sourceext/imagej/ij/process/ColorBlitter.java [new file with mode: 0644]
sourceext/imagej/ij/process/ColorProcessor.java [new file with mode: 0644]
sourceext/imagej/ij/process/ColorStatistics.java [new file with mode: 0644]
sourceext/imagej/ij/process/DownsizeTable.java [new file with mode: 0644]
sourceext/imagej/ij/process/EllipseFitter.java [new file with mode: 0644]
sourceext/imagej/ij/process/FHT.java [new file with mode: 0644]
sourceext/imagej/ij/process/FloatBlitter.java [new file with mode: 0644]
sourceext/imagej/ij/process/FloatPolygon.java [new file with mode: 0644]
sourceext/imagej/ij/process/FloatProcessor.java [new file with mode: 0644]
sourceext/imagej/ij/process/FloatStatistics.java [new file with mode: 0644]
sourceext/imagej/ij/process/FloodFiller.java [new file with mode: 0644]
sourceext/imagej/ij/process/ImageConverter.java [new file with mode: 0644]
sourceext/imagej/ij/process/ImageProcessor.java [new file with mode: 0644]
sourceext/imagej/ij/process/ImageStatistics.java [new file with mode: 0644]
sourceext/imagej/ij/process/LUT.java [new file with mode: 0644]
sourceext/imagej/ij/process/MedianCut.java [new file with mode: 0644]
sourceext/imagej/ij/process/PolygonFiller.java [new file with mode: 0644]
sourceext/imagej/ij/process/ShortBlitter.java [new file with mode: 0644]
sourceext/imagej/ij/process/ShortProcessor.java [new file with mode: 0644]
sourceext/imagej/ij/process/ShortStatistics.java [new file with mode: 0644]
sourceext/imagej/ij/process/StackConverter.java [new file with mode: 0644]
sourceext/imagej/ij/process/StackProcessor.java [new file with mode: 0644]
sourceext/imagej/ij/process/StackStatistics.java [new file with mode: 0644]
sourceext/imagej/ij/process/TypeConverter.java [new file with mode: 0644]
sourceext/imagej/ij/text/TextCanvas.java [new file with mode: 0644]
sourceext/imagej/ij/text/TextPanel.java [new file with mode: 0644]
sourceext/imagej/ij/text/TextWindow.java [new file with mode: 0644]
sourceext/imagej/ij/util/DicomTools.java [new file with mode: 0644]
sourceext/imagej/ij/util/Java2.java [new file with mode: 0644]
sourceext/imagej/ij/util/StringSorter.java [new file with mode: 0644]
sourceext/imagej/ij/util/Tools.java [new file with mode: 0644]
sourceext/imagej/images/about.jpg [new file with mode: 0644]
sourceext/imagej/images/microscope.gif [new file with mode: 0644]
sourceext/imagej/macros/AddParticles.txt [new file with mode: 0644]
sourceext/imagej/macros/ConvertStackToBinary.txt [new file with mode: 0644]
sourceext/imagej/macros/EnlargeSelection.txt [new file with mode: 0644]
sourceext/imagej/macros/HyperStackMaker.txt [new file with mode: 0644]
sourceext/imagej/macros/MoveSelection.txt [new file with mode: 0644]
sourceext/imagej/macros/PropagateMinAndMax.txt [new file with mode: 0644]
sourceext/imagej/macros/RotateSelection.txt [new file with mode: 0644]
sourceext/imagej/macros/Search.txt [new file with mode: 0644]
sourceext/imagej/macros/Stack Tools.txt [new file with mode: 0644]
sourceext/imagej/macros/StartupMacros.txt [new file with mode: 0644]
sourceext/imagej/macros/TimeStamp.ijm [new file with mode: 0644]
sourceext/imagej/nbproject/build-impl.xml [new file with mode: 0755]
sourceext/imagej/nbproject/genfiles.properties [new file with mode: 0755]
sourceext/imagej/nbproject/project.properties [new file with mode: 0755]
sourceext/imagej/nbproject/project.xml [new file with mode: 0755]
sourceext/imagej/plugins/JavaScriptEvaluator.class [new file with mode: 0644]
sourceext/imagej/plugins/JavaScriptEvaluator.source [new file with mode: 0644]
sourceext/imagej/plugins/MacAdapter.class [new file with mode: 0644]
sourceext/imagej/plugins/MacAdapter.source [new file with mode: 0644]
sourceext/imagej/plugins/MacClipboard.class [new file with mode: 0644]
sourceext/imagej/plugins/MacClipboard.source [new file with mode: 0644]
sourceext/imagej/policy [new file with mode: 0644]
sourceext/imagej/release-notes.html [new file with mode: 0644]
sourceext/imagej/run_appletviewer.bat [new file with mode: 0644]

diff --git a/sourceext/ij_source/.gitignore b/sourceext/ij_source/.gitignore
deleted file mode 100644 (file)
index eadac27..0000000
+++ /dev/null
@@ -1,4 +0,0 @@
-.DS_Store
-*.class
-*.jar
-*~
diff --git a/sourceext/ij_source/Fakefile b/sourceext/ij_source/Fakefile
deleted file mode 100644 (file)
index 1b9014d..0000000
+++ /dev/null
@@ -1,11 +0,0 @@
-JAVAVERSION=1.4
-all <- ij.jar
-
-MAINCLASS(ij.jar)=ij.ImageJ
-ij.jar <- ij/**/*.java \
-       icon.gif[images/icon.gif] aboutja.jpg[images/aboutja.jpg] plugins/*.java \
-       plugins/JavaScriptEvaluator.class plugins/MacAdapter.class \
-       IJ_Props.txt macros/*.txt
-
-JARSIGNEROPTS=-signedjar signed-ij.jar ij.jar dscho
-signed-ij.jar[jarsigner $JARSIGNEROPTS] <- ij.jar
diff --git a/sourceext/ij_source/IJ_Props.txt b/sourceext/ij_source/IJ_Props.txt
deleted file mode 100644 (file)
index 015236f..0000000
+++ /dev/null
@@ -1,414 +0,0 @@
- # IJ_Props.txt - This is the ImageJ properties file. ImageJ uses
-# the information in this file to install plug-ins in menus.
-# ImageJ looks for this file in ij.jar. It can be edited by
-# opening ij.jar with a ZIP utility. With WinZip, you can open 
-# ij.jar and double click on IJ_Props.txt.
-
-# Note that commands must be unique.
-
-# Version 1.43
-
-# Popup Menu
-popup01=Undo
-popup02=-
-popup03=Cut
-popup04=Copy
-popup05=Paste
-popup06=-
-popup07=Clear
-popup08=Fill
-popup09=Draw
-popup10=-
-popup11=Rename...
-popup12=Duplicate...
-
-# Plugins installed in the File/New submenu
-new01="Image...[n]",ij.plugin.Commands("new")
-new02="Hyperstack...",ij.plugin.HyperStackConverter("new")
-new03="Text Window[N]",ij.plugin.NewPlugin("text")
-new04="Internal Clipboard",ij.plugin.Clipboard("show")
-new05="System Clipboard[V]",ij.plugin.Clipboard("showsys")
-
-# Plugins installed in the File/Import submenu
-import01="Image Sequence...",ij.plugin.FolderOpener
-import02="Raw...",ij.plugin.Raw
-import03="LUT... ",ij.plugin.LutLoader
-import04="Text Image... ",ij.plugin.TextReader
-import05="Text File... ",ij.plugin.TextFileReader
-import06="Results... ",ij.plugin.SimpleCommands("import")
-import07="URL...",ij.plugin.URLOpener
-import08="Stack From List...",ij.plugin.ListVirtualStack
-import09="TIFF Virtual Stack...",ij.plugin.FileInfoVirtualStack
-import10="AVI...",ij.plugin.AVI_Reader
-#import08="TWAIN...",ij.plugin.twain.Twain
-#import09="Capture Video...",QT_Capture
-#import10="QuickTime Movie...",Movie_Opener
-#import11="Pict...",QuickTime_Opener
-
-# Plugins installed in the File/Save As submenu
-save01="Tiff...",ij.plugin.filter.Writer("tiff")
-save02="Gif...",ij.plugin.filter.Writer("gif")
-save03="Jpeg...",ij.plugin.filter.Writer("jpeg")
-save04="Text Image...",ij.plugin.filter.Writer("text")
-save05="ZIP...",ij.plugin.filter.Writer("zip")
-save06="Raw Data...",ij.plugin.filter.Writer("raw")
-save07="Image Sequence... ",ij.plugin.StackWriter
-save08="AVI... ",ij.plugin.filter.AVI_Writer
-save09="BMP...",ij.plugin.filter.Writer("bmp")
-save10="PNG...",ij.plugin.filter.Writer("png")
-save11="PGM...",ij.plugin.filter.Writer("pgm")
-save12="FITS...",ij.plugin.filter.Writer("fits")
-save13="LUT...",ij.plugin.filter.Writer("lut")
-save14="Selection...",ij.plugin.filter.RoiWriter
-save15="XY Coordinates...",ij.plugin.filter.XYWriter
-save16="Results...",ij.plugin.MeasurementsWriter
-save17="Text...",ij.plugin.TextWriter
-#save18="QuickTime Movie... ",QT_Movie_Writer
-
-# Plugins installed in the Edit/Selection submenu
-selection01="Select All[a]",ij.plugin.Selection("all")
-selection02="Select None[A]",ij.plugin.Selection("none")
-selection03="Restore Selection[E]",ij.plugin.Selection("restore")
-selection04="Fit Spline",ij.plugin.Selection("spline")
-selection05="Fit Ellipse",ij.plugin.Selection("ellipse")
-selection06="Convex Hull",ij.plugin.Selection("hull")
-selection07="Make Inverse",ij.plugin.Selection("inverse")
-selection08="Create Selection",ij.plugin.Selection("from")
-selection09="Create Mask",ij.plugin.Selection("mask")
-selection10=-
-selection11="Properties... ",ij.plugin.Selection("properties")
-selection12="Rotate...",ij.plugin.Selection("rotate")
-selection13="Enlarge...",ij.plugin.Selection("enlarge")
-selection14="Make Band...",ij.plugin.Selection("band")
-selection15="Specify...",ij.plugin.SpecifyROI
-selection16="Straighten...",ij.plugin.Straightener
-selection17="Line to Area",ij.plugin.Selection("toarea")
-selection18="Add to Manager [t]",ij.plugin.Selection("add")
-
-# Plugins installed in the Edit/Options submenu
-options01="Line Width...",ij.plugin.Options("line")
-options02="Input/Output...",ij.plugin.Options("io")
-options03="Fonts...",ij.plugin.frame.Fonts
-options04="Profile Plot Options...",ij.plugin.filter.Profiler("set")
-options05="Arrow Tool...",ij.plugin.ArrowToolOptions
-options06="Point Tool...",ij.plugin.Colors("point")
-options07="Wand Tool...",ij.plugin.WandToolOptions
-options08="Colors...",ij.plugin.Colors
-options09="Appearance...",ij.plugin.Options("display")
-options10="Conversions...",ij.plugin.Options("conv")
-options11="Memory & Threads...",ij.plugin.Memory
-options12="Proxy Settings...",ij.plugin.ProxySettings
-options13="Compiler...",ij.plugin.Compiler("options")
-options14="DICOM...",ij.plugin.Options("dicom")
-options15="Misc...",ij.plugin.Options("misc")
-
-# Plugins installed in the Image/Adjust submenu
-adjust01="Brightness/Contrast...[C]",ij.plugin.frame.ContrastAdjuster
-adjust02="Window/Level...",ij.plugin.frame.ContrastAdjuster("wl")
-adjust03="Color Balance...",ij.plugin.frame.ContrastAdjuster("balance")
-adjust04="Threshold...[T]",ij.plugin.frame.ThresholdAdjuster
-adjust05="Color Threshold...",ij.plugin.frame.ColorThresholder
-adjust06="Size...",ij.plugin.Resizer
-adjust07="Canvas Size...",ij.plugin.CanvasResizer
-adjust08="Line Width... ",ij.plugin.frame.LineWidthAdjuster
-
-# Plugins installed in the Image/Color submenu
-color01="Split Channels",ij.plugin.filter.RGBStackSplitter
-color02="Merge Channels...",ij.plugin.RGBStackMerge
-color03="Channels Tool... ",ij.plugin.frame.Channels
-color04=-
-color05="Stack to RGB",ij.plugin.RGBStackConverter
-color06="Make Composite",ij.plugin.CompositeConverter
-color07="Show LUT",ij.plugin.filter.LutViewer
-color08="Edit LUT...",ij.plugin.LUT_Editor
-color09="Color Picker...[K]",ij.plugin.frame.ColorPicker
-
-# Plugins installed in the Image/Stacks submenu
-stacks01="Add Slice",ij.plugin.StackEditor("add")
-stacks02="Delete Slice",ij.plugin.StackEditor("delete")
-stacks03="Next Slice [>]",ij.plugin.Animator("next")
-stacks04="Previous Slice [<]",ij.plugin.Animator("previous")
-stacks05="Set Slice...",ij.plugin.Animator("set")
-stacks06=-
-stacks07="Images to Stack",ij.plugin.ImagesToStack
-stacks08="Stack to Images",ij.plugin.StackEditor("toimages")
-stacks09="Make Montage...",ij.plugin.MontageMaker
-stacks10="Reslice [/]...",ij.plugin.Slicer
-stacks11="Orthogonal Views",ij.plugin.Orthogonal_Views
-stacks12="Z Project...",ij.plugin.ZProjector
-stacks13="3D Project...",ij.plugin.filter.Projector
-stacks14="Plot Z-axis Profile",ij.plugin.filter.ZAxisProfiler
-stacks15="Label...",ij.plugin.filter.StackLabeler
-
-# Plugins installed in the Image/Stacks/Tools submenu
-tools_01="Combine...",ij.plugin.StackCombiner
-tools_02="Concatenate...",ij.plugin.Concatenator
-tools_03="Reduce...",ij.plugin.StackReducer
-tools_04="Reverse",ij.plugin.StackReverser
-tools_05="Insert...",ij.plugin.StackInserter
-tools_06="Montage to Stack...",ij.plugin.StackMaker
-tools_07="Make Substack...",ij.plugin.SubstackMaker
-tools_08="Grouped Z Project...",ij.plugin.GroupedZProjector
-tools_09=-
-tools_10="Start Animation [\\]",ij.plugin.Animator("start")
-tools_11="Stop Animation",ij.plugin.Animator("stop")
-tools_12="Animation Options...",ij.plugin.Animator("options")
-
-# Plugins installed in the Image/Hyperstacks submenu
-hyperstacks01="New Hyperstack...",ij.plugin.HyperStackConverter("new")
-hyperstacks02="Stack to Hyperstack...",ij.plugin.HyperStackConverter("stacktohs")
-hyperstacks03="Hyperstack to Stack",ij.plugin.HyperStackConverter("hstostack")
-hyperstacks04="Reduce Dimensionality...",ij.plugin.HyperStackReducer
-hyperstacks05="Channels Tool...[Z]",ij.plugin.frame.Channels
-
-# Plugins installed in the Image/Transform submenu
-transform01="Flip Horizontally",ij.plugin.filter.Transformer("fliph")
-transform02="Flip Vertically",ij.plugin.filter.Transformer("flipv")
-transform03="Flip Z",ij.plugin.StackReverser
-transform04="Rotate 90 Degrees Right",ij.plugin.filter.Transformer("right")
-transform05="Rotate 90 Degrees Left",ij.plugin.filter.Transformer("left")
-transform06="Rotate... ",ij.plugin.filter.Rotator
-transform07="Translate...",ij.plugin.filter.Translator
-
-# Plugins installed in the Image/Zoom submenu
-zoom01="In[+]",ij.plugin.Zoom("in")
-zoom02="Out[-]",ij.plugin.Zoom("out")
-zoom03="Original Scale[4]",ij.plugin.Zoom("orig")
-zoom04="View 100%[5]",ij.plugin.Zoom("100%")
-zoom05="To Selection",ij.plugin.Zoom("to")
-zoom06="Set... ",ij.plugin.Zoom("set")
-#zoom07="Maximize",ij.plugin.Zoom("max")
-
-# Plugins installed in the Image/Overlay submenu
-overlay01="Add Selection...[b]",ij.plugin.OverlayCommands("add")
-overlay02="Add Image...",ij.plugin.OverlayCommands("image")
-overlay03="Hide Overlay",ij.plugin.OverlayCommands("hide")
-overlay04="Show Overlay",ij.plugin.OverlayCommands("show")
-overlay05="From ROI Manager",ij.plugin.OverlayCommands("from")
-overlay06="To ROI Manager",ij.plugin.OverlayCommands("to")
-overlay07="Remove Overlay",ij.plugin.OverlayCommands("remove")
-overlay08="Flatten[F]",ij.plugin.OverlayCommands("flatten")
-
-# Plugins installed in the Image/Lookup Tables submenu
-lookup01="Invert LUT",ij.plugin.LutLoader("invert")
-lookup02="Apply LUT",ij.plugin.filter.LutApplier
-lookup03=-
-lookup04="Fire",ij.plugin.LutLoader("fire")
-lookup05="Grays",ij.plugin.LutLoader("grays")
-lookup06="Ice",ij.plugin.LutLoader("ice")
-lookup07="Spectrum",ij.plugin.LutLoader("spectrum")
-lookup08="3-3-2 RGB",ij.plugin.LutLoader("3-3-2 RGB")
-lookup09="Red",ij.plugin.LutLoader("red")
-lookup10="Green",ij.plugin.LutLoader("green")
-lookup11="Blue",ij.plugin.LutLoader("blue")
-lookup12="Cyan",ij.plugin.LutLoader("cyan")
-lookup13="Magenta",ij.plugin.LutLoader("magenta")
-lookup14="Yellow",ij.plugin.LutLoader("yellow")
-lookup15="Red/Green",ij.plugin.LutLoader("redgreen")
-
-# Plug-ins installed in the Process/Noise submenu
-noise01="Add Noise",ij.plugin.filter.Filters("add")
-noise02="Add Specified Noise...",ij.plugin.filter.Filters("noise")
-noise03="Salt and Pepper",ij.plugin.filter.SaltAndPepper
-noise04=-
-noise05="Despeckle",ij.plugin.filter.RankFilters("despeckle")
-noise06="Remove Outliers...",ij.plugin.filter.RankFilters("outliers")
-
-# Plugins installed in the Process/Shadows submenu
-shadows01="North",ij.plugin.filter.Shadows("north")
-shadows02="Northeast",ij.plugin.filter.Shadows("northeast")
-shadows03="East",ij.plugin.filter.Shadows("east")
-shadows04="Southeast",ij.plugin.filter.Shadows("southeast")
-shadows05="South",ij.plugin.filter.Shadows("south")
-shadows06="Southwest",ij.plugin.filter.Shadows("southwest")
-shadows07="West",ij.plugin.filter.Shadows("west")
-shadows08="Northwest",ij.plugin.filter.Shadows("northwest")
-shadows09=-
-shadows10="Shadows Demo",ij.plugin.filter.Shadows("demo")
-
-# Plugins installed in the Process/Binary submenu
-binary01="Make Binary",ij.plugin.Thresholder
-binary02="Convert to Mask",ij.plugin.Thresholder("mask")
-binary03=-
-binary04="Erode",ij.plugin.filter.Binary("erode")
-binary05="Dilate",ij.plugin.filter.Binary("dilate")
-binary06="Open",ij.plugin.filter.Binary("open")
-# Can't use "Close" because it conflicts with File/Close
-binary07="Close-",ij.plugin.filter.Binary("close")
-binary08=-
-binary09="Outline",ij.plugin.filter.Binary("outline")
-binary10="Fill Holes",ij.plugin.filter.Binary("fill")
-binary11="Skeletonize",ij.plugin.filter.Binary("skel")
-binary12=-
-binary13="Distance Map",ij.plugin.filter.EDM("edm")
-binary14="Ultimate Points",ij.plugin.filter.EDM("points")
-binary15="Watershed",ij.plugin.filter.EDM("watershed")
-binary16="Voronoi",ij.plugin.filter.EDM("voronoi")
-binary17=-
-binary18="Options...",ij.plugin.filter.Binary("options")
-
-# Plugins installed in the Process/Math submenu
-math01="Add...",ij.plugin.filter.ImageMath("add")
-math02="Subtract...",ij.plugin.filter.ImageMath("sub")
-math03="Multiply...",ij.plugin.filter.ImageMath("mul")
-math04="Divide...",ij.plugin.filter.ImageMath("div")
-math05="AND...",ij.plugin.filter.ImageMath("and")
-math06="OR...",ij.plugin.filter.ImageMath("or")
-math07="XOR...",ij.plugin.filter.ImageMath("xor")
-math08="Min...",ij.plugin.filter.ImageMath("min")
-math09="Max...",ij.plugin.filter.ImageMath("max")
-math10="Gamma...",ij.plugin.filter.ImageMath("gamma")
-math11="Set...",ij.plugin.filter.ImageMath("set")
-math12="Log",ij.plugin.filter.ImageMath("log")
-math13="Exp",ij.plugin.filter.ImageMath("exp")
-math14="Square",ij.plugin.filter.ImageMath("sqr")
-math15="Square Root",ij.plugin.filter.ImageMath("sqrt")
-math16="Reciprocal",ij.plugin.filter.ImageMath("reciprocal")
-math17="NaN Background",ij.plugin.filter.ImageMath("nan")
-math18="Abs",ij.plugin.filter.ImageMath("abs")
-math19="Macro...",ij.plugin.filter.ImageMath("macro")
-
-# Plugins installed in the Process/FFT submenu
-fft01="FFT",ij.plugin.FFT("fft")
-fft02="Inverse FFT",ij.plugin.FFT("inverse")
-fft03="Redisplay Power Spectrum",ij.plugin.FFT("redisplay")
-fft04="FFT Options...",ij.plugin.FFT("options")
-fft05=-
-fft06="Bandpass Filter...",ij.plugin.filter.FFTFilter
-fft07="Custom Filter...",ij.plugin.filter.FFTCustomFilter
-fft08="FD Math...",ij.plugin.FFTMath
-fft09="Swap Quadrants",ij.plugin.FFT("swap")
-
-# Plugins installed in the Process/Filters submenu
-filters01="Convolve...",ij.plugin.filter.Convolver
-filters02="Gaussian Blur...",ij.plugin.filter.GaussianBlur
-filters03="Median...",ij.plugin.filter.RankFilters("median")
-filters04="Mean...",ij.plugin.filter.RankFilters("mean")
-filters05="Minimum...",ij.plugin.filter.RankFilters("min")
-filters06="Maximum...",ij.plugin.filter.RankFilters("max")
-filters07="Unsharp Mask...",ij.plugin.filter.UnsharpMask
-filters08="Variance...",ij.plugin.filter.RankFilters("variance")
-filters09=-
-filters10="Show Circular Masks...",ij.plugin.filter.RankFilters("masks")
-
-# Plugins installed in the File/Batch submenu
-batch01="Measure...",ij.plugin.BatchMeasure
-batch02="Convert...",ij.plugin.BatchConverter
-batch03="Macro... ",ij.plugin.BatchProcesser
-batch04="Virtual Stack...",ij.plugin.BatchProcesser("stack")
-
-
-# Plugins installed in the Analyze/Gels submenu
-gels01="Select First Lane[1]",ij.plugin.GelAnalyzer("first")
-gels02="Select Next Lane[2]",ij.plugin.GelAnalyzer("next")
-gels03="Plot Lanes[3]",ij.plugin.GelAnalyzer("plot")
-gels04="Re-plot Lanes",ij.plugin.GelAnalyzer("replot")
-gels05="Reset",ij.plugin.GelAnalyzer("reset")
-gels06="Label Peaks",ij.plugin.GelAnalyzer("label")
-gels07="Gel Analyzer Options...",ij.plugin.GelAnalyzer("options")
-
-# Plugins installed in the Analyze/Tools submenu
-tools01="Save XY Coordinates...",ij.plugin.XYCoordinates
-tools02="Fractal Box Count...",ij.plugin.filter.FractalBoxCounter
-tools03="Analyze Line Graph",ij.plugin.filter.LineGraphAnalyzer
-tools04="Curve Fitting...",ij.plugin.frame.Fitter
-tools05="ROI Manager...",ij.plugin.frame.RoiManager
-tools06="Scale Bar...",ij.plugin.ScaleBar
-tools07="Calibration Bar...",ij.plugin.filter.CalibrationBar
-
-# Plugins installed in the Plugins menu
-plug-in01=>"Macros"
-plug-in02=>"Shortcuts"
-plug-in03=>"Utilities"
-plug-in04=>"New_"
-plug-in05="Compile and Run...",ij.plugin.Compiler
-#plug-in06=-
-#plug-in07=>"User_Plugins"
-
-# Install user plugins located in ij.jar to Plugins>User Plugins submenu
-#user_plugins01="Red And Blue",RedAndBlue_
-#user_plugins02="Inverter",Inverter_
-
-
-# Plugins installed in the Plugins/Macros submenu
-# 'MACROS_MENU_COMMANDS' in MacroInstaller must be updated when items are added
-macros01="Install...[M]",ij.plugin.MacroInstaller
-macros02="Run...",ij.plugin.Macro_Runner
-macros03="Edit...",ij.plugin.Compiler("edit")
-macros04="Startup Macros...",ij.plugin.Commands("startup")
-macros05="Record...",ij.plugin.frame.Recorder
-macros06=-
-
-# Plugins installed in the Plugins/Shortcuts submenu
-shortcuts01="List Shortcuts...",ij.plugin.CommandLister("shortcuts")
-shortcuts02="Create Shortcut... ",ij.plugin.Hotkeys("install")
-shortcuts03="Install Plugin...",ij.plugin.Installer
-shortcuts04="Remove...",ij.plugin.Hotkeys("remove")
-shortcuts05=-
-
-# Plugins installed in the Plugins/Utilities submenu
-utilities01="Control Panel... [U]",ij.plugin.ControlPanel
-utilities02="ImageJ Properties...",ij.plugin.JavaProperties
-utilities03="Threads...",ij.plugin.ThreadLister
-utilities04="Benchmark",ij.plugin.filter.Benchmark
-utilities05="Reset...",ij.plugin.SimpleCommands("reset")
-utilities06="Monitor Memory...",ij.plugin.MemoryMonitor
-utilities07="Search...",ij.plugin.SimpleCommands("search")
-utilities08="Capture Screen [G]",ij.plugin.ScreenGrabber
-utilities09="Capture Image",ij.plugin.ScreenGrabber("image")
-utilities10="Find Commands... [l]",ij.plugin.CommandFinder
-
-# Plugins installed in the Plugins/New submenu
-new_01="Macro",ij.plugin.NewPlugin("macro")
-new_02="JavaScript",ij.plugin.NewPlugin("javascript")
-new_03=-
-new_04="Plugin",ij.plugin.NewPlugin("plugin")
-new_05="Plugin Filter",ij.plugin.NewPlugin("filter")
-new_06="Plugin Frame",ij.plugin.NewPlugin("frame")
-new_07=-
-new_08="Text Window...",ij.plugin.NewPlugin("text+dialog")
-new_09="Table...",ij.plugin.NewPlugin("table")
-
-# Plugins installed in the Help/About submenu
-about01="About This Submenu...",ij.plugin.SimpleCommands("about")
-about02=-
-
-# URL of directory containing the sample images
-# Used when ImageJ is running as an application,
-# otherwise applet.getDocumentBase()+"/images" is used.
-images.location=http://imagej.nih.gov/ij/images/
-
-# Images installed in the Open Samples submenu
-# RawReader expects a string with "name width height nImages bitsPerPixel offset [white]"
-open01="AuPbSn 40 (56K)",ij.plugin.URLOpener("AuPbSn40.jpg")
-open02="Bat Cochlea Volume (19K)",ij.plugin.URLOpener("bat-cochlea-volume.zip")
-open03="Bat Cochlea Renderings (449K)",ij.plugin.URLOpener("bat-cochlea-renderings.zip")
-open04="Blobs (25K)[B]",ij.plugin.URLOpener("blobs.gif")
-open05="Boats (356K)",ij.plugin.URLOpener("boats.gif")
-open06="Bridge (174K)",ij.plugin.URLOpener("bridge.gif")
-open07="Cardio (768K, RGB DICOM)",ij.plugin.URLOpener("cardio.dcm.zip")
-open08="Cell Colony (31K)",ij.plugin.URLOpener("Cell_Colony.jpg")
-open09="Clown (14K)",ij.plugin.URLOpener("clown.jpg")
-open10="Confocal Series (2.2MB)",ij.plugin.URLOpener("confocal-series.zip")
-open11="CT (420K, 16-bit DICOM)",ij.plugin.URLOpener("ct.dcm.zip")
-open12="Dot Blot (7K)",ij.plugin.URLOpener("Dot_Blot.jpg")
-open13="Embryos (42K)",ij.plugin.URLOpener("embryos.jpg")
-open14="Fluorescent Cells (400K)",ij.plugin.URLOpener("FluorescentCells.zip")
-open15="Fly Brain (1MB)",ij.plugin.URLOpener("flybrain.zip")
-open16="Gel (105K)",ij.plugin.URLOpener("gel.gif")
-open17="HeLa Cells (1.3M, 48-bit RGB)",ij.plugin.URLOpener("hela-cells.zip")
-open18="Leaf (36K)",ij.plugin.URLOpener("leaf.jpg")
-open19="Lena (68K)",ij.plugin.URLOpener("lena-std.tif")
-open20="Line Graph (21K)",ij.plugin.URLOpener("LineGraph.jpg")
-open21="Mitosis (26MB, 5D stack)",ij.plugin.URLOpener("Spindly-GFP.zip")
-open22="MRI Stack (528K)",ij.plugin.URLOpener("mri-stack.zip")
-open23="M51 Galaxy (177K, 16-bits)",ij.plugin.URLOpener("m51.zip")
-open24="Neuron (1.6M, 5 channels)",ij.plugin.URLOpener("Rat_Hippocampal_Neuron.zip")
-open25="Nile Bend (1.9M)",ij.plugin.URLOpener("NileBend.jpg")
-open26="Organ of Corti (2.8M, 4D stack)",ij.plugin.URLOpener("organ-of-corti.zip")
-open27="Particles (75K)",ij.plugin.URLOpener("particles.gif")
-open28="T1 Head (2.4M, 16-bits)",ij.plugin.URLOpener("t1-head.zip")
-open29="T1 Head Renderings (736K)",ij.plugin.URLOpener("t1-rendering.zip")
-open30="TEM Filter (112K)",ij.plugin.URLOpener("TEM_filter_sample.jpg")
-open31="Tree Rings (48K)",ij.plugin.URLOpener("Tree_Rings.jpg")
-
diff --git a/sourceext/ij_source/MANIFEST.MF b/sourceext/ij_source/MANIFEST.MF
deleted file mode 100644 (file)
index b3cca5b..0000000
+++ /dev/null
@@ -1,2 +0,0 @@
-Main-Class: ij.ImageJ\r
-\r
diff --git a/sourceext/ij_source/Makefile b/sourceext/ij_source/Makefile
deleted file mode 100644 (file)
index 942948d..0000000
+++ /dev/null
@@ -1,42 +0,0 @@
-JAVAS=$(wildcard ij/*.java ij/*/*.java ij/*/*/*.java)
-CLASSES=$(patsubst %.java,%.class,$(JAVAS))
-ALLCLASSES=ij/*.class ij/*/*.class ij/*/*/*.class
-COPYFILES=icon.gif aboutja.jpg plugins/*.class
-TEXTFILES=IJ_Props.txt $(wildcard macros/*.txt)
-
-ifeq ($(JAVA_HOME),)
-       JAVA_HOME=$(shell ../fiji --print-java-home)/..
-endif
-
-ifeq ($(shell javac > /dev/null 2>&1; echo $$?),127)
-       PATH:=$(PATH):$(JAVA_HOME)/bin
-endif
-
-uname_O := $(shell sh -c 'uname -o 2>/dev/null || echo not')
-ifeq ($(uname_O),Cygwin)
-PLUGINSHOME=$(shell cygpath --mixed "$(shell pwd)")
-CPSEP=\;
-TOOLSCP=$(shell cygpath --mixed "$(JAVA_HOME)")/lib/tools.jar
-else
-PLUGINSHOME=$(shell pwd)
-CPSEP=:
-TOOLSCP=$(JAVA_HOME)/lib/tools.jar
-endif
-CLASSPATH=../jars/javac.jar$(CPSEP)$(TOOLSCP)$(CPSEP)$(PLUGINSHOME)/../ImageJ/ij.jar$(CPSEP)$(PLUGINSHOME)/jzlib-1.0.7.jar$(CPSEP).
-JAVACOPTS=-O -classpath "$(CLASSPATH)" -source 1.3 -target 1.3
-
-ij.jar: $(COPYFILES) $(CLASSES) $(TEXTFILES)
-       jar cvmf MANIFEST.MF ij.jar $(COPYFILES) $(ALLCLASSES) $(TEXTFILES)
-
-signed-ij.jar: ij.jar
-       jarsigner -signedjar signed-ij.jar $(shell cat .jarsignerrc) ij.jar dscho
-
-icon.gif aboutja.jpg: %: images/%
-       cp $< $@
-
-%.class: %.java
-       javac $(JAVACOPTS) $(JAVAS)
-
-clean:
-       rm -f $(COPYFILES) $(ALLCLASSES)
-
diff --git a/sourceext/ij_source/aREADME.txt b/sourceext/ij_source/aREADME.txt
deleted file mode 100644 (file)
index 569279c..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-The ant utility (http://ant.apache.org/) will compile and run ImageJ using \r
-the build file (build.xml) in this directory. There is a version of ant at   \r
-\r
-    http://rsb.info.nih.gov/ij/download/tools/ant/ant.zip\r
-    \r
-set up to use the JVM distributed with the Windows version of ImageJ.\r
-The README included in the ZIP archive has more information.\r
diff --git a/sourceext/ij_source/applet.html b/sourceext/ij_source/applet.html
deleted file mode 100644 (file)
index 49a9f7d..0000000
+++ /dev/null
@@ -1,13 +0,0 @@
-<!-- Runs ImageJ as an Applet -->\r
-\r
-<html>\r
-<head>\r
-<title>ImageJ Applet</title>\r
-</head>\r
-<body>\r
-\r
-<applet codebase="." code="ij.ImageJApplet.class" archive="ij.jar" width=0 height=0>\r
-</applet>\r
-\r
-</body>\r
-</html>\r
diff --git a/sourceext/ij_source/compile.bat b/sourceext/ij_source/compile.bat
deleted file mode 100644 (file)
index 9c355d9..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-javac ij\ImageJ.java\r
-javac ij\plugin\*.java\r
-javac ij\plugin\filter\*.java\r
-javac ij\plugin\frame\*.java\r
-java ij.ImageJ\r
diff --git a/sourceext/ij_source/compile.sh b/sourceext/ij_source/compile.sh
deleted file mode 100755 (executable)
index 3570457..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-#!/bin/sh
-echo "Cleaning up ... "
-ant clean 
-echo "Building ImageJA ..."
-ant
diff --git a/sourceext/ij_source/ij/CommandListener.java b/sourceext/ij_source/ij/CommandListener.java
deleted file mode 100644 (file)
index 7ec2870..0000000
+++ /dev/null
@@ -1,16 +0,0 @@
-package ij;
-
-       /** Plugins that implement this interface are notified when ImageJ
-               is about to run a menu command. There is an example plugin at
-               http://imagej.nih.gov/ij/plugins/download/misc/Command_Listener.java
-       */
-       public interface CommandListener {
-
-       /*      The method is called when ImageJ is about to run a menu command, 
-               where 'command' is the name of the command. Return this string 
-               and ImageJ will run the command, return a different command name
-               and ImageJ will run that command, or return null to not run a command.
-       */
-       public String commandExecuting(String command);
-
-}
diff --git a/sourceext/ij_source/ij/CompositeImage.java b/sourceext/ij_source/ij/CompositeImage.java
deleted file mode 100644 (file)
index ca16cad..0000000
+++ /dev/null
@@ -1,608 +0,0 @@
-package ij;
-import ij.process.*;
-import ij.gui.*;
-import ij.plugin.*;
-import ij.plugin.frame.*;
-import ij.io.FileInfo;
-import java.awt.*;
-import java.awt.image.*;
-
-public class CompositeImage extends ImagePlus {
-
-       // Note: TRANSPARENT mode has not yet been implemented
-       public static final int COMPOSITE=1, COLOR=2, GRAYSCALE=3, TRANSPARENT=4;
-       public static final int MAX_CHANNELS = 7;
-       int[] rgbPixels;
-       boolean newPixels;
-       MemoryImageSource imageSource;
-       Image awtImage;
-       WritableRaster rgbRaster;
-       SampleModel rgbSampleModel;
-       BufferedImage rgbImage;
-       ColorModel rgbCM;
-       ImageProcessor[] cip;
-       Color[] colors = {Color.red, Color.green, Color.blue, Color.white, Color.cyan, Color.magenta, Color.yellow};
-       LUT[] lut;
-       int currentChannel = -1;
-       int previousChannel;
-       int currentSlice = 1;
-       int currentFrame = 1;
-       static int count;
-       boolean singleChannel;
-       boolean[] active = new boolean[MAX_CHANNELS];
-       int mode = COLOR;
-       int bitDepth;
-       double[] displayRanges;
-       byte[][] channelLuts;
-       boolean customLuts;
-       boolean syncChannels;
-       boolean channelsUpdated;
-
-       public CompositeImage(ImagePlus imp) {
-               this(imp, COLOR);
-       }
-       
-       public CompositeImage(ImagePlus imp, int mode) {
-               if (mode<COMPOSITE || mode>GRAYSCALE)
-                       mode = COLOR;
-               this.mode = mode;
-               int channels = imp.getNChannels();
-               bitDepth = getBitDepth();
-               if (IJ.debugMode) IJ.log("CompositeImage: "+imp+" "+mode+" "+channels);
-               ImageStack stack2;
-               boolean isRGB = imp.getBitDepth()==24;
-               if (isRGB) {
-                       if (imp.getImageStackSize()>1)
-                               throw new IllegalArgumentException("RGB stacks not supported");
-                       stack2 = getRGBStack(imp);
-               } else
-                       stack2 = imp.getImageStack();
-               int stackSize = stack2.getSize();
-               if (channels==1 && isRGB) channels = 3;
-               if (channels==1 && stackSize<=MAX_CHANNELS) channels = stackSize;
-               if (channels<2 || (stackSize%channels)!=0)
-                       throw new IllegalArgumentException("channels<2 or stacksize not multiple of channels");
-               if (mode==COMPOSITE && channels>MAX_CHANNELS)
-                       this.mode = COLOR;
-               compositeImage = true;
-               int z = imp.getNSlices();
-               int t = imp.getNFrames();
-               if (channels==stackSize || channels*z*t!=stackSize)
-                       setDimensions(channels, stackSize/channels, 1);
-               else
-                       setDimensions(channels, z, t);
-               setStack(imp.getTitle(), stack2);
-               setCalibration(imp.getCalibration());
-               FileInfo fi = imp.getOriginalFileInfo();
-               if (fi!=null) {
-                       displayRanges = fi.displayRanges; 
-                       channelLuts = fi.channelLuts;
-               }
-               setFileInfo(fi);
-               Object info = imp.getProperty("Info");
-               if (info!=null)
-                       setProperty("Info", imp.getProperty("Info"));
-               if (mode==COMPOSITE) {
-                       for (int i=0; i<MAX_CHANNELS; i++)
-                               active[i] = true;
-               } else
-                       active[0] = true;
-               //if (!(channels==3&&stackSize==3))
-               setRoi(imp.getRoi());
-               setOverlay(imp.getOverlay());
-               if (channels!=stackSize)
-                       setOpenAsHyperStack(true);
-       }
-
-       public Image getImage() {
-               if (img==null)
-                       updateImage();
-               return img;
-       }
-       
-       public void updateChannelAndDraw() {
-               if (!customLuts) singleChannel = true;
-               updateAndDraw();
-       }
-       
-       public void updateAllChannelsAndDraw() {
-               if (mode!=COMPOSITE)
-                       updateChannelAndDraw();
-               else {
-                       syncChannels = true;
-                       singleChannel = false;
-                       updateAndDraw();
-               }
-       }
-
-       public ImageProcessor getChannelProcessor() {
-               if (cip!=null && currentChannel!=-1)
-                       return cip[currentChannel];
-               else
-                       return getProcessor();
-       }
-
-       void setup(int channels, ImageStack stack2) {
-               setupLuts(channels);
-               if (mode==COMPOSITE) {
-                       cip = new ImageProcessor[channels];
-                       for (int i=0; i<channels; ++i) {
-                               cip[i] = stack2.getProcessor(i+1);
-                               cip[i].setColorModel(lut[i]);
-                               cip[i].setMinAndMax(lut[i].min, lut[i].max);
-                       }
-                       currentSlice = currentFrame = 1;
-               }
-       }
-
-       void setupLuts(int channels) {
-               if (lut==null || lut.length<channels) {
-                       if (displayRanges!=null && channels!=displayRanges.length/2)
-                               displayRanges = null;
-                       if (displayRanges==null&&ip.getMin()==0.0&&ip.getMax()==0.0)
-                               ip.resetMinAndMax();
-                       lut = new LUT[channels];
-                       LUT lut2 = channels>MAX_CHANNELS?createLutFromColor(Color.white):null;
-                       for (int i=0; i<channels; ++i) {
-                               if (channelLuts!=null && i<channelLuts.length) {
-                                       lut[i] = createLutFromBytes(channelLuts[i]);
-                                       customLuts = true;
-                               } else if (i<MAX_CHANNELS)
-                                       lut[i] = createLutFromColor(colors[i]);
-                               else
-                                       lut[i] = (LUT)lut2.clone();
-                               if (displayRanges!=null) {
-                                       lut[i].min = displayRanges[i*2];
-                                       lut[i].max = displayRanges[i*2+1];
-                               } else {
-                                       lut[i].min = ip.getMin();
-                                       lut[i].max = ip.getMax();
-                               }
-                       }
-                       displayRanges = null;
-               }
-       }
-       
-       public void resetDisplayRanges() {
-               int channels = getNChannels();
-               ImageStack stack2 = getImageStack();
-               if (lut==null || channels!=lut.length || channels>stack2.getSize() || channels>MAX_CHANNELS)
-                       return;
-               for (int i=0; i<channels; ++i) {
-                       ImageProcessor ip2 = stack2.getProcessor(i+1);
-                       ip2.resetMinAndMax();
-                       lut[i].min = ip2.getMin();
-                       lut[i].max = ip2.getMax();
-               }
-       }
-
-       public void updateAndDraw() {
-               updateImage();
-               if (win!=null)
-                       notifyListeners(UPDATED);
-               draw();
-       }
-
-       public synchronized void updateImage() {
-               int imageSize = width*height;
-               int nChannels = getNChannels();
-               int redValue, greenValue, blueValue;
-               int ch = getChannel();
-               
-               //IJ.log("CompositeImage.updateImage: "+ch+"/"+nChannels+" "+currentSlice+" "+currentFrame);
-               if (ch>nChannels) ch = nChannels;
-               boolean newChannel = false;
-               if (ch-1!=currentChannel) {
-                       previousChannel = currentChannel;
-                       currentChannel = ch-1;
-                       newChannel = true;
-               }
-
-               ImageProcessor ip = getProcessor();
-               if (mode!=COMPOSITE) {
-                       if (newChannel) {
-                               setupLuts(nChannels);
-                               LUT cm = lut[currentChannel];
-                               if (mode==COLOR)
-                                       ip.setColorModel(cm);
-                               if (!(cm.min==0.0&&cm.max==0.0))
-                                       ip.setMinAndMax(cm.min, cm.max);
-                               if (!IJ.isMacro()) ContrastAdjuster.update();
-                               Frame channels = Channels.getInstance();
-                               for (int i=0; i<MAX_CHANNELS; i++)
-                                       active[i] = i==currentChannel?true:false;
-                               if (channels!=null) ((Channels)channels).update();
-                       }
-                       img = ip.createImage();
-                       return;
-               }
-
-               if (nChannels==1) {
-                       cip = null;
-                       rgbPixels = null;
-                       awtImage = null;
-                       if (ip!=null)
-                               img = ip.createImage();
-                       return;
-               }
-       
-               if (cip==null||cip[0].getWidth()!=width||cip[0].getHeight()!=height||getBitDepth()!=bitDepth) {
-                       setup(nChannels, getImageStack());
-                       rgbPixels = null;
-                       rgbSampleModel = null;
-                       if (currentChannel>=nChannels) {
-                               setSlice(1);
-                               currentChannel = 0;
-                               newChannel = true;
-                       }
-                       bitDepth = getBitDepth();
-               }
-               
-               if (newChannel) {
-                       getProcessor().setMinAndMax(cip[currentChannel].getMin(), cip[currentChannel].getMax());
-                       if (!IJ.isMacro()) ContrastAdjuster.update();
-               }
-               //IJ.log(nChannels+" "+ch+" "+currentChannel+"  "+newChannel);
-                               
-               if (getSlice()!=currentSlice || getFrame()!=currentFrame || channelsUpdated) {
-                       channelsUpdated = false;
-                       currentSlice = getSlice();
-                       currentFrame = getFrame();
-                       int position = getStackIndex(1, currentSlice, currentFrame);
-                       for (int i=0; i<nChannels; ++i)
-                               cip[i].setPixels(getImageStack().getProcessor(position+i).getPixels());
-               }
-
-               if (rgbPixels == null) {
-                       rgbPixels = new int[imageSize];
-                       newPixels = true;
-                       imageSource = null;
-                       rgbRaster = null;
-                       rgbImage = null;
-               }
-               
-               cip[currentChannel].setMinAndMax(ip.getMin(),ip.getMax());
-               if (singleChannel && nChannels<=3) {
-                       switch (currentChannel) {
-                               case 0: cip[0].updateComposite(rgbPixels, 1); break;
-                               case 1: cip[1].updateComposite(rgbPixels, 2); break;
-                               case 2: cip[2].updateComposite(rgbPixels, 3); break;
-                       }
-               } else {
-                       if (syncChannels) {
-                               ImageProcessor ip2 = getProcessor();
-                               double min=ip2.getMin(), max=ip2.getMax();
-                               for (int i=0; i<nChannels; i++) {
-                                       cip[i].setMinAndMax(min, max);
-                                       lut[i].min = min;
-                                       lut[i].max = max;
-                               }
-                               syncChannels = false;
-                       }
-                       if (active[0])
-                               cip[0].updateComposite(rgbPixels, 4);
-                       else
-                               {for (int i=1; i<imageSize; i++) rgbPixels[i] = 0;}
-                       for (int i=1; i<nChannels; i++) {
-                               if (active[i]) cip[i].updateComposite(rgbPixels, 5);
-                       }
-               }
-               if (IJ.isJava16())
-                       createBufferedImage();
-               else
-                       createImage();
-               if (img==null && awtImage!=null)
-                       img = awtImage;
-               singleChannel = false;
-       }
-               
-       void createImage() {
-               if (imageSource==null) {
-                       rgbCM = new DirectColorModel(32, 0xff0000, 0xff00, 0xff);
-                       imageSource = new MemoryImageSource(width, height, rgbCM, rgbPixels, 0, width);
-                       imageSource.setAnimated(true);
-                       imageSource.setFullBufferUpdates(true);
-                       awtImage = Toolkit.getDefaultToolkit().createImage(imageSource);
-                       newPixels = false;
-               } else if (newPixels){
-                       imageSource.newPixels(rgbPixels, rgbCM, 0, width);
-                       newPixels = false;
-               } else
-                       imageSource.newPixels();        
-       }
-
-       /** Uses less memory but only works correctly with Java 1.6 and later. */
-       void createBufferedImage() {
-               if (rgbSampleModel==null)
-                       rgbSampleModel = getRGBSampleModel();
-               if (rgbRaster==null) {
-                       DataBuffer dataBuffer = new DataBufferInt(rgbPixels, width*height, 0);
-                       rgbRaster = Raster.createWritableRaster(rgbSampleModel, dataBuffer, null);
-               }
-               if (rgbImage==null)
-                       rgbImage = new BufferedImage(rgbCM, rgbRaster, false, null);
-               awtImage = rgbImage;
-       }
-
-       SampleModel getRGBSampleModel() {
-               rgbCM = new DirectColorModel(24, 0xff0000, 0xff00, 0xff);
-               WritableRaster wr = rgbCM.createCompatibleWritableRaster(1, 1);
-               SampleModel sampleModel = wr.getSampleModel();
-               sampleModel = sampleModel.createCompatibleSampleModel(width, height);
-               return sampleModel;
-       }
-
-       /*
-       void createBlitterImage(int n) {
-               ImageProcessor ip = cip[n-1].duplicate();
-               if (ip instanceof FloatProcessor){
-                       FloatBlitter fb = new FloatBlitter((FloatProcessor)ip);
-                       for (int i=1; i<n; i++)
-                               fb.copyBits(cip[i], 0, 0, Blitter.COPY_ZERO_TRANSPARENT);
-               } else if (ip instanceof ByteProcessor){
-                       ByteBlitter bb = new ByteBlitter((ByteProcessor)ip);
-                       for (int i=1; i<n; i++)
-                               bb.copyBits(cip[i], 0, 0, Blitter.OR);
-               } else if (ip instanceof ShortProcessor){
-                       ShortBlitter sb = new ShortBlitter((ShortProcessor)ip);
-                       for (int i=n-2; i>=0; i--)
-                               sb.copyBits(cip[i], 0, 0, Blitter. OR);
-               }
-               img = ip.createImage();
-               singleChannel = false;
-       }
-       */
-
-       ImageStack getRGBStack(ImagePlus imp) {
-               ImageProcessor ip = imp.getProcessor();
-               int w = ip.getWidth();
-               int h = ip.getHeight();
-               int size = w*h;
-               byte[] r = new byte[size];
-               byte[] g = new byte[size];
-               byte[] b = new byte[size];
-               ((ColorProcessor)ip).getRGB(r, g, b);
-               ImageStack stack = new ImageStack(w, h);
-               stack.addSlice("Red", r);       
-               stack.addSlice("Green", g);     
-               stack.addSlice("Blue", b);
-               stack.setColorModel(ip.getDefaultColorModel());
-               return stack;
-       }
-
-       public LUT createLutFromColor(Color color) {
-               byte[] rLut = new byte[256];
-               byte[] gLut = new byte[256];
-               byte[] bLut = new byte[256];
-               int red = color.getRed();
-               int green = color.getGreen();
-               int blue = color.getBlue();
-               double rIncr = ((double)red)/255d;
-               double gIncr = ((double)green)/255d;
-               double bIncr = ((double)blue)/255d;
-               for (int i=0; i<256; ++i) {
-                       rLut[i] = (byte)(i*rIncr);
-                       gLut[i] = (byte)(i*gIncr);
-                       bLut[i] = (byte)(i*bIncr);
-               }
-               return new LUT(rLut, gLut, bLut);
-       }
-       
-       LUT createLutFromBytes(byte[] bytes) {
-               if (bytes==null || bytes.length!=768)
-                       return createLutFromColor(Color.white);
-               byte[] r = new byte[256];
-               byte[] g = new byte[256];
-               byte[] b = new byte[256];
-               for (int i=0; i<256; i++) r[i] = bytes[i];
-               for (int i=0; i<256; i++) g[i] = bytes[256+i];
-               for (int i=0; i<256; i++) b[i] = bytes[512+i];
-               return new LUT(r, g, b);
-       }
-
-       public Color getChannelColor() {
-               if (lut==null || mode==GRAYSCALE)
-                       return Color.black;
-               IndexColorModel cm = lut[getChannelIndex()];
-               if (cm==null)
-                       return Color.black;
-               int index = cm.getMapSize() - 1;
-               int r = cm.getRed(index);
-               int g = cm.getGreen(index);
-               int b = cm.getBlue(index);
-               //IJ.log(index+" "+r+" "+g+" "+b);
-               if (r<100 || g<100 || b<100)
-                       return new Color(r, g, b);
-               else
-                       return Color.black;
-       }
-
-       public ImageProcessor getProcessor(int channel) {
-               if (cip==null || channel>cip.length)
-                       return null;
-               else
-                       return cip[channel-1];
-       }
-
-       public boolean[] getActiveChannels() {
-               return active;
-       }
-       
-       public void setMode(int mode) {
-               if (mode<COMPOSITE || mode>GRAYSCALE)
-                       return;
-               if (mode==COMPOSITE && getNChannels()>MAX_CHANNELS)
-                       mode = COLOR;
-               for (int i=0; i<MAX_CHANNELS; i++)
-                       active[i] = true;
-               if (this.mode!=COMPOSITE && mode==COMPOSITE)
-                       img = null;
-               this.mode = mode;
-               if (mode==COLOR || mode==GRAYSCALE) {
-                       if (cip!=null) {
-                               for (int i=0; i<cip.length; i++) {
-                                       if (cip[i]!=null) cip[i].setPixels(null);
-                                       cip[i] = null;
-                               }
-                       }
-                       cip = null;
-                       rgbPixels = null;
-                       awtImage = null;
-                       currentChannel = -1;
-               }
-               if (mode==GRAYSCALE || mode==TRANSPARENT)
-                       ip.setColorModel(ip.getDefaultColorModel());
-               Frame channels = Channels.getInstance();
-               if (channels!=null) ((Channels)channels).update();
-       }
-
-       public int getMode() {
-               return mode;
-       }
-       
-       public String getModeAsString() {
-               switch (mode) {
-                       case COMPOSITE: return "composite";
-                       case COLOR: return "color";
-                       case GRAYSCALE: return "grayscale";
-               }
-               return "";
-       }
-       
-       /* Returns the LUT used by the specified channel. */
-       public LUT getChannelLut(int channel) {
-               int channels = getNChannels();
-               if (lut==null) setupLuts(channels);
-               if (channel<1 || channel>lut.length)
-                       throw new IllegalArgumentException("Channel out of range");
-               return lut[channel-1];
-       }
-       
-       /* Returns the LUT used by the current channel. */
-       public LUT getChannelLut() {
-               int c = getChannelIndex();
-               return lut[c];
-       }
-       
-       /* Returns a copy of this image's channel LUTs as an array. */
-       public LUT[] getLuts() {
-               int channels = getNChannels();
-               if (lut==null) setupLuts(channels);
-               LUT[] luts = new LUT[channels];
-               for (int i=0; i<channels; i++)
-                       luts[i] = (LUT)lut[i].clone();
-               return luts;
-       }
-
-       /* Sets the channel LUTs with clones of the LUTs in 'luts'. */
-       public void setLuts(LUT[] luts) {
-               int channels = getNChannels();
-               if (lut==null) setupLuts(channels);
-               if (luts==null || luts.length<channels)
-                       throw new IllegalArgumentException("Lut array is null or too small");
-               for (int i=0; i<channels; i++)
-                       setChannelLut(luts[i], i+1);
-       }
-
-       /** Copies the LUTs and display mode of 'imp' to this image. Does
-               nothing if 'imp' is not a CompositeImage or 'imp' and this
-               image do not have the same number of channels. */
-       public void copyLuts(ImagePlus imp) {
-               int channels = getNChannels();
-               if (!imp.isComposite() || imp.getNChannels()!=channels)
-                       return;
-               CompositeImage ci = (CompositeImage)imp;
-               LUT[] luts = ci.getLuts();
-               if (luts!=null && luts.length==channels) {
-                       lut = luts;
-                       cip = null;
-               }
-               int mode2 = ci.getMode();
-               setMode(mode2);
-               if (mode2==COMPOSITE) {
-                       boolean[] active2 = ci.getActiveChannels();
-                       for (int i=0; i<MAX_CHANNELS; i++)
-                               active[i] = active2[i];
-               }
-       }
-
-       int getChannelIndex() {
-               int channels = getNChannels();
-               if (lut==null) setupLuts(channels);
-               int index = getChannel()-1;
-               return index;
-       }
-       
-       public void reset() {
-               setup(getNChannels(), getImageStack());
-       }
-       
-       /* Sets the LUT of the current channel. */
-       public void setChannelLut(LUT table) {
-               if (mode==GRAYSCALE)
-                       getProcessor().setColorModel(table);
-               else {
-                       int c = getChannelIndex();
-                       double min = lut[c].min;
-                       double max = lut[c].max;
-                       lut[c] = table;
-                       lut[c].min = min;
-                       lut[c].max = max;
-                       if (mode==COMPOSITE && cip!=null && c<cip.length) {
-                               cip[c].setColorModel(lut[c] );
-                               imageSource = null;
-                               newPixels = true;
-                               img = null;
-                       }
-                       currentChannel = -1;
-                       if (!IJ.isMacro()) ContrastAdjuster.update();
-               }
-               customLuts = true;
-       }
-       
-       /* Sets the LUT of the specified channel using a clone of 'table'. */
-       public void setChannelLut(LUT table, int channel) {
-               int channels = getNChannels();
-               if (lut==null) setupLuts(channels);
-               if (channel<1 || channel>lut.length)
-                       throw new IllegalArgumentException("Channel out of range");
-               lut[channel-1] = (LUT)table.clone();
-               cip = null;
-       }
-
-       /* Sets the IndexColorModel of the current channel. */
-       public void setChannelColorModel(IndexColorModel cm) {
-               setChannelLut(new LUT(cm,0.0,0.0));
-       }
-       
-       public void setDisplayRange(double min, double max) {
-               ip.setMinAndMax(min, max);
-               int c = getChannelIndex();
-               lut[c].min = min;
-               lut[c].max = max;
-       }
-
-       public double getDisplayRangeMin() {
-               return lut[getChannelIndex()].min;
-       }
-
-       public double getDisplayRangeMax() {
-               return lut[getChannelIndex()].max;
-       }
-
-       public void resetDisplayRange() {
-               ip.resetMinAndMax();
-               int c = getChannelIndex();
-               lut[c].min = ip.getMin();
-               lut[c].max = ip.getMax();
-       }
-       
-       public boolean hasCustomLuts() {
-               return customLuts && mode!=GRAYSCALE;
-       }
-       
-       public void setChannelsUpdated() {
-               channelsUpdated = true;
-       }
-
-}
diff --git a/sourceext/ij_source/ij/Executer.java b/sourceext/ij_source/ij/Executer.java
deleted file mode 100644 (file)
index 1080eac..0000000
+++ /dev/null
@@ -1,173 +0,0 @@
-package ij;
-import ij.util.Tools;
-import ij.text.TextWindow;
-import ij.plugin.MacroInstaller;
-import ij.plugin.frame.Recorder;
-import ij.io.OpenDialog;
-import java.io.*;
-import java.util.*;
-import java.awt.event.KeyEvent;
-import java.awt.Menu;
-
-
-/** Runs ImageJ menu commands in a separate thread.*/
-public class Executer implements Runnable {
-
-       private static String previousCommand;
-       private static CommandListener listener;
-       private static Vector listeners = new Vector();
-       
-       private String command;
-       private Thread thread;
-       
-       /** Create an Executer to run the specified menu command
-               in this thread using the active image. */
-       public Executer(String cmd) {
-               command = cmd;
-       }
-
-       /** Create an Executer that runs the specified menu command
-               in a separate thread using the active image image. */
-       public Executer(String cmd, ImagePlus ignored) {
-               if (cmd.startsWith("Repeat")) {
-                       command = previousCommand;
-                       IJ.setKeyUp(KeyEvent.VK_SHIFT);         
-               } else {
-                       command = cmd;
-                       if (!(cmd.equals("Undo")||cmd.equals("Close")))
-                               previousCommand = cmd;
-               }
-               IJ.resetEscape();
-               thread = new Thread(this, cmd);
-               thread.setPriority(Math.max(thread.getPriority()-2, Thread.MIN_PRIORITY));
-               thread.start();
-       }
-
-       public void run() {
-               if (command==null) return;
-               if (listeners.size()>0) synchronized (listeners) {
-                       for (int i=0; i<listeners.size(); i++) {
-                               CommandListener listener = (CommandListener)listeners.elementAt(i);
-                               command = listener.commandExecuting(command);
-                               if (command==null) return;
-                       }
-               }
-               try {
-                       if (Recorder.record) {
-                               Recorder.setCommand(command);
-                               runCommand(command);
-                               Recorder.saveCommand();
-                       } else
-                               runCommand(command);
-                       int len = command.length();
-                       if (command.charAt(len-1)!=']' && !(len<4&&(command.equals("In")||command.equals("Out"))))
-                               IJ.setKeyUp(IJ.ALL_KEYS);  // set keys up except for "<", ">", "+" and "-" shortcuts
-               } catch(Throwable e) {
-                       IJ.showStatus("");
-                       IJ.showProgress(1, 1);
-                       ImagePlus imp = WindowManager.getCurrentImage();
-                       if (imp!=null) imp.unlock();
-                       String msg = e.getMessage();
-                       if (e instanceof OutOfMemoryError)
-                               IJ.outOfMemory(command);
-                       else if (e instanceof RuntimeException && msg!=null && msg.equals(Macro.MACRO_CANCELED))
-                               ; //do nothing
-                       else {
-                               CharArrayWriter caw = new CharArrayWriter();
-                               PrintWriter pw = new PrintWriter(caw);
-                               e.printStackTrace(pw);
-                               String s = caw.toString();
-                               if (IJ.isMacintosh()) {
-                                       if (s.indexOf("ThreadDeath")>0)
-                                               return;
-                                       s = Tools.fixNewLines(s);
-                               }
-                               int w=350, h=250;
-                               if (s.indexOf("UnsupportedClassVersionError")!=-1) {
-                                       if (s.indexOf("version 49.0")!=-1) {
-                                               s = e + "\n \nThis plugin requires Java 1.5 or later.";
-                                               w=700; h=150;
-                                       }
-                                       if (s.indexOf("version 50.0")!=-1) {
-                                               s = e + "\n \nThis plugin requires Java 1.6 or later.";
-                                               w=700; h=150;
-                                       }
-                                       if (s.indexOf("version 51.0")!=-1) {
-                                               s = e + "\n \nThis plugin requires Java 1.7 or later.";
-                                               w=700; h=150;
-                                       }
-                               }
-                               if (IJ.getInstance()!=null)
-                                       new TextWindow("Exception", s, w, h);
-                               else
-                                       IJ.log(s);
-                       }
-               }
-       }
-       
-    void runCommand(String cmd) {
-               Hashtable table = Menus.getCommands();
-               String className = (String)table.get(cmd);
-               if (className!=null) {
-                       String arg = "";
-                       if (className.endsWith("\")")) {
-                               // extract string argument (e.g. className("arg"))
-                               int argStart = className.lastIndexOf("(\"");
-                               if (argStart>0) {
-                                       arg = className.substring(argStart+2, className.length()-2);
-                                       className = className.substring(0, argStart);
-                               }
-                       }
-                       if (IJ.shiftKeyDown() && className.startsWith("ij.plugin.Macro_Runner") && !Menus.getShortcuts().contains("*"+cmd))
-                       IJ.open(IJ.getDirectory("plugins")+arg);
-               else
-                               IJ.runPlugIn(cmd, className, arg);
-               } else {
-                       // Is this command in Plugins>Macros?
-                       if (MacroInstaller.runMacroCommand(cmd))
-                               return;
-                       // Is this command a LUT name?
-                       String path = IJ.getDirectory("luts")+cmd+".lut";
-                       File f = new File(path);
-                       if (f.exists()) {
-                               String dir = OpenDialog.getLastDirectory();
-                               IJ.open(path);
-                               OpenDialog.setLastDirectory(dir);
-                       } else if (!openRecent(cmd))
-                               IJ.error("Unrecognized command: " + cmd);
-               }
-    }
-    
-    /** Opens a file from the File/Open Recent menu 
-             and returns 'true' if successful. */
-    boolean openRecent(String cmd) {
-               Menu menu = Menus.openRecentMenu;
-               if (menu==null) return false;
-               for (int i=0; i<menu.getItemCount(); i++) {
-                       if (menu.getItem(i).getLabel().equals(cmd)) {
-                               IJ.open(cmd);
-                               return true;
-                       }
-               }
-               return false;
-    }
-
-       /** Returns the last command executed. Returns null
-               if no command has been executed. */
-       public static String getCommand() {
-               return previousCommand;
-       }
-       
-       /** Adds the specified command listener. */
-       public static void addCommandListener(CommandListener listener) {
-               listeners.addElement(listener);
-       }
-       
-       /** Removes the specified command listener. */
-       public static void removeCommandListener(CommandListener listener) {
-               listeners.removeElement(listener);
-       }
-
-}
-
-
diff --git a/sourceext/ij_source/ij/IJ.java b/sourceext/ij_source/ij/IJ.java
deleted file mode 100644 (file)
index f409e39..0000000
+++ /dev/null
@@ -1,1739 +0,0 @@
-package ij;
-import ij.gui.*;
-import ij.process.*;
-import ij.text.*;
-import ij.io.*;
-import ij.plugin.*;
-import ij.plugin.filter.*;
-import ij.util.Tools;
-import ij.plugin.frame.Recorder;
-import ij.macro.Interpreter;
-import ij.measure.Calibration;
-import ij.measure.ResultsTable;
-import java.awt.event.*;
-import java.text.*;
-import java.util.*;    
-import java.awt.*;     
-import java.applet.Applet;
-import java.io.*;
-import java.lang.reflect.*;
-import java.net.*;
-
-
-/** This class consists of static utility methods. */
-public class IJ {
-       public static final String URL = "http://imagej.nih.gov/ij";
-       public static final int ALL_KEYS = -1;
-       
-       public static boolean debugMode;
-       public static boolean hideProcessStackDialog;
-           
-    public static final char micronSymbol = '\u00B5';
-    public static final char angstromSymbol = '\u00C5';
-    public static final char degreeSymbol = '\u00B0';
-
-       private static ImageJ ij;
-       private static java.applet.Applet applet;
-       private static ProgressBar progressBar;
-       private static TextPanel textPanel;
-       private static String osname, osarch;
-       private static boolean isMac, isWin, isJava2, isJava14, isJava15, isJava16, isJava17, isLinux, isVista, is64Bit;
-       private static boolean controlDown, altDown, spaceDown, shiftDown;
-       private static boolean macroRunning;
-       private static Thread previousThread;
-       private static TextPanel logPanel;
-       private static boolean checkForDuplicatePlugins = true;         
-       private static ClassLoader classLoader;
-       private static boolean memMessageDisplayed;
-       private static long maxMemory;
-       private static boolean escapePressed;
-       private static boolean redirectErrorMessages, redirectErrorMessages2;
-       private static boolean suppressPluginNotFoundError;
-       private static Hashtable commandTable;
-       private static Vector eventListeners = new Vector();
-                       
-       static {
-               osname = System.getProperty("os.name");
-               isWin = osname.startsWith("Windows");
-               isMac = !isWin && osname.startsWith("Mac");
-               isLinux = osname.startsWith("Linux");
-               isVista = isWin && (osname.indexOf("Vista")!=-1||osname.indexOf(" 7")!=-1);
-               String version = System.getProperty("java.version").substring(0,3);
-               if (version.compareTo("2.9")<=0) {  // JVM on Sharp Zaurus PDA claims to be "3.1"!
-                       isJava2 = version.compareTo("1.1")>0;
-                       isJava14 = version.compareTo("1.3")>0;
-                       isJava15 = version.compareTo("1.4")>0;
-                       isJava16 = version.compareTo("1.5")>0;
-                       isJava17 = version.compareTo("1.6")>0;
-               }
-       }
-                       
-       static void init(ImageJ imagej, Applet theApplet) {
-               ij = imagej;
-               applet = theApplet;
-               progressBar = ij.getProgressBar();
-       }
-
-       static void cleanup() {
-               ij=null; applet=null; progressBar=null; textPanel=null;
-       }
-
-       /**Returns a reference to the "ImageJ" frame.*/
-       public static ImageJ getInstance() {
-               return ij;
-       }
-       
-       /** Runs the macro contained in the string <code>macro</code>.
-               Returns any string value returned by the macro, null if the macro
-               does not return a value, or "[aborted]" if the macro was aborted
-               due to an error. The equivalent macro function is eval(). */
-       public static String runMacro(String macro) {
-               return runMacro(macro, "");
-       }
-
-       /** Runs the macro contained in the string <code>macro</code>.
-               The optional string argument can be retrieved in the
-               called macro using the getArgument() macro function. 
-               Returns any string value returned by the macro, null if the macro
-               does not return a value, or "[aborted]" if the macro was aborted
-               due to an error.  */
-       public static String runMacro(String macro, String arg) {
-               Macro_Runner mr = new Macro_Runner();
-               return mr.runMacro(macro, arg);
-       }
-
-       /** Runs the specified macro or script file in the current thread.
-               The file is assumed to be in the macros folder
-               unless <code>name</code> is a full path. ".txt"  is
-       added if <code>name</code> does not have an extension.
-               The optional string argument (<code>arg</code>) can be retrieved in the called 
-               macro or script (v1.42k or later) using the getArgument() function. 
-               Returns any string value returned by the macro, or null. Scripts always return null.
-               The equivalent macro function is runMacro(). */
-       public static String runMacroFile(String name, String arg) {
-               if (ij==null && Menus.getCommands()==null)
-                       init();
-               Macro_Runner mr = new Macro_Runner();
-               return mr.runMacroFile(name, arg);
-       }
-
-       /** Runs the specified macro file. */
-       public static String runMacroFile(String name) {
-               return runMacroFile(name, null);
-       }
-
-       /** Runs the specified plugin using the specified image. */
-       public static Object runPlugIn(ImagePlus imp, String className, String arg) {
-               if (imp!=null) {
-                       ImagePlus temp = WindowManager.getTempCurrentImage();
-                       WindowManager.setTempCurrentImage(imp);
-                       Object o = runPlugIn("", className, arg);
-                       WindowManager.setTempCurrentImage(temp);
-                       return o;
-               } else
-                       return runPlugIn(className, arg);
-       }
-
-       /** Runs the specified plugin and returns a reference to it. */
-       public static Object runPlugIn(String className, String arg) {
-               return runPlugIn("", className, arg);
-       }
-       
-       /** Runs the specified plugin and returns a reference to it. */
-       static Object runPlugIn(String commandName, String className, String arg) {
-               if (IJ.debugMode)
-                       IJ.log("runPlugin: "+className+" "+arg);
-               if (arg==null) arg = "";
-               // Load using custom classloader if this is a user 
-               // plugin and we are not running as an applet
-               if (!className.startsWith("ij.") && applet==null)
-                       return runUserPlugIn(commandName, className, arg, false);
-               Object thePlugIn=null;
-               try {
-                       Class c = Class.forName(className);
-                       thePlugIn = c.newInstance();
-                       if (thePlugIn instanceof PlugIn)
-                               ((PlugIn)thePlugIn).run(arg);
-                       else
-                               new PlugInFilterRunner(thePlugIn, commandName, arg);
-               }
-               catch (ClassNotFoundException e) {
-                       if (IJ.getApplet()==null)
-                               log("Plugin or class not found: \"" + className + "\"\n(" + e+")");
-               }
-               catch (InstantiationException e) {log("Unable to load plugin (ins)");}
-               catch (IllegalAccessException e) {log("Unable to load plugin, possibly \nbecause it is not public.");}
-               redirectErrorMessages = false;
-               return thePlugIn;
-       }
-        
-       static Object runUserPlugIn(String commandName, String className, String arg, boolean createNewLoader) {
-               if (applet!=null) return null;
-               if (checkForDuplicatePlugins) {
-                       // check for duplicate classes and jars in the plugins folder
-                       IJ.runPlugIn("ij.plugin.ClassChecker", "");
-                       checkForDuplicatePlugins = false;
-               }
-               if (createNewLoader) classLoader = null;
-               ClassLoader loader = getClassLoader();
-               Object thePlugIn = null;
-               try { 
-                       thePlugIn = (loader.loadClass(className)).newInstance(); 
-                       if (thePlugIn instanceof PlugIn)
-                               ((PlugIn)thePlugIn).run(arg);
-                       else if (thePlugIn instanceof PlugInFilter)
-                               new PlugInFilterRunner(thePlugIn, commandName, arg);
-               }
-               catch (ClassNotFoundException e) {
-                       if (className.indexOf('_')!=-1 && !suppressPluginNotFoundError)
-                               error("Plugin or class not found: \"" + className + "\"\n(" + e+")");
-               }
-               catch (NoClassDefFoundError e) {
-                       int dotIndex = className.indexOf('.');
-                       if (dotIndex >= 0)
-                               return runUserPlugIn(commandName, className.substring(dotIndex + 1), arg, createNewLoader);
-                       if (className.indexOf('_')!=-1 && !suppressPluginNotFoundError)
-                               error("Plugin or class not found: \"" + className + "\"\n(" + e+")");
-               }
-               catch (InstantiationException e) {error("Unable to load plugin (ins)");}
-               catch (IllegalAccessException e) {error("Unable to load plugin, possibly \nbecause it is not public.");}
-               if (redirectErrorMessages && !"HandleExtraFileTypes".equals(className))
-                       redirectErrorMessages = false;
-               suppressPluginNotFoundError = false;
-               return thePlugIn;
-       } 
-
-       static void wrongType(int capabilities, String cmd) {
-               String s = "\""+cmd+"\" requires an image of type:\n \n";
-               if ((capabilities&PlugInFilter.DOES_8G)!=0) s +=  "    8-bit grayscale\n";
-               if ((capabilities&PlugInFilter.DOES_8C)!=0) s +=  "    8-bit color\n";
-               if ((capabilities&PlugInFilter.DOES_16)!=0) s +=  "    16-bit grayscale\n";
-               if ((capabilities&PlugInFilter.DOES_32)!=0) s +=  "    32-bit (float) grayscale\n";
-               if ((capabilities&PlugInFilter.DOES_RGB)!=0) s += "    RGB color\n";
-               error(s);
-       }
-       
-    /** Starts executing a menu command in a separete thread and returns immediately. */
-       public static void doCommand(String command) {
-               if (ij!=null)
-                       ij.doCommand(command);
-       }
-       
-    /** Runs an ImageJ command. Does not return until 
-       the command has finished executing. To avoid "image locked",
-       errors, plugins that call this method should implement
-       the PlugIn interface instead of PlugInFilter. */
-       public static void run(String command) {
-               run(command, null);
-       }
-       
-    /** Runs an ImageJ command, with options that are passed to the
-               GenericDialog and OpenDialog classes. Does not return until
-               the command has finished executing. */
-       public static void run(String command, String options) {
-               //IJ.log("run1: "+command+" "+Thread.currentThread().hashCode());
-               if (ij==null && Menus.getCommands()==null)
-                       init();
-               Macro.abort = false;
-               Macro.setOptions(options);
-               Thread thread = Thread.currentThread();
-               if (previousThread==null || thread!=previousThread) {
-                       String name = thread.getName();
-                       if (!name.startsWith("Run$_"))
-                               thread.setName("Run$_"+name);
-               }
-               command = convert(command);
-               previousThread = thread;
-               macroRunning = true;
-               Executer e = new Executer(command);
-               e.run();
-               macroRunning = false;
-               Macro.setOptions(null);
-               testAbort();
-               //IJ.log("run2: "+command+" "+Thread.currentThread().hashCode());
-       }
-       
-       /** Converts commands that have been renamed so 
-               macros using the old names continue to work. */
-       private static String convert(String command) {
-               if (commandTable==null) {
-                       commandTable = new Hashtable(23); // initial capacity should be increased as needed
-                       commandTable.put("New...", "Image...");
-                       commandTable.put("Threshold", "Make Binary");
-                       commandTable.put("Display...", "Appearance...");
-                       commandTable.put("Start Animation", "Start Animation [\\]");
-                       commandTable.put("Convert Images to Stack", "Images to Stack");
-                       commandTable.put("Convert Stack to Images", "Stack to Images");
-                       commandTable.put("Convert Stack to RGB", "Stack to RGB");
-                       commandTable.put("Convert to Composite", "Make Composite");
-                       commandTable.put("New HyperStack...", "New Hyperstack...");
-                       commandTable.put("Stack to HyperStack...", "Stack to Hyperstack...");
-                       commandTable.put("HyperStack to Stack", "Hyperstack to Stack");
-                       commandTable.put("RGB Split", "Split Channels");
-                       commandTable.put("RGB Merge...", "Merge Channels...");
-                       commandTable.put("Channels...", "Channels Tool...");
-                       commandTable.put("New... ", "Table...");
-                       commandTable.put("Arbitrarily...", "Rotate... ");
-                       commandTable.put("Measurements...", "Results... ");
-               }
-               String command2 = (String)commandTable.get(command);
-               if (command2!=null)
-                       return command2;
-               else
-                       return command;
-       }
-
-       /** Runs an ImageJ command using the specified image and options. */
-       public static void run(ImagePlus imp, String command, String options) {
-               if (imp!=null) {
-                       ImagePlus temp = WindowManager.getTempCurrentImage();
-                       WindowManager.setTempCurrentImage(imp);
-                       run(command, options);
-                       WindowManager.setTempCurrentImage(temp);
-               } else
-                       run(command, options);
-       }
-
-       static void init() {
-               Menus m = new Menus(null, null);
-               Prefs.load(m, null);
-               m.addMenuBar();
-       }
-
-       private static void testAbort() {
-               if (Macro.abort)
-                       abort();
-       }
-
-       /** 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;
-       }
-
-       /**Returns the Applet that created this ImageJ or null if running as an application.*/
-       public static java.applet.Applet getApplet() {
-               return applet;
-       }
-       
-       /**Displays a message in the ImageJ status bar.*/
-       public static void showStatus(String s) {
-               if (ij!=null) ij.showStatus(s);
-               ImagePlus imp = WindowManager.getCurrentImage();
-               ImageCanvas ic = imp!=null?imp.getCanvas():null;
-               if (ic!=null)
-                       ic.setShowCursorStatus(s.length()==0?true:false);
-       }
-
-       /**
-       * @deprecated
-       * replaced by IJ.log(), ResultsTable.setResult() and TextWindow.append().
-       * There are examples at
-       *   http://imagej.nih.gov/ij/plugins/sine-cosine.html
-       */
-       public static void write(String s) {
-               if (textPanel==null && ij!=null)
-                       showResults();
-               if (textPanel!=null)
-                               textPanel.append(s);
-               else
-                       System.out.println(s);
-       }
-
-       private static void showResults() {
-               TextWindow resultsWindow = new TextWindow("Results", "", 400, 250);
-               textPanel = resultsWindow.getTextPanel();
-               textPanel.setResultsTable(Analyzer.getResultsTable());
-               if (ij!=null)
-                       textPanel.addKeyListener(ij);
-       }
-
-       public static synchronized void log(String s) {
-               if (s==null) return;
-               if (logPanel==null && ij!=null) {
-                       TextWindow logWindow = new TextWindow("Log", "", 400, 250);
-                       logPanel = logWindow.getTextPanel();
-                       logPanel.setFont(new Font("SansSerif", Font.PLAIN, 16));
-               }
-               if (logPanel!=null) {
-                       if (s.startsWith("\\"))
-                               handleLogCommand(s);
-                       else
-                               logPanel.append(s);
-               } else
-                       System.out.println(s);
-       }
-
-       static void handleLogCommand(String s) {
-               if (s.equals("\\Closed"))
-                       logPanel = null;
-               else if (s.startsWith("\\Update:")) {
-                       int n = logPanel.getLineCount();
-                       String s2 = s.substring(8, s.length());
-                       if (n==0)
-                               logPanel.append(s2);
-                       else
-                               logPanel.setLine(n-1, s2);
-               } else if (s.startsWith("\\Update")) {
-                       int cindex = s.indexOf(":");
-                       if (cindex==-1)
-                               {logPanel.append(s); return;}
-                       String nstr = s.substring(7, cindex);
-                       int line = (int)Tools.parseDouble(nstr, -1);
-                       if (line<0 || line>25)
-                               {logPanel.append(s); return;}
-                       int count = logPanel.getLineCount();
-                       while (line>=count) {
-                               log("");
-                               count++;
-                       }
-                       String s2 = s.substring(cindex+1, s.length());
-                       logPanel.setLine(line, s2);
-               } else if (s.equals("\\Clear"))
-                       logPanel.clear();
-               else
-                       logPanel.append(s);
-       }
-       
-       /** Clears the "Results" window and sets the column headings to
-               those in the tab-delimited 'headings' String. Writes to
-               System.out.println if the "ImageJ" frame is not present.*/
-       public static void setColumnHeadings(String headings) {
-               if (textPanel==null && ij!=null)
-                       showResults();
-               if (textPanel!=null)
-                       textPanel.setColumnHeadings(headings);
-               else
-                       System.out.println(headings);
-       }
-
-       /** Returns true if the "Results" window is open. */
-       public static boolean isResultsWindow() {
-               return textPanel!=null;
-       }
-       
-       /** Renames a results window. */
-       public static void renameResults(String title) {
-               Frame frame = WindowManager.getFrontWindow();
-               if (frame!=null && (frame instanceof TextWindow)) {
-                       TextWindow tw = (TextWindow)frame;
-                       if (tw.getTextPanel().getResultsTable()==null) {
-                               IJ.error("Rename", "\""+tw.getTitle()+"\" is not a results table");
-                               return;
-                       }
-                       tw.rename(title);
-               } else if (isResultsWindow()) {
-                       TextPanel tp = getTextPanel();
-                       TextWindow tw = (TextWindow)tp.getParent();
-                       tw.rename(title);
-               }
-       }
-
-       /** Deletes 'row1' through 'row2' of the "Results" window. Arguments
-            must be in the range 0-Analyzer.getCounter()-1. */
-       public static void deleteRows(int row1, int row2) {
-               int n = row2 - row1 + 1;
-               ResultsTable rt = Analyzer.getResultsTable();
-               for (int i=row1; i<row1+n; i++)
-                       rt.deleteRow(row1);
-               rt.show("Results");
-       }
-
-       /** Returns a reference to the "Results" window TextPanel.
-               Opens the "Results" window if it is currently not open.
-               Returns null if the "ImageJ" window is not open. */
-       public static TextPanel getTextPanel() {
-               if (textPanel==null && ij!=null)
-                       showResults();
-               return textPanel;
-       }
-       
-       /** TextWindow calls this method with a null argument when the "Results" window is closed. */
-       public static void setTextPanel(TextPanel tp) {
-               textPanel = tp;
-       }
-    
-    /**Displays a "no images are open" dialog box.*/
-       public static void noImage() {
-               error("No Image", "There are no images open.");
-       }
-
-       /** Displays an "out of memory" message to the "Log" window. */
-       public static void outOfMemory(String name) {
-               Undo.reset();
-               System.gc();
-               String tot = Runtime.getRuntime().totalMemory()/1048576L+"MB";
-               if (!memMessageDisplayed)
-                       log(">>>>>>>>>>>>>>>>>>>>>>>>>>>");
-               log("<Out of memory>");
-               if (!memMessageDisplayed) {
-                       log("<All available memory ("+tot+") has been>");
-                       log("<used. Instructions for making more>");
-                       log("<available can be found in the \"Memory\" >");
-                       log("<sections of the installation notes at>");
-                       log("<"+IJ.URL+"/docs/install/>");
-                       log(">>>>>>>>>>>>>>>>>>>>>>>>>>>");
-                       memMessageDisplayed = true;
-               }
-               Macro.abort();
-       }
-
-       /**     Updates the progress bar, where 0<=progress<=1.0. The progress bar is 
-       not shown in BatchMode and erased if progress>=1.0. The progress bar is
-    updated only if more than 90 ms have passes since the last call. Does nothing 
-       if the ImageJ window is not present. */
-       public static void showProgress(double progress) {
-               if (progressBar!=null) progressBar.show(progress, false);
-       }
-
-       /**     Updates the progress bar, where the length of the bar is set to
-    (<code>currentValue+1)/finalValue</code> of the maximum bar length.
-    The bar is erased if <code>currentValue&gt;=finalValue</code>. 
-    The bar is updated only if more than 90 ms have passed since the last call.
-    Does nothing if the ImageJ window is not present. */
-    public static void showProgress(int currentIndex, int finalIndex) {
-               if (progressBar!=null) {
-                       progressBar.show(currentIndex, finalIndex);
-                       if (currentIndex==finalIndex)
-                               progressBar.setBatchMode(false);
-               }
-       }
-
-       /** Displays a message in a dialog box titled "Message".
-               Writes the Java console if ImageJ is not present. */
-       public static void showMessage(String msg) {
-               showMessage("Message", msg);
-       }
-
-       /**     Displays a message in a dialog box with the specified title.
-               Writes the Java console if ImageJ is not present. */
-       public static void showMessage(String title, String msg) {
-               if (ij!=null) {
-                       if (msg!=null && msg.startsWith("<html>"))
-                               new HTMLDialog(title, msg);
-                       else
-                               new MessageDialog(ij, title, msg);
-               } else
-                       System.out.println(msg);
-       }
-
-       /** Displays a message in a dialog box titled "ImageJ". If a 
-               macro is running, it is aborted. Writes to the Java console
-               if the ImageJ window is not present.*/
-       public static void error(String msg) {
-               error(null, msg);
-               if (Thread.currentThread().getName().endsWith("JavaScript"))
-                       throw new RuntimeException(Macro.MACRO_CANCELED);
-               else
-                       Macro.abort();
-       }
-       
-       /**Displays a message in a dialog box with the specified title.
-               If a macro is running, it is aborted. Writes to the Java  
-               console if ImageJ is not present. */
-       public static void error(String title, String msg) {
-               String title2 = title!=null?title:"ImageJ";
-               boolean abortMacro = title!=null;
-               if (redirectErrorMessages || redirectErrorMessages2) {
-                       IJ.log(title2 + ": " + msg);
-                       if (abortMacro && title.equals("Opener")) abortMacro = false;
-               } else
-                       showMessage(title2, msg);
-               redirectErrorMessages = false;
-               if (abortMacro) Macro.abort();
-       }
-
-       /** Displays a message in a dialog box with the specified title.
-               Returns false if the user pressed "Cancel". */
-       public static boolean showMessageWithCancel(String title, String msg) {
-               GenericDialog gd = new GenericDialog(title);
-               gd.addMessage(msg);
-               gd.showDialog();
-               return !gd.wasCanceled();
-       }
-
-       public static final int CANCELED = Integer.MIN_VALUE;
-
-       /** Allows the user to enter a number in a dialog box. Returns the      
-           value IJ.CANCELED (-2,147,483,648) if the user cancels the dialog box. 
-           Returns 'defaultValue' if the user enters an invalid number. */
-       public static double getNumber(String prompt, double defaultValue) {
-               GenericDialog gd = new GenericDialog("");
-               int decimalPlaces = (int)defaultValue==defaultValue?0:2;
-               gd.addNumericField(prompt, defaultValue, decimalPlaces);
-               gd.showDialog();
-               if (gd.wasCanceled())
-                       return CANCELED;
-               double v = gd.getNextNumber();
-               if (gd.invalidNumber())
-                       return defaultValue;
-               else
-                       return v;
-       }
-
-       /** Allows the user to enter a string in a dialog box. Returns
-           "" if the user cancels the dialog box. */
-       public static String getString(String prompt, String defaultString) {
-               GenericDialog gd = new GenericDialog("");
-               gd.addStringField(prompt, defaultString, 20);
-               gd.showDialog();
-               if (gd.wasCanceled())
-                       return "";
-               return gd.getNextString();
-       }
-
-       /**Delays 'msecs' milliseconds.*/
-       public static void wait(int msecs) {
-               try {Thread.sleep(msecs);}
-               catch (InterruptedException e) { }
-       }
-       
-       /** Emits an audio beep. */
-       public static void beep() {
-               java.awt.Toolkit.getDefaultToolkit().beep();
-       }
-       
-       /**     Runs the garbage collector and returns a string something
-               like "64K of 256MB (25%)" that shows how much of 
-               the  available memory is in use. This is the string
-               displayed when the user clicks in the status bar. */
-       public static String freeMemory() {
-               long inUse = currentMemory();
-               String inUseStr = inUse<10000*1024?inUse/1024L+"K":inUse/1048576L+"MB";
-               String maxStr="";
-               long max = maxMemory();
-               if (max>0L) {
-                       double percent = inUse*100/max;
-                       maxStr = " of "+max/1048576L+"MB ("+(percent<1.0?"<1":d2s(percent,0)) + "%)";
-               }
-               return  inUseStr + maxStr;
-       }
-       
-       /** Returns the amount of memory currently being used by ImageJ. */
-       public static long currentMemory() {
-               long freeMem = Runtime.getRuntime().freeMemory();
-               long totMem = Runtime.getRuntime().totalMemory();
-               return totMem-freeMem;
-       }
-
-       /** Returns the maximum amount of memory available to ImageJ or
-               zero if ImageJ is unable to determine this limit. */
-       public static long maxMemory() {
-               if (maxMemory==0L) {
-                       Memory mem = new Memory();
-                       maxMemory = mem.getMemorySetting();
-                       if (maxMemory==0L) maxMemory = mem.maxMemory();
-               }
-               return maxMemory;
-       }
-       
-       public static void showTime(ImagePlus imp, long start, String str) {
-               showTime(imp, start, str, 1);
-       }
-       
-       public static void showTime(ImagePlus imp, long start, String str, int nslices) {
-               if (Interpreter.isBatchMode()) return;
-           long elapsedTime = System.currentTimeMillis() - start;
-               double seconds = elapsedTime / 1000.0;
-               long pixels = imp.getWidth() * imp.getHeight();
-               int rate = (int)((double)pixels*nslices/seconds);
-               String str2;
-               if (rate>1000000000)
-                       str2 = "";
-               else if (rate<1000000)
-                       str2 = ", "+rate+" pixels/second";
-               else
-                       str2 = ", "+d2s(rate/1000000.0,1)+" million pixels/second";
-               showStatus(str+seconds+" seconds"+str2);
-       }
-
-       /** Converts a number to a formatted string using
-               2 digits to the right of the decimal point. */
-       public static String d2s(double n) {
-               return d2s(n, 2);
-       }
-       
-       private static DecimalFormat[] df;
-       private static DecimalFormat[] sf;
-       private static DecimalFormatSymbols dfs;
-
-       /** Converts a number to a rounded formatted string.
-               The 'decimalPlaces' argument specifies the number of
-               digits to the right of the decimal point (0-9). Uses
-               scientific notation if 'decimalPlaces is negative. */
-       public static String d2s(double n, int decimalPlaces) {
-               if (Double.isNaN(n))
-                       return "NaN";
-               if (n==Float.MAX_VALUE) // divide by 0 in FloatProcessor
-                       return "3.4e38";
-               double np = n;
-               if (n<0.0) np = -n;
-               if (df==null) {
-                       dfs = new DecimalFormatSymbols(Locale.US);
-                       df = new DecimalFormat[10];
-                       df[0] = new DecimalFormat("0", dfs);
-                       df[1] = new DecimalFormat("0.0", dfs);
-                       df[2] = new DecimalFormat("0.00", dfs);
-                       df[3] = new DecimalFormat("0.000", dfs);
-                       df[4] = new DecimalFormat("0.0000", dfs);
-                       df[5] = new DecimalFormat("0.00000", dfs);
-                       df[6] = new DecimalFormat("0.000000", dfs);
-                       df[7] = new DecimalFormat("0.0000000", dfs);
-                       df[8] = new DecimalFormat("0.00000000", dfs);
-                       df[9] = new DecimalFormat("0.000000000", dfs);
-               }
-               if (decimalPlaces<0) {
-                       decimalPlaces = -decimalPlaces;
-                       if (decimalPlaces>9) decimalPlaces=9;
-                       if (sf==null) {
-                               sf = new DecimalFormat[10];
-                               sf[1] = new DecimalFormat("0.0E0",dfs);
-                               sf[2] = new DecimalFormat("0.00E0",dfs);
-                               sf[3] = new DecimalFormat("0.000E0",dfs);
-                               sf[4] = new DecimalFormat("0.0000E0",dfs);
-                               sf[5] = new DecimalFormat("0.00000E0",dfs);
-                               sf[6] = new DecimalFormat("0.000000E0",dfs);
-                               sf[7] = new DecimalFormat("0.0000000E0",dfs);
-                               sf[8] = new DecimalFormat("0.00000000E0",dfs);
-                               sf[9] = new DecimalFormat("0.000000000E0",dfs);
-                       }
-                       if (Double.isInfinite(n))
-                               return ""+n;
-                       else
-                               return sf[decimalPlaces].format(n); // use scientific notation
-               }
-               if (decimalPlaces<0) decimalPlaces = 0;
-               if (decimalPlaces>9) decimalPlaces = 9;
-               return df[decimalPlaces].format(n);
-       }
-
-       /** Adds the specified class to a Vector to keep it from being garbage
-       collected, which would cause the classes static fields to be reset. 
-       Probably not needed with Java 1.2 or later. */
-       public static void register(Class c) {
-               if (ij!=null) ij.register(c);
-       }
-       
-       /** Returns true if the space bar is down. */
-       public static boolean spaceBarDown() {
-               return spaceDown;
-       }
-
-       /** Returns true if the control key is down. */
-       public static boolean controlKeyDown() {
-               return controlDown;
-       }
-
-       /** Returns true if the alt key is down. */
-       public static boolean altKeyDown() {
-               return altDown;
-       }
-
-       /** Returns true if the shift key is down. */
-       public static boolean shiftKeyDown() {
-               return shiftDown;
-       }
-       
-       public static void setKeyDown(int key) {
-               if (debugMode) IJ.log("setKeyDown: "+key);
-               switch (key) {
-                       case KeyEvent.VK_CONTROL:
-                               controlDown=true;
-                               break;
-                       case KeyEvent.VK_META:
-                               if (isMacintosh()) controlDown=true;
-                               break;
-                       case KeyEvent.VK_ALT:
-                               altDown=true;
-                               break;
-                       case KeyEvent.VK_SHIFT:
-                               shiftDown=true;
-                               if (debugMode) beep();
-                               break;
-                       case KeyEvent.VK_SPACE: {
-                               spaceDown=true;
-                               ImageWindow win = WindowManager.getCurrentWindow();
-                               if (win!=null) win.getCanvas().setCursor(-1,-1,-1, -1);
-                               break;
-                       }
-                       case KeyEvent.VK_ESCAPE: {
-                               escapePressed = true;
-                               break;
-                       }
-               }
-       }
-
-       public static void setKeyUp(int key) {
-               if (debugMode) IJ.log("setKeyUp: "+key);
-               switch (key) {
-                       case KeyEvent.VK_CONTROL: controlDown=false; break;
-                       case KeyEvent.VK_META: if (isMacintosh()) controlDown=false; break;
-                       case KeyEvent.VK_ALT: altDown=false; break;
-                       case KeyEvent.VK_SHIFT: shiftDown=false; if (debugMode) beep(); break;
-                       case KeyEvent.VK_SPACE:
-                               spaceDown=false;
-                               ImageWindow win = WindowManager.getCurrentWindow();
-                               if (win!=null) win.getCanvas().setCursor(-1,-1,-1,-1);
-                               break;
-                       case ALL_KEYS:
-                               shiftDown=controlDown=altDown=spaceDown=false;
-                               break;
-               }
-       }
-       
-       public static void setInputEvent(InputEvent e) {
-               altDown = e.isAltDown();
-               shiftDown = e.isShiftDown();
-       }
-
-       /** Returns true if this machine is a Macintosh. */
-       public static boolean isMacintosh() {
-               return isMac;
-       }
-       
-       /** Returns true if this machine is a Macintosh running OS X. */
-       public static boolean isMacOSX() {
-               return isMacintosh();
-       }
-
-       /** Returns true if this machine is running Windows. */
-       public static boolean isWindows() {
-               return isWin;
-       }
-       
-       /** Always returns true. */
-       public static boolean isJava2() {
-               return isJava2;
-       }
-       
-       /** Returns true if ImageJ is running on a Java 1.4 or greater JVM. */
-       public static boolean isJava14() {
-               return isJava14;
-       }
-
-       /** Returns true if ImageJ is running on a Java 1.5 or greater JVM. */
-       public static boolean isJava15() {
-               return isJava15;
-       }
-
-       /** Returns true if ImageJ is running on a Java 1.6 or greater JVM. */
-       public static boolean isJava16() {
-               return isJava16;
-       }
-
-       /** Returns true if ImageJ is running on a Java 1.7 or greater JVM. */
-       public static boolean isJava17() {
-               return isJava17;
-       }
-
-       /** Returns true if ImageJ is running on Linux. */
-       public static boolean isLinux() {
-               return isLinux;
-       }
-
-       /** Returns true if ImageJ is running on Windows Vista. */
-       public static boolean isVista() {
-               return isVista;
-       }
-       
-       /** Returns true if ImageJ is running a 64-bit version of Java. */
-       public static boolean is64Bit() {
-               if (osarch==null)
-                       osarch = System.getProperty("os.arch");
-               return osarch!=null && osarch.indexOf("64")!=-1;
-       }
-
-       /** Displays an error message and returns false if the
-               ImageJ version is less than the one specified. */
-       public static boolean versionLessThan(String version) {
-               boolean lessThan = ImageJ.VERSION.compareTo(version)<0;
-               if (lessThan)
-                       error("This plugin or macro requires ImageJ "+version+" or later. Use\nHelp>Update ImageJ to upgrade to the latest version.");
-               return lessThan;
-       }
-       
-       /** Displays a "Process all images?" dialog. Returns
-               'flags'+PlugInFilter.DOES_STACKS if the user selects "Yes",
-               'flags' if the user selects "No" and PlugInFilter.DONE
-               if the user selects "Cancel".
-       */
-       public static int setupDialog(ImagePlus imp, int flags) {
-               if (imp==null || (ij!=null&&ij.hotkey))
-                       return flags;
-               int stackSize = imp.getStackSize();
-               if (stackSize>1) {
-                       if (imp.isComposite() && ((CompositeImage)imp).getMode()==CompositeImage.COMPOSITE)
-                               return flags+PlugInFilter.DOES_STACKS;
-                       String macroOptions = Macro.getOptions();
-                       if (macroOptions!=null) {
-                               if (macroOptions.indexOf("stack ")>=0)
-                                       return flags+PlugInFilter.DOES_STACKS;
-                               else
-                                       return flags;
-                       }
-                       if (hideProcessStackDialog)
-                               return flags;
-                       String note = ((flags&PlugInFilter.NO_CHANGES)==0)?" There is\nno Undo if you select \"Yes\".":"";
-                       YesNoCancelDialog d = new YesNoCancelDialog(getInstance(),
-                               "Process Stack?", "Process all "+stackSize+" images?"+note);
-                       if (d.cancelPressed())
-                               return PlugInFilter.DONE;
-                       else if (d.yesPressed()) {
-                       if (imp.getStack().isVirtual()) {
-                               int size = (stackSize*imp.getWidth()*imp.getHeight()*imp.getBytesPerPixel()+524288)/1048576;
-                               String msg =
-                                               "Custom code is required to process this virtual stack\n"+
-                                               "(e.g., \"Process Virtual Stack\" macro) or it must be\n"+
-                                               "converted to a normal stack using Image>Duplicate,\n"+
-                                               "which will require "+size+"MB of additional memory.";
-                               error(msg);
-                                       return PlugInFilter.DONE;
-                       }
-                               if (Recorder.record)
-                                       Recorder.recordOption("stack");
-                               return flags+PlugInFilter.DOES_STACKS;
-                       }
-                       if (Recorder.record)
-                               Recorder.recordOption("slice");
-               }
-               return flags;
-       }
-               
-       /** Creates a rectangular selection. Removes any existing 
-               selection if width or height are less than 1. */
-       public static void makeRectangle(int x, int y, int width, int height) {
-               if (width<=0 || height<0)
-                       getImage().killRoi();
-               else {
-                       ImagePlus img = getImage();
-                       if (Interpreter.isBatchMode())
-                               img.setRoi(new Roi(x,y,width,height), false);
-                       else
-                               img.setRoi(x, y, width, height);
-               }
-       }
-       
-       /** Creates an elliptical selection. Removes any existing 
-               selection if width or height are less than 1. */
-       public static void makeOval(int x, int y, int width, int height) {
-               if (width<=0 || height<0)
-                       getImage().killRoi();
-               else {
-                       ImagePlus img = getImage();
-                       img.setRoi(new OvalRoi(x, y, width, height));
-               }
-       }
-       
-       /** Creates a straight line selection. */
-       public static void makeLine(int x1, int y1, int x2, int y2) {
-               getImage().setRoi(new Line(x1, y1, x2, y2));
-       }
-       
-       /** Creates a point selection. */
-       public static void makePoint(int x, int y) {
-               ImagePlus img = getImage();
-               Roi roi = img.getRoi();
-               if (shiftKeyDown() && roi!=null && roi.getType()==Roi.POINT) {
-                       Polygon p = roi.getPolygon();
-                       p.addPoint(x, y);
-                       img.setRoi(new PointRoi(p.xpoints, p.ypoints, p.npoints));
-               } else
-                       img.setRoi(new PointRoi(x, y));
-       }
-
-       /** Creates a straight line selection using double coordinates. */
-       public static void makeLine(double x1, double y1, double x2, double y2) {
-               getImage().setRoi(new Line(x1, y1, x2, y2));
-       }
-
-       /** Sets the minimum and maximum displayed pixel values. */
-       public static void setMinAndMax(double min, double max) {
-               setMinAndMax(min, max, 7);
-       }
-
-       /** Sets the minimum and maximum displayed pixel values on the specified RGB
-       channels, where 4=red, 2=green and 1=blue. */
-       public static void setMinAndMax(double min, double max, int channels) {
-               ImagePlus img = getImage();
-               Calibration cal = img.getCalibration();
-               min = cal.getRawValue(min); 
-               max = cal.getRawValue(max);
-               if (channels==7)
-                       img.setDisplayRange(min, max);
-               else
-                       img.setDisplayRange(min, max, channels);
-               img.updateAndDraw();
-       }
-
-       /** Resets the minimum and maximum displayed pixel values
-               to be the same as the min and max pixel values. */
-       public static void resetMinAndMax() {
-               ImagePlus img = getImage();
-               img.resetDisplayRange();
-               img.updateAndDraw();
-       }
-
-       /** Sets the lower and upper threshold levels and displays the image 
-               using red to highlight thresholded pixels. May not work correctly on
-               16 and 32 bit images unless the display range has been reset using IJ.resetMinAndMax().
-       */
-       public static void setThreshold(double lowerThreshold, double upperThresold) {
-               setThreshold(lowerThreshold, upperThresold, null);
-       }
-       
-       /** Sets the lower and upper threshold levels and displays the image using
-               the specified <code>displayMode</code> ("Red", "Black & White", "Over/Under" or "No Update"). */
-       public static void setThreshold(double lowerThreshold, double upperThreshold, String displayMode) {
-               setThreshold(getImage(), lowerThreshold, upperThreshold, displayMode);
-       }
-
-       /** Sets the lower and upper threshold levels of the specified image. */
-       public static void setThreshold(ImagePlus img, double lowerThreshold, double upperThreshold) {
-               setThreshold(img, lowerThreshold, upperThreshold, "Red");
-       }
-
-       /** Sets the lower and upper threshold levels of the specified image and updates the display using
-               the specified <code>displayMode</code> ("Red", "Black & White", "Over/Under" or "No Update"). */
-       public static void setThreshold(ImagePlus img, double lowerThreshold, double upperThreshold, String displayMode) {
-               int mode = ImageProcessor.RED_LUT;
-               if (displayMode!=null) {
-                       displayMode = displayMode.toLowerCase(Locale.US);
-                       if (displayMode.indexOf("black")!=-1)
-                               mode = ImageProcessor.BLACK_AND_WHITE_LUT;
-                       else if (displayMode.indexOf("over")!=-1)
-                               mode = ImageProcessor.OVER_UNDER_LUT;
-                       else if (displayMode.indexOf("no")!=-1)
-                               mode = ImageProcessor.NO_LUT_UPDATE;
-               }
-               Calibration cal = img.getCalibration();
-               lowerThreshold = cal.getRawValue(lowerThreshold); 
-               upperThreshold = cal.getRawValue(upperThreshold); 
-               img.getProcessor().setThreshold(lowerThreshold, upperThreshold, mode);
-               if (mode != ImageProcessor.NO_LUT_UPDATE) {
-                       img.getProcessor().setLutAnimation(true);
-                       img.updateAndDraw();
-               }
-       }
-
-       public static void setAutoThreshold(ImagePlus img, String method) {
-               ImageProcessor ip = img.getProcessor();
-               if (ip instanceof ColorProcessor)
-                       throw new IllegalArgumentException("Non-RGB image required");
-               ip.setRoi(img.getRoi());
-               if (method!=null) {
-                       try {ip.setAutoThreshold(method);}
-                       catch (Exception e) {IJ.log(e.getMessage());}
-               } else
-                       ip.setAutoThreshold(ImageProcessor.ISODATA2, ImageProcessor.RED_LUT);
-               img.updateAndDraw();
-       }
-
-       /** Disables thresholding on the current image. */
-       public static void resetThreshold() {
-               resetThreshold(getImage());
-       }
-       
-       /** Disables thresholding on the specified image. */
-       public static void resetThreshold(ImagePlus img) {
-               ImageProcessor ip = img.getProcessor();
-               ip.resetThreshold();
-               ip.setLutAnimation(true);
-               img.updateAndDraw();
-       }
-       
-       /** For IDs less than zero, activates the image with the specified ID.
-               For IDs greater than zero, activates the Nth image. */
-       public static void selectWindow(int id) {
-               if (id>0)
-                       id = WindowManager.getNthImageID(id);
-               ImagePlus imp = WindowManager.getImage(id);
-               if (imp==null)
-                       error("Macro Error", "Image "+id+" not found or no images are open.");
-               if (Interpreter.isBatchMode()) {
-                       ImagePlus imp2 = WindowManager.getCurrentImage();
-                       if (imp2!=null && imp2!=imp) imp2.saveRoi();
-            WindowManager.setTempCurrentImage(imp);
-            WindowManager.setWindow(null);
-               } else {
-                       ImageWindow win = imp.getWindow();
-                       win.toFront();
-                       WindowManager.setWindow(win);
-                       long start = System.currentTimeMillis();
-                       // timeout after 2 seconds unless current thread is event dispatch thread
-                       String thread = Thread.currentThread().getName();
-                       int timeout = thread!=null&&thread.indexOf("EventQueue")!=-1?0:2000;
-                       while (true) {
-                               wait(10);
-                               imp = WindowManager.getCurrentImage();
-                               if (imp!=null && imp.getID()==id)
-                                       return; // specified image is now active
-                               if ((System.currentTimeMillis()-start)>timeout) {
-                                       WindowManager.setCurrentWindow(win);
-                                       return;
-                               }
-                       }
-               }
-       }
-
-       /** Activates the window with the specified title. */
-       public static void selectWindow(String title) {
-               if (title.equals("ImageJ")&&ij!=null)
-                       {ij.toFront(); return;}
-               long start = System.currentTimeMillis();
-               while (System.currentTimeMillis()-start<3000) { // 3 sec timeout
-                       Frame frame = WindowManager.getFrame(title);
-                       if (frame!=null && !(frame instanceof ImageWindow)) {
-                               selectWindow(frame);
-                               return;
-                       }
-                       int[] wList = WindowManager.getIDList();
-                       int len = wList!=null?wList.length:0;
-                       for (int i=0; i<len; i++) {
-                               ImagePlus imp = WindowManager.getImage(wList[i]);
-                               if (imp!=null) {
-                                       if (imp.getTitle().equals(title)) {
-                                               selectWindow(imp.getID());
-                                               return;
-                                       }
-                               }
-                       }
-                       wait(10);
-               }
-               error("Macro Error", "No window with the title \""+title+"\" found.");
-       }
-       
-       static void selectWindow(Frame frame) {
-               frame.toFront();
-               long start = System.currentTimeMillis();
-               while (true) {
-                       wait(10);
-                       if (WindowManager.getFrontWindow()==frame)
-                               return; // specified window is now in front
-                       if ((System.currentTimeMillis()-start)>1000) {
-                               WindowManager.setWindow(frame);
-                               return;   // 1 second timeout
-                       }
-               }
-       }
-       
-       /** Sets the foreground color. */
-       public static void setForegroundColor(int red, int green, int blue) {
-               setColor(red, green, blue, true);
-       }
-
-       /** Sets the background color. */
-       public static void setBackgroundColor(int red, int green, int blue) {
-               setColor(red, green, blue, false);
-       }
-       
-       static void setColor(int red, int green, int blue, boolean foreground) {
-           if (red<0) red=0; if (green<0) green=0; if (blue<0) blue=0; 
-           if (red>255) red=255; if (green>255) green=255; if (blue>255) blue=255;  
-               Color c = new Color(red, green, blue);
-               if (foreground) {
-                       Toolbar.setForegroundColor(c);
-                       ImagePlus img = WindowManager.getCurrentImage();
-                       if (img!=null)
-                               img.getProcessor().setColor(c);
-               } else
-                       Toolbar.setBackgroundColor(c);
-       }
-
-       /** Switches to the specified tool, where id = Toolbar.RECTANGLE (0),
-               Toolbar.OVAL (1), etc. */
-       public static void setTool(int id) {
-               Toolbar.getInstance().setTool(id);
-       }
-
-       /** Switches to the specified tool, where 'name' is "rect", "elliptical", 
-               "brush", etc. Returns 'false' if the name is not recognized. */
-       public static boolean setTool(String name) {
-               return Toolbar.getInstance().setTool(name);
-       }
-
-       /** Returns the name of the current tool. */
-       public static String getToolName() {
-               return Toolbar.getToolName();
-       }
-
-       /** Equivalent to clicking on the current image at (x,y) with the
-               wand tool. Returns the number of points in the resulting ROI. */
-       public static int doWand(int x, int y) {
-               return doWand(x, y, 0, null);
-       }
-
-       /** Traces the boundary of the area with pixel values within
-       * 'tolerance' of the value of the pixel at the starting location.
-       * 'tolerance' is in uncalibrated units.
-       * 'mode' can be "4-connected", "8-connected" or "Legacy".
-       * "Legacy" is for compatibility with previous versions of ImageJ;
-       * it is ignored if 'tolerance' > 0.
-       */
-       public static int doWand(int x, int y, double tolerance, String mode) {
-               ImagePlus img = getImage();
-               ImageProcessor ip = img.getProcessor();
-               if ((img.getType()==ImagePlus.GRAY32) && Double.isNaN(ip.getPixelValue(x,y)))
-                       return 0;
-               int imode = Wand.LEGACY_MODE;
-               if (mode!=null) {
-                       if (mode.startsWith("4"))
-                               imode = Wand.FOUR_CONNECTED;
-                       else if (mode.startsWith("8"))
-                               imode = Wand.EIGHT_CONNECTED;
-               }
-               Wand w = new Wand(ip);
-               double t1 = ip.getMinThreshold();
-               if (t1==ImageProcessor.NO_THRESHOLD || (ip.getLutUpdateMode()==ImageProcessor.NO_LUT_UPDATE&& tolerance>0.0))
-                       w.autoOutline(x, y, tolerance, imode);
-               else
-                       w.autoOutline(x, y, t1, ip.getMaxThreshold(), imode);
-               if (w.npoints>0) {
-                       Roi previousRoi = img.getRoi();
-                       int type = Wand.allPoints()?Roi.FREEROI:Roi.TRACED_ROI;
-                       Roi roi = new PolygonRoi(w.xpoints, w.ypoints, w.npoints, type);
-                       img.killRoi();
-                       img.setRoi(roi);
-                       // add/subtract this ROI to the previous one if the shift/alt key is down
-                       if (previousRoi!=null)
-                               roi.update(shiftKeyDown(), altKeyDown());
-               }
-               return w.npoints;
-       }
-       
-       /** Sets the transfer mode used by the <i>Edit/Paste</i> command, where mode is "Copy", "Blend", "Average", "Difference", 
-               "Transparent", "Transparent2", "AND", "OR", "XOR", "Add", "Subtract", "Multiply", or "Divide". */
-       public static void setPasteMode(String mode) {
-               mode = mode.toLowerCase(Locale.US);
-               int m = Blitter.COPY;
-               if (mode.startsWith("ble") || mode.startsWith("ave"))
-                       m = Blitter.AVERAGE;
-               else if (mode.startsWith("diff"))
-                       m = Blitter.DIFFERENCE;
-               else if (mode.indexOf("zero")!=-1)
-                       m = Blitter.COPY_ZERO_TRANSPARENT;
-               else if (mode.startsWith("tran"))
-                       m = Blitter.COPY_TRANSPARENT;
-               else if (mode.startsWith("and"))
-                       m = Blitter.AND;
-               else if (mode.startsWith("or"))
-                       m = Blitter.OR;
-               else if (mode.startsWith("xor"))
-                       m = Blitter.XOR;
-               else if (mode.startsWith("sub"))
-                       m = Blitter.SUBTRACT;
-               else if (mode.startsWith("add"))
-                       m = Blitter.ADD;
-               else if (mode.startsWith("div"))
-                       m = Blitter.DIVIDE;
-               else if (mode.startsWith("mul"))
-                       m = Blitter.MULTIPLY;
-               else if (mode.startsWith("min"))
-                       m = Blitter.MIN;
-               else if (mode.startsWith("max"))
-                       m = Blitter.MAX;
-               Roi.setPasteMode(m);
-       }
-
-       /** Returns a reference to the active image. Displays an error
-               message and aborts the macro if no images are open. */
-       public static ImagePlus getImage() {  //ts
-               ImagePlus img = WindowManager.getCurrentImage();
-               if (img==null) {
-                       IJ.noImage();
-                       if (ij==null)
-                               System.exit(0);
-                       else
-                               abort();
-               }
-               return img;
-       }
-       
-       /** Switches to the specified stack slice, where 1<='slice'<=stack-size. */
-       public static void setSlice(int slice) {
-               getImage().setSlice(slice);
-       }
-
-       /** Returns the ImageJ version number as a string. */
-       public static String getVersion() {
-               return ImageJ.VERSION;
-       }
-       
-       /** Returns the path to the home ("user.home"), startup, ImageJ, plugins, macros, 
-               luts, temp, current or image directory if <code>title</code> is "home", "startup", 
-               "imagej", "plugins", "macros", "luts", "temp", "current" or "image", otherwise, 
-               displays a dialog and returns the path to the directory selected by the user. 
-               Returns null if the specified directory is not found or the user
-               cancels the dialog box. Also aborts the macro if the user cancels
-               the dialog box.*/
-       public static String getDirectory(String title) {
-               if (title.equals("plugins"))
-                       return Menus.getPlugInsPath();
-               else if (title.equals("macros"))
-                       return Menus.getMacrosPath();
-               else if (title.equals("luts")) {
-                       String ijdir = getIJDir();
-                       if (ijdir!=null)
-                               return ijdir + "luts" + File.separator;
-                       else
-                               return null;
-               } else if (title.equals("home"))
-                       return System.getProperty("user.home") + File.separator;
-               else if (title.equals("startup"))
-                       return Prefs.getHomeDir() + File.separator;
-               else if (title.equals("imagej"))
-                       return getIJDir();
-               else if (title.equals("current"))
-                       return OpenDialog.getDefaultDirectory();
-               else if (title.equals("temp")) {
-                       String dir = System.getProperty("java.io.tmpdir");
-                       if (isMacintosh()) dir = "/tmp/";
-                       if (dir!=null && !dir.endsWith(File.separator)) dir += File.separator;
-                       return dir;
-               } else if (title.equals("image")) {
-                       ImagePlus imp = WindowManager.getCurrentImage();
-               FileInfo fi = imp!=null?imp.getOriginalFileInfo():null;
-                       if (fi!=null && fi.directory!=null)
-                               return fi.directory;
-                       else
-                               return null;
-               } else {
-                       DirectoryChooser dc = new DirectoryChooser(title);
-                       String dir = dc.getDirectory();
-                       if (dir==null) Macro.abort();
-                       return dir;
-               }
-       }
-       
-       private static String getIJDir() {
-               String path = Menus.getPlugInsPath();
-               if (path==null) return null;
-               String ijdir = (new File(path)).getParent();
-               if (ijdir!=null) ijdir += File.separator;
-               return ijdir;
-       }
-       
-       /** Displays a file open dialog box and then opens the tiff, dicom, 
-               fits, pgm, jpeg, bmp, gif, lut, roi, or text file selected by 
-               the user. Displays an error message if the selected file is not
-               in one of the supported formats, or if it is not found. */
-       public static void open() {
-               open(null);
-       }
-
-       /** Opens and displays a tiff, dicom, fits, pgm, jpeg, bmp, gif, lut, 
-               roi, or text file. Displays an error message if the specified file
-               is not in one of the supported formats, or if it is not found.
-               With 1.41k or later, opens images specified by a URL.
-               */
-       public static void open(String path) {
-               if (ij==null && Menus.getCommands()==null) init();
-               Opener o = new Opener();
-               macroRunning = true;
-               if (path==null || path.equals(""))              
-                       o.open();
-               else
-                       o.open(path);
-               macroRunning = false;
-       }
-               
-       /** Opens and displays the nth image in the specified tiff stack. */
-       public static void open(String path, int n) {
-               if (ij==null && Menus.getCommands()==null) init();
-               ImagePlus imp = openImage(path, n);
-               if (imp!=null) imp.show();
-       }
-
-       /** Opens the specified file as a tiff, bmp, dicom, fits, pgm, gif 
-               or jpeg image and returns an ImagePlus object if successful.
-               Calls HandleExtraFileTypes plugin if the file type is not recognised.
-               Displays a file open dialog if 'path' is null or an empty string.
-               Note that 'path' can also be a URL. Some reader plugins, including
-               the Bio-Formats plugin, display the image and return null. */
-       public static ImagePlus openImage(String path) {
-               return (new Opener()).openImage(path);
-       }
-
-       /** Opens the nth image of the specified tiff stack. */
-       public static ImagePlus openImage(String path, int n) {
-               return (new Opener()).openImage(path, n);
-       }
-
-       /** Opens an image using a file open dialog and returns it as an ImagePlus object. */
-       public static ImagePlus openImage() {
-               return openImage(null);
-       }
-
-       /** Opens a URL and returns the contents as a string.
-               Returns "<Error: message>" if there an error, including
-               host or file not found. */
-       public static String openUrlAsString(String url) {
-               StringBuffer sb = null;
-               url = url.replaceAll(" ", "%20");
-               try {
-                       URL u = new URL(url);
-                       URLConnection uc = u.openConnection();
-                       long len = uc.getContentLength();
-                       if (len>1048576L)
-                               return "<Error: file is larger than 1MB>";
-                       InputStream in = u.openStream();
-                       BufferedReader br = new BufferedReader(new InputStreamReader(in));
-                       sb = new StringBuffer() ;
-                       String line;
-                       while ((line=br.readLine()) != null)
-                               sb.append (line + "\n");
-                       in.close ();
-               } catch (Exception e) {
-                       return("<Error: "+e+">");
-               }
-               if (sb!=null)
-                       return new String(sb);
-               else
-                       return "";
-       }
-
-       /** Saves the current image, lookup table, selection or text window to the specified file path. 
-               The path must end in ".tif", ".jpg", ".gif", ".zip", ".raw", ".avi", ".bmp", ".fits", ".pgm", ".png", ".lut", ".roi" or ".txt".  */
-       public static void save(String path) {
-               save(null, path);
-       }
-
-       /** Saves the specified image, lookup table or selection to the specified file path. 
-               The path must end in ".tif", ".jpg", ".gif", ".zip", ".raw", ".avi", ".bmp", ".fits", ".pgm", ".png", ".lut", ".roi" or ".txt".  */
-       public static void save(ImagePlus imp, String path) {
-               int dotLoc = path.lastIndexOf('.');
-               if (dotLoc!=-1) {
-                       ImagePlus imp2 = imp;
-                       if (imp2==null) imp2 = WindowManager.getCurrentImage();
-                       String title = imp2!=null?imp2.getTitle():null;
-                       saveAs(imp, path.substring(dotLoc+1), path);
-                       if (title!=null) imp2.setTitle(title);
-               } else
-                       error("The save() macro function requires a file name extension.\n \n"+path);
-       }
-
-       /* Saves the active image, lookup table, selection, measurement results, selection XY 
-               coordinates or text window to the specified file path. The format argument must be "tiff", 
-               "jpeg", "gif", "zip", "raw", "avi", "bmp", "fits", "pgm", "png", "text image", "lut", "selection", "measurements", 
-               "xy Coordinates" or "text".  If <code>path</code> is null or an emply string, a file
-               save dialog is displayed. */
-       public static void saveAs(String format, String path) {
-               saveAs(null, format, path);
-       }
-
-       /* Saves the specified image. The format argument must be "tiff",  
-               "jpeg", "gif", "zip", "raw", "avi", "bmp", "fits", "pgm", "png", 
-               "text image", "lut", "selection" or "xy Coordinates". */
-       public static void saveAs(ImagePlus imp, String format, String path) {
-               if (format==null) return;
-               if (path!=null && path.length()==0) path = null;
-               format = format.toLowerCase(Locale.US);
-               if (format.indexOf("tif")!=-1) {
-                       path = updateExtension(path, ".tif");
-                       format = "Tiff...";
-               } else if (format.indexOf("jpeg")!=-1  || format.indexOf("jpg")!=-1) {
-                       path = updateExtension(path, ".jpg");
-                       format = "Jpeg...";
-               } else if (format.indexOf("gif")!=-1) {
-                       path = updateExtension(path, ".gif");
-                       format = "Gif...";
-               } else if (format.indexOf("text image")!=-1) {
-                       path = updateExtension(path, ".txt");
-                       format = "Text Image...";
-               } else if (format.indexOf("text")!=-1 || format.indexOf("txt")!=-1) {
-                       if (path!=null && !path.endsWith(".xls"))
-                               path = updateExtension(path, ".txt");
-                       format = "Text...";
-               } else if (format.indexOf("zip")!=-1) {
-                       path = updateExtension(path, ".zip");
-                       format = "ZIP...";
-               } else if (format.indexOf("raw")!=-1) {
-                       path = updateExtension(path, ".raw");
-                       format = "Raw Data...";
-               } else if (format.indexOf("avi")!=-1) {
-                       path = updateExtension(path, ".avi");
-                       format = "AVI... ";
-               } else if (format.indexOf("bmp")!=-1) {
-                       path = updateExtension(path, ".bmp");
-                       format = "BMP...";
-               } else if (format.indexOf("fits")!=-1) {
-                       path = updateExtension(path, ".fits");
-                       format = "FITS...";
-               } else if (format.indexOf("png")!=-1) {
-                       path = updateExtension(path, ".png");
-                       format = "PNG...";
-               } else if (format.indexOf("pgm")!=-1) {
-                       path = updateExtension(path, ".pgm");
-                       format = "PGM...";
-               } else if (format.indexOf("lut")!=-1) {
-                       path = updateExtension(path, ".lut");
-                       format = "LUT...";
-               } else if (format.indexOf("results")!=-1 || format.indexOf("measurements")!=-1) {
-                       format = "Results...";
-               } else if (format.indexOf("selection")!=-1 || format.indexOf("roi")!=-1) {
-                       path = updateExtension(path, ".roi");
-                       format = "Selection...";
-               } else if (format.indexOf("xy")!=-1 || format.indexOf("coordinates")!=-1) {
-                       path = updateExtension(path, ".txt");
-                       format = "XY Coordinates...";
-               } else
-                       error("Unrecognized format: "+format);
-               if (path==null)
-                       run(format);
-               else
-                       run(imp, format, "save=["+path+"]");
-       }
-
-       static String updateExtension(String path, String extension) {
-               if (path==null) return null;
-               int dotIndex = path.lastIndexOf(".");
-               int separatorIndex = path.lastIndexOf(File.separator);
-               if (dotIndex>=0 && dotIndex>separatorIndex && (path.length()-dotIndex)<=5) {
-                       if (dotIndex+1<path.length() && Character.isDigit(path.charAt(dotIndex+1)))
-                               path += extension;
-                       else
-                               path = path.substring(0, dotIndex) + extension;
-               } else
-                       path += extension;
-               return path;
-       }
-       
-       /** Saves a string as a file. Displays a file save dialog if
-               'path' is null or blank. Returns an error message 
-               if there is an exception, otherwise returns null. */
-       public static String saveString(String string, String path) {
-               return write(string, path, false);
-       }
-
-       /** Appends a string to the end of a file. A newline character ("\n") 
-               is added to the end of the string before it is written. Returns an  
-               error message if there is an exception, otherwise returns null. */
-       public static String append(String string, String path) {
-               return write(string+"\n", path, true);
-       }
-
-       private static String write(String string, String path, boolean append) {
-               if (path==null || path.equals("")) {
-                       String msg = append?"Append String...":"Save String...";
-                       SaveDialog sd = new SaveDialog(msg, "Untitled", ".txt");
-                       String name = sd.getFileName();
-                       if (name==null) return null;
-                       path = sd.getDirectory() + name;
-               }
-               try {
-                       BufferedWriter out = new BufferedWriter(new FileWriter(path, append));
-                       out.write(string);
-                       out.close();
-               } catch (IOException e) {
-                       return ""+e;
-               }
-               return null;
-       }
-
-       /** Opens a text file as a string. Displays a file open dialog
-               if path is null or blank. Returns null if the user cancels
-               the file open dialog. If there is an error, returns a 
-                message in the form "Error: message". */
-       public static String openAsString(String path) {
-               if (path==null || path.equals("")) {
-                       OpenDialog od = new OpenDialog("Open Text File", "");
-                       String directory = od.getDirectory();
-                       String name = od.getFileName();
-                       if (name==null) return null;
-                       path = directory + name;
-               }
-               String str = "";
-               File file = new File(path);
-               if (!file.exists())
-                       return "Error: file not found";
-               try {
-                       StringBuffer sb = new StringBuffer(5000);
-                       BufferedReader r = new BufferedReader(new FileReader(file));
-                       while (true) {
-                               String s=r.readLine();
-                               if (s==null)
-                                       break;
-                               else
-                                       sb.append(s+"\n");
-                       }
-                       r.close();
-                       str = new String(sb);
-               }
-               catch (Exception e) {
-                       str = "Error: "+e.getMessage();
-               }
-               return str;
-       }
-
-        /** Creates a new imagePlus. <code>Type</code> should contain "8-bit", "16-bit", "32-bit" or "RGB". 
-                In addition, it can contain "white", "black" or "ramp" (the default is "white"). <code>Width</code> 
-               and <code>height</code> specify the width and height of the image in pixels.  
-               <code>Depth</code> specifies the number of stack slices. */
-        public static ImagePlus createImage(String title, String type, int width, int height, int depth) {
-               type = type.toLowerCase(Locale.US);
-               int bitDepth = 8;
-               if (type.indexOf("16")!=-1) bitDepth = 16;
-               if (type.indexOf("24")!=-1||type.indexOf("rgb")!=-1) bitDepth = 24;
-               if (type.indexOf("32")!=-1) bitDepth = 32;
-               int options = NewImage.FILL_WHITE;
-               if (bitDepth==16 || bitDepth==32)
-                       options = NewImage.FILL_BLACK;
-               if (type.indexOf("white")!=-1)
-                       options = NewImage.FILL_WHITE;
-               else if (type.indexOf("black")!=-1)
-                       options = NewImage.FILL_BLACK;
-               else if (type.indexOf("ramp")!=-1)
-                       options = NewImage.FILL_RAMP;
-               options += NewImage.CHECK_AVAILABLE_MEMORY;
-               return NewImage.createImage(title, width, height, depth, bitDepth, options);
-       }
-
-        /** Opens a new image. <code>Type</code> should contain "8-bit", "16-bit", "32-bit" or "RGB". 
-               In addition, it can contain "white", "black" or "ramp" (the default is "white"). <code>Width</code> 
-               and <code>height</code> specify the width and height of the image in pixels.  
-               <code>Depth</code> specifies the number of stack slices. */
-       public static void newImage(String title, String type, int width, int height, int depth) {
-               ImagePlus imp = createImage(title, type, width, height, depth);
-               if (imp!=null) {
-                       macroRunning = true;
-                       imp.show();
-                       macroRunning = false;
-               }
-       }
-
-       /** Returns true if the <code>Esc</code> key was pressed since the
-               last ImageJ command started to execute or since resetEscape() was called. */
-       public static boolean escapePressed() {
-               return escapePressed;
-       }
-
-       /** This method sets the <code>Esc</code> key to the "up" position.
-               The Executer class calls this method when it runs 
-               an ImageJ command in a separate thread. */
-       public static void resetEscape() {
-               escapePressed = false;
-       }
-       
-       /** Causes IJ.error() output to be temporarily redirected to the "Log" window. */
-       public static void redirectErrorMessages() {
-               redirectErrorMessages = true;
-       }
-       
-       /** Set 'true' and IJ.error() output will be redirected to the "Log" window. */
-       public static void redirectErrorMessages(boolean redirect) {
-               redirectErrorMessages2 = redirect;
-       }
-
-       /** Returns the state of the  'redirectErrorMessages' flag. The File/Import/Image Sequence command sets this flag.*/
-       public static boolean redirectingErrorMessages() {
-               return redirectErrorMessages || redirectErrorMessages2;
-       }
-
-       /** Temporarily suppress "plugin not found" errors. */
-       public static void suppressPluginNotFoundError() {
-               suppressPluginNotFoundError = true;
-       }
-
-       /** Returns the class loader ImageJ uses to run plugins or the
-               system class loader if Menus.getPlugInsPath() returns null. */
-       public static ClassLoader getClassLoader() {
-               if (classLoader==null) {
-                       String pluginsDir = Menus.getPlugInsPath();
-                       if (pluginsDir==null) {
-                               String home = System.getProperty("plugins.dir");
-                               if (home!=null) {
-                                       if (!home.endsWith(Prefs.separator)) home+=Prefs.separator;
-                                       pluginsDir = home+"plugins"+Prefs.separator;
-                                       if (!(new File(pluginsDir)).isDirectory()) pluginsDir = home;
-                               }
-                       }
-                       if (pluginsDir==null)
-                               return IJ.class.getClassLoader();
-                       else {
-                               if (Menus.jnlp)
-                                       classLoader = new PluginClassLoader(pluginsDir, true);
-                               else
-                                       classLoader = new PluginClassLoader(pluginsDir);
-                       }
-               }
-               return classLoader;
-       }
-       
-       /** Returns the size, in pixels, of the primary display. */
-       public static Dimension getScreenSize() {
-               if (isWindows())  // GraphicsEnvironment.getConfigurations is *very* slow on Windows
-                       return Toolkit.getDefaultToolkit().getScreenSize();
-               if (GraphicsEnvironment.isHeadless())
-                       return new Dimension(0, 0);
-               // Can't use Toolkit.getScreenSize() on Linux because it returns 
-               // size of all displays rather than just the primary display.
-               GraphicsEnvironment ge = GraphicsEnvironment.getLocalGraphicsEnvironment();
-               GraphicsDevice[] gd = ge.getScreenDevices();
-               GraphicsConfiguration[] gc = gd[0].getConfigurations();
-               Rectangle bounds = gc[0].getBounds();
-               if (bounds.x==0&&bounds.y==0)
-                       return new Dimension(bounds.width, bounds.height);
-               else
-                       return Toolkit.getDefaultToolkit().getScreenSize();
-       }
-       
-       static void abort() {
-               if (ij!=null || Interpreter.isBatchMode())
-                       throw new RuntimeException(Macro.MACRO_CANCELED);
-       }
-       
-       static void setClassLoader(ClassLoader loader) {
-               classLoader = loader;
-       }
-
-       /** Displays a stack trace. Use the setExceptionHandler 
-               method() to override with a custom exception handler. */
-       public static void handleException(Throwable e) {
-               if (exceptionHandler!=null) {
-                       exceptionHandler.handle(e);
-                       return;
-               }
-               CharArrayWriter caw = new CharArrayWriter();
-               PrintWriter pw = new PrintWriter(caw);
-               e.printStackTrace(pw);
-               String s = caw.toString();
-               if (getInstance()!=null)
-                       new TextWindow("Exception", s, 350, 250);
-               else
-                       log(s);
-       }
-
-       /** Installs a custom exception handler that 
-               overrides the handleException() method. */
-       public static void setExceptionHandler(ExceptionHandler handler) {
-               exceptionHandler = handler;
-       }
-
-       public interface ExceptionHandler {
-               public void handle(Throwable e);
-       }
-
-       static ExceptionHandler exceptionHandler;
-
-       public static void addEventListener(IJEventListener listener) {
-               eventListeners.addElement(listener);
-       }
-       
-       public static void removeEventListener(IJEventListener listener) {
-               eventListeners.removeElement(listener);
-       }
-       
-       public static void notifyEventListeners(int eventID) {
-               synchronized (eventListeners) {
-                       for (int i=0; i<eventListeners.size(); i++) {
-                               IJEventListener listener = (IJEventListener)eventListeners.elementAt(i);
-                               listener.eventOccurred(eventID);
-                       }
-               }
-       }
-
-}
diff --git a/sourceext/ij_source/ij/IJEventListener.java b/sourceext/ij_source/ij/IJEventListener.java
deleted file mode 100644 (file)
index f5af9b5..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
-package ij;
-
-       /** Plugins that implement this interface are notified when the user
-            changes the foreground color, changes the background color,
-            closes the color picker, closes the Log window or switches to
-            another tool.
-       */
-       public interface IJEventListener {
-               public static final int FOREGROUND_COLOR_CHANGED = 0;
-               public static final int BACKGROUND_COLOR_CHANGED = 1;
-               public static final int COLOR_PICKER_CLOSED= 2;
-               public static final int LOG_WINDOW_CLOSED= 3;
-               public static final int TOOL_CHANGED= 4;
-
-       public void eventOccurred(int eventID);
-
-}
diff --git a/sourceext/ij_source/ij/ImageJ.java b/sourceext/ij_source/ij/ImageJ.java
deleted file mode 100644 (file)
index 682d997..0000000
+++ /dev/null
@@ -1,730 +0,0 @@
-package ij;
-
-import java.awt.*;
-import java.util.*;
-import java.awt.event.*;
-import java.io.*;
-import java.net.*;
-import java.awt.image.*;
-import ij.gui.*;
-import ij.process.*;
-import ij.io.*;
-import ij.plugin.*;
-import ij.plugin.filter.*;
-import ij.plugin.frame.*;
-import ij.text.*;
-import ij.macro.Interpreter;
-import ij.io.Opener;
-import ij.util.*;
-
-/**
-This frame is the main ImageJ class.
-<p>
-ImageJ is a work of the United States Government. It is in the public domain 
-and open source. There is no copyright. You are free to do anything you want 
-with this source but I like to get credit for my work and I would like you to 
-offer your changes to me so I can possibly add them to the "official" version.
-
-<pre>
-The following command line options are recognized by ImageJ:
-
-  "file-name"
-     Opens a file
-     Example 1: blobs.tif
-     Example 2: /Users/wayne/images/blobs.tif
-     Example3: e81*.tif
-
-  -ijpath path
-     Specifies the path to the directory containing the plugins directory
-     Example: -ijpath /Applications/ImageJ
-
-  -port<n>
-     Specifies the port ImageJ uses to determine if another instance is running
-     Example 1: -port1 (use default port address + 1)
-     Example 2: -port2 (use default port address + 2)
-     Example 3: -port0 (do not check for another instance)
-
-  -macro path [arg]
-     Runs a macro or script, passing it an optional argument,
-     which can be retieved using getArgument()
-     Example 1: -macro analyze.ijm
-     Example 2: -macro analyze /Users/wayne/images/stack1
-
-  -batch path [arg]
-    Runs a macro or script in batch (no GUI) mode, passing it an optional argument.
-    ImageJ exits when the macro finishes.
-
-  -eval "macro code"
-     Evaluates macro code
-     Example 1: -eval "print('Hello, world');"
-     Example 2: -eval "return getVersion();"
-
-  -run command
-     Runs an ImageJ menu command
-     Example: -run "About ImageJ..."
-     
-  -debug
-     Runs ImageJ in debug mode
-</pre>
-@author Wayne Rasband (wsr@nih.gov)
-*/
-public class ImageJ extends Frame implements ActionListener, 
-       MouseListener, KeyListener, WindowListener, ItemListener, Runnable {
-
-       /** Plugins should call IJ.getVersion() to get the version string. */
-       public static final String VERSION = "1.44g";
-       public static final String BUILD = "10"; 
-       public static Color backgroundColor = new Color(220,220,220); //224,226,235
-       /** SansSerif, 12-point, plain font. */
-       public static final Font SansSerif12 = new Font("SansSerif", Font.PLAIN, 12);
-       /** Address of socket where Image accepts commands */
-       public static final int DEFAULT_PORT = 57294;
-       public static final int STANDALONE=0, EMBEDDED=1;
-
-       private static final String IJ_X="ij.x",IJ_Y="ij.y";
-       private static int port = DEFAULT_PORT;
-       private static String[] arguments;
-       
-       private Toolbar toolbar;
-       private Panel statusBar;
-       private ProgressBar progressBar;
-       private Label statusLine;
-       private boolean firstTime = true;
-       private java.applet.Applet applet; // null if not running as an applet
-       private Vector classes = new Vector();
-       private boolean exitWhenQuitting;
-       private boolean quitting;
-       private long keyPressedTime, actionPerformedTime;
-       private String lastKeyCommand;
-       private boolean embedded;
-       private boolean windowClosed;
-       
-       boolean hotkey;
-       
-       /** Creates a new ImageJ frame that runs as an application. */
-       public ImageJ() {
-               this(null, STANDALONE);
-       }
-       
-       /** Creates a new ImageJ frame that runs as an applet. */
-       public ImageJ(java.applet.Applet applet) {
-               this(applet, 0);
-       }
-
-       /** If 'applet' is not null, creates a new ImageJ frame that runs as an applet.
-               If  'mode' is ImageJ.EMBEDDED and 'applet is null, creates an embedded 
-               version of ImageJ which does not start the SocketListener. */
-       public ImageJ(java.applet.Applet applet, int mode) {
-               super("ImageJ");
-               embedded = applet==null && mode==EMBEDDED;
-               this.applet = applet;
-               String err1 = Prefs.load(this, applet);
-               if (IJ.isLinux()) {
-                       backgroundColor = new Color(240,240,240);
-                       setBackground(backgroundColor);
-               }
-               Menus m = new Menus(this, applet);
-               String err2 = m.addMenuBar();
-               m.installPopupMenu(this);
-               setLayout(new GridLayout(2, 1));
-               
-               // Tool bar
-               toolbar = new Toolbar();
-               toolbar.addKeyListener(this);
-               add(toolbar);
-
-               // Status bar
-               statusBar = new Panel();
-               statusBar.setLayout(new BorderLayout());
-               statusBar.setForeground(Color.black);
-               statusBar.setBackground(backgroundColor);
-               statusLine = new Label();
-               statusLine.setFont(SansSerif12);
-               statusLine.addKeyListener(this);
-               statusLine.addMouseListener(this);
-               statusBar.add("Center", statusLine);
-               progressBar = new ProgressBar(120, 20);
-               progressBar.addKeyListener(this);
-               progressBar.addMouseListener(this);
-               statusBar.add("East", progressBar);
-               statusBar.setSize(toolbar.getPreferredSize());
-               add(statusBar);
-
-               IJ.init(this, applet);
-               addKeyListener(this);
-               addWindowListener(this);
-               setFocusTraversalKeysEnabled(false);
-               
-               Point loc = getPreferredLocation();
-               Dimension tbSize = toolbar.getPreferredSize();
-               int ijWidth = tbSize.width+10;
-               int ijHeight = 100;
-               setCursor(Cursor.getDefaultCursor()); // work-around for JDK 1.1.8 bug
-               if (IJ.isWindows()) try {setIcon();} catch(Exception e) {}
-               setBounds(loc.x, loc.y, ijWidth, ijHeight); // needed for pack to work
-               setLocation(loc.x, loc.y);
-               pack();
-               setResizable(!(IJ.isMacintosh() || IJ.isWindows())); // make resizable on Linux
-               //if (IJ.isJava15()) {
-               //      try {
-               //              Method method = Frame.class.getMethod("setAlwaysOnTop", new Class[] {boolean.class});
-               //              method.invoke(this, new Object[]{Boolean.TRUE});
-               //      } catch(Exception e) {}
-               //}
-               show();
-               if (err1!=null)
-                       IJ.error(err1);
-               if (err2!=null) {
-                       IJ.error(err2);
-                       IJ.runPlugIn("ij.plugin.ClassChecker", "");
-               }
-               m.installStartupMacroSet();
-               if (IJ.isMacintosh()&&applet==null) { 
-                       Object qh = null; 
-                       qh = IJ.runPlugIn("MacAdapter", ""); 
-                       if (qh==null) 
-                               IJ.runPlugIn("QuitHandler", ""); 
-               } 
-               if (applet==null)
-                       IJ.runPlugIn("ij.plugin.DragAndDrop", "");
-               String str = m.getMacroCount()==1?" macro":" macros";
-               IJ.showStatus(version()+ m.getPluginCount() + " commands; " + m.getMacroCount() + str);
-               if (applet==null && !embedded && Prefs.runSocketListener)
-                       new SocketListener();
-               configureProxy();
-       }
-       
-       void configureProxy() {
-               String server = Prefs.get("proxy.server", null);
-               if (server==null||server.equals("")) return;
-               int port = (int)Prefs.get("proxy.port", 0);
-               if (port==0) return;
-               String user = Prefs.get("proxy.user", null);    
-               Properties props = System.getProperties();
-               props.put("proxySet", "true");
-               props.put("http.proxyHost", server);
-               props.put("http.proxyPort", ""+port);
-               if (user!=null)
-                       props.put("http.proxyUser", user);
-               //IJ.log(server+"  "+port+"  "+user);
-       }
-       
-    void setIcon() throws Exception {
-               URL url = this.getClass().getResource("/microscope.gif");
-               if (url==null) return;
-               Image img = createImage((ImageProducer)url.getContent());
-               if (img!=null) setIconImage(img);
-       }
-       
-       public Point getPreferredLocation() {
-               if (!IJ.isJava14()) return new Point(0, 0);
-               GraphicsEnvironment ge = GraphicsEnvironment.getLocalGraphicsEnvironment();
-               Rectangle maxBounds = ge.getMaximumWindowBounds();
-               int ijX = Prefs.getInt(IJ_X,-99);
-               int ijY = Prefs.getInt(IJ_Y,-99);
-               if (ijX>=0 && ijY>0 && ijX<(maxBounds.x+maxBounds.width-75))
-                       return new Point(ijX, ijY);
-               Dimension tbsize = toolbar.getPreferredSize();
-               int ijWidth = tbsize.width+10;
-               double percent = maxBounds.width>832?0.8:0.9;
-               ijX = (int)(percent*(maxBounds.width-ijWidth));
-               if (ijX<10) ijX = 10;
-               return new Point(ijX, maxBounds.y);
-       }
-       
-       void showStatus(String s) {
-        statusLine.setText(s);
-       }
-
-       public ProgressBar getProgressBar() {
-        return progressBar;
-       }
-
-       public Panel getStatusBar() {
-        return statusBar;
-       }
-
-    /** Starts executing a menu command in a separate thread. */
-    void doCommand(String name) {
-               new Executer(name, null);
-    }
-        
-       public void runFilterPlugIn(Object theFilter, String cmd, String arg) {
-               new PlugInFilterRunner(theFilter, cmd, arg);
-       }
-        
-       public Object runUserPlugIn(String commandName, String className, String arg, boolean createNewLoader) {
-               return IJ.runUserPlugIn(commandName, className, arg, createNewLoader);  
-       } 
-       
-       /** Return the current list of modifier keys. */
-       public static String modifiers(int flags) { //?? needs to be moved
-               String s = " [ ";
-               if (flags == 0) return "";
-               if ((flags & Event.SHIFT_MASK) != 0) s += "Shift ";
-               if ((flags & Event.CTRL_MASK) != 0) s += "Control ";
-               if ((flags & Event.META_MASK) != 0) s += "Meta ";
-               if ((flags & Event.ALT_MASK) != 0) s += "Alt ";
-               s += "] ";
-               return s;
-       }
-
-       /** Handle menu events. */
-       public void actionPerformed(ActionEvent e) {
-               if ((e.getSource() instanceof MenuItem)) {
-                       MenuItem item = (MenuItem)e.getSource();
-                       String cmd = e.getActionCommand();
-                       if (item.getParent()==Menus.openRecentMenu) {
-                               new RecentOpener(cmd); // open image in separate thread
-                               return;
-                       }
-                       int flags = e.getModifiers();
-                       //IJ.log(""+KeyEvent.getKeyModifiersText(flags));
-                       hotkey = false;
-                       actionPerformedTime = System.currentTimeMillis();
-                       long ellapsedTime = actionPerformedTime-keyPressedTime;
-                       if (cmd!=null && (ellapsedTime>=200L||!cmd.equals(lastKeyCommand))) {
-                               if ((flags & Event.ALT_MASK)!=0)
-                                       IJ.setKeyDown(KeyEvent.VK_ALT);
-                               if ((flags & Event.SHIFT_MASK)!=0)
-                                       IJ.setKeyDown(KeyEvent.VK_SHIFT);
-                               doCommand(cmd);
-                       }
-                       lastKeyCommand = null;
-                       if (IJ.debugMode) IJ.log("actionPerformed: time="+ellapsedTime+", "+e);
-               }
-       }
-
-       /** Handles CheckboxMenuItem state changes. */
-       public void itemStateChanged(ItemEvent e) {
-               MenuItem item = (MenuItem)e.getSource();
-               MenuComponent parent = (MenuComponent)item.getParent();
-               String cmd = e.getItem().toString();
-               if ((Menu)parent==Menus.window)
-                       WindowManager.activateWindow(cmd, item);
-               else
-                       doCommand(cmd);
-       }
-
-       public void mousePressed(MouseEvent e) {
-               Undo.reset();
-               System.gc();
-               IJ.showStatus(version()+IJ.freeMemory());
-               if (IJ.debugMode)
-                       IJ.log("Windows: "+WindowManager.getWindowCount());
-       }
-       
-       private String version() {
-               return "ImageJ "+VERSION+BUILD + "; "+"Java "+System.getProperty("java.version")+(IJ.is64Bit()?" [64-bit]; ":" [32-bit]; ");
-       }
-       
-       public void mouseReleased(MouseEvent e) {}
-       public void mouseExited(MouseEvent e) {}
-       public void mouseClicked(MouseEvent e) {}
-       public void mouseEntered(MouseEvent e) {}
-
-       public void keyPressed(KeyEvent e) {
-               //if (e.isConsumed()) return;
-               int keyCode = e.getKeyCode();
-               IJ.setKeyDown(keyCode);
-               hotkey = false;
-               if (keyCode==e.VK_CONTROL || keyCode==e.VK_SHIFT)
-                       return;
-               char keyChar = e.getKeyChar();
-               int flags = e.getModifiers();
-               if (IJ.debugMode) IJ.log("keyPressed: code=" + keyCode + " (" + KeyEvent.getKeyText(keyCode)
-                       + "), char=\"" + keyChar + "\" (" + (int)keyChar + "), flags="
-                       + KeyEvent.getKeyModifiersText(flags));
-               boolean shift = (flags & e.SHIFT_MASK) != 0;
-               boolean control = (flags & e.CTRL_MASK) != 0;
-               boolean alt = (flags & e.ALT_MASK) != 0;
-               boolean meta = (flags & e.META_MASK) != 0;
-               String cmd = "";
-               ImagePlus imp = WindowManager.getCurrentImage();
-               boolean isStack = (imp!=null) && (imp.getStackSize()>1);
-               
-               if (imp!=null && !control && ((keyChar>=32 && keyChar<=255) || keyChar=='\b' || keyChar=='\n')) {
-                       Roi roi = imp.getRoi();
-                       if (roi instanceof TextRoi) {
-                               if ((flags & e.META_MASK)!=0 && IJ.isMacOSX()) return;
-                               if (alt)
-                                       switch (keyChar) {
-                                               case 'u': case 'm': keyChar = IJ.micronSymbol; break;
-                                               case 'A': keyChar = IJ.angstromSymbol; break;
-                                               default:
-                                       }
-                               ((TextRoi)roi).addChar(keyChar);
-                               return;
-                       }
-               }
-                       
-               // Handle one character macro shortcuts
-               if (!control && !meta) {
-                       Hashtable macroShortcuts = Menus.getMacroShortcuts();
-                       if (macroShortcuts.size()>0) {
-                               if (shift)
-                                       cmd = (String)macroShortcuts.get(new Integer(keyCode+200));
-                               else
-                                       cmd = (String)macroShortcuts.get(new Integer(keyCode));
-                               if (cmd!=null) {
-                                       //MacroInstaller.runMacroCommand(cmd);
-                                       MacroInstaller.runMacroShortcut(cmd);
-                                       return;
-                               }
-                       }
-               }
-
-               if ((!Prefs.requireControlKey || control || meta) && keyChar!='+') {
-                       Hashtable shortcuts = Menus.getShortcuts();
-                       if (shift)
-                               cmd = (String)shortcuts.get(new Integer(keyCode+200));
-                       else
-                               cmd = (String)shortcuts.get(new Integer(keyCode));
-               }
-               
-               if (cmd==null) {
-                       switch (keyChar) {
-                               case '<': case ',': cmd="Previous Slice [<]"; break;
-                               case '>': case '.': case ';': cmd="Next Slice [>]"; break;
-                               case '+': case '=': cmd="In"; break;
-                               case '-': cmd="Out"; break;
-                               case '/': cmd="Reslice [/]..."; break;
-                               default:
-                       }
-               }
-
-               if (cmd==null) {
-                       switch(keyCode) {
-                               case KeyEvent.VK_TAB: WindowManager.putBehind(); return;
-                               case KeyEvent.VK_BACK_SPACE: cmd="Clear"; hotkey=true; break; // delete
-                               //case KeyEvent.VK_BACK_SLASH: cmd=IJ.altKeyDown()?"Animation Options...":"Start Animation"; break;
-                               case KeyEvent.VK_EQUALS: cmd="In"; break;
-                               case KeyEvent.VK_MINUS: cmd="Out"; break;
-                               case KeyEvent.VK_SLASH: case 0xbf: cmd="Reslice [/]..."; break;
-       &nb