Skip to content

Instantly share code, notes, and snippets.

@jeesay
Created December 29, 2011 09:32
Show Gist options
  • Save jeesay/1533204 to your computer and use it in GitHub Desktop.
Save jeesay/1533204 to your computer and use it in GitHub Desktop.
drawArrow.ijm
// Draw Arrow
// Jean-Christophe Taveau
// Inspired by J Mutterer
// Post published in IJ mailing list - Mar 24, 2010; 9:12am Re: Drawing Arrows with a Macro?
// http://crazybiocomputing.com/blogspot.com
function drawArrow(x0,y0,x1,y1,dummy)
{
setLineWidth(1);
eval('script','img = IJ.getImage();a= new Arrow('+x0+','+y0+','+x1+','+y1+');a.setHeadSize(6);a.setStrokeWidth(1);a.setStyle(Arrow.FILLED);img.setRoi(a);');
run("Draw");
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment