Hot Door CORE  0.7.0
Adobe® Illustrator® Plug-in Library
Public Types | Public Member Functions | Static Public Member Functions | Friends | List of all members
hdi::core::Plugin Class Reference

Base plugin class; the heart of any plugin project. More...

#include <hdicorePlugin.h>

Public Types

enum  Options { NoOptions = 0, AutoSelectsResultsOption = 1 << 0, RetainsPartialPathSelectionOption = 1 << 1 }
 Allows for configuration of various plug-in behaviors.
 
enum  UndoContext { UnknownUndoContext = 0, StandardUndoContext = 10, SilentUndoContext = 20, AppendUndoContext = 30 }
 Allows for setting of the undo context to other behaviors.
 
typedef std::vector< byte > ByteVector
 

Public Member Functions

virtual SPPluginRef spPluginRef () const
 Gets the plugin ref around which the target object is wrapped. More...
 
PlatformPluginPtr platformPlugin () const
 Gets a pointer to the platform object representing the current Plugin instance. More...
 
virtual std::string filePath () const
 Gets the full path of the plugin file at runtime. More...
 
virtual std::string fileName () const
 Gets the name of the plugin file at runtime. More...
 
virtual std::string name () const
 Gets the plugin name. More...
 
virtual void setName (const std::string &name_)
 Sets the plugin name. More...
 
virtual Options options () const
 Gets the plugin's options. More...
 
virtual void setOptions (const Options options_)
 Sets the plugin's options. More...
 
virtual Dispatcher *const dispatcher () const
 Convenience method to return the Dispatcher instance. More...
 
virtual Tool *const currentTool () const
 Gets a pointer to the currently selected tool. More...
 
virtual void undo () const
 Undoes the last set of artwork changes by this specific plugin. More...
 
virtual bool setUndoKind (const UndoContext uc_)
 Changes the undo context to another type. More...
 
virtual bool resourceData (const int32_t type_, const int16_t id_, ByteVector &data__) const
 Acquires a byte vector for a given resource. More...
 
virtual bool resourceData (const int32_t type_, const std::string &name_, ByteVector &data__) const
 Acquires a byte vector for a given resource. More...
 
virtual bool toolsSnapToArt () const
 Gets whether tools belonging to this plugin should snap the cursor to artwork. More...
 
virtual void setToolsSnapToArt (const bool snap_)
 Sets whether tools belonging to this plugin should snap the cursor to artwork. More...
 
virtual bool toolsSnapToArtBounds () const
 Gets whether tools belonging to this plugin should snap the cursor to artwork bounds. More...
 
virtual void setToolsSnapToArtBounds (const bool snap_)
 Sets whether tools belonging to this plugin should snap the cursor to artwork bounds. More...
 
virtual bool toolsSnapToArtboard () const
 Gets whether tools belonging to this plugin should snap the cursor to the artboard edges. More...
 
virtual void setToolsSnapToArtboard (const bool snap_)
 Sets whether tools belonging to this plugin should snap the cursor to the artboard edges. More...
 
virtual bool toolsSnapToGrids () const
 Gets whether tools belonging to this plugin should snap the cursor to the Illustrator gridlines. More...
 
virtual void setToolsSnapToGrids (const bool snap_)
 Sets whether tools belonging to this plugin should snap the cursor to the Illustrator gridlines. More...
 
virtual bool startingUp () const
 Gets whether the plugin is in the process of starting up. More...
 
virtual bool hasStartedUp () const
 Gets whether the plugin has already completed starting up. More...
 
virtual bool postStartingUp () const
 Gets whether the plugin is in the process of post-starting up. More...
 
virtual bool hasPostStartedUp () const
 Gets whether the plugin has already completed post-starting up. More...
 
virtual bool preShuttingDown () const
 Gets whether the plugin is in the process of pre-shutting down. More...
 
virtual bool hasPreShutdown () const
 Gets whether the plugin has already completed pre-shutting down. More...
 
virtual bool shuttingDown () const
 Gets whether the plugin is in the process of shutting down. More...
 
virtual bool hasShutdown () const
 Gets whether the plugin has already completed shutting down. More...
 
virtual Callback *const startupCallback () const
 Gets the callback that's called when the plugin is starting up. More...
 
virtual void setStartupCallback (const Callback &cb_)
 Sets the callback that's called when the plugin is starting up. More...
 
virtual Callback *const postStartupCallback () const
 Gets the callback that's called just after the plugin has started up. More...
 
virtual void setPostStartupCallback (const Callback &cb_)
 Sets the callback that's called just after the plugin has started up. More...
 
virtual Callback *const preShutdownCallback () const
 Gets the callback that's called just before the plugin will shutdown. More...
 
virtual void setPreShutdownCallback (const Callback &cb_)
 Sets the callback that's called just before the plugin will shutdown. More...
 
virtual Callback *const shutdownCallback () const
 Gets the callback that's called when the plugin is shutting down. More...
 
virtual void setShutdownCallback (const Callback &cb_)
 Sets the callback that's called when the plugin is shutting down. More...
 
virtual Callback *const menuItemSelectedCallback () const
 Gets the callback that's called when a user selects one of the plugin's menu items. More...
 
virtual void setMenuItemSelectedCallback (const Callback &cb_)
 Sets the callback that's called when a user selects one of the plugin's menu items. More...
 
