summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/tex/latex/sanitize-umlaut
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/tex/latex/sanitize-umlaut')
-rw-r--r--Master/texmf-dist/tex/latex/sanitize-umlaut/sanitize-umlaut.sty50
1 files changed, 36 insertions, 14 deletions
diff --git a/Master/texmf-dist/tex/latex/sanitize-umlaut/sanitize-umlaut.sty b/Master/texmf-dist/tex/latex/sanitize-umlaut/sanitize-umlaut.sty
index d48a86874a0..86918c3baa1 100644
--- a/Master/texmf-dist/tex/latex/sanitize-umlaut/sanitize-umlaut.sty
+++ b/Master/texmf-dist/tex/latex/sanitize-umlaut/sanitize-umlaut.sty
@@ -1,9 +1,9 @@
-%% The LaTeX package sanitize-umlaut - version 1.00 (2016/05/28)
+%% The LaTeX package sanitize-umlaut - version 1.10 (2020/01/01)
%% sanitize-umlaut.sty: Sanitize umlauts for makeindex
%%
-%% --------------------------------------------------------------------------------------
-%% Copyright (c) 2016 by Prof. Dr. Dr. Thomas F. Sturm <thomas dot sturm at unibw dot de>
-%% --------------------------------------------------------------------------------------
+%% -------------------------------------------------------------------------------------------
+%% Copyright (c) 2016-2020 by Prof. Dr. Dr. Thomas F. Sturm <thomas dot sturm at unibw dot de>
+%% -------------------------------------------------------------------------------------------
%%
%% This work may be distributed and/or modified under the
%% conditions of the LaTeX Project Public License, either version 1.3
@@ -18,23 +18,42 @@
%% This work consists of all files listed in README
%%
\NeedsTeXFormat{LaTeX2e}
-\ProvidesPackage{sanitize-umlaut}[2016/05/28 version 1.00 sanitize umlauts]
+\ProvidesPackage{sanitize-umlaut}[2020/01/01 version 1.10 sanitize umlauts]
-\def\define@unicode@char#1#2{%
+\def\sanitize@unicode@char#1#2{%
\@namedef{u8:\detokenize{#1}}{#2}%
}
+\long\def\sanitize@umlaut@UTFviii@two@octets{% patch for 'utf8.def'
+ \ifincsname
+ \expandafter \UTF@two@octets@string
+ \else
+ \fi
+ \UTFviii@two@octets@combine
+}
+
\begingroup
\catcode`\"=12
\gdef\sanitize@umlaut@utfviii{%
- \define@unicode@char{^^c3^^a4}{"a}%
- \define@unicode@char{^^c3^^b6}{"o}%
- \define@unicode@char{^^c3^^bc}{"u}%
- \define@unicode@char{^^c3^^84}{"A}%
- \define@unicode@char{^^c3^^96}{"O}%
- \define@unicode@char{^^c3^^9c}{"U}%
- \define@unicode@char{^^c3^^9f}{"s}%
+ \let\UTFviii@two@octets\sanitize@umlaut@UTFviii@two@octets%
+ \sanitize@unicode@char{^^c3^^a4}{"a}%
+ \sanitize@unicode@char{^^c3^^b6}{"o}%
+ \sanitize@unicode@char{^^c3^^bc}{"u}%
+ \sanitize@unicode@char{^^c3^^84}{"A}%
+ \sanitize@unicode@char{^^c3^^96}{"O}%
+ \sanitize@unicode@char{^^c3^^9c}{"U}%
+ \sanitize@unicode@char{^^c3^^9f}{"s}%
+}
+
+\gdef\sanitize@umlaut@utfviii@old{%
+ \sanitize@unicode@char{^^c3^^a4}{"a}%
+ \sanitize@unicode@char{^^c3^^b6}{"o}%
+ \sanitize@unicode@char{^^c3^^bc}{"u}%
+ \sanitize@unicode@char{^^c3^^84}{"A}%
+ \sanitize@unicode@char{^^c3^^96}{"O}%
+ \sanitize@unicode@char{^^c3^^9c}{"U}%
+ \sanitize@unicode@char{^^c3^^9f}{"s}%
}
\gdef\sanitize@umlaut@latini{%
@@ -64,6 +83,9 @@
\def\@tempa{utf8}\ifx\inputencodingname\@tempa
\let\sanitize@umlaut\sanitize@umlaut@utfviii
\PackageInfo{sanitize-umlaut}{encoding utf8 selected}
+ \else\def\@tempa{utf8-2018}\ifx\inputencodingname\@tempa
+ \let\sanitize@umlaut\sanitize@umlaut@utfviii@old
+ \PackageInfo{sanitize-umlaut}{encoding utf8-2018 selected}
\else\def\@tempa{latin1}\ifx\inputencodingname\@tempa
\let\sanitize@umlaut\sanitize@umlaut@latini
\PackageInfo{sanitize-umlaut}{encoding latin1 selected}
@@ -79,7 +101,7 @@
\else
\def\sanitize@umlaut{}%
\PackageWarning{sanitize-umlaut}{encoding \inputencodingname\space is not supported}
- \fi\fi\fi\fi\fi
+ \fi\fi\fi\fi\fi\fi
\else
\let\sanitize@umlaut\sanitize@umlaut@utfviii
\PackageWarning{sanitize-umlaut}{encoding unknown. utf8 is selected as fallback (possibly nonsense)}