Previous | Table of Contents | Next |
This declaration is constructed according to the syntax illustrated in figure 16.7. In this example, the SGML keyword NOTATION identifies the declaration type. The name of the notation being declared is listed following the keyword (indicated by not-type). The notation identifier can be either SYSTEM or PUBLIC.
Fig. 16.7 The NOTATION declaration.
Note:
SYSTEM identifiers are used to specify system-specific data objects (commonly through the use of a system-specific identifier such as c;\caution2a.dat).PUBLIC identifiers are used to specify data objects with a mechanism that is usable across various computer systems or software environments. A PUBLIC identifier can be identified in a way that has a registered owner associated with it. Through the use of such formal PUBLIC identifiers, the uniqueness of a data object can be preserved.
To use a declared NOTATION in an element, link it to the element in an attribute list. For example, to use it for equations, you might use the commonly available TeX equation editor in the following way:
<!NOTATION TeX SYSTEM > <!ELEMENT Pcurve - - CDATA> <!ATTLIST Pcurve form NOTATION TeX>
In the past, people working in SGML often found themselves in the position of putting tags into documents by hand. In a lot of cases, it was the path of least resistance for getting many documents converted into SGML.
Fortunately, the SGML world has changed a great deal in just a few short years. Today, a great many tools are becoming available to help automate the process. However, the situation may still arise where you find yourself faced with the need to pound out some tags manually.
The short reference (or shortref) provides you with the capability of using shorthand to reference longer, or more complex, text strings. If youre inputting your SGML text by hand (a not so common experience these days), you might use the shortref to aid you in defining such things as tags for tables (columns, rows, cells, and so on). It is most commonly used to map SGML tagging sequences to easily accessible keys on standard typewriter/computer style keyboards.
Be aware that the use of the shortref can be complex.
Because the shortref was more commonly used in the days before the existence of sophisticated SGML authoring tools, this chapter will not examine it in detail. Instead, youll get a brief overview of some of the issues involved with its use.
Through character set mapping, you can use the shortref to map standard, easily typed key patterns to specified SGML tags or tag fragments. Behind the curtains, this is accomplished through a linkage of entity references that are resolved during the parsing stage.
You can define your own mapping schemes or use those in the standard reference concrete syntax of SGML. Those included in the standard set are listed in table 16.3.
String | Usage |
---|---|
TAB; | Horizontal Tab |
RE; | Record End |
RS; | Record Start |
RS;B | Leading Blanks |
RS;RE; | Empty Record |
RS;BRE; | Blank Record |
BRE; | Trailing Blanks |
SPACE; | Space |
BB | Two or More Blanks |
" | Quotation Mark |
# | Number Sign |
% | Percent Sign |
' | Apostrophe |
( | Left Parenthesis |
) | Right Parenthesis |
* | Asterisk |
+ | Plus Sign |
, | Comma |
- | Hyphen |
- - | Two Hyphens |
: | Colon |
; | Semicolon |
= | Equal Sign |
@ | Commercial At |
[ | Left Square Bracket |
] | Right Square Bracket |
^ | Circumflex Accent |
_ | Low Line |
{ | Left Curly Bracket |
} | Right Curly Bracket |
| | Vertical Line |
~ | Tilde |
To use the shortref, you must include three components in the form of SGML markup declarations:
Note:
As previously mentioned, this look at shortref usage includes only a brief overview. For further information on shortrefs, the reader should reference the SGML standard, ISO 8879.
This concludes your look at tagging challenges and specialized content. Through the use of entities, you saw that you could easily reproduce standard text. You also saw how to produce conditional documents through the application of marked sections.
For more information, refer to the following:
Previous | Table of Contents | Next |