virtual Callback *const menuItemsUpdateCallback () const
 Gets the callback that's called when a user hovers over menu groups that will show this plugin's menu items. More...
 
virtual void setMenuItemsUpdateCallback (const Callback &cb_)
 Sets the callback that's called when a user hovers over menu groups that will show this plugin's menu items. More...
 
virtual Callback *const brightnessAdjustedCallback () const
 Gets the callback that's called when the brightness of the Illustrator UI is changed via the app preference dialog. More...
 
virtual void setBrightnessAdjustedCallback (const Callback &cb_)
 Sets the callback that's called when the brightness of the Illustrator UI is changed via the app preference dialog. More...
 
virtual Callback *const toolPreSelectedCallback () const
 Gets the callback that's called just before a tool is selected from the toolbar (i.e. the tool's selection callback has not been called) More...
 
virtual void setToolPreSelectedCallback (const Callback &cb_)
 Sets the callback that's called just before a tool is selected from the toolbar (i.e. the tool's selection callback has not been called) More...
 
virtual Callback *const toolPostSelectedCallback () const
 Gets the callback that's called just after a tool is selected from the toolbar (i.e. the tool's selection callback has already been called) More...
 
virtual void setToolPostSelectedCallback (const Callback &cb_)
 Sets the callback that's called just after a tool is selected from the toolbar (i.e. the tool's selection callback has already been called) More...
 
virtual Callback *const toolPreDeselectedCallback () const
 Gets the callback that's called just before a tool is deselected (i.e. the tool's deselection callback has not been called) More...
 
virtual void setToolPreDeselectedCallback (const Callback &cb_)
 Sets the callback that's called just before a tool is deselected (i.e. the tool's deselection callback has not been called) More...
 
virtual Callback *const toolPostDeselectedCallback () const
 Gets the callback that's called just after a tool is deselected (i.e. the tool's deselection callback has already been called) More...
 
virtual void setToolPostDeselectedCallback (const Callback &cb_)
 Sets the callback that's called just after a tool is deselected (i.e. the tool's deselection callback has already been called) More...
 
virtual Callback *const toolPreReselectedCallback () const
 Gets the callback that's called just before a tool is reselected (i.e. the tool's reselection callback has not been called) More...
 
virtual void setToolPreReselectedCallback (const Callback &cb_)
 Sets the callback that's called just before a tool is reselected (i.e. the tool's reselection callback has not been called) More...
 
virtual Callback *const toolPostReselectedCallback () const
 Gets the callback that's called just after a tool is reselected (i.e. the tool's reselection callback has already been called) More...
 
virtual void setToolPostReselectedCallback (const Callback &cb_)
 Sets the callback that's called just after a tool is reselected (i.e. the tool's reselection callback has already been called) More...
 
virtual Callback *const toolPreTrackedCallback () const
 Gets the callback that's called just before the cursor moves (with the mouse button released; i.e. the tool's track callback has not been called) More...
 
virtual void setToolPreTrackedCallback (const Callback &cb_)
 Sets the callback that's called just before the cursor moves (with the mouse button released; i.e. the tool's track callback has not been called) More...
 
virtual Callback *const toolPostTrackedCallback () const
 Gets the callback that's called just after the cursor moves (with the mouse button released; i.e. the tool's track callback has already been called) More...
 
virtual void setToolPostTrackedCallback (const Callback &cb_)
 Sets the callback that's called just after the cursor moves (with the mouse button released; i.e. the tool's track callback has already been called) More...
 
virtual Callback *const toolPreMouseDownCallback () const
 Gets the callback that's called just before the mouse button goes down (i.e. the tool's mouse down callback has not been called) More...
 
virtual void setToolPreMouseDownCallback (const Callback &cb_)
 Sets the callback that's called just before the mouse button goes down (i.e. the tool's mouse down callback has not been called) More...
 
virtual Callback *const toolPostMouseDownCallback () const
 Gets the callback that's called just after the mouse button goes down (i.e. the tool's mouse down callback has already been called) More...
 
virtual void setToolPostMouseDownCallback (const Callback &cb_)
 Sets the callback that's called just after the mouse button goes down (i.e. the tool's mouse down callback has already been called) More...
 
virtual Callback *const toolPreDraggedCallback () const
 Gets the callback that's called just before the mouse button is down and the cursor moves (i.e. the tool's drag callback has not been called) More...
 
virtual void setToolPreDraggedCallback (const Callback &cb_)
 Sets the callback that's called just before the mouse button is down and the cursor moves (i.e. the tool's drag callback has not been called) More...
 
virtual Callback *const toolPostDraggedCallback () const
 Gets the callback that's called just after the mouse button is down and the cursor moves (i.e. the tool's drag callback has already been called) More...
 
virtual void setToolPostDraggedCallback (const Callback &cb_)
 Sets the callback that's called just after the mouse button is down and the cursor moves (i.e. the tool's drag callback has already been called) More...
 
virtual Callback *const toolPreMouseUpCallback () const
 Gets the callback that's called just before the mouse button comes up (i.e. the tool's mouse up callback has not been called) More...
 
virtual void setToolPreMouseUpCallback (const Callback &cb_)
 Sets the callback that's called just before the mouse button comes up (i.e. the tool's mouse up callback has not been called) More...
 
virtual Callback *const toolPostMouseUpCallback () const
 Gets the callback that's called just after the mouse button comes up (i.e. the tool's mouse up callback has already been called) More...
 
