- java.lang.Object
-
- ij.plugin.tool.PlugInTool
-
- ij.plugin.tool.BrushTool
-
- All Implemented Interfaces:
PlugIn,java.lang.Runnable
public class BrushTool extends PlugInTool implements java.lang.Runnable
This class implements the Paintbrush Tool, which allows the user to draw on an image, or on an Overlay if "Paint on overlay" is enabled.
-
-
Constructor Summary
Constructors Constructor Description BrushTool()
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetToolIcon()Return the string encoding of the tool icon.java.lang.StringgetToolName()Return the tool name.voidmouseDragged(ImagePlus imp, java.awt.event.MouseEvent e)voidmousePressed(ImagePlus imp, java.awt.event.MouseEvent e)voidmouseReleased(ImagePlus imp, java.awt.event.MouseEvent e)voidrun()voidrun(java.lang.String arg)This method is called when the plugin is loaded.static voidsetBrushWidth(int width)voidshowOptionsDialog()-
Methods inherited from class ij.plugin.tool.PlugInTool
getMacroProgram, mouseClicked, mouseEntered, mouseExited, mouseMoved, runMacroTool, runMenuTool, showPopupMenu
-
-
-
-
Method Detail
-
run
public void run(java.lang.String arg)
Description copied from interface:PlugInThis method is called when the plugin is loaded. 'arg', which may be blank, is the argument specified for this plugin in IJ_Props.txt.- Specified by:
runin interfacePlugIn- Overrides:
runin classPlugInTool
-
mousePressed
public void mousePressed(ImagePlus imp, java.awt.event.MouseEvent e)
- Overrides:
mousePressedin classPlugInTool
-
mouseDragged
public void mouseDragged(ImagePlus imp, java.awt.event.MouseEvent e)
- Overrides:
mouseDraggedin classPlugInTool
-
mouseReleased
public void mouseReleased(ImagePlus imp, java.awt.event.MouseEvent e)
- Overrides:
mouseReleasedin classPlugInTool
-
showOptionsDialog
public void showOptionsDialog()
- Overrides:
showOptionsDialogin classPlugInTool
-
getToolName
public java.lang.String getToolName()
Description copied from class:PlugInToolReturn the tool name.- Overrides:
getToolNamein classPlugInTool
-
getToolIcon
public java.lang.String getToolIcon()
Description copied from class:PlugInToolReturn the string encoding of the tool icon. See http://rsb.info.nih.gov/ij/developer/macro/macros.html#icons The default icon is the first letter of the tool name.- Overrides:
getToolIconin classPlugInTool
-
run
public void run()
- Specified by:
runin interfacejava.lang.Runnable
-
setBrushWidth
public static void setBrushWidth(int width)
-
-