diff options
author | Karl Berry <karl@freefriends.org> | 2023-11-20 20:54:50 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2023-11-20 20:54:50 +0000 |
commit | f2c544db15e39f47082849b2a648f144852810d0 (patch) | |
tree | 317eb8bbdbd0dbae851e17feef2c5af11344918e /Master/texmf-dist/tex/latex | |
parent | a5dced73080c4a32837513e82957c71c4b776aed (diff) |
tex-ini-files, now merging most from TL-specific dirs
git-svn-id: svn://tug.org/texlive/trunk@68920 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/tex/latex')
-rw-r--r-- | Master/texmf-dist/tex/latex/latexconfig/lualatexquotejobname.tex | 63 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/tex-ini-files/dvilualatex.ini | 4 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/tex-ini-files/latex.ini (renamed from Master/texmf-dist/tex/latex/latexconfig/latex.ini) | 2 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/tex-ini-files/lualatex.ini | 19 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/tex-ini-files/lualatexquotejobname.lua (renamed from Master/texmf-dist/tex/latex/latexconfig/lualatexquotejobname.lua) | 3 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/tex-ini-files/mllatex.ini (renamed from Master/texmf-dist/tex/latex/latexconfig/mllatex.ini) | 2 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/tex-ini-files/pdflatex.ini (renamed from Master/texmf-dist/tex/latex/latexconfig/pdflatex.ini) | 3 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/tex-ini-files/xelatex.ini | 17 |
8 files changed, 48 insertions, 65 deletions
diff --git a/Master/texmf-dist/tex/latex/latexconfig/lualatexquotejobname.tex b/Master/texmf-dist/tex/latex/latexconfig/lualatexquotejobname.tex deleted file mode 100644 index cea56d72bcd..00000000000 --- a/Master/texmf-dist/tex/latex/latexconfig/lualatexquotejobname.tex +++ /dev/null @@ -1,63 +0,0 @@ -% $Id$ -% Manuel Pegourie-Gonnard, originally written 2010. WTFPL v2. -% -% Quote \jobname if it contains spaces, similarly to what other engines do. -% -% Recent versions of luatex kindly provide a process_jobname callback for -% this. Detect if it is available and use a fallback in pure TeX otherwise. -% If using the callback, register it at \everyjob time since callbacks are not -% dumped in formats currently. -% -% The TeX version fails (jobname is set to texput) with invocations like -% luatex '\input foo' -% but work correctly with the following: -% luatex foo\ bar -% luatex -jobname foo\ bar '\input "foo bar"' -% It is is not possible to support all this case without the callback. It is -% debatable if supporting another set cases would be better, but this is the -% historical (TL 2010) behaviour, so just keep it. -% -% \jobname quoting is normalized in the same way as in web2c's -% normalize_quotes() function (see lib/texmfmp.c, non-XeTeX case), that is: -% - remove quotes -% - complain if quotes are not "balanced" (ie not in even number) -% - enclose the result in quotes iff it contains spaces -% -% This file is inputed after latex.ltx. -% -\makeatletter -\everyjob\expandafter{\the\everyjob - \ifcase\directlua{ - tex.sprint(callback.list().process_jobname == nil and 0 or 1)}\relax - % no callback, do what we can in TeX - \begingroup - % strip quotes from job name and count them - \def\stripquotes#1"#2\@nil{% - \edef\clean{\clean#1}% - \ifx\empty#2\empty \else - \advance\count@\@ne - \stripquotes#2\@nil - \fi}% - \count@\z@ - \def\clean{}% - \expandafter\stripquotes\jobname"\@nil - % complain if their was not an even ("balanced") number of quotes - \ifodd\count@ - \errmessage{Unbalanced quotes in jobname: \jobname}% - \fi - % now check if their are spaces and quote if necessary - \def\testsp#1 #2\@nil{% - \ifx\empty#2\empty - \edef\fixjobname{\def\noexpand\jobname{\clean}}% - \else - \edef\fixjobname{\def\noexpand\jobname{"\clean"}}% - \fi}% - \edef\dotest{\noexpand\testsp\clean\space\noexpand\@nil}\dotest - % do it after closing the group - \expandafter\endgroup\fixjobname - \or % callback available, use it - % function in a separate file for convenience (uses %, ~, etc) - \directlua{dofile(assert(kpse.find_file("lualatexquotejobname.lua")))} - \fi} -\makeatother -\endinput diff --git a/Master/texmf-dist/tex/latex/tex-ini-files/dvilualatex.ini b/Master/texmf-dist/tex/latex/tex-ini-files/dvilualatex.ini new file mode 100644 index 00000000000..dcb75e3f534 --- /dev/null +++ b/Master/texmf-dist/tex/latex/tex-ini-files/dvilualatex.ini @@ -0,0 +1,4 @@ +% tex-ini-files 20223-11-17: dvilualatex.ini + +\let\dvimode\relax +\input lualatex.ini diff --git a/Master/texmf-dist/tex/latex/latexconfig/latex.ini b/Master/texmf-dist/tex/latex/tex-ini-files/latex.ini index 984b8e96ce2..665dda30364 100644 --- a/Master/texmf-dist/tex/latex/latexconfig/latex.ini +++ b/Master/texmf-dist/tex/latex/tex-ini-files/latex.ini @@ -1,3 +1,5 @@ +% tex-ini-files 20223-11-17: latex.ini + % Thomas Esser, 1998. public domain. % \ifx\pdfoutput\undefined \else diff --git a/Master/texmf-dist/tex/latex/tex-ini-files/lualatex.ini b/Master/texmf-dist/tex/latex/tex-ini-files/lualatex.ini new file mode 100644 index 00000000000..a23534c094d --- /dev/null +++ b/Master/texmf-dist/tex/latex/tex-ini-files/lualatex.ini @@ -0,0 +1,19 @@ +% tex-ini-files 20223-11-17: lualatex.ini + +% Originally written 2008 by Karl Berry. Public domain. + +\input luatexconfig.tex + +\begingroup + \catcode`\{=1 % + \catcode`\}=2 % + % Set up job name quoting before latex.ltx + % Web2c pdfTeX/XeTeX quote job names containing spaces, but LuaTeX does + % not do this at the engine level. The behaviour can be changed using + % a callback. Originally this code was loaded via lualatexquotejobname.tex + % but that required a hack around latex.ltx: the behaviour has been altered + % to allow the callback route to be used directly. + \global\everyjob{\directlua{require("lualatexquotejobname.lua")}} +\endgroup + +\input latex.ltx diff --git a/Master/texmf-dist/tex/latex/latexconfig/lualatexquotejobname.lua b/Master/texmf-dist/tex/latex/tex-ini-files/lualatexquotejobname.lua index 1809a67874d..2980c78e264 100644 --- a/Master/texmf-dist/tex/latex/latexconfig/lualatexquotejobname.lua +++ b/Master/texmf-dist/tex/latex/tex-ini-files/lualatexquotejobname.lua @@ -1,4 +1,5 @@ --- $Id: lualatexquotejobname.tex 22957 2011-06-13 20:49:26Z mpg $ +-- tex-ini-files 20223-11-17: lualatexquotejobname.tex + -- Manuel Pegourie-Gonnard, originally written 2010. WTFPL v2. -- -- Goal: see lualatexquotejobname.tex diff --git a/Master/texmf-dist/tex/latex/latexconfig/mllatex.ini b/Master/texmf-dist/tex/latex/tex-ini-files/mllatex.ini index 3ae01d135c2..727b702a862 100644 --- a/Master/texmf-dist/tex/latex/latexconfig/mllatex.ini +++ b/Master/texmf-dist/tex/latex/tex-ini-files/mllatex.ini @@ -1,3 +1,5 @@ +% tex-ini-files 20223-11-17: mllatex.ini + % Thomas Esser, 1998. public domain. \scrollmode \input latex.ltx diff --git a/Master/texmf-dist/tex/latex/latexconfig/pdflatex.ini b/Master/texmf-dist/tex/latex/tex-ini-files/pdflatex.ini index f868629c086..6e89d697d64 100644 --- a/Master/texmf-dist/tex/latex/latexconfig/pdflatex.ini +++ b/Master/texmf-dist/tex/latex/tex-ini-files/pdflatex.ini @@ -1,5 +1,6 @@ +% tex-ini-files 20223-11-17: pdflatex.ini + % Thomas Esser, 1998. public domain. \input pdftexconfig.tex -\scrollmode \input latex.ltx \endinput diff --git a/Master/texmf-dist/tex/latex/tex-ini-files/xelatex.ini b/Master/texmf-dist/tex/latex/tex-ini-files/xelatex.ini new file mode 100644 index 00000000000..902392407ba --- /dev/null +++ b/Master/texmf-dist/tex/latex/tex-ini-files/xelatex.ini @@ -0,0 +1,17 @@ +% tex-ini-files 20223-11-17: xelatex.ini + +% Public domain. Originally by Jonathan Kew. + +% Primitives in pdftex and luatex, we'll just use macros here. +% Since we are generating a whatsit, not 100% compatible, +% but hopefully close enough. +% +\begingroup + \catcode`\{=1 % + \catcode`\}=2 % + \catcode`\#=6 % + \csname protected\endcsname\gdef\pdfmapfile#1{\special{pdf:mapfile #1}}% + \csname protected\endcsname\gdef\pdfmapline#1{\special{pdf:mapline #1}}% +\endgroup + +\input latex.ltx |