virtual void setToolPostMouseUpCallback (const Callback &cb_)
 Sets the callback that's called just after the mouse button comes up (i.e. the tool's mouse up callback has already been called) More...
 
virtual Callback *const toolPreDiameterDecreasedCallback () const
 Gets the callback that's called just before the '[' key is hit while a tool is selected (i.e. the tool's diameter decrease callback has not been called) More...
 
virtual void setToolPreDiameterDecreasedCallback (const Callback &cb_)
 Sets the callback that's called just before the '[' key is hit while a tool is selected (i.e. the tool's diameter decrease callback has not been called) More...
 
virtual Callback *const toolPostDiameterDecreasedCallback () const
 Gets the callback that's called just after the '[' key is hit while a tool is selected (i.e. the tool's diameter decrease callback has already been called) More...
 
virtual void setToolPostDiameterDecreasedCallback (const Callback &cb_)
 Sets the callback that's called just after the '[' key is hit while a tool is selected (i.e. the tool's diameter decrease callback has already been called) More...
 
virtual Callback *const toolPreDiameterIncreasedCallback () const
 Gets the callback that's called just before the ']' key is hit while a tool is selected (i.e. the tool's diameter increase callback has not been called) More...
 
virtual void setToolPreDiameterIncreasedCallback (const Callback &cb_)
 Sets the callback that's called just before the ']' key is hit while a tool is selected (i.e. the tool's diameter increase callback has not been called) More...
 
virtual Callback *const toolPostDiameterIncreasedCallback () const
 Gets the callback that's called just after the ']' key is hit while a tool is selected (i.e. the tool's diameter increase callback has already been called) More...
 
virtual void setToolPostDiameterIncreasedCallback (const Callback &cb_)
 Sets the callback that's called just after the ']' key is hit while a tool is selected (i.e. the tool's diameter increase callback has already been called) More...
 
virtual Callback *const toolPreEditedCallback () const
 Gets the callback that's called just before a tool is double-clicked in the toolbar (i.e. the tool's edit callback has not been called) More...
 
virtual void setToolPreEditedCallback (const Callback &cb_)
 Sets the callback that's called just before a tool is double-clicked in the toolbar (i.e. the tool's edit callback has not been called) More...
 
virtual Callback *const toolPostEditedCallback () const
 Gets the callback that's called just after a tool is double-clicked in the toolbar (i.e. the tool's edit callback has already been called) More...
 
virtual void setToolPostEditedCallback (const Callback &cb_)
 Sets the callback that's called just after a tool is double-clicked in the toolbar (i.e. the tool's edit callback has already been called) More...
 
virtual ModalDialog *const aboutBox () const
 Gets the about box modal dialog for the plugin. More...
 
virtual void setAboutBox (const ModalDialog &dialog_)
 Sets the about box modal dialog for the plugin. More...
 
virtual ModalDialog *const prefsDialog () const
 Gets the global prefs modal dialog for the plugin. More...
 
virtual void setPrefsDialog (const ModalDialog &dialog_)
 Sets the global prefs modal dialog for the plugin. More...
 
virtual MenuItem *const aboutMenuItem () const
 Gets the about box menu item for the plugin. More...
 
virtual void setAboutMenuItem (const MenuItem &mi_)
 Sets the about box menu item for the plugin. More...
 
virtual MenuItem *const prefsMenuItem () const
 Gets the global prefs menu item for the plugin. More...
 
virtual void setPrefsMenuItem (const MenuItem &mi_)
 Sets the global prefs menu item for the plugin. More...
 

Static Public Member Functions

static Plugin *const instance ()
 Allows access to the singleton Plugin instance object. More...
 

Friends

__MainError() PluginMain (const char *, const char *, void *)
 Main entry point for all plugins (required by Illustrator). This is called whenever a plugin should perform some action or respond to some message. More...
 

Detailed Description

Base plugin class; the heart of any plugin project.

Receives startup/shutdown messages, tool messages, menu messages, etc.; allows for preference access, registration access, etc.

Member Function Documentation

virtual ModalDialog* const hdi::core::Plugin::aboutBox ( ) const
virtual

Gets the about box modal dialog for the plugin.

Author
GW
Date
09/2014
Returns
A pointer to the about box dialog for the plugin, or NULL if none/error
Note
See also the aboutMenuItem() method.
It is common for plugins to have about box modal dialogs that are shown when an "About <Your Plugin Name>" menu item is chosen; however, this process is not automated for the creator of the plugin as not all plugins necessitate this feature. The Plugin class merely offers a convenient place to store said dialog object.
virtual MenuItem* const hdi::core::Plugin::aboutMenuItem ( ) const
virtual

Gets the about box menu item for the plugin.

Author
GW
Date
09/2014
Returns
A pointer to the about box menu item for the plugin, or NULL if none/error
Note
See also the aboutBox() method.
It is common for plugins to have about box modal dialogs that are shown when an "About <Your Plugin Name>" menu item is chosen; however, this process is not automated for the creator of the plugin as not all plugins necessitate this feature. The Plugin class merely offers a convenient place to store said menu item object.
virtual Callback* const hdi::core::Plugin::brightnessAdjustedCallback ( ) const
virtual

Gets the callback that's called when the brightness of the Illustrator UI is changed via the app preference dialog.

