Importing and exporting templates
You can import and export templates.
Note: A template must be an .xml file formatted as follows:
<?xml version="1.0" encoding="UTF-8" ?> <templates> <template name="author" description="author name" context="C" enabled="true">author ${user}</template> </templates>
To import a template
- Click Window > Preferences.
- Expand C/C++, expand Editor and click Templates.
- Click Import.
- Select the template file that you want to import.
- Click OK.
The template list is updated to include the template that you imported.
To export a template
- Click Window > Preferences.
- Expand C/C++, expand Editor and click Templates.
- Select the templates that you want to export and click the Export... button. The Export Templates dialog opens.
- In File name box, type the path where you want your templates file to be saved.
- Click Save.
The templates.xml file containing the templates you exported is saved in your file system.
Using Content Assist
Creating and editing templates