Home Forums DITA and XMetaL Discussion Controlled Drop-Down Lists for Attribute Inspector othermeta element Reply To: Controlled Drop-Down Lists for Attribute Inspector othermeta element

Derek Read

Reply to: Controlled Drop-Down Lists for Attribute Inspector othermeta element

That forum example should work in versions up to 13 (and continue to work thereafter). In general, customizations for older versions will continue to work for newer ones (provided APIs are used in the way they were designed). However, for DITA, and because you are asking specifically about subject schemes, I don't think that's the best option. For non-DITA DTDs I would still recommend that demo as a starting point (but see “Non-DITA” below). The DITA authoring customization also does not generally support this level of modification (as it is easy to break existing features when adding script).

DITA Subject Schemes:
Your best option might be to upgrade to XMetaL Author Enterprise version 13. In version 13 we added support for working with DITA subject schemes. You can create them (as a DITA document), manage them, and attach them to maps and topics. Once you have attached one to a document the values for that scheme are listed in the Attribute Inspector for the particular attributes defined in the subject scheme. The resulting UI is the same as you see for an attribute with enumerated values (ie: when the DTD defines an enumerated list of values for the attribute and not simply CDATA). If you download the trial version from the xmetal.com website you will get the current release (which is as of this posting version 13). Two new items appear on the Reuse menu (“Apply/Remove Subject Scheme” and “Show subjectScheme Manager”) and the documentation discusses the feature as well. If you try this feature, I would recommend using the example subjectScheme listed in the DITA documentation for the topic to start with (this is accessible via our F1 help, just search for “subjectScheme”).

For Non-DITA:
If that post's example looks like it would help then base whatever you want to create on it. The form will need modification to match the attribute and it's values, and you might want to trigger the form another way, perhaps by letting the user double click on the element, select it from a toolbar/menu, open it with a shortcut key, etc.

Another option (assuming you have control of / permission to modify the DTD or W3C Schema) is to modify the attribute to be an enumerated list. In this case the Attribute Inspector will list only those values allowed by the DTD or W3C Schema. Of course, this pretty much rules out DITA specialization as it suggests basing new attributes on @props and @base, which are themselves CDATA.

Reply

Products
Downloads
Support