<?xml version="1.0" encoding="utf-8"?> | |
<!--Arbortext, Inc., 1988-2005, v.4002--> | |
<!DOCTYPE task PUBLIC "-//OASIS//DTD DITA Task//EN" | |
"task.dtd"> | |
<task id="txprefs" xml:lang="en-us"> | |
<title>Defining XML editor preferences</title> | |
<titlealts> | |
<searchtitle>Defining XML editor preferences</searchtitle> | |
</titlealts> | |
<shortdesc>You can set various preferences for the Source view of the XML | |
editor such as the formatter indentation style, line wrapping rules, and content | |
assist rules. To apply the formatting styles, right-click in in the Source | |
view for your XML document, and click <menucascade><uicontrol>Format</uicontrol> | |
<uicontrol>Document</uicontrol></menucascade>.</shortdesc> | |
<prolog><metadata> | |
<keywords><indexterm>XML editor<indexterm>preferences</indexterm></indexterm> | |
<indexterm>preferences<indexterm>XML editor</indexterm></indexterm> | |
</keywords> | |
</metadata></prolog> | |
<taskbody> | |
<context><p>To define XML preferences, perform the following steps:</p></context> | |
<steps> | |
<step><cmd>Click <menucascade><uicontrol>Window</uicontrol><uicontrol>Preferences</uicontrol> | |
<uicontrol>Web and XML</uicontrol><uicontrol>XML Files</uicontrol><uicontrol>XML | |
Source</uicontrol></menucascade>.</cmd></step> | |
<step><cmd>Enter a maximum width for formatted lines in the <uicontrol>Line | |
width</uicontrol> field</cmd><info>The default value is 72.</info></step> | |
<step><cmd>Select <uicontrol>Split multiple attributes each on a new line</uicontrol> to | |
start every attribute on a new line.</cmd></step> | |
<step><cmd>If you want blank lines to be removed when the document is formatted, | |
select the <uicontrol>Clear all blank lines</uicontrol> check box. </cmd> | |
<info>By default, blank lines are preserved in a formatted document.</info> | |
</step> | |
<step><cmd>Select <uicontrol>Indent using tabs</uicontrol> if you want to | |
use tab characters (\t) as the standard formatting indentation, or, if you | |
prefer to use spaces, select <uicontrol>Indent using spaces</uicontrol>.</cmd> | |
</step> | |
<step><cmd>You can also specify the <uicontrol>Indentation size</uicontrol> which | |
is the number of tabs or space characters used for formatting indentation.</cmd> | |
</step> | |
<step><cmd>You can specify certain characters ('<' is default) that will | |
cause the content assist list to pop up automatically. Ensure the <uicontrol>Automatically | |
make suggestions</uicontrol> check box is selected and specify the characters | |
in the <uicontrol>Prompt when these characters are inserted</uicontrol> field. </cmd> | |
</step> | |
<step><cmd>If you select <b>Strict</b> from the <b>Suggestion strategy</b> list, | |
suggestions that are grammatically valid will be shown first (with bold icons) | |
in the content assist list. Other suggestions that are applicable to the element | |
scope, but not grammatically valid, will be shown below them with a de-emphasized | |
icon. The default value for this field is <b>Strict</b>.</cmd></step> | |
<step><cmd>The <uicontrol>Use inferred grammar in absence of DTD/Schema</uicontrol> check | |
box is selected by default. </cmd><info>If this box is selected, when you | |
have an XML file that is not associated with a DTD or XML schema, you will | |
still be able to get content assist - the tool will infer what should come | |
next in your file based on the existing content.</info></step> | |
<step><cmd>Click <uicontrol>Apply</uicontrol> and then <uicontrol>OK</uicontrol> to | |
save your changes.</cmd></step> | |
</steps> | |
</taskbody> | |
</task> |