![]() | InDesign SDK 20.5 |
#include <IToolManager.h>

Public Member Functions | |
| virtual void | SetActiveTool (ITool *newActiveTool, ClassID toolType)=0 |
| virtual ITool * | QueryActiveTool (ClassID toolType)=0 |
| virtual ITool * | QueryPreviousActiveTool (ClassID toolType)=0 |
| virtual ITool * | QueryMostRecentSelectionTool ()=0 |
| virtual ITool * | QueryMostRecentCreationTool ()=0 |
| virtual int32 | GetNumToolTypes ()=0 |
| virtual ClassID | GetNthToolType (int32 index)=0 |
| virtual void | Startup (const PMLocaleId &localId)=0 |
| virtual void | Shutdown (const PMLocaleId &localeId)=0 |
| virtual void | AddTool (ITool *tool, int32 groupNum, int32 toolNum, ClassID parentTool, int32 subToolNum, RsrcID iconID, const PluginID &pluginID)=0 |
| virtual ToolRecord | GetNthTool (int32 index)=0 |
| virtual ToolRecord | GetNthSubTool (int32 index)=0 |
| virtual int32 | GetNumTools ()=0 |
| virtual int32 | GetNumSubTools ()=0 |
| virtual bool16 | FindParentTool (ClassID parentClass, ToolRecord *result)=0 |
| virtual bool16 | FindTool (ClassID toolClass, ToolRecord *result)=0 |
| virtual void | SetMostRecentSelectionTool (ITool *selectionTool)=0 |
| virtual void | SetSpringLoadedTool (ITool *tool)=0 |
| virtual void | RestoreSpringLoadedTool ()=0 |
| virtual bool16 | OnKeyUp (IEvent *e)=0 |
| virtual bool16 | OnKeyDown (IEvent *e)=0 |
| virtual bool16 | IsToolSpringLoaded ()=0 |
Public Member Functions inherited from IPMUnknown | |
| virtual IPMUnknown * | QueryInterface (PMIID interfaceID) const =0 |
| virtual void | AddRef () const =0 |
| virtual void | Release () const =0 |
Interface responsible for maintaining a list of tools. Also keeps track of MRU tools of specific types.
| pure virtual |
Add a new tool to the tool manager. This is only legal to do during startup. Usually this gets called as a result of registering plugins and reading in their ToolDef resources
| tool | the new tool |
| groupNum | the group number this tool should be in in the toolbox. See ToolboxDefs.h |
| toolNum | the tool number for this tool within its group in the toolbox. See ToolboxDefs.h |
| parentTool | the ClassID of the tool this tool should be 'under' in the toolbox. |
| subToolNum | the subtool number for this tool. Used for relative positioning of subtools. See ToolboxDefs.h |
| iconID | the icon for the toolbox to display for this tool |
| pluginID | the plugin where the tool resource can be found. |
| pure virtual |
Request the ToolRecord for the parent tool.
| parentClass | the ClassID of the parent tool you want to find. |
| result | the requested ToolRecord for the parent tool is copied into the passed in 'result' param |
| pure virtual |
Request the ToolRecord for a tool or subtool
| toolClass | the ClassID of the tool you want to find. |
| result | the requested ToolRecord for the tool is copied into the passed in 'result' param |
| pure virtual |
Request the nth subtool. None of these tools live in the main toolbox(i.e. they are subtools)
| index | the index of the subtool you're interested in. |
| pure virtual |
Request the nth tool. All these tools live in the main toolbox(i.e. they are not subtools)
| index | the index of the tool you're interested in. |
| pure virtual |
request the nth tool type. Note that the tool type is a ClassID equal to the ClassID of the default tool for that type.
| index | the index of the tool type you're interested in. |
| pure virtual |
Request the number of subtools. None of these tools live in the main toolbox(i.e. they are subtools)
| pure virtual |
Request the number of tools. All these tools live in the main toolbox(i.e. they are not subtools)
| pure virtual |
request the number of tool types. Traditional tools are of type kPointerToolBoss. Tools of the same type are mutually exclusive.
| pure virtual |
checks to see if we have a spring loaded tool in the hopper.
| pure virtual |
Handles KeyDown events for spring loaded shortcuts
| e | event from the KeyDown event that fired. |
| pure virtual |
Handles KeyUp events for spring loaded shortcuts
| e | event from the KeyUp event that fired. |
returns the active tool. Most often this is accessed by calling Utils<IToolBoxUtils>()->QueryActiveTool( toolType );
| toolType | the 'type' of this tool. Traditional tools are of type kPointerToolBoss. Tools of the same type are mutually exclusive. |
| pure virtual |
returns the most recent creation tool. If the user is using the oval tool, then switches to the zoom tool, calling this would return the oval tool to you.
| pure virtual |
returns the most recent active selection tool. If the user is using the direct select tool, and then switches to the zoom tool, and then switches to the oval tool, calling this would return the direct select tool to you.
returns the previous active tool. If the user is using the rectangle tool, and then switches to the oval tool, calling this would return the rectangle tool to you. Most often this is accessed by calling Utils<IToolBoxUtils>()->QueryPreviousActiveTool( toolType );
| toolType | the 'type' of this tool. Traditional tools are of type kPointerToolBoss. Tools of the same type are mutually exclusive. |
| pure virtual |
Restores the spring loaded tool
Sets the active tool. Typically only called by SetToolCmd, which in turn is usually invoked by calling Utils<IToolBoxUtils>()->SetActiveTool( itool, toolType );
| newActiveTool | the new tool to make active |
| toolType | the 'type' of this tool. Traditional tools are of type kPointerToolBoss. Tools of the same type are mutually exclusive. |
| pure virtual |
Sets the selection tool returned by QueryMostRecentSelectionTool to a different selection tool without changing tools. Used for cmd-tab behavior.
| selectionTool | the newly used selection tool. |
| pure virtual |
Sets the tool that RestoreSpringLoadedTool will restore.
| tool | tool that should be restored. |
| pure virtual |
Shutdown the tool manager. Internal use only.
| pure virtual |
Startup the tool manager. Internal use only.