Author
GW
Date
09/2013
Returns
The brightness adjusted callback
virtual Tool* const hdi::core::Plugin::currentTool ( ) const
virtual

Gets a pointer to the currently selected tool.

Author
GW
Date
09/2013
Returns
The currently selected tool, or NULL if none
virtual Dispatcher* const hdi::core::Plugin::dispatcher ( ) const
virtual

Convenience method to return the Dispatcher instance.

Author
GW
Date
09/2013
Returns
The plugin message dispatcher instance
virtual std::string hdi::core::Plugin::fileName ( ) const
virtual

Gets the name of the plugin file at runtime.

Author
GW
Date
09/2013
Returns
Plugin file name as UTF-8, e.g. "MyPlugin.aip"
virtual std::string hdi::core::Plugin::filePath ( ) const
virtual

Gets the full path of the plugin file at runtime.

Author
GW
Date
09/2013
Returns
Plugin file path as UTF-8, e.g. "/Applications/Adobe Illustrator CS6/Plug-ins/Tools/MyPlugin.aip"
virtual bool hdi::core::Plugin::hasPostStartedUp ( ) const
virtual

Gets whether the plugin has already completed post-starting up.

Author
GW
Date
04/2015
Returns
true if the postStartup callback has completed
virtual bool hdi::core::Plugin::hasPreShutdown ( ) const
virtual

Gets whether the plugin has already completed pre-shutting down.

Author
GW
Date
04/2015
Returns
true if the preShutdown callback has completed
virtual bool hdi::core::Plugin::hasShutdown ( ) const
virtual

Gets whether the plugin has already completed shutting down.

Author
GW
Date
04/2015
Returns
true if the shutdown callback has completed
virtual bool hdi::core::Plugin::hasStartedUp ( ) const
virtual

Gets whether the plugin has already completed starting up.

Author
GW
Date
04/2015
Returns
true if the startup callback has completed
static Plugin* const hdi::core::Plugin::instance ( )
static

Allows access to the singleton Plugin instance object.

Author
GW
Date
09/2013
Returns
The singleton Plugin object
virtual Callback* const hdi::core::Plugin::menuItemSelectedCallback ( ) const
virtual

Gets the callback that's called when a user selects one of the plugin's menu items.

Author
GW
Date
09/2013
Returns
The menu item selection callback
virtual Callback* const hdi::core::Plugin::menuItemsUpdateCallback ( ) const
virtual

Gets the callback that's called when a user hovers over menu groups that will show this plugin's menu items.

Author
GW
Date
09/2013
Returns
The menu items update callback
virtual std::string hdi::core::Plugin::name ( ) const
virtual

Gets the plugin name.

Author
GW
Date
09/2013
Returns
The plugin name, as UTF-8
virtual Options hdi::core::Plugin::options ( ) const
virtual

Gets the plugin's options.

Author
GW
Date
09/2013
Returns
Current plugin options
PlatformPluginPtr hdi::core::Plugin::platformPlugin ( ) const

Gets a pointer to the platform object representing the current Plugin instance.

Author
GW
Date
12/2015
Returns
A pointer to the platform object for the plugin instance (bundle on Mac, DLL on Windows)
virtual bool hdi::core::Plugin::postStartingUp ( ) const
virtual

Gets whether the plugin is in the process of post-starting up.

Author
GW
Date
04/2015
Returns
true if the postStartup callback is currently executing, false otherwise
virtual Callback* const hdi::core::Plugin::postStartupCallback ( ) const
virtual

Gets the callback that's called just after the plugin has started up.

Author
GW
Date
09/2013
Returns
The post-startup callback
virtual ModalDialog* const hdi::core::Plugin::prefsDialog ( ) const
virtual

Gets the global prefs modal dialog for the plugin.

Author
GW
Date
09/2014
Returns
A pointer to the prefs dialog for the plugin, or NULL if none/error
Note
See also the prefsMenuItem() method.
It is common for plugins to have global prefs modal dialogs that are shown when a "<Your Plugin Name> Preferences" menu item is chosen; however, this process is not automated for the creator of the plugin as not all plugins necessitate this feature. The Plugin class merely offers a convenient place to store said dialog object.
virtual MenuItem* const hdi::core::Plugin::prefsMenuItem ( ) const
virtual

Gets the global prefs menu item for the plugin.

Author
GW
Date
09/2014
Returns
A pointer to the prefs menu item for the plugin, or NULL if none/error
Note
See also the prefsDialog() method.
It is common for plugins to have global prefs modal dialogs that are shown when a "<Your Plugin Name> Preferences" menu item is chosen; however, this process is not automated for the creator of the plugin as not all plugins necessitate this feature. The Plugin class merely offers a convenient place to store said menu item object.
virtual Callback* const hdi::core::Plugin::preShutdownCallback ( ) const
virtual

Gets the callback that's called just before the plugin will shutdown.

Author
GW
Date
09/2013
Returns
The pre-shutdown callback
virtual bool hdi::core::Plugin::preShuttingDown ( ) const
virtual

Gets whether the plugin is in the process of pre-shutting down.

Author
GW
Date
04/2015
Returns
true if the preShutdown callback is currently executing, false otherwise
virtual bool hdi::core::Plugin::resourceData ( const int32_t  type_,
const int16_t  id_,
ByteVector &  data__ 
) const
virtual

Acquires a byte vector for a given resource.

