updated
[latex2e.git] / base / lthyphen.dtx
blobeb9489a8d24155210ae425f1182679e33c507348
1 % \iffalse meta-comment
3 % Copyright 1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009
4 % The LaTeX3 Project and any individual authors listed elsewhere
5 % in this file. 
6
7 % This file is part of the LaTeX base system.
8 % -------------------------------------------
9
10 % It may be distributed and/or modified under the
11 % conditions of the LaTeX Project Public License, either version 1.3c
12 % of this license or (at your option) any later version.
13 % The latest version of this license is in
14 %    http://www.latex-project.org/lppl.txt
15 % and version 1.3c or later is part of all distributions of LaTeX 
16 % version 2005/12/01 or later.
17
18 % This file has the LPPL maintenance status "maintained".
19
20 % The list of all files belonging to the LaTeX base distribution is
21 % given in the file `manifest.txt'. See also `legal.txt' for additional
22 % information.
23
24 % The list of derived (unpacked) files belonging to the distribution 
25 % and covered by LPPL is defined by the unpacking scripts (with 
26 % extension .ins) which are part of the distribution.
27
28 % \fi
29 % \iffalse
30 %<*driver>
31 \ProvidesFile{lthyphen.dtx}
32 %</driver>
33 %<default>\ProvidesFile{hyphen.ltx}
34 % \fi
35 %         \ProvidesFile{lthyphen.dtx}
36           [1994/12/04 v1.0h LaTeX Kernel (hyphenation interface)]
39 % \CheckSum{13}
40 %% \CharacterTable
41 %%  {Upper-case    \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
42 %%   Lower-case    \a\b\c\d\e\f\g\h\i\j\k\l\m\n\o\p\q\r\s\t\u\v\w\x\y\z
43 %%   Digits        \0\1\2\3\4\5\6\7\8\9
44 %%   Exclamation   \!     Double quote  \"     Hash (number) \#
45 %%   Dollar        \$     Percent       \%     Ampersand     \&
46 %%   Acute accent  \'     Left paren    \(     Right paren   \)
47 %%   Asterisk      \*     Plus          \+     Comma         \,
48 %%   Minus         \-     Point         \.     Solidus       \/
49 %%   Colon         \:     Semicolon     \;     Less than     \<
50 %%   Equals        \=     Greater than  \>     Question mark \?
51 %%   Commercial at \@     Left bracket  \[     Backslash     \\
52 %%   Right bracket \]     Circumflex    \^     Underscore    \_
53 %%   Grave accent  \`     Left brace    \{     Vertical bar  \|
54 %%   Right brace   \}     Tilde         \~}
56 %\iffalse        This is a META comment
58 % File `lthyphen.dtx'.
59 % Copyright (C) 1994-94 LaTeX3 project, Frank Mittelbach and
60 % Rainer Sch\"opf, all rights reserved.
62 %\fi
63 % \GetFileInfo{lthyphen.dtx}
64 % \title{The \texttt{lthyphen.dtx} file\thanks
65 %     {This file has version number \fileversion, dated \filedate.}\\
66 %       for use with \LaTeXe}
67 % \author{Frank Mittelbach, Chris Rowley \and Rainer Sch\"opf}
69 % \def\dst{{\normalfont\scshape docstrip}}
70 % \setcounter{StandardModuleDepth}{1}
73 % \maketitle
75 % This file contains the code for loading hyphenation patterns into
76 % \LaTeX. Most of this will end up in a file called
77 % \texttt{hyphen.ltx}. If you wish to customize your \LaTeX{} system
78 % in respect of hyphenation patterns, write a file
79 % \texttt{hyphen.cfg}. If this file exists, it will be loaded instead
80 % of \texttt{hyphen.ltx}.  See the comments below for additional
81 % information.
82
83 % \StopEventually{}
85 % To produce the printed version of this file the following code
86 % is used. It can be extracted with the \dst{} program, or one can run
87 % this file directly through \LaTeXe{}.
88 %    \begin{macrocode}
89 %<*driver>
90 \documentclass{ltxdoc}
91 \begin{document}
92 \DocInput{lthyphen.dtx}
93 \end{document}
94 %</driver>
95 %    \end{macrocode}
97 % \changes{v0.1c}{1994/03/07}{move the 2ekernel code to ltfinal.dtx}
98 % \changes{v1.0g}{1994/12/01}{Rename lthyphen.ltx/cfg to hyphen.ltx/cfg}
99 % \changes{v1.0h}{1994/12/04}{Documentation edits for /1989}
101 % The default file |hyphen.ltx| loads hyphenation patterns for US
102 % english.  If you want to load additional or other hyphenation
103 % patterns, you should create a file |hyphen.cfg|. This is best done
104 % by starting from |hyphen.ltx|.
106 % For backward compatibility, the default file, |hyphen.ltx|,
107 % first tries to load
108 % the file |hyphen.tex|. If this file exists, an information
109 % message is issued and the appropriate defaults for \TeX's internal
110 % parameters are set: |\language| is initialized to $0$, and
111 % |\lefthyphenmin| and |\righthyphenmin| to $2$ and $3$, respectively,
112 % to disallow x- or -xx breaks.
113 %    \begin{macrocode}
114 %<*default>
115 \InputIfFileExists{hyphen.tex}%
116    {\message{Loading hyphenation patterns for US english.}%
117     \language=0
118     \lefthyphenmin=2 \righthyphenmin=3 }%
119 %    \end{macrocode}
120 % Otherwise, since we cannot do anything without any hyphenation
121 % patterns, an error message is printed and the Ini\TeX{} run
122 % is terminated by invoking |\@@end| (which is the \LaTeXe{} name
123 % for \TeX's |\end| primitive).
124 %    \begin{macrocode}
125    {\errhelp{The configuration for hyphenation is incorrectly
126              installed.^^J%
127              If you don't understand this error message you need
128              to seek^^Jexpert advice.}%
129     \errmessage{OOPS! I can't find any hyphenation patterns for
130                 US english.^^J \space Think of getting some or the
131                 latex2e setup will never succeed}\@@end}
132 %</default>
133 %    \end{macrocode}
134 % The following example describes the possible contents of a file
135 % |hyphen.cfg| that will load both US English and German hyphenation
136 % patterns, making the former the default. 
137 % It sets |\language| to $0$ for the US patterns and to $1$ for the
138 % German patterns.
139 % Then |\language| is set to $0$ to make this the default and the
140 % default values of |\lefthyphenmin| and |\righthyphenmin| are set.
141 % \begin{verbatim}
142 %\language=0
143 %\input hyphen % (or \input ushyphen1 if the file has been renamed)
144 %\language=1
145 %\input ghyph31
146 %\language=0
147 %\lefthyphenmin=2
148 %\righthyphenmin=3
149 %\endinput
150 %\end{verbatim}
152 % Another possibility is to use the package |babel|, by Johannes Braams.
153 % That package is distributed with a suitable |hyphen.cfg| file.
156 % \Finale
158 \endinput