blob: 861b64a5ec6346762950ab03bf94b917f38c4ca6 [file] [log] [blame]
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<meta name="GENERATOR" content="Microsoft FrontPage 4.0">
<meta name="ProgId" content="FrontPage.Editor.Document">
<title>Unicode Character Database</title>
table { padding: 4 }
td { padding: 4 }
<span class="cb" id style="DISPLAY: block">
<h1 align="center">Unicode Character Database (UCD) in XML Format</h1>
<h1 align="center"><b><font color="#FF0000">WARNING: FORMAT IS DRAFT!</font></b></h1>
<p align="center">MD 2000.10.16</p>
<table border="1" width="40%" align="right" cellspacing="4" cellpadding="0">
<td width="100%" bgcolor="#C0C0C0"><span class="cb" id
style="DISPLAY: block">
<h4 align="center">Using Internet Explorer</h4>
<p>The UCD-Main.xml file can be read in Internet Explorer (5.0 and above).
<li>It may take a few minutes to load completely.</li>
<li>The XML parser in IE does not appear to be conformant: it seems to
break on</span> the following valid code points (and others):
<p><a href="UCD-Main.xml">UCD-Main.xml</a> provides an XML format for the main
files in the Unicode Character Database. These include:</p>
<p>Other files in the UCD have very different structure or purpose, and are best
expressed with separate files. Some annotational data, such as that in
NamesList.txt or the 10646 comment in UnicodeData, is also best served with
separate files. The current UCD files not yet in XML format are:</p>
<p>The Unicode blocks are provided as a list of &lt;block .../&gt; elements,
with attributes providing the start, end, and name.</p>
<p>Each assigned code point is a &lt;e .../&gt; element, with attributes
supplying specific properties. The meaning of the attributes is specified below.
There is one exception: large ranges of code points&nbsp; for characters such as
Hangul Syllables are abbreviated by indicating the start and end of the range.</p>
<p>Because of the volume of data, the attribute names are abbreviated. A <a
href="#AttributeAbbreviations">key</a> explains the abbreviations, and relates
them to the fields and values of the original UCD semicolon-delimited files.
With few exceptions, the values in the XML are directly copied from data in the
original UCD semicolon-delimited files. Those exceptions are described <a
<p>Numeric character references (NCRs) are used to encode the Unicode code
points. Some Unicode code points cannot be transmitted in XML, even as NCRs (see
<a href=""></a>),
or would not be visibly distinct (TAB, CR, LF) in the data. Such code points are
represented by '#xX;', where X is a hex number.</p>
<h3><a name="AttributeAbbreviations">Attribute Abbreviations</a></h3>
<p>To reduce the size of the document, the following attribute abbreviations are
used. If an attribute is missing, that means it gets a default value. The
defaults are listed in parentheses below. If there is no specific default, then
a missing attribute should be read as N/A (not applicable). A default with '='
means the default is the value of another other field (recursively!). Thus if
the titlecase attribute is missing, then the value is the same as the uppercase.
If that in turn is missing, then the value is the same as the code point itself.</p>
<p>For a description of the source files, see <a
That file also has links to the descriptions of the fields within the files.
Since the PropList values are so long, they will probably also be abbreviated in
the future.</p>
<table border="1" width="100%">
<td width="50%" valign="top"><span class="cb" id style="DISPLAY: block">
<p>&nbsp; c: code point<br>
&nbsp; n: name<br>
&nbsp; gc: general category (Lo)<br>
&nbsp; cc: combining class (0)<br>
&nbsp; bc: bidi category (L)<br>
&nbsp; dm: decomposition mapping<br>
&nbsp; dt: decomposition type (canonical)<br>
&nbsp; nt: numeric type<br>
&nbsp; nv: numeric value<br>
&nbsp; bm: bidi mirrored (N)<br>
&nbsp; uc: uppercase (=c)<br>
&nbsp; lc: lowercase (=c)<br>
&nbsp; tc: titlecase (=uc)</p>
<p>&nbsp; sl: special lower (=lc)<br>
&nbsp; su: special upper (=uc)<br>
&nbsp; st: special title (=su)<br>
&nbsp; sc: special case condition</p>
<p>&nbsp; fc: foldcase (=sl)</span></td>
<td width="50%" valign="top"><span class="cb" id style="DISPLAY: block">
<p>&nbsp; ce: composition exclusion (N)</p>
<p>&nbsp; ea: east asian width (N)</p>
<p>&nbsp; jn: jamo name</p>
<p>&nbsp; lb: line break class (AL)</p>
<p>&nbsp; jt: joining type<br>
&nbsp; jg: joining group</p>
<p>&nbsp; bg: bidi mirroring glyph (=c)</p>
<p>&nbsp; xs: space-delimited list of properties from the file</p>
<p><b><i>WARNING: these values are likely to change!</i></b></span></td>
<h3><a name="DataModifications">Data Modifications</a></h3>
<p>The XML format is generated from the original semicolon-delimited UCD files.
In general, all fields and values are direct copies. However, there are some
changes, detailed below.</p>
<h4>1. Some redundant or annotational fields are omitted</h4>
<table border="1" width="100%">
<td width="50%" valign="top"><b>UnicodeData<br>
</b>1.0 Name<br>
10646 comment<br>
</b>Type (since it is computable from whether the fold equals the normal
<td width="50%" valign="top"><b>PropList</b><font face="Times New Roman"
<p>The fields are based on the proposed PropList.alpha, which changes the
fields considerably.</p>
<p><span class="cb" id style="display: block"><b><i>WARNING: other values
are also likely to change!</i></b></span></p>
<h4>2. Some fields are broken into several fields; others may be combined into a
single field</h4>
<li><b>dt: </b>decomposition tag
<li>the 'tag' field extracted from the decomposition mapping. If there is
no tag, the value is &quot;canonical&quot;. Only has meaning if there is
a decomposition (<b>dm</b>).</li>
<li><b>nt: </b>numeric type
<li>an enumeration [decimal, digit, numeric] for the type of number. It
replaces having duplicate field values for numbers</li>
<li><b>rg: </b>range
<li>used for ranges of values that share characteristics, instead of
having to do a substring check.<br>
&quot;START&quot; corresponds to &quot;&lt;..., First&gt;&quot;<br>
&quot;END&quot; corresponds to &quot;&lt;..., Last&gt;&quot;</li>
<li><b>nc: </b>name computed
<li>if &quot;COMPUTED&quot;, indicates that the name must be computed:
e.g. Hangul Syllables, Ideographs</li>
<li><b>na: </b>name annotation
<li>used for code points that do not really have associated names, like
control characters and private use characters. The data in that case is
either extracted from the &quot;&lt;...&gt;&quot; style name in the old
format, or gotten from the &quot;1.0 Unicode name&quot;.</li>