[latex3-commits] [git/LaTeX3-latex3-latex2e] softhyphen: Add \textsofthyphen (c1a3389c)

Marcel Fabian Krüger tex at 2krueger.de
Fri Apr 24 01:15:44 CEST 2020


Repository : https://github.com/latex3/latex2e
On branch  : softhyphen
Link       : https://github.com/latex3/latex2e/commit/c1a3389c7ad829c1c6083ed61a6b8b3e0c36ce4d

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

commit c1a3389c7ad829c1c6083ed61a6b8b3e0c36ce4d
Author: Marcel Fabian Krüger <tex at 2krueger.de>
Date:   Wed Apr 15 19:43:33 2020 +0200

    Add \textsofthyphen


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

c1a3389c7ad829c1c6083ed61a6b8b3e0c36ce4d
 base/inputenc.dtx | 20 ++++++++++----------
 base/ltspace.dtx  | 16 +++++++++++-----
 base/utf8ienc.dtx |  2 +-
 3 files changed, 22 insertions(+), 16 deletions(-)

diff --git a/base/inputenc.dtx b/base/inputenc.dtx
index 01a8303e..53c34fa3 100644
--- a/base/inputenc.dtx
+++ b/base/inputenc.dtx
@@ -970,7 +970,7 @@
 \DeclareInputText{187}{\v t}
 \DeclareInputText{172}{\@tabacckludge'Z}
 \DeclareInputText{188}{\@tabacckludge'z}
-\DeclareInputText{173}{\-}
+\DeclareInputText{173}{\textsofthyphen}
 \DeclareInputText{189}{\H{}}
 \DeclareInputText{174}{\v Z}
 \DeclareInputText{190}{\v z}
@@ -1090,7 +1090,7 @@
 \DeclareInputText{187}{\u g}
 \DeclareInputText{172}{\^J}
 \DeclareInputText{188}{\^\j}
-\DeclareInputText{173}{\-}
+\DeclareInputText{173}{\textsofthyphen}
 \DeclareInputText{189}{\textonehalf}
 % \DeclareInputText{174}{\notdef}
 % \DeclareInputText{190}{\notdef}
@@ -1201,7 +1201,7 @@
 \DeclareInputText{170}{\@tabacckludge=E}
 \DeclareInputText{171}{\c G}
 \DeclareInputText{172}{\textTstroke}%% Northern Sami
-\DeclareInputText{173}{\-}
+\DeclareInputText{173}{\textsofthyphen}
 \DeclareInputText{174}{\v Z}
 \DeclareInputText{175}{\@tabacckludge={}}
 \DeclareInputText{176}{\textdegree}
@@ -1329,7 +1329,7 @@
 \DeclareInputText{187}{\guillemetright}
 \DeclareInputMath{172}{\lnot}
 \DeclareInputText{188}{\textonequarter}
-\DeclareInputText{173}{\-}
+\DeclareInputText{173}{\textsofthyphen}
 \DeclareInputText{189}{\textonehalf}
 \DeclareInputText{174}{\textregistered}
 \DeclareInputText{190}{\textthreequarters}
@@ -1619,7 +1619,7 @@
 %
 %    \begin{macrocode}
 \DeclareInputText{224}{\@tabacckludge'O}
-\DeclareInputText{240}{\-}
+\DeclareInputText{240}{\textsofthyphen}
 \DeclareInputText{225}{\ss}
 \DeclareInputMath{241}{\pm}
 \DeclareInputText{226}{\^O}
@@ -1744,7 +1744,7 @@
 %
 %    \begin{macrocode}
 \DeclareInputText{224}{\@tabacckludge'O}
-\DeclareInputText{240}{\-}
+\DeclareInputText{240}{\textsofthyphen}
 \DeclareInputText{225}{\ss}
 \DeclareInputText{241}{\H{}}
 \DeclareInputText{226}{\^O}
@@ -2517,7 +2517,7 @@
 \DeclareInputText{171}{\guillemetleft}
 \DeclareInputText{187}{\guillemetright}
 \DeclareInputMath{172}{\lnot}
-\DeclareInputText{173}{\-}
+\DeclareInputText{173}{\textsofthyphen}
 \DeclareInputText{174}{\textregistered}
 \DeclareInputText{175}{\@tabacckludge={}}
 \DeclareInputText{191}{\textquestiondown}
@@ -2657,7 +2657,7 @@
 \DeclareInputText{170}{\textcommabelow S}
 \DeclareInputText{171}{\guillemetleft}
 \DeclareInputText{172}{\@tabacckludge'Z}
-\DeclareInputText{173}{\-}
+\DeclareInputText{173}{\textsofthyphen}
 \DeclareInputText{174}{\@tabacckludge'z}
 \DeclareInputText{175}{\.Z}
 \DeclareInputText{176}{\textdegree}
@@ -2815,7 +2815,7 @@
 \DeclareInputText{170}{\c S}
 \DeclareInputText{171}{\guillemetleft}
 \DeclareInputMath{172}{\lnot}
-\DeclareInputText{173}{\-}% soft hyphen
+\DeclareInputText{173}{\textsofthyphen}
 \DeclareInputText{174}{\textregistered}
 \DeclareInputText{175}{\.Z}
 \DeclareInputText{176}{\textdegree}
@@ -2956,7 +2956,7 @@
 \DeclareInputText{170}{\c R}
 \DeclareInputText{171}{\guillemetleft}
 \DeclareInputMath{172}{\lnot}
-\DeclareInputText{173}{\-}
+\DeclareInputText{173}{\textsofthyphen}
 \DeclareInputText{174}{\textregistered}
 \DeclareInputText{175}{\AE}
 \DeclareInputText{176}{\textdegree}
diff --git a/base/ltspace.dtx b/base/ltspace.dtx
index 93e152a2..036b0008 100644
--- a/base/ltspace.dtx
+++ b/base/ltspace.dtx
@@ -32,7 +32,7 @@
 %<*driver>
 % \fi
 \ProvidesFile{ltspace.dtx}
-             [2020/04/15 v1.3m LaTeX Kernel (spacing)]
+             [2020/04/24 v1.3m LaTeX Kernel (spacing)]
 % \iffalse
 \documentclass{ltxdoc}
 \GetFileInfo{ltspace.dtx}
@@ -1218,17 +1218,23 @@
 % \end{macro}
 % \end{macro}
 %
-% \changes{v1.3m}{2020/04/15}{Made softhyphen active in TU engines}
+% \begin{macro}{\textsofthyphen}
+% \changes{v1.3m}{2020/04/24}{Macro added}
 %
-%   For Unicode engines, make the Unicode soft hyphen an active
-%   character defined as \cs{-}.
+%   This is a robust command that has the same effect as inserting a
+%   soft hyphen in the input. By default, it becomes \cs{-}.
+%   For Unicode engines, we also make the Unicode soft hyphen an active
+%   character defined as \cs{textsofthyphen}. (For other engines, this
+%   will be done by the input encoding)
 %
 %    \begin{macrocode}
+\DeclareRobustCommand{\textsofthyphen}{\-}
 \ifx\Umathcode\@undefined\else
   \catcode "AD=13
-  \def^^ad{\-}
+  \def^^ad{\IeC{\textsofthyphen}}
 \fi
 %    \end{macrocode}
+% \end{macro}
 %
 % \begin{macro}{\obeycr}
 % \begin{macro}{\restorecr}
diff --git a/base/utf8ienc.dtx b/base/utf8ienc.dtx
index 8d454d1c..20946e7d 100644
--- a/base/utf8ienc.dtx
+++ b/base/utf8ienc.dtx
@@ -1153,7 +1153,7 @@
 \DeclareUnicodeCharacter{00AB}{\guillemotleft}
 %</all,x2,t2c,t2b,t2a,t1,ot2,ly1,lcy>
 %<all,ts1>\DeclareUnicodeCharacter{00AC}{\textlnot}
-%<all,t1,ot1,ly1>\DeclareUnicodeCharacter{00AD}{\-}
+%<all,t1,ot1,ly1>\DeclareUnicodeCharacter{00AD}{\textsofthyphen}
 %<all,ts1,ly1,utf8>\DeclareUnicodeCharacter{00AE}{\textregistered}
 %<all,ts1>\DeclareUnicodeCharacter{00AF}{\textasciimacron}
 %<all,ts1,ly1>\DeclareUnicodeCharacter{00B0}{\textdegree}





More information about the latex3-commits mailing list.