Package ij.gui

Class PlotCanvas

    • Constructor Detail

      • PlotCanvas

        public PlotCanvas​(ImagePlus imp)
        Creates a new PlotCanvas
    • Method Detail

      • setPlot

        public void setPlot​(Plot plot)
        Tells the PlotCanvas which plot to use for zooming etc. Call this immediately after construction
      • getPlot

        public Plot getPlot()
        Returns the Plot displayed in this canvas
      • isFrozen

        public boolean isFrozen()
        Whether the plot is frozen, i.e. its ImageProcessor can not be changed
      • zoom

        public void zoom​(String arg)
        Zoom operations that are handled by ij.plugin.Zoom
      • zoomIn

        public void zoomIn​(int sx,
                           int sy)
        Zooms in by modifying the plot range; sx and sy are screen coordinates
        Overrides:
        zoomIn in class ImageCanvas
      • zoomOut

        public void zoomOut​(int sx,
                            int sy)
        Zooms out by modifying the plot range; sx and sy are screen coordinates
        Overrides:
        zoomOut in class ImageCanvas
      • unzoom

        public void unzoom()
        Implements the Image/Zoom/Original Scale command. Sets the original range of the x, y axes (unless the plot is frozen)
        Overrides:
        unzoom in class ImageCanvas
      • zoom100Percent

        public void zoom100Percent()
        Implements the Image/Zoom/View 100% command: Sets the original frame size as specified in Edit/Options/Plots (unless the plot is frozen)
        Overrides:
        zoom100Percent in class ImageCanvas
      • fitToWindow

        public void fitToWindow()
        Resizes the plot (unless frozen) to fit the window
        Overrides:
        fitToWindow in class ImageCanvas
      • setMagnification

        public void setMagnification​(double magnification)
        The image of a PlotCanvas is always shown at 100% magnification unless the plot is frozen
        Overrides:
        setMagnification in class ImageCanvas
      • setSourceRect

        public void setSourceRect​(Rectangle r)
        Scrolling a PlotCanvas is updating the plot, not viewing part of the plot, unless the plot is frozen
        Overrides:
        setSourceRect in class ImageCanvas
      • setupScroll

        protected void setupScroll​(int ox,
                                   int oy)
        overrides ImageCanvas.setupScroll; if plot is not frozen, scrolling modifies the plot data range
        Overrides:
        setupScroll in class ImageCanvas
      • scroll

        protected void scroll​(int sx,
                              int sy)
        overrides ImageCanvas.scroll; if plot is not frozen, scrolling modifies the plot data range
        Overrides:
        scroll in class ImageCanvas