Understanding the config.xml


Summary
The config.xml file is used to describe the static aspects of a given add-in, including captions, ToolTips, Help information, images, and initial layout details. This topic examines the Extensible Markup Language (XML) at a high-level to educate the developer of what is being generated by Eclipse's add-in editor.

In this topic


About the config.xml file

This topic guides you through a high-level discussion on the add-in editor's source view. The XML configuration file is almost identical for each of the ArcGIS for Desktop products supported by the add-in framework; therefore, this topic only illustrates ArcMap as an example. The places where the desktop application defines a difference is noted in the topic. Finally, each example uses simple scenarios to avoid cluttering the discussion. This topic is broken out into sections that match each of the how to topics that describe the workflow for defining your add-ins.
When creating an add-in project, as discussed in How to create an add-in project in Eclipse, there are various properties that you have the ability to set (for example, add-in project name, description, and so on). The properties defined under the add-in overview section of the Eclipse add-in editor view essentially represent the project's metadata, and is used in various places for end users using your customizations.
Behind the scenes, when the values of the properties are being completed, the editor is generating XML that can be viewed in the source view of the config.xml file. For example, if an ArcMap project is created and properties are set for all of the required and optional parameters, the add-in and source views will resemble the following screen shot:

The preceding screen shot represents the graphical user interface (GUI) view of the editor for the config.xml file. The sample GUI is represented as follows in the source view:

Take a moment to do a quick comparison between the GUI and the XML. You will notice that many of the XML tags match what is shown on the GUI. However, some additional items are added to describe the software version the add-in will be used with as a couple examples. Line numbers have been included on the screen shot and will be referenced in the discussion that describes these additional tags.
It is not possible to specify ArcGIS Engine as the target instead of ArcGIS for Desktop. The add-in framework is currently only supported with ArcGIS for Desktop products (specifically ArcMap, ArcCatalog, ArcGlobe, and ArcScene).
The XML syntax image is syntactically colored to make the XML more readable; however, the source view uses a normal text editor and syntax highlighting is not available.
Once a project is defined and set up, the next step in the workflow is to define your customizations. Each section discusses each individual type of add-in and explores the available topic examples.

Understanding the button XML

When creating a button, there are various properties that are set in the Button Details section of the editor. The properties defined under the Button Details represent the static information of your add-in. Behind the scenes, the XML is being generated to represent these static properties. For example, if an add-in button is created and defined with the following parameters, the add-in and source views will resemble the following screen shot:

The preceding screen shot represents the add-in view of the add-in editor for the config.xml file when defining the properties for a button. The same GUI is represented as follows in the source view:

Take a moment to do a quick comparison between the GUI and the XML. Notice that many of the XML tags and attributes match what is shown on the GUI. Notice that the XML that defines the button is wrapped in the ArcMap tag. The following descriptions use specific line numbers to highlight some additional features of the displayed XML:

Understanding the tool XML

When creating a tool, there are various properties that are set in the Tool Details section of the add-in editor. The properties defined under the Tool Details section represent the static information of your add-in. Behind the scenes, the XML is being generated to represent these static properties. For example, if a tool is created and defined with the following parameters, the add-in and source views will resemble the following screen shot:

The preceding screen shot represents the add-in view of the editor for the config.xml file when defining the properties for a tool. The sample GUI is represented as follows in the source view:

Take a moment to do a quick comparison between the GUI and the XML. Notice that many of the XML tags and attributes match what is shown on the GUI. Notice that the XML that defines the tool are wrapped in the ArcMap tags. The following descriptions use specific line numbers to highlight some additional features of the displayed XML:

Understanding the tool palette XML

When creating tool palette, there are various properties that are set on the Tool Palette Details section of the add-in editor. The properties defined on the Tool Palette Details section represent the static information of your add-in. Behind the scenes, the XML is generated to represent these static properties. For example, if a tool palette is created and defined with the parameters on the following screen shot, the add-in and source views will resemble the following:
The preceding screen shot represents the add-in view of the editor for the config.xml file when defining the properties for a tool palette. The same GUI is represented as follows in the source view:

