<body>
<section id="general">
<title>How to configure FOP</title>
- <p>In the directory xml-fop/conf you will find two configuration files. One of them,
+ <p>In the directory {fop-dir}/conf you will find two configuration files. One of them,
config.xml, is only intended for FOP developers, who want to add new default values
to some FOP feature. Don't change this file. For user configuration there is a file called
userconfig.xml. It contains templates for all settings a user can change. Most of them are
</section>
<section id="hyphenation">
<title>Setting up hyphenation</title>
- <p>FOP comes already with some hyphenation pattern. If you need a hyphenation pattern
- which isn't included in the distribution, do the following:
+ <p>
+ FOP comes already with some hyphenation patterns. If you need a hyphenation pattern
+ which isn't included in the distribution, do the following:
</p>
<ol>
<li>
Get the TeX hyphenation pattern file and turn it into an xml file which
-conforms to the hyphenation.dtd in the subdirectory /src/hyph.
+conforms to the hyphenation.dtd in the subdirectory {fop-dir}/src/hyph.
</li>
<li>
-Name this new file following this schema: languageCode_countryCode.xml. If
-you don't need a country code, leave it out, e.g the file name for an American
-english hyphenation pattern would look like this: en_US.xml. For an Italian
-file: it.xml. Language and country codes must be the same as in xsl:fo, that
+Name this new file following this schema: <code>languageCode_countryCode.xml</code>. If
+you don't need a country code, leave it out, e.g. the file name for an American
+english hyphenation pattern would look like this: <code>en_US.xml</code>. For an Italian
+file: <code>it.xml</code>. Language and country codes must be the same as in XSL-FO, that
is follow
<link href="http://www.ics.uci.edu/pub/ietf/http/related/iso639.txt">ISO 639</link>
and
written in lower case, while country codes are written in upper case.
</li>
<li>
-If you have build your new hyphenation pattern file successfully there are
+If you have built your new hyphenation pattern file successfully there are
two ways to make it accessible to FOP.
<ul>
<li>
-Put this new file into the directory /src/hyph and rebuild FOP. The file will
-be picked up and added to the fop.jar.
+Put this new file into the directory {fop-dir}/src/hyph and rebuild FOP. The file will
+be picked up and added to fop.jar.
</li>
<li>
Put the file into a directory of your choice and specify this directory
-in the userconfig.xml in the entry <hyphenation-dir>.
+in the userconfig.xml in the entry <hyphenation-dir>.
</li>
</ul>
</li>
</ol>
+ <section id="hyphenation-sources">
+ <title>Places to find TeX hyphenation pattern files</title>
+ <p>
+ The most important place to find hyphenation pattern file is the CTAN TeX Archive:
+ </p>
+ <ul>
+ <li><fork href="http://www.ctan.org/tex-archive/language/hyphenation/">CTAN TeX Archive</fork></li>
+ </ul>
+ </section>
+ <warning>
+ You have to carefully check license issues when using hyphenation
+ pattern files from other places. The licenses of the files found
+ on the Internet are not always clear.
+ </warning>
+ <note>
+ Most of the files published in the CTAN Archive are licenced under the
+ <fork href="http://www.latex-project.org/lppl.html">LaTeX Project Public License (LPPL)</fork>.
+ The Apache Foundation can't redistribute files under this license. If you want to use such
+ a file you have to decide for yourself if you can use (and possibly distribute) the file under
+ these conditions.
+ </note>
</section>
</body>
</document>
</p>
</answer>
</faq>
- <faq id="hypenation-fails">
+ <faq id="hyphenation-fails">
<question>Hyphenation does not work.</question>
<answer>
<p>
- Set the language attribute somewhere. Check whether you use a language
- for which hyphenation is supported. Supported languages can be deduced
- from the files in the hyph directory of the FOP source distribution.
+ Set the language attribute somewhere and explicitly enable hyphenation.
+ Check whether you use a language for which hyphenation is supported.
+ Supported languages can be deduced from the files in the {fop-dir}/src/hyph
+ directory of the FOP source distribution. If you want to use a language
+ FOP currently doesn't hyphenate, please see the
+ <link href="configuration.html#hyphenation">Configuration page</link>.
</p>
+ <p>
+ Set the language (on fo:page-sequence, fo:block or fo:character):
+ </p>
+ <source><![CDATA[<fo:page-sequence language="fi">]]></source>
+ <p>
+ Enable hyphenation on a block:
+ </p>
+ <source><![CDATA[<fo:block hyphenate="true">]]></source>
</answer>
</faq>
</part>