xmlgraphics-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From build...@apache.org
Subject svn commit: r841657 - in /websites/staging/xmlgraphics/trunk/content: ./ fop/fo.html
Date Tue, 11 Dec 2012 09:41:21 GMT
Author: buildbot
Date: Tue Dec 11 09:41:20 2012
New Revision: 841657

Log:
Staging update by buildbot for xmlgraphics

Modified:
    websites/staging/xmlgraphics/trunk/content/   (props changed)
    websites/staging/xmlgraphics/trunk/content/fop/fo.html

Propchange: websites/staging/xmlgraphics/trunk/content/
------------------------------------------------------------------------------
--- cms:source-revision (original)
+++ cms:source-revision Tue Dec 11 09:41:20 2012
@@ -1 +1 @@
-1420048
+1420053

Modified: websites/staging/xmlgraphics/trunk/content/fop/fo.html
==============================================================================
--- websites/staging/xmlgraphics/trunk/content/fop/fo.html (original)
+++ websites/staging/xmlgraphics/trunk/content/fop/fo.html Tue Dec 11 09:41:20 2012
@@ -349,14 +349,14 @@ $(document).ready(function () {
 <h3 id="xml-special-chars">Special Characters</h3>
 <p>When entering special (non-ASCII) characters in XML, the general rule is to use
the applicable Unicode character instead of trying to use a character entity as you would
with HTML. Remember that HTML is an SGML document type. SGML has a limited character set,
which requires it to use character entities to represent special characters. One of the improvements
of XML over SGML (and thus HTML) is native support for Unicode. Basic XML has only a handful
of character entities, primarily because it doesn't really need more.</p>
 <p>Entities such as <code>&amp;uuml;</code> (u with an umlaut), which
work in HTML, will be flagged as undefined entities unless you define them yourself in your
DTD. Use the corresponding Unicode character instead. A list of predefined HTML entities and
their Unicode codepoints can be found at <a href="http://www.w3.org/TR/html4/sgml/entities.html">Character
entity references in HTML 4</a>.</p>
-<p>One common example is <code>&amp;nbsp;</code>, used to obtain a
non-breaking space in HTML. In XML, use &#160; instead.</p>
+<p>One common example is <code>&amp;nbsp;</code>, used to obtain a
non-breaking space in HTML. In XML, use <code>&amp;#160;</code> or <code>&amp;#xa0;</code>
instead.</p>
 <p>For other non-ASCII characters, such as the Euro symbol, checkbox, etc., see the
<a href="http://www.unicode.org/charts/charindex.html">Unicode Reference By Name</a>
document that is found at the <a href="http://www.unicode.org">Unicode Consortium</a>
site.</p>
-<p>After finding the correct Unicode codepoint to represent the character, use <a
href="http://www.w3.org/TR/2000/REC-xml-20001006#sec-references">XML Character References</a>
to put the character into your source XML, XSLT or FO. See the non-breaking-space comments
above for an example of the syntax using decimal notation. The following hexadecimal example
will result in a Euro sign:
-&#x20AC;
-Getting your XML correctly encoded is only part of the job. If you want the character to
display or print correctly (and you probably do), then the selected font must contain the
necessary glyph. Because of differences between font encoding methods, and limitations in
some font technologies, this can be a troublesome issue, especially for symbol characters.
The FOP example file <a href="fo/fonts.fo.pdf">Base-14 Font Character Mapping</a>
is a very useful resource in sorting these issues out for the Base-14 fonts. For other fonts,
use font editing sofware or operating system utilities (such as the Character Map in most
Windows platforms) to determine what characters the font supports.</p>
+<p>After finding the correct Unicode codepoint to represent the character, use <a
href="http://www.w3.org/TR/2000/REC-xml-20001006#sec-references">XML Character References</a>
to put the character into your source XML, XSLT or FO. See the non-breaking-space comments
above for an example of the syntax using decimal notation. The following hexadecimal example
will result in a Euro sign:</p>
+<p><code>&amp;#x20AC;</code></p>
+<p>Getting your XML correctly encoded is only part of the job. If you want the character
to display or print correctly (and you probably do), then the selected font must contain the
necessary glyph. Because of differences between font encoding methods, and limitations in
some font technologies, this can be a troublesome issue, especially for symbol characters.
The FOP example file <a href="fo/fonts.fo.pdf">Base-14 Font Character Mapping</a>
is a very useful resource in sorting these issues out for the Base-14 fonts. For other fonts,
use font editing sofware or operating system utilities (such as the Character Map in most
Windows platforms) to determine what characters the font supports.</p>
 <p>An alternative to encoding the character and making it available through a font
is to use an embedded graphic to represent the character: GIF, PNG, SVG, etc.</p>
 <h3 id="xml-entity-chars">Entity Characters</h3>
-<p>The handful of basic XML character entities that do exist are the ampersand, apostrophe,
less-than, greater-than, and single-quote characters. These are needed to distinguish markup
tags from content, and to distinguish character entities from content. To avoid parser complaints
about illegal characters and entities in your input, ensure that ampersands in text and attributes
are written as &amp;, "&lt;" is written as &lt;, and "&gt;" as &gt;. It
is not necessary everywhere, but it is wise to do so anyway, just to be sure.</p>
+<p>The handful of basic XML character entities that do exist are the ampersand, apostrophe,
less-than, greater-than, and single-quote characters. These are needed to distinguish markup
tags from content, and to distinguish character entities from content. To avoid parser complaints
about illegal characters and entities in your input, ensure that ampersands in text and attributes
are written as <code>&amp;amp;</code>, "&lt;" is written as <code>&amp;lt;</code>,
and "&gt;" as <code>&amp;gt;</code>. It is not necessary everywhere, but
it is wise to do so anyway, just to be sure.</p>
 <p>Most XML parsers will provide a line number and sometimes a column number for offending
characters.</p>
 <p>Review the <a href="http://www.w3.org/XML/">XML Specification</a> or
a good tutorial for details of the XML file format.</p>
 <h3 id="xml-encoding">Encoding Issues</h3>



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@xmlgraphics.apache.org
For additional commands, e-mail: commits-help@xmlgraphics.apache.org


Mime
View raw message