Author
GW
Date
09/2013
Parameters
type_Type of resource (four-byte code, e.g. 'PNGI')
id_ID number of the resource
data__Return-by-reference for the resource data
Returns
true if the resource could be read, false otherwise
Note
A maximum size of 10MB is supported; resource data any larger will be truncated.
virtual bool hdi::core::Plugin::resourceData ( const int32_t  type_,
const std::string &  name_,
ByteVector &  data__ 
) const
virtual

Acquires a byte vector for a given resource.

Author
GW
Date
09/2013
Parameters
type_Type of resource (four-byte code, e.g. 'PNGI')
name_Name of the resource
data__Return-by-reference for the resource data
Returns
true if the resource could be read, false otherwise
Note
A maximum size of 10MB is supported; resource data any larger will be truncated.
virtual void hdi::core::Plugin::setAboutBox ( const ModalDialog dialog_)
virtual

Sets the about box modal dialog for the plugin.

Author
GW
Date
09/2014
Parameters
dialog_New about box modal dialog for the plugin
Note
See also the setAboutMenuItem() method.
It is common for plugins to have about box modal dialogs that are shown when an "About <Your Plugin Name>" menu item is chosen; however, this process is not automated for the creator of the plugin as not all plugins necessitate this feature. The Plugin class merely offers a convenient place to store said dialog object.
virtual void hdi::core::Plugin::setAboutMenuItem ( const MenuItem mi_)
virtual

Sets the about box menu item for the plugin.

Author
GW
Date
09/2014
Parameters
mi_New about box menu item for the plugin
Note
See also the setAboutBox() method.
Typically, one would want to place this menu item in the built-in group AboutMenuGroup.
It is common for plugins to have about box modal dialogs that are shown when an "About <Your Plugin Name>" menu item is chosen; however, this process is not automated for the creator of the plugin as not all plugins necessitate this feature. The Plugin class merely offers a convenient place to store said menu item object.
virtual void hdi::core::Plugin::setBrightnessAdjustedCallback ( const Callback cb_)
virtual

Sets the callback that's called when the brightness of the Illustrator UI is changed via the app preference dialog.

Author
GW
Date
09/2013
Parameters
cb_New brightness change callback
virtual void hdi::core::Plugin::setMenuItemSelectedCallback ( const Callback cb_)
virtual

Sets the callback that's called when a user selects one of the plugin's menu items.

Author
GW
Date
09/2013
Parameters
cb_New menu item selection callback
virtual void hdi::core::Plugin::setMenuItemsUpdateCallback ( const Callback cb_)
virtual

Sets the callback that's called when a user hovers over menu groups that will show this plugin's menu items.

Author
GW
Date
09/2013
Parameters
cb_New menu items update callback
virtual void hdi::core::Plugin::setName ( const std::string &  name_)
virtual

Sets the plugin name.

Author
GW
Date
09/2013
Parameters
name_The new plugin name, as UTF-8
virtual void hdi::core::Plugin::setOptions ( const Options  options_)
virtual

Sets the plugin's options.

Author
GW
Date
09/2013
Parameters
options_New options for the plugin
virtual void hdi::core::Plugin::setPostStartupCallback ( const Callback cb_)
virtual

Sets the callback that's called just after the plugin has started up.

Author
GW
Date
09/2013
Parameters
cb_New post-startup callback
virtual void hdi::core::Plugin::setPrefsDialog ( const ModalDialog dialog_)
virtual

Sets the global prefs modal dialog for the plugin.

Author
GW
Date
09/2014
Parameters
dialog_New global prefs modal dialog for the plugin
Note
See also the setPrefsMenuItem() method.
It is common for plugins to have global prefs modal dialogs that are shown when a "<Your Plugin Name> Preferences" menu item is chosen; however, this process is not automated for the creator of the plugin as not all plugins necessitate this feature. The Plugin class merely offers a convenient place to store said dialog object.
virtual void hdi::core::Plugin::setPrefsMenuItem ( const MenuItem mi_)
virtual

Sets the global prefs menu item for the plugin.

Author
GW
Date
09/2014
Parameters
mi_New global prefs menu item for the plugin
Note
See also the setPrefsDialog() method.
Typically, one would want to place this menu item in the built-in group PrefsMenuGroup.
It is common for plugins to have global prefs modal dialogs that are shown when a "<Your Plugin Name> Preferences" menu item is chosen; however, this process is not automated for the creator of the plugin as not all plugins necessitate this feature. The Plugin class merely offers a convenient place to store said menu item object.
virtual void hdi::core::Plugin::setPreShutdownCallback ( const Callback cb_)
virtual

Sets the callback that's called just before the plugin will shutdown.

Author
GW
Date
09/2013
Parameters
cb_New pre-shutdown callback
virtual void hdi::core::Plugin::setShutdownCallback ( const Callback cb_)
virtual

Sets the callback that's called when the plugin is shutting down.

Author
GW
Date
09/2013
Parameters
cb_New shutdown callback
virtual void hdi::core::Plugin::setStartupCallback ( const Callback cb_)
virtual

Sets the callback that's called when the plugin is starting up.

Author
GW
Date
09/2013
Parameters
cb_New startup callback
virtual void hdi::core::Plugin::setToolPostDeselectedCallback ( const Callback cb_)
virtual

Sets the callback that's called just after a tool is deselected (i.e. the tool's deselection callback has already been called)

