diff options
Diffstat (limited to 'Master/texmf-dist/source/latex/base/inputenc.dtx')
-rw-r--r-- | Master/texmf-dist/source/latex/base/inputenc.dtx | 37 |
1 files changed, 28 insertions, 9 deletions
diff --git a/Master/texmf-dist/source/latex/base/inputenc.dtx b/Master/texmf-dist/source/latex/base/inputenc.dtx index 81aa5e2ceaf..c88d488b482 100644 --- a/Master/texmf-dist/source/latex/base/inputenc.dtx +++ b/Master/texmf-dist/source/latex/base/inputenc.dtx @@ -1,6 +1,6 @@ % \iffalse meta-comment % -% Copyright 1993-2016 +% Copyright 1993-2018 % LaTeX3 Project and any individual authors listed elsewhere % in this file. % @@ -11,7 +11,7 @@ % conditions of the LaTeX Project Public License, either version 1.3c % of this license or (at your option) any later version. % The latest version of this license is in -% http://www.latex-project.org/lppl.txt +% https://www.latex-project.org/lppl.txt % and version 1.3c or later is part of all distributions of LaTeX % version 2005/12/01 or later. % @@ -308,7 +308,7 @@ % % \subsubsection{\normalfont\ttfamily Keyboard character used is undefined in % inputencoding `\meta{name}'} - +% % The document contains an 8-bit character that is not defined by the % current input encoding in force. This means that either there is a % mismatch between the document encoding that the document claims it @@ -410,7 +410,7 @@ %<cp1252&!ansinew> \ProvidesFile{cp1252.def} %<cp1250> \ProvidesFile{cp1250.def} %<cp1257> \ProvidesFile{cp1257.def} - [2015/03/17 v1.2c Input encoding file] + [2018/04/06 v1.3b Input encoding file] %<cp850>%% %<cp850>%% If you need a Euro symbol, try cp858 instead. %<cp850>%% @@ -534,6 +534,8 @@ % \changes{v0.95}{1997/12/20}{Changed to work in any vmode, for David} % \changes{v1.2a}{2014/04/20}{Added alternative definition for xe/lua tex (pr/4024)}% % \changes{v1.2b}{2014/04/30}{Allow (x-)ascii and utf8x aliases for utf8 in xetex/luatex}% +% \changes{v1.3a}{2018/03/24}{Make \cs{inputencoding} do nothing if +% the argument matches current encoding}% % This sets the encoding to be |#1|. It first sets all the % characters 128--255 to be active (and sets their initial % definition to be |\@inpenc@undefined|). @@ -549,6 +551,9 @@ % % \begin{macrocode} \def\inputencoding#1{% + \edef\reserved@a{#1}% + \ifx\reserved@a\inputencodingname + \else % \end{macrocode} % We start with a hook to be executed before the encoding change % happens. @@ -631,6 +636,10 @@ % \changes{v1.1a}{2006/02/22}{Added \cs{inpenc@posthook}} % \begin{macrocode} \the\inpenc@posthook +% \end{macrocode} +% +% \begin{macrocode} + \fi } % \end{macrocode} % @@ -680,8 +689,8 @@ % \changes{v1.1a}{2006/02/22}{Hook added} % Two hooks to be executed before and after an encoding changes happened. % \begin{macrocode} -\newtoks\inpenc@prehook -\newtoks\inpenc@posthook +\ifx\inpenc@prehook\@undefined\newtoks\inpenc@prehook\fi +\ifx\inpenc@posthook\@undefined\newtoks\inpenc@posthook\fi % \end{macrocode} % \end{macro} % \end{macro} @@ -728,7 +737,17 @@ % % % Then for each option, we input that encoding file. -% \begin{macrocode} +% Only exception: for utf8x (from \texttt{ucs} package) we +% first restore the raw input encoding. That should be moved to the +% \texttt{utf8x.def} file, eventually. +% In case of a rollback |\UseRawInputEncoding| is not defined so we +% only input the encoding. +% \changes{v1.3b}{2018/04/06}{Handle utf8x encoding manually for now} +% \begin{macrocode} +\DeclareOption{utf8x}{\ifdefined\UseRawInputEncoding + \UseRawInputEncoding + \fi + \inputencoding{\CurrentOption}} \DeclareOption*{\inputencoding{\CurrentOption}} \ProcessOptions %</package> @@ -2594,7 +2613,7 @@ % % Data for the \LaTeX{} support was mainly provided by Ionel Ciob\^{i}c\u{a} % with additions and corrections taken from\\ -% \texttt{http://www.unicode.org/Public/MAPPINGS/ISO8859/8859-16.TXT}. +% \texttt{https://www.unicode.org/Public/MAPPINGS/ISO8859/8859-16.TXT}. % % \changes{v1.1b}{2006/03/03}{Corrections (pr/3849)} % @@ -2892,7 +2911,7 @@ % This is an MS Windows encoding for Baltic languages, % known as Code Page 1257; provided by Heiko Oberdiek % using the mappings to Unicode in\\ -% \texttt{http://www.unicode.org/\\Public/MAPPINGS/VENDORS/MICSFT/WINDOWS/CP1257.TXT}\\ +% \texttt{https://www.unicode.org/\\Public/MAPPINGS/VENDORS/MICSFT/WINDOWS/CP1257.TXT}\\ % and\\ % \texttt{http://www.microsoft.com/globaldev/reference/sbcs/1257.mspx}. % |