Gets the current tool of the active viewer.
The tool object.
const tool = instance.UI.getToolMode();if (tool.name === instance.Core.Tools.ToolNames.RECTANGLE) { console.log('The rectangle tool is active');} Copy
const tool = instance.UI.getToolMode();if (tool.name === instance.Core.Tools.ToolNames.RECTANGLE) { console.log('The rectangle tool is active');}
Gets the current tool of the active viewer.