Login  Register

Detect when Polygon closed

Posted by mdhiggins on Aug 15, 2015; 2:39pm
URL: http://imagej.273.s1.nabble.com/Detect-when-Polygon-closed-tp5014039.html

Hello,

I am writing a macro to outline crystals in an image.

The user outlines the crystal with the polygon tool. Then I want a message to pop up then asking if the outline is correct. This is what I have tried. However, I can't work out how to determine when the user has closed the polygon and the message should pop up.

do
{
setTool("polygon");

// something is needed here to show when polygon is closed by user.

outline_OK = getBoolean("Is outline correct?");

}
while (outline_OK==false) ;

Cheers  Michael

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