Author
GW
Date
01/2015
Parameters
cb_New tool post-deselection callback
virtual void hdi::core::Plugin::setToolPostDiameterDecreasedCallback ( const Callback cb_)
virtual

Sets the callback that's called just after the '[' key is hit while a tool is selected (i.e. the tool's diameter decrease callback has already been called)

Author
GW
Date
01/2015
Parameters
cb_New tool diameter post-decreased callback
virtual void hdi::core::Plugin::setToolPostDiameterIncreasedCallback ( const Callback cb_)
virtual

Sets the callback that's called just after the ']' key is hit while a tool is selected (i.e. the tool's diameter increase callback has already been called)

Author
GW
Date
01/2015
Parameters
cb_New tool diameter post-increased callback
virtual void hdi::core::Plugin::setToolPostDraggedCallback ( const Callback cb_)
virtual

Sets the callback that's called just after the mouse button is down and the cursor moves (i.e. the tool's drag callback has already been called)

Author
GW
Date
01/2015
Parameters
cb_New tool post-dragging callback
virtual void hdi::core::Plugin::setToolPostEditedCallback ( const Callback cb_)
virtual

Sets the callback that's called just after a tool is double-clicked in the toolbar (i.e. the tool's edit callback has already been called)

Author
GW
Date
01/2015
Parameters
cb_New tool post-editing callback
virtual void hdi::core::Plugin::setToolPostMouseDownCallback ( const Callback cb_)
virtual

Sets the callback that's called just after the mouse button goes down (i.e. the tool's mouse down callback has already been called)

Author
GW
Date
01/2015
Parameters
cb_New tool post-mouse down callback
virtual void hdi::core::Plugin::setToolPostMouseUpCallback ( const Callback cb_)
virtual

Sets the callback that's called just after the mouse button comes up (i.e. the tool's mouse up callback has already been called)

Author
GW
Date
01/2015
Parameters
cb_New tool post-mouse up callback
virtual void hdi::core::Plugin::setToolPostReselectedCallback ( const Callback cb_)
virtual

Sets the callback that's called just after a tool is reselected (i.e. the tool's reselection callback has already been called)

Author
GW
Date
01/2015
Parameters
cb_New tool post-reselection callback
virtual void hdi::core::Plugin::setToolPostSelectedCallback ( const Callback cb_)
virtual

Sets the callback that's called just after a tool is selected from the toolbar (i.e. the tool's selection callback has already been called)

Author
GW
Date
09/2013
Parameters
cb_New tool post-selection callback
virtual void hdi::core::Plugin::setToolPostTrackedCallback ( const Callback cb_)
virtual

Sets the callback that's called just after the cursor moves (with the mouse button released; i.e. the tool's track callback has already been called)

Author
GW
Date
01/2015
Parameters
cb_New tool post-tracking callback
virtual void hdi::core::Plugin::setToolPreDeselectedCallback ( const Callback cb_)
virtual

Sets the callback that's called just before a tool is deselected (i.e. the tool's deselection callback has not been called)

Author
GW
Date
09/2013
Parameters
cb_New tool pre-deselection callback
virtual void hdi::core::Plugin::setToolPreDiameterDecreasedCallback ( const Callback cb_)
virtual

Sets the callback that's called just before the '[' key is hit while a tool is selected (i.e. the tool's diameter decrease callback has not been called)

Author
GW
Date
09/2013
Parameters
cb_New tool diameter pre-decreased callback
virtual void hdi::core::Plugin::setToolPreDiameterIncreasedCallback ( const Callback cb_)
virtual

Sets the callback that's called just before the ']' key is hit while a tool is selected (i.e. the tool's diameter increase callback has not been called)

Author
GW
Date
09/2013
Parameters
cb_New tool diameter pre-increased callback
virtual void hdi::core::Plugin::setToolPreDraggedCallback ( const Callback cb_)
virtual

Sets the callback that's called just before the mouse button is down and the cursor moves (i.e. the tool's drag callback has not been called)

Author
GW
Date
09/2013
Parameters
cb_New tool pre-dragging callback
virtual void hdi::core::Plugin::setToolPreEditedCallback ( const Callback cb_)
virtual

Sets the callback that's called just before a tool is double-clicked in the toolbar (i.e. the tool's edit callback has not been called)

Author
GW
Date
09/2013
Parameters
cb_New tool pre-editing callback
virtual void hdi::core::Plugin::setToolPreMouseDownCallback ( const Callback cb_)
virtual

Sets the callback that's called just before the mouse button goes down (i.e. the tool's mouse down callback has not been called)

Author
GW
Date
09/2013
Parameters
cb_New tool pre-mouse down callback
virtual void hdi::core::Plugin::setToolPreMouseUpCallback ( const Callback cb_)
virtual

Sets the callback that's called just before the mouse button comes up (i.e. the tool's mouse up callback has not been called)

Author
GW
Date
09/2013
Parameters
cb_New tool pre-mouse up callback
virtual void hdi::core::Plugin::setToolPreReselectedCallback ( const Callback cb_)
virtual

Sets the callback that's called just before a tool is reselected (i.e. the tool's reselection callback has not been called)

Author
GW
Date
09/2013
Parameters
cb_New tool pre-reselection callback
virtual void hdi::core::Plugin::setToolPreSelectedCallback ( const Callback cb_)
virtual

Sets the callback that's called just before a tool is selected from the toolbar (i.e. the tool's selection callback has not been called)

