Edit online

Customizing the Content Completion Proposals

When editing an XML document either in the Text or Author editing modes, you can invoke the Content Completion Assistant (Ctrl+Space in Text mode or ENTER in Author mode) to see the allowed XML elements or attributes that can be inserted at the current location. The Elements view also presents the elements that can be inserted in the document at a certain location, while the Attributes view presents a list of allowed attributes and their values.

The content completion proposals can be customized in various ways:

  • Each framework can contain a special content completion configuration file. Such a file can:

    • Filter out element proposals for a parent element.

    • Configure a set of required attributes to be inserted along with a certain element.

    • Add new attribute value proposals and for each proposal, add an annotation that will appear in the Attributes view for each value.

    • Call an external XSLT script to compute value proposals for a certain attribute.

    • Customize how the element names are presented in the Outline view, Elements view, and Content Completion Assistant.

  • You can alter the schema that is associated with the XML document. For example, in the case of the DITA vocabulary, you can create a DTD specialization plugin and integrate it into Oxygen XML Editor.

  • You can use the SchemaManagerFilter API to filter the set of proposed elements and attribute values using Java code.