Login  Register

Re: ImageJ does not add new plugins to the menu

Posted by Michael Schmid on Mar 29, 2017; 5:36pm
URL: http://imagej.273.s1.nabble.com/ImageJ-does-not-add-new-plugins-to-the-menu-tp5018403p5018414.html

Hi Paul,

sorry, I cannot reproduce the problem.

I tried your plugin with 'Compile&Run' in plain ImageJ 1.51m.
I had to remove the line "ImageWindow(ImagePlus imp);", which does
nothing and caused an error during compilation.
Then the plugin appears in the Plugins menu after Help>Refresh Menus and
also after restarting ImageJ.

Maybe you have overlooked the error message of the compiler? If it can't
be compiled, it can't appear in the plugins menu.


Michael
________________________________________________________________
On 28/03/2017 15:56, Paul Cholerzynski wrote:

> I used it and it worked fine, but as a separate project using ImageJ. I was
> hoping that I could add it directly to the plugins menu (in the plugins
> forder). Another way around is to load my images and open them in
> ImageWindow, but I doun't know yet how to do that.
>
> Right now it looks like this:
>
> import ij.IJ;
> import ij.ImagePlus;
> import ij.io.Opener;
> import ij.plugin.PlugIn;
> import ij.process.ImageProcessor;
> import ij.gui.ImageWindow;
>
> public class Cephalometric_analysis implements PlugIn{
>     @Override
>     public void run(String args){
>        IJ.showMessage("This is a test");
>         Opener opener = new Opener();
>         String imageFilePath =
> "C:/Users/Admin/Documents/Notatki/Meh/Obrazy/";
>         ImagePlus imp = opener.openImage(imageFilePath);
>         ImageProcessor ip = imp.getProcessor();
>         ImageWindow(ImagePlus imp);
>         ImageWindow iw = new ImageWindow(imp);
>         iw.setImage(imp);
>     }
>     public static void main(final String... args){
>
>         new ij.ImageJ();
>         new Cephalometric_analysis().run("");
>     }
> }
>
>

--
ImageJ mailing list: http://imagej.nih.gov/ij/list.html