Author
GW
Date
09/2013
Parameters
cb_New tool pre-selection callback
virtual void hdi::core::Plugin::setToolPreTrackedCallback ( const Callback cb_)
virtual

Sets the callback that's called just before the cursor moves (with the mouse button released; i.e. the tool's track callback has not been called)

Author
GW
Date
09/2013
Parameters
cb_New tool pre-tracking callback
virtual void hdi::core::Plugin::setToolsSnapToArt ( const bool  snap_)
virtual

Sets whether tools belonging to this plugin should snap the cursor to artwork.

Author
GW
Date
09/2013
Parameters
snap_true if tools should snap the cursor to artwork, false otherwise
virtual void hdi::core::Plugin::setToolsSnapToArtboard ( const bool  snap_)
virtual

Sets whether tools belonging to this plugin should snap the cursor to the artboard edges.

Author
GW
Date
09/2013
Parameters
snap_true if tools should snap the cursor to artboard edges, false otherwise
virtual void hdi::core::Plugin::setToolsSnapToArtBounds ( const bool  snap_)
virtual

Sets whether tools belonging to this plugin should snap the cursor to artwork bounds.

Author
GW
Date
09/2013
Parameters
snap_true if tools should snap the cursor to artwork bounds, false otherwise
virtual void hdi::core::Plugin::setToolsSnapToGrids ( const bool  snap_)
virtual

Sets whether tools belonging to this plugin should snap the cursor to the Illustrator gridlines.

Author
GW
Date
09/2013
Parameters
snap_true if tools should snap the cursor to gridlines, false otherwise
virtual bool hdi::core::Plugin::setUndoKind ( const UndoContext  uc_)
virtual

Changes the undo context to another type.

Author
GW
Date
12/2014
Parameters
uc_New undo context
Returns
true if the context was changed, false otherwise
virtual Callback* const hdi::core::Plugin::shutdownCallback ( ) const
virtual

Gets the callback that's called when the plugin is shutting down.

Author
GW
Date
09/2013
Returns
The shutdown callback
virtual bool hdi::core::Plugin::shuttingDown ( ) const
virtual

Gets whether the plugin is in the process of shutting down.

Author
GW
Date
04/2015
Returns
true if the shutdown callback is currently executing, false otherwise
virtual SPPluginRef hdi::core::Plugin::spPluginRef ( ) const
virtual

Gets the plugin ref around which the target object is wrapped.

Author
GW
Date
11/2013
Returns
SPPluginRef for the target object
Note
Generally, you shouldn't need to call this method. Only use it if you know what you're doing. If a specific piece of functionality provided by Illustrator is not handled by this class (or related classes), then it should probably be added to the hdi_core library.
virtual bool hdi::core::Plugin::startingUp ( ) const
virtual

Gets whether the plugin is in the process of starting up.

Author
GW
Date
04/2015
Returns
true if the startup callback is currently executing, false otherwise
virtual Callback* const hdi::core::Plugin::startupCallback ( ) const
virtual

Gets the callback that's called when the plugin is starting up.

Author
GW
Date
09/2013
Returns
The startup callback
virtual Callback* const hdi::core::Plugin::toolPostDeselectedCallback ( ) const
virtual

Gets the callback that's called just after a tool is deselected (i.e. the tool's deselection callback has already been called)

Author
GW
Date
01/2015
Returns
The tool post-deselected callback
virtual Callback* const hdi::core::Plugin::toolPostDiameterDecreasedCallback ( ) const
virtual

Gets the callback that's called just after the '[' key is hit while a tool is selected (i.e. the tool's diameter decrease callback has already been called)

Author
GW
Date
01/2015
Returns
The tool diameter post-decreased callback
virtual Callback* const hdi::core::Plugin::toolPostDiameterIncreasedCallback ( ) const
virtual

Gets the callback that's called just after the ']' key is hit while a tool is selected (i.e. the tool's diameter increase callback has already been called)

Author
GW
Date
01/2015
Returns
The tool diameter post-increased callback
virtual Callback* const hdi::core::Plugin::toolPostDraggedCallback ( ) const
virtual

Gets the callback that's called just after the mouse button is down and the cursor moves (i.e. the tool's drag callback has already been called)

Author
GW
Date
01/2015
Returns
The tool post-dragged callback
virtual Callback* const hdi::core::Plugin::toolPostEditedCallback ( ) const
virtual

Gets the callback that's called just after a tool is double-clicked in the toolbar (i.e. the tool's edit callback has already been called)

Author
GW
Date
01/2015
Returns
The tool post-edited callback
virtual Callback* const hdi::core::Plugin::toolPostMouseDownCallback ( ) const
virtual

Gets the callback that's called just after the mouse button goes down (i.e. the tool's mouse down callback has already been called)

Author
GW
Date
01/2015
Returns
The tool post-mouse down callback
virtual Callback* const hdi::core::Plugin::toolPostMouseUpCallback ( ) const
virtual

Gets the callback that's called just after the mouse button comes up (i.e. the tool's mouse up callback has already been called)

Author
GW
Date
01/2015
Returns
The tool post-mouse up callback
virtual Callback* const hdi::core::Plugin::toolPostReselectedCallback ( ) const
virtual

Gets the callback that's called just after a tool is reselected (i.e. the tool's reselection callback has already been called)

