4.12 Reviewing the XML-Specific Document Options

So far, we've introduced a number of different XML-related document options in various contexts. Now let's take a look at them together, including some new ones. You can configure most of these through the XML Options dialog. Figure 4-22 shows the XML Options dialog with the default XML settings. To open this dialog, select Tools Templates and Add-Ins XML Schema XML Options.

Figure 4-22. The XML Options dialog

The options in Figure 4-22 correspond to these elements in WordprocessingML:

  1. w:removeWordSchemaOnSave When enabled, Word removes all Word-specific markup from the document when saving.

  2. w:useXSLTWhenSaving When enabled, Word applies an XSLT stylesheet to the document when saving.

  3. w:saveThroughXSLT When the "Apply custom transform" option is on, this element's w:xslt attribute determines what stylesheet will be applied.

  4. w:validateAgainstSchema When enabled, Word validates the document while the user is editing it. This option is turned on by default unless explicitly turned off.

  5. w:doNotUnderlineInvalidXML When enabled, Word does not display validation errors in the document being edited.

  6. w:ignoreMixedContent When checked, Word strips out mixed content text for the purpose of validation, as well as for the purpose of saving (when the "Save data only" option is on).

  7. w:saveInvalidXML When checked, Word will not disallow the user from saving a document as XML even though the embedded XML document is invalid according to its schema.

  8. w:alwaysShowPlaceholderText When checked, Word automatically displays the name of each empty leaf element as placeholder text when "Show XML tags" is turned off, and when the element does not explicitly specify its own placeholder text.

Except for the w:saveThroughXSLT element, all of these options are Boolean options. Each of their corresponding elements is defined in the WordprocessingML schema to use the onOffProperty type, which means that it is an empty element and that it has a w:val attribute whose value can be either on or off. When the element is present but the attribute is absent, then it defaults to on.

The other two checkboxes listed under "XML view options" in Figure 4-22 are not document-specific options and so do not have a WordprocessingML representation.

Office 2003 XML
Office 2003 XML
ISBN: 0596005385
EAN: 2147483647
Year: 2003
Pages: 135

Similar book on Amazon

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net