[latex3-commits] [git/LaTeX3-latex3-latex3] master: Added option `suppress-backend-headers` (d9355f33a)

Joseph Wright joseph.wright at morningstar2.co.uk
Fri Feb 21 00:06:52 CET 2020


Repository : https://github.com/latex3/latex3
On branch  : master
Link       : https://github.com/latex3/latex3/commit/d9355f33a9194764bc3255d9f4f59b12e9446bd9

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

commit d9355f33a9194764bc3255d9f4f59b12e9446bd9
Author: Joseph Wright <joseph.wright at morningstar2.co.uk>
Date:   Thu Feb 20 23:06:52 2020 +0000

    Added option `suppress-backend-headers`


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

d9355f33a9194764bc3255d9f4f59b12e9446bd9
 l3backend/CHANGELOG.md          | 4 ++++
 l3backend/l3backend-basics.dtx  | 5 ++++-
 l3kernel/CHANGELOG.md           | 4 ++++
 l3kernel/expl3.dtx              | 9 +++++++++
 l3kernel/l3kernel-functions.dtx | 4 ++++
 5 files changed, 25 insertions(+), 1 deletion(-)

diff --git a/l3backend/CHANGELOG.md b/l3backend/CHANGELOG.md
index ef903e99e..64aeea3db 100644
--- a/l3backend/CHANGELOG.md
+++ b/l3backend/CHANGELOG.md
@@ -6,6 +6,10 @@ this project uses date-based 'snapshot' version identifiers.
 
 ## [Unreleased]
 
+### Added
+- Support for suppressing backend headers (see matching change in
+  `l3kernel`)
+
 ## [2020-02-03]
 
 ### Fixed
diff --git a/l3backend/l3backend-basics.dtx b/l3backend/l3backend-basics.dtx
index 2bab1907c..1bae82977 100644
--- a/l3backend/l3backend-basics.dtx
+++ b/l3backend/l3backend-basics.dtx
@@ -158,7 +158,10 @@
 \cs_if_exist:NTF \AtBeginDvi
   { \exp_not:N \AtBeginDvi }
   { \use:n }
-    { \__kernel_backend_literal:n { header = l3backend-dvips.pro } }
+    {
+      \bool_if:NT \g__kernel_backend_header_bool
+        { \__kernel_backend_literal:n { header = l3backend-dvips.pro } }
+    }
 %    \end{macrocode}
 %
 % \begin{macro}
diff --git a/l3kernel/CHANGELOG.md b/l3kernel/CHANGELOG.md
index 5c0b06ae7..4dda08edc 100644
--- a/l3kernel/CHANGELOG.md
+++ b/l3kernel/CHANGELOG.md
@@ -7,6 +7,10 @@ this project uses date-based 'snapshot' version identifiers.
 
 ## [Unreleased]
 
+### Added
+- Option `suppress-backend-headers` (see matching change in
+  `l3backend`)
+
 ### Changed
 - Allow `dvisvgm` driver with XeTeX (issue #677)
 
diff --git a/l3kernel/expl3.dtx b/l3kernel/expl3.dtx
index f1b4fa087..20aac5cad 100644
--- a/l3kernel/expl3.dtx
+++ b/l3kernel/expl3.dtx
@@ -922,6 +922,12 @@
 %   \item[xdvipdfmx] Use the \texttt{xdvipdfmx} driver (\XeTeX{} only).
 % \end{itemize}
 %
+% \DescribeOption{suppress-backend-headers}
+% The \texttt{suppress-backend-headers} option suppresses loading of
+% backend-specific header files; currently this only affects \texttt{dvips}.
+% This option is available to support DVI-based routes that do not
+% support the |header| line used by \texttt{dvips}.
+%
 % \section{Using \pkg{expl3} with formats other than \LaTeXe{}}
 %
 % As well as the \LaTeXe{} package \pkg{expl3}, there is also a
@@ -1273,6 +1279,9 @@
         \sys_load_debug:
         \debug_on:n { log-functions }
       } ,
+    suppress-backend-headers .bool_set_inverse:N
+      = \g__kernel_backend_header_bool ,
+    suppress-backend-headers .initial:n = false ,
     undo-recent-deprecations .code:n =
       {
         \bool_gset_true:N \g__kernel_deprecation_undo_recent_bool
diff --git a/l3kernel/l3kernel-functions.dtx b/l3kernel/l3kernel-functions.dtx
index 853ad9ca6..0e7731a71 100644
--- a/l3kernel/l3kernel-functions.dtx
+++ b/l3kernel/l3kernel-functions.dtx
@@ -504,6 +504,10 @@
 %   Applies the \meta{matrix} to the current transformation matrix.
 % \end{function}
 %
+% \begin{function}{\g__kernel_backend_header_bool}
+%   Specifies whether to write headers for the backend.
+% \end{function}
+%
 % \begin{function}{\l__kernel_color_stack_int}
 %   The color stack used in \pdfTeX{} and \LuaTeX{} for the main color.
 % \end{function}





More information about the latex3-commits mailing list.