Saving and deleting schemes, Working with tags, Default tags – Slick EDIT V3.3 User Manual

Page 306: Base tags

Advertising
background image

Saving and Deleting Schemes

In the XML/HTML Formatting Scheme Configuration dialog, modified schemes are denoted by asterisks
around the name (for example, *html*). To save a modified scheme, right-click on it and select Save
Scheme Changes
. Alternatively, when you close the XML/HTML Formatting dialog, you are prompted
whether to save modified schemes.

To delete a selected scheme, right-click and choose Delete Scheme.

Working with Tags

As described previously, formatting schemes are comprised of individual tags with associated formatting
settings. For example, in HTML, you may want start and end <div> tags to be on separate lines above/be-
low the text, while start/end style tags (such as <b> and <i>) are formatted inline with the text.

In order to configure formatting for individual tags, you must first define a scheme (see

Creating

Schemes

), or you can use one of the default schemes (see

Default Schemes

). The Tags column of the

XML/HTML Formatting dialog shows a list of tags associated with the selected scheme.

Default Tags

For all schemes, a (default) tag is included. It defines the settings that are applied to tags that are not
specifically listed in the Tags list. It can also be used as a basis for other tags when you use the Match
tag style of
option on the General tab.

The default settings for the (default) tag are based on a block-style tag, in that the start and end tags are
on separate lines, content and nested tags are indented according to your extension indent style, and
content is wrapped to a fixed right margin at column 80. Use the Preview area at the bottom of the dialog
to see how tags based on the (default) tag will be formatted in your code.

Base Tags

Base tags are used to define groups of tags with similar behaviors. By creating a base tag and associat-
ing a set of actual tags with that tag, you can configure that set of tags by changing the settings for the
base tag. The sample HTML schemes included with SlickEdit

®

Core include two base tags: (block) and

(semi-block). When creating your own base tags, be sure to use unique tag names that are not used in
formatting to make it easy to spot them.

The (block) tag is useful as a base tag for tags like <div>, where you want the start and end tags on sep-
arate lines from the content and aligned vertically. By default, this style indents nested tags and content
according to your extension indent style, and content is wrapped to a fixed right margin at column 80. Be-
cause this is a common style in HTML, the (block) tag has the same settings as the (default) tag.

The (semi-block) tag is useful as a base tag for tags such as <h1>, where you want the start and end
tags on the same line as the content. The default settings for (semi-block) are the same as for (block),
except for the start and end tags.

Use the Preview area at the bottom of the dialog to see how tags based on these base tags will be

Working with Tags

284

Advertising