[latex3-commits] [git/LaTeX3-latex3-latex2e] develop, softhyphen: Make ^^ad active in Unicode engines (348d6a2d)

Marcel Fabian Krüger tex at 2krueger.de
Fri May 8 03:08:04 CEST 2020


Repository : https://github.com/latex3/latex2e
On branches: develop,softhyphen
Link       : https://github.com/latex3/latex2e/commit/348d6a2d2abff48da79a914a56eaf04f852dca1f

>---------------------------------------------------------------

commit 348d6a2d2abff48da79a914a56eaf04f852dca1f
Author: Marcel Fabian Krüger <tex at 2krueger.de>
Date:   Wed May 6 06:08:41 2020 +0200

    Make ^^ad active in Unicode engines


>---------------------------------------------------------------

348d6a2d2abff48da79a914a56eaf04f852dca1f
 base/changes.txt      |  5 +++++
 base/doc/ltnews32.tex | 11 +++++++++++
 base/ltspace.dtx      | 14 +++++++++++++-
 3 files changed, 29 insertions(+), 1 deletion(-)

diff --git a/base/changes.txt b/base/changes.txt
index b93f908c..4d662ee6 100644
--- a/base/changes.txt
+++ b/base/changes.txt
@@ -11,6 +11,11 @@ are not part of the distribution.
 	* ltxref.dtx:
 	added \@currentcounter to \refstepcounter (gh/300)
 
+2020-05-06  Marcel Krüger    <Marcel.Krueger at latex-project.org>
+
+  * ltspace.dtx:
+  Make Unicode softhyphen U+00AD active and defined as \-.
+
 2020-05-02  Johannes Braams  <texniek at braams.xs4all.nl>
 
 	* ltexpl.dtx: Created aliases for two expl3 macros in order to use
diff --git a/base/doc/ltnews32.tex b/base/doc/ltnews32.tex
index 3796b23a..60147965 100644
--- a/base/doc/ltnews32.tex
+++ b/base/doc/ltnews32.tex
@@ -517,6 +517,17 @@ documentation~\cite{32:babel}.
 
 
 
+\subsection{Add support for Unicode soft hyphens}
+
+For a long time, the UTF-8 option for \pkg{inputenc} made the Unicode
+soft hyphen character (U+00AD) an alias for the \LaTeX\ soft hyphen
+|\-|. The Unicode engines \XeTeX{} and \LuaTeX{} behaved
+different though: They either ignored U+00AD or interpreted it as an
+unconditional hyphen. This inconsistency is fixed now and \LaTeX{}
+always treats \texttt{U+00AD} as |\-|.
+
+
+
 \begin{thebibliography}{9}
 
 \fontsize{9.3}{11.3}\selectfont
diff --git a/base/ltspace.dtx b/base/ltspace.dtx
index 3c3ef1f4..1a672c64 100644
--- a/base/ltspace.dtx
+++ b/base/ltspace.dtx
@@ -32,7 +32,7 @@
 %<*driver>
 % \fi
 \ProvidesFile{ltspace.dtx}
-             [2020/04/21 v1.3m LaTeX Kernel (spacing)]
+             [2020/05/06 v1.3n LaTeX Kernel (spacing)]
 % \iffalse
 \documentclass{ltxdoc}
 \GetFileInfo{ltspace.dtx}
@@ -1362,6 +1362,18 @@
 % \end{macro}
 % \end{macro}
 %
+% \changes{v1.3n}{2020/05/06}{Made softhyphen active in TU engines}
+%
+%   For Unicode engines, make the Unicode soft hyphen an active
+%   character defined as \cs{-}.
+%
+%    \begin{macrocode}
+\ifx\Umathcode\@undefined\else
+  \catcode "AD=13
+  \def^^ad{\-}
+\fi
+%    \end{macrocode}
+%
 % \begin{macro}{\obeycr}
 % \begin{macro}{\restorecr}
 % The following definitions will probably get deleted or moved to





More information about the latex3-commits mailing list.