Debian Codegraph @

texmf-dist/doc/latex/base/ltnews28.tex

raw
1 % \iffalse meta-comment
2 %
3 % Copyright (C) 2017-2025
4 % The LaTeX 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 2008 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 % Filename: ltnews28.tex
30 %
31 % This is issue 28 of LaTeX News.
32
33 \documentclass{ltnews}
34 \usepackage[T1]{fontenc}
35
36 \usepackage{lmodern,url,hologo}
37
38 \providecommand\acro[1]{\textsc{#1}}
39 \providecommand\meta[1]{$\langle$\textit{#1}$\rangle$}
40
41
42 \publicationmonth{April}
43 \publicationyear{2018}
44
45 \publicationissue{28}
46
47 \providecommand\pkg[1]{\texttt{#1}}
48 \providecommand\cls[1]{\texttt{#1}}
49 \providecommand\option[1]{\texttt{#1}}
50 \providecommand\env[1]{\texttt{#1}}
51 \providecommand\file[1]{\texttt{#1}}
52
53 \begin{document}
54
55 \maketitle
56 \tableofcontents
57
58 \setlength\rightskip{0pt plus 3em}
59
60 \section{A new home for \LaTeXe{} sources}
61
62 In the past the development version of the \LaTeXe{} source files has
63 been managed in a Subversion source control system with read access
64 for the public. This way it was possible to download in an emergency
65 the latest version even before it was released to CTAN and made its
66 way into the various distributions.
67
68 We have recently changed this setup and now manage the sources using
69 Git and placed the master sources on GitHub at
70 \begin{quote}
71 \url{https://github.com/latex3/latex2e}
72 \end{quote}
73 where we already store the sources
74 for \pkg{expl3} and other work. As before, direct write access is restricted
75 to \LaTeX{} Project Team members, but everything is publicly accessible
76 including the ability to download, clone (using Git) or checkout
77 (using SVN). More details are given in~\cite{Mittelbach:TB39-1}.
78
79 \section{Bug reports for core \LaTeXe{}}
80
81 For more than two decades we used GNATS, an open source bug tracking
82 system developed by the FSF. While that has served us well in the past
83 it started to show its age more and more. So as part of this move we
84 also decided to finally retire the old \LaTeX{} bug database and replace
85 it with the standard ``Issue Tracker'' available at Github.
86
87 The requirements and the workflow for reporting a bug in the core
88 \LaTeX{} software is documented at
89 \begin{quote}
90 \url{https://www.latex-project.org/bugs/}
91 \end{quote}
92 and with further details also discussed in~\cite{Mittelbach:TB39-1}.
93
94
95 \section{UTF-8: the new default input encoding}
96
97 The first \TeX{} implementations only supported reading 7-bit
98 \acro{ascii} files---any accented or otherwise ``special'' character
99 had to be entered using commands, if it could be represented at
100 all. For example to obtain an ``\"a'' one would enter \verb=\"a=, and to
101 typeset a ``\ss'' the command \verb=\ss=. Furthermore fonts at that
102 time had 128 glyphs inside, holding the \acro{ascii} characters, some
103 accents to build composite glyphs from a letter and an accent, and a
104 few special symbols such as parentheses, etc.
105
106 With 8-bit \TeX{} engines such as \hologo{pdfTeX} this situation changed
107 somewhat: it was now possible to process 8-bit files, i.e., files that
108 could encode 256 different characters. However, 256 is still a fairly
109 small number and with this limitation it is only possible to encode a
110 few languages and for other languages one would need to change the
111 encoding (i.e., interpret the character positions 0--255 in a
112 different way). The first code points 0--127 were essentially normed
113 (corresponding to \acro{ascii}) while the second half 128--255 would
114 vary by holding different accented characters to support a certain set
115 of languages.
116
117 Each computer used one of these encodings when storing or interpreting
118 files and as long as two computers used the same encoding it was
119 (easily) possible to exchange files between them and have them
120 interpreted and processed correctly.
121
122 But different computers may have used different encodings and given
123 that a computer file is simply a sequence of bytes with no indication for
124 which encoding is intended, chaos could easily happen and has
125 happened. For example, the German word ``Gr\"o\ss e'' (height) entered on a
126 German keyboard could show up as ``Gr\v T\`ae'' on a different
127 computer using a different encoding by default.
128
129 So in summary the situation wasn't at all good and it was clear in
130 the early nineties that \LaTeXe{} (that was being developed to provide
131 a \LaTeX{} version usable across the world) had to provide a solution
132 to this issue.
133
134 The \LaTeXe{} answer was the introduction of the \pkg{inputenc}
135 package~\cite{Mittelbach:Brno95} through which it is possible to
136 provide support for multiple encodings. It also allows to correctly
137 process a file written in one encoding on a computer using a different
138 encoding and even supports documents where the encoding changes
139 midway.
140
141 Since the first release of \LaTeXe{} in 1994, \LaTeX{} documents that
142 used any characters outside \acro{ascii} in the source (i.e. any
143 characters in the range of 128--255) were supposed to load
144 \pkg{inputenc} and specify in which file encoding they were
145 written and stored.
146 %
147 If the \pkg{inputenc} package was not loaded then \LaTeX{} used a
148 ``raw'' encoding which essentially took each byte from the input file
149 and typeset the glyph that happened to be in that position in the
150 current font---something that sometimes produces the right result but
151 often enough will not.
152
153 In 1992 Ken Thompson and Rob Pike developed the UTF-8 encoding scheme
154 which enables the encoding of all Unicode characters within 8-bit sequences.
155 Over time this encoding has gradually taken over the world,
156 replacing the legacy 8-bit encodings used before. These days all major
157 computer operating systems use UTF-8 to store their files and it
158 requires some effort to explicitly store files in one of the legacy
159 encodings.
160
161 As a result, whenever \LaTeX{} users want to use any accented
162 characters from their keyboard (instead of resorting to \verb=\"a= and
163 the like) they always have to use
164 \begin{verbatim}
165 \usepackage[utf8]{inputenc}
166 \end{verbatim}
167 in the preamble of their documents as otherwise \LaTeX{} will produce
168 gibberish.
169
170 \subsection{The new default}
171
172 With this release, the default encoding for \LaTeX\ files has been
173 changed from the ``fall through raw'' encoding to UTF-8 if used with
174 classic \TeX\ or \hologo{pdfTeX}. The implementation is essentially
175 the same as the existing UTF-8 support from
176 \verb|\usepackage[utf8]{inputenc}|.
177
178 The \hologo{LuaTeX} and \hologo{XeTeX} engines always supported the
179 UTF-8 encoding as their native (and only) input encoding, so with
180 these engines \pkg{inputenc} was always a no-op.
181
182 This means that with new documents one can assume UTF-8 input and it
183 is no longer required to always specify
184 \verb|\usepackage[utf8]{inputenc}|. But if this line is present it
185 will not hurt either.
186
187
188 \subsection{Compatibility}
189
190 For most existing documents this change will be transparent:
191 \begin{itemize}
192 \item documents using only \acro{ascii} in the input file and
193 accessing accented characters via commands;
194 \item documents that specified the encoding of their file via an
195 option to the \pkg{inputenc} package and then used 8-bit
196 characters in that encoding;
197 \item documents that already had been stored in UTF-8 (whether or not
198 specifying this via \pkg{inputenc}).
199 \end{itemize}
200 Only documents that have been stored in a legacy encoding and used
201 accented letters from the keyboard \emph{without} loading
202 \pkg{inputenc} (relying on the similarities between the input used
203 and the T1 font encoding) are affected.
204
205 These documents will now generate an error that they contain invalid
206 UTF-8 sequences. However, such documents may be easily processed by
207 adding the new command \verb|\UseRawInputEncoding| as the first line
208 of the file. This will re-instate the previous ``raw'' encoding
209 default.
210
211 \verb|\UseRawInputEncoding| may also be used on the command line to
212 process existing files without requiring the file to be edited
213 \begin{verbatim}
214 pdflatex '\UseRawInputEncoding \input' file
215 \end{verbatim}
216 will process the file using the previous default encoding.
217
218 Possible alternatives are reencoding the file to UTF-8 using a tool
219 (such as recode or iconv or an editor) or adding the line
220 \begin{flushleft}
221 \verb= \usepackage[=\meta{encoding}\verb=]{inputenc}=
222 \end{flushleft}
223 to the preamble specifying the \meta{encoding} that fits the file
224 encoding. In many cases this will be \option{latin1} or
225 \option{cp1252}. For other encoding names and their meaning see the
226 \pkg{inputenc} documentation.
227
228 As usual, this change may also be reverted via the more general
229 \pkg{latexrelease} package mechanism, by specifying a release date
230 earlier than this release.
231
232
233 \subsection{BOM: byte order mark handling}
234
235 When using Unicode the first bytes of a file may be a, so called, BOM
236 character (byte order mark) to indicate the byte order used in the
237 file. While this is not required with UTF-8 encoded files (where the
238 byte order is known) it is nevertheless allowed by the standard and
239 some editors add that byte sequence to the beginning of a file. In the
240 past such files would have generated a ``Missing begin document''
241 error or displayed strange characters when loaded at a later stage.
242
243 With the addition of UTF-8 support to the kernel it is now possible to
244 identify and ignore such BOMs characters even before
245 \verb=\documentclass= so that these issues will no longer be showing
246 up.
247
248
249
250 \section[A general rollback concept]
251 {A general rollback concept for packages and classes}
252
253 In 2015 a rollback concept for the \LaTeX{} kernel was introduced.
254 Providing this feature allowed us to make corrections to the
255 software (which more or less didn't happen for nearly two decades)
256 while continuing to maintain backward compatibility to the highest
257 degree.
258
259 In this release we have now extended this concept to
260 the world of packages and classes which was not covered
261 initially. As the classes and the extension packages have different
262 requirements compared to the kernel, the approach is different (and
263 simplified). This should make it easy for package developers to
264 apply it to their packages and authors to use when necessary.
265
266 The documentation of this new feature is given in an article
267 submitted to TUGboat and also available from our
268 website~\cite{Mittelbach:TB39-2}.
269
270
271 \section[Integration of \pkg{remreset} and \pkg{chngcntr} packages]
272 {Integration of \pkg{remreset} and \pkg{chngcntr} packages
273 into the kernel}
274
275 With the optional argument to \cs{newcounter} \LaTeX{} offers to
276 automatically reset counters when some counter is stepped, e.g.,
277 stepping a \texttt{chapter} counter resets the \texttt{section}
278 counter (and recursively all other heading counters). However, what
279 was until now missing was a way to undo such a link between counters
280 or to link two counters after they have been defined.
281
282 This can be now be done with \cs{counterwithin} and \cs{counterwithout},
283 respectively. In the past one had to load the \pkg{chngcntr} package
284 for this. For the programming level we also added
285 \cs{@removefromreset} as the counterpart of the already existing
286 \cs{@addtoreset} command. Up to now this was offered by the
287 \pkg{remreset} package.
288
289 \section{Testing for undefined commands}
290 \LaTeX\ packages often use a test \verb|\@ifundefined| to test if a command
291 is defined. Unfortunately this had the side effect of \emph{defining}
292 the command to \verb|\relax| in the case that it had no definition.
293 The new release uses a modified definition
294 (using extra testing possibilities available in \hologo{eTeX}). The new definition
295 is more natural, however code that was relying on the side effect of the
296 command being tested being defined if it was previously undefined may have to add
297 \verb|\let\|\meta{command}\verb|\relax|.
298
299
300 \section{Changes to packages in the \pkg{tools} category}
301
302 \subsection{\LaTeX{} table columns with fixed widths}
303
304 Frank published a short paper in
305 TUGboat~\cite{Mittelbach:TB38-2-213} on producing tables that have
306 columns with fixed widths. The outlined approach using column
307 specifiers ``\texttt{w}'' and ``\texttt{W}'' has now been integrated
308 into the \pkg{array} package.
309
310 \subsection{Obscure overprinting with \pkg{multicol} fixed}
311
312 A rather peculiar bug was reported on StackExchange for
313 \pkg{multicol}. If the column/page breaking was fully controlled by
314 the user (through \cs{columnbreak}) instead of letting the environment
315 do its job and if then more \cs{columnbreak} commands showed up on the
316 last page then the balancing algorithm was thrown off track.
317 As a result some parts of the columns did overprint each other.
318
319 The fix required a redesign of the output routines used by
320 \pkg{multicol} and while it ``should'' be transparent in other cases
321 (and all tests in the regression test suite came out fine) there is the
322 off-chance that code that hooked into internals of \pkg{multicol}
323 needs adjustment.
324
325
326 \section{Changes to packages in the \pkg{amsmath} category}
327
328 With this release of \LaTeX{} a few minor issues with \pkg{amsmath}
329 have been corrected.
330
331 \subsection{Updated user's guide}
332
333 Furthermore, \file{amsldoc.pdf}, the AMS user's
334 guide for the \pkg{amsmath} package~\cite{amsldoc}, has been updated
335 from version~2.0 to~2.1 to incorporate changes and corrections made
336 between 2016 and 2018.
337
338
339 \begin{thebibliography}{9}
340
341 \bibitem{Mittelbach:TB39-1} Frank Mittelbach:
342 \emph{New rules for reporting bugs in the \LaTeX{} core software}.
343 In: TUGboat, 39\#1, 2018.
344 \url{https://www.latex-project.org/publications/}
345
346 \bibitem{Mittelbach:Brno95} Frank Mittelbach:
347 \emph{\LaTeXe{} Encoding Interface --- Purpose, concepts, and
348 Open Problems}.
349 Talk given in Brno June 1995.
350 \url{https://www.latex-project.org/publications/}
351
352 \bibitem{Mittelbach:TB39-2} Frank Mittelbach:
353 \emph{A rollback concept for packages and classes}.
354 Submitted to TUGboat.
355 \url{https://www.latex-project.org/publications/}
356
357 \bibitem{Mittelbach:TB38-2-213} Frank Mittelbach:
358 \emph{\LaTeX{} table columns with fixed widths}.
359 In: TUGboat, 38\#2, 2017.
360 \url{https://www.latex-project.org/publications/}
361
362 \bibitem{amsldoc} American Mathematical Society and The \LaTeX\ Project:
363 \emph{User's Guide for the \pkg{amsmath} package} (Version 2.1).
364 April 2018.
365 Available from
366 \url{https://www.ctan.org}
367 and distributed as part of every \LaTeX{} distribution.
368
369 \end{thebibliography}
370
371 \end{document}