Author
GW
Date
01/2015
Returns
The tool post-reselected callback
virtual Callback* const hdi::core::Plugin::toolPostSelectedCallback ( ) const
virtual

Gets the callback that's called just after a tool is selected from the toolbar (i.e. the tool's selection callback has already been called)

Author
GW
Date
09/2013
Returns
The tool post-selected callback
virtual Callback* const hdi::core::Plugin::toolPostTrackedCallback ( ) const
virtual

Gets the callback that's called just after the cursor moves (with the mouse button released; i.e. the tool's track callback has already been called)

Author
GW
Date
01/2015
Returns
The tool post-tracked callback
virtual Callback* const hdi::core::Plugin::toolPreDeselectedCallback ( ) const
virtual

Gets the callback that's called just before a tool is deselected (i.e. the tool's deselection callback has not been called)

Author
GW
Date
09/2013
Returns
The tool pre-deselected callback
virtual Callback* const hdi::core::Plugin::toolPreDiameterDecreasedCallback ( ) const
virtual

Gets the callback that's called just before the '[' key is hit while a tool is selected (i.e. the tool's diameter decrease callback has not been called)

Author
GW
Date
09/2013
Returns
The tool diameter pre-decreased callback
virtual Callback* const hdi::core::Plugin::toolPreDiameterIncreasedCallback ( ) const
virtual

Gets the callback that's called just before the ']' key is hit while a tool is selected (i.e. the tool's diameter increase callback has not been called)

Author
GW
Date
09/2013
Returns
The tool diameter pre-increased callback
virtual Callback* const hdi::core::Plugin::toolPreDraggedCallback ( ) const
virtual

Gets the callback that's called just before the mouse button is down and the cursor moves (i.e. the tool's drag callback has not been called)

Author
GW
Date
09/2013
Returns
The tool pre-dragged callback
virtual Callback* const hdi::core::Plugin::toolPreEditedCallback ( ) const
virtual

Gets the callback that's called just before a tool is double-clicked in the toolbar (i.e. the tool's edit callback has not been called)

Author
GW
Date
09/2013
Returns
The tool pre-edited callback
virtual Callback* const hdi::core::Plugin::toolPreMouseDownCallback ( ) const
virtual

Gets the callback that's called just before the mouse button goes down (i.e. the tool's mouse down callback has not been called)

Author
GW
Date
09/2013
Returns
The tool pre-mouse down callback
virtual Callback* const hdi::core::Plugin::toolPreMouseUpCallback ( ) const
virtual

Gets the callback that's called just before the mouse button comes up (i.e. the tool's mouse up callback has not been called)

Author
GW
Date
09/2013
Returns
The tool pre-mouse up callback
virtual Callback* const hdi::core::Plugin::toolPreReselectedCallback ( ) const
virtual

Gets the callback that's called just before a tool is reselected (i.e. the tool's reselection callback has not been called)

Author
GW
Date
09/2013
Returns
The tool pre-reselected callback
virtual Callback* const hdi::core::Plugin::toolPreSelectedCallback ( ) const
virtual

Gets the callback that's called just before a tool is selected from the toolbar (i.e. the tool's selection callback has not been called)

Author
GW
Date
09/2013
Returns
The tool pre-selected callback
virtual Callback* const hdi::core::Plugin::toolPreTrackedCallback ( ) const
virtual

Gets the callback that's called just before the cursor moves (with the mouse button released; i.e. the tool's track callback has not been called)

Author
GW
Date
09/2013
Returns
The tool pre-tracked callback
virtual bool hdi::core::Plugin::toolsSnapToArt ( ) const
virtual

Gets whether tools belonging to this plugin should snap the cursor to artwork.

Author
GW
Date
09/2013
Returns
true if tools should snap the cursor to artwork, false otherwise
Note
This is merely an indicator of whether snapping will occur (it happens automatically); the caller need not manually snap anything.
virtual bool hdi::core::Plugin::toolsSnapToArtboard ( ) const
virtual

Gets whether tools belonging to this plugin should snap the cursor to the artboard edges.

Author
GW
Date
09/2013
Returns
true if tools should snap the cursor to artboard edges, false otherwise
Note
This is merely an indicator of whether snapping will occur (it happens automatically); the caller need not manually snap anything.
virtual bool hdi::core::Plugin::toolsSnapToArtBounds ( ) const
virtual

Gets whether tools belonging to this plugin should snap the cursor to artwork bounds.

Author
GW
Date
09/2013
Returns
true if tools should snap the cursor to artwork bounds, false otherwise
Note
This is merely an indicator of whether snapping will occur (it happens automatically); the caller need not manually snap anything.
virtual bool hdi::core::Plugin::toolsSnapToGrids ( ) const
virtual

Gets whether tools belonging to this plugin should snap the cursor to the Illustrator gridlines.

Author
GW
Date
09/2013
Returns
true if tools should snap the cursor to gridlines, false otherwise
Note
This is merely an indicator of whether snapping will occur (it happens automatically); the caller need not manually snap anything.
virtual void hdi::core::Plugin::undo ( ) const
virtual

Undoes the last set of artwork changes by this specific plugin.

Author
GW
Date
09/2013

Friends And Related Function Documentation

__MainError() PluginMain ( const char *  ,
const char *  ,
void *   
)
friend

Main entry point for all plugins (required by Illustrator). This is called whenever a plugin should perform some action or respond to some message.

Author
GW
Date
09/2013