Take a moment to do a quick comparison between the GUI and the XML. Notice that many of the XML tags and attributes match what is shown on the GUI. Notice that the XML that defines the tool palette with the opening and closing ArcMap tags. The following descriptions use specific line numbers to highlight some additional features of the displayed XML:

Understanding the toolbar XML

When creating a toolbar, there are various properties that are set on the Toolbar Details section of the add-in editor. The properties defined under the Toolbar Details section, represent the static information of your add-in. Behind the scenes, the XML is generated to represent these static properties. For example, if an add-in toolbar is created and defined with the following parameters, the add-in and source views will resemble the following:

The preceding screen shot represents the add-in view of the editor for the config.xml file when defining the properties for a toolbar. The same GUI is represented as follows in the source view:

Take a moment to do a quick comparison between the GUI and the XML. Notice that many of the XML tags and attributes match what is shown on the GUI. Notice the XML that defines the toolbar. The following descriptions use specific line numbers to highlight some additional features of the displayed XML:

Understanding the menu XML

When creating a menu, there are a number of properties that are set on the Menu Details section of the add-in editor. The properties defined under the Menu Details section represent the static information of your add-in. Behind the scenes, the XML is generated to represent these static properties. For example, if a menu is created and defined with the parameters on the following screen shot, the add-in and source views will resemble the following:
The preceding screen shot represents the add-in view of the editor for the config.xml file when defining the properties for a menu. The same GUI is represented as follows in the source view:

Take a moment to do a quick comparison between the GUI and the XML. Notice that many of the XML tags and attributes match what is shown on the GUI. Notice the XML that defines the menu. The following descriptions use specific line numbers to highlight some additional features of the displayed XML:

Understanding the combo box XML

When creating a combo box, there are various properties that are set on the Combo Box Details section of the add-in editor. The properties defined under the Combo Box Details section represent the static information of your add-in. Behind the scenes, the XML is generated to represent these static properties. For example, if a combo box is created and defined with the parameters on the following screen shot, the add-in and source views will resemble the following:

The preceding screen shot represents the add-in view of the editor for the config.xml file when defining the properties for a combo box. The same GUI is represented as follows in the source view:

Take a moment to do a quick comparison between the GUI and the XML. Notice that many of the XML tags and attributes match what is shown on the GUI. Notice the XML that defines the combo box. The following descriptions use specific line numbers to highlight some additional features of the displayed XML:

Understanding the dockable window XML

When creating a dockable window, there are various properties that are set on the Dockable Window Details section of the add-in editor. The properties defined under the Dockable Window Details section represent the static information of your add-in. Behind the scenes, the XML is generated to represent these static properties. For example, if a dockable window is created and defined with the parameters on the following screen shot, the add-in and source views will resemble the following:

The preceding screen shot represents the add-in view of the editor for the config.xml file when defining the properties for a dockable window. The same GUI is represented as follows in the source view:

Take a moment to do a quick comparison between the GUI and the XML. Notice that many of the XML tags and attributes match what is shown on the GUI. Notice the XML that defines the dockable window. The following descriptions use specific line numbers to highlight some additional features of the displayed XML:

Understanding the application extension XML

When creating an application extension, there are various properties that are set on the Extension Details section of the add-in editor. The properties defined under the Extension Details section represent the static information of your add-in. Behind the scenes, the XML is generated to represent these static properties. For example, if an application extension is created and defined with the parameters on the following screen shot, the add-in and source views will resemble the following:

The preceding screen shot represents the add-in view of the editor for the config.xml file when defining the properties for an application extension. The sample GUI is represented as follows in the source view:
Take a moment to do a quick comparison between the GUI and the XML. Notice that many of the XML tags and attributes match what is shown on the GUI. Notice the XML that defines the application extension. The following descriptions use specific line numbers to highlight some additional features of the displayed SML:


See Also:

How to create an add-in button
How to create an add-in tool
How to create an add-in combo box
How to create an add-in toolbar
How to create an add-in tool palette
How to create an add-in menu
How to create an add-in dockable window
How to create an add-in application extension




Development licensingDeployment licensing
ArcGIS for Desktop BasicArcGIS for Desktop Basic
ArcGIS for Desktop StandardArcGIS for Desktop Standard
ArcGIS for Desktop AdvancedArcGIS for Desktop Advanced