texlive[64851] Master: pdflscape (29oct22)

commits+karl at tug.org commits+karl at tug.org
Sat Oct 29 21:49:11 CEST 2022


Revision: 64851
          http://tug.org/svn/texlive?view=revision&revision=64851
Author:   karl
Date:     2022-10-29 21:49:11 +0200 (Sat, 29 Oct 2022)
Log Message:
-----------
pdflscape (29oct22)

Modified Paths:
--------------
    trunk/Master/texmf-dist/doc/latex/pdflscape/README.md
    trunk/Master/texmf-dist/doc/latex/pdflscape/pdflscape.pdf
    trunk/Master/texmf-dist/source/latex/pdflscape/pdflscape.dtx
    trunk/Master/texmf-dist/tex/latex/pdflscape/pdflscape.sty
    trunk/Master/tlpkg/libexec/ctan2tds

Added Paths:
-----------
    trunk/Master/texmf-dist/tex/latex/pdflscape/pdflscape-nometadata.sty

Modified: trunk/Master/texmf-dist/doc/latex/pdflscape/README.md
===================================================================
--- trunk/Master/texmf-dist/doc/latex/pdflscape/README.md	2022-10-29 19:47:54 UTC (rev 64850)
+++ trunk/Master/texmf-dist/doc/latex/pdflscape/README.md	2022-10-29 19:49:11 UTC (rev 64851)
@@ -1,10 +1,16 @@
-# pdflscape
+# pdflscape package for LaTeX
 
-pdflscape package for LaTeX
+Version: 2022-10-28 v0.13
 
-
 Package pdflscape adds PDF support to the
 environment landscape of package lscape
 by setting the PDF page attribute /Rotate.
 
+% Copyright (C)
+%    2001, 2004, 2006-2008 Heiko Oberdiek
+%    2016-2022 Oberdiek Package Support Group
+%    https://github.com/ho-tex/pdflscape/issues
 
+
+## License
+LATEX Project Public License, version 1.3c or later.

Modified: trunk/Master/texmf-dist/doc/latex/pdflscape/pdflscape.pdf
===================================================================
(Binary files differ)

Modified: trunk/Master/texmf-dist/source/latex/pdflscape/pdflscape.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/pdflscape/pdflscape.dtx	2022-10-29 19:47:54 UTC (rev 64850)
+++ trunk/Master/texmf-dist/source/latex/pdflscape/pdflscape.dtx	2022-10-29 19:49:11 UTC (rev 64851)
@@ -1,12 +1,12 @@
 % \iffalse meta-comment
 %
 % File: pdflscape.dtx
-% Version: 2019/12/05 v0.12
+% Version: 2022-10-28 v0.13
 % Info: Display of landscape pages in PDF
 %
 % Copyright (C)
 %    2001, 2004, 2006-2008 Heiko Oberdiek
-%    2016-2019 Oberdiek Package Support Group
+%    2016-2022 Oberdiek Package Support Group
 %    https://github.com/ho-tex/pdflscape/issues
 %
 % This work may be distributed and/or modified under the
@@ -27,7 +27,8 @@
 %
 % This work consists of the main source file pdflscape.dtx
 % and the derived files
-%    pdflscape.sty, pdflscape.pdf, pdflscape.ins, pdflscape.drv,
+%    pdflscape.sty, pdflscape-nometadata, pdflscape.pdf, 
+%    pdflscape.ins, pdflscape.drv,
 %
 % Distribution:
 %    CTAN:macros/latex/contrib/pdflscape/pdflscape.dtx
@@ -61,6 +62,7 @@
 %
 % Installation:
 %    TDS:tex/latex/pdflscape/pdflscape.sty
+%    TDS:tex/latex/pdflscape/pdflscape-nometadata.sty
 %    TDS:doc/latex/pdflscape/pdflscape.pdf
 %    TDS:source/latex/pdflscape/pdflscape.dtx
 %
@@ -79,7 +81,7 @@
 \input docstrip.tex
 \Msg{************************************************************************}
 \Msg{* Installation}
-\Msg{* Package: pdflscape 2019/12/05 v0.12 Display of landscape pages in PDF (HO)}
+\Msg{* Package: pdflscape 2022-10-28 v0.13 Display of landscape pages in PDF (HO)}
 \Msg{************************************************************************}
 
 \keepsilent
@@ -91,11 +93,11 @@
 This is a generated file.
 
 Project: pdflscape
-Version: 2019/12/05 v0.12
+Version: 2022-10-28 v0.13
 
 Copyright (C)
    2001, 2004, 2006-2008 Heiko Oberdiek
-   2016-2019 Oberdiek Package Support Group
+   2016-2022 Oberdiek Package Support Group
 
 This work may be distributed and/or modified under the
 conditions of the LaTeX Project Public License, either
@@ -116,7 +118,8 @@
 
 This work consists of the main source file pdflscape.dtx
 and the derived files
-   pdflscape.sty, pdflscape.pdf, pdflscape.ins, pdflscape.drv,
+   pdflscape.sty, pdflscape-nometadata.sty, pdflscape.pdf,
+   pdflscape.ins, pdflscape.drv,
 
 \endpreamble
 \let\MetaPrefix\DoubleperCent
@@ -125,7 +128,8 @@
   \file{pdflscape.ins}{\from{pdflscape.dtx}{install}}%
   \file{pdflscape.drv}{\from{pdflscape.dtx}{driver}}%
   \usedir{tex/latex/pdflscape}%
-  \file{pdflscape.sty}{\from{pdflscape.dtx}{package}}%
+  \file{pdflscape-nometadata.sty}{\from{pdflscape.dtx}{package}}%
+  \file{pdflscape.sty}{\from{pdflscape.dtx}{package-new}}%
 }
 
 \catcode32=13\relax% active space
@@ -136,6 +140,7 @@
 \Msg{* file into a directory searched by TeX:}
 \Msg{*}
 \Msg{*     pdflscape.sty}
+\Msg{*     pdflscape-nometadata.sty}
 \Msg{*}
 \Msg{* To produce the documentation run the file `pdflscape.drv'}
 \Msg{* through LaTeX.}
@@ -152,7 +157,7 @@
 %<*driver>
 \NeedsTeXFormat{LaTeX2e}
 \ProvidesFile{pdflscape.drv}%
-  [2019/12/05 v0.12 Display of landscape pages in PDF (HO)]%
+  [2022-10-28 v0.13 Display of landscape pages in PDF (HO)]%
 \documentclass{ltxdoc}
 \usepackage{holtxdoc}[2011/11/22]
 \usepackage{graphics}
@@ -167,7 +172,7 @@
 % \GetFileInfo{pdflscape.drv}
 %
 % \title{The \xpackage{pdflscape} package}
-% \date{2019/12/05 v0.12}
+% \date{2022-10-28 v0.13}
 % \author{Heiko Oberdiek\thanks
 % {Please report any issues at \url{https://github.com/ho-tex/pdflscape/issues}}}
 %
@@ -184,13 +189,21 @@
 % \section{Documentation}
 %
 % \subsection{Supported drivers}
+% 
+% If the PDF management is loaded by the use of \verb+\DocumentMetadata{}+ at
+% the beginning of the document, the engines and backends supported by \texttt{l3backend}
+% can be used. Driver options are passed to graphics and are typically only needed if
+% \LaTeX{} is used with \texttt{dvipdfmx}. 
+% 
+% Without the PDF management the following driver options can be used (many are
+% simply aliases to each other):
 %
 % \begin{itemize}
 % \item \xoption{pdftex},\xoption{luatex}
 % \item \xoption{dvips}, \xoption{dvipsone},
-%       \xoption{pctex32}, \xoption{pctexps}
+%       \xoption{pctexps}
 %       (and other drivers that provide a non-empty \cs{Gin at PS@raw})
-% \item \xoption{dvipdfm}
+% \item \xoption{dvipdfm}, \xoption{dvipdfmx}, \xoption{xetex} 
 % \end{itemize}
 %
 % \subsection{Caveat}
@@ -224,8 +237,55 @@
 % }
 %
 % \section{Implementation}
+% \subsection{New version using the methods of the PDF management} 
+% Identification
+%    \begin{macrocode}
+%<*package-new>
+\NeedsTeXFormat{LaTeX2e}[2020/10/01]
+\ProvidesExplPackage{pdflscape}{2022-10-27}{0.13}
+  {Display of landscape pages in PDF}%
+%    \end{macrocode}
+% Testing if the pdfmanagement is used
+%    \begin{macrocode}
+\@ifl at t@r\fmtversion{2022-06-01}
+  {
+    \IfDocumentMetadataTF {}{\RequirePackageWithOptions{pdflscape-nometadata}}
+    \IfDocumentMetadataTF {}{\endinput}
+  }
+  {\RequirePackageWithOptions{pdflscape-nometadata}}  
+%    \end{macrocode}
+% Load lscape, but don't pass the \texttt{pdftex} option
+% as it would use \cs{pdfpageattr} which is incompatible with the pdf management.
+%    \begin{macrocode}
+\DeclareOption*{\PassOptionsToPackage\CurrentOption{graphics}}
+\ProcessOptions
+\RequirePackage{lscape}
+%    \end{macrocode}
+% this always turns in the same direction as the original code 
+% of pdflscape does. left and right would need
+% \verb+\pdfmanagement_add:nnn{ThisPage}{Rotate}{..}+
+% on every page (e.g. in a shipout hook) and some option to control the wanted
+% orientation.
+
+%    \begin{macrocode}
+\tl_new:N\g__pdflscape_saverotate_tl
+\hook_gput_code:nnn {env/landscape/begin}{pdflscape}
+  {
+    \pdfmanagement_get:nnN {Page}{Rotate}\l_tmpa_tl
+    \tl_gset_eq:NN\g__pdflscape_saverotate_tl\l_tmpa_tl
+    \clearpage
+    \pdfmanagement_add:nnn{Page}{Rotate}{90}
+  }
+\hook_gput_code:nnn {env/landscape/after}{pdflscape}
+ {
+  \quark_if_no_value:NTF\g__pdflscape_saverotate_tl
+   {\pdfmanagement_remove:nn{Page}{Rotate}}
+   {\pdfmanagement_add:nnx{Page}{Rotate}{\g__pdflscape_saverotate_tl}}
+ }
+%</package-new>
+%    \end{macrocode}
 %
-% \subsection{Package identification}
+% \subsection{Old version without the PDF management}
 %
 %    \begin{macrocode}
 %<*package>
@@ -233,8 +293,8 @@
 %    Package identification.
 %    \begin{macrocode}
 \NeedsTeXFormat{LaTeX2e}
-\ProvidesPackage{pdflscape}%
-  [2019/12/05 v0.12 Display of landscape pages in PDF (HO)]
+\ProvidesPackage{pdflscape-nometadata}%
+  [2022-10-28 v0.13 Display of landscape pages in PDF (HO)]
 %    \end{macrocode}
 %
 % \subsection{Driver options}
@@ -452,19 +512,18 @@
 %    \begin{macrocode}
 \def\PLS at temp{dvips}
 \ifx\PLS at temp\PLS at driver
-  \RequirePackage{atbegshi}%
-  \AtBeginShipout{\PLS at AtBeginShipout}%
+  \AddToHook{shipout/before}{\PLS at AtBeginShipout}%
   \let\PLS at AtBeginShipout\@empty
   \def\PLS at AddRotate#1{%
     \ifnum#1=0 %
     \else
       \def\PLS at AtBeginShipout{%
-        \global\setbox\AtBeginShipoutBox\vbox{%
+        \global\setbox\ShipoutBox\vbox{%
           \Gin at PS@raw{%
             [{ThisPage}\string<\string</Rotate #1\string>\string>%
             /PUT pdfmark%
           }%
-          \box\AtBeginShipoutBox
+          \box\ShipoutBox
         }%
       }%
     \fi
@@ -478,16 +537,15 @@
 %    \begin{macrocode}
 \def\PLS at temp{dvipdfm}
 \ifx\PLS at temp\PLS at driver
-  \RequirePackage{atbegshi}%
-  \AtBeginShipout{\PLS at AtBeginShipout}%
+  \AddToHook{shipout/before}{\PLS at AtBeginShipout}%
   \let\PLS at AtBeginShipout\@empty
   \def\PLS at AddRotate#1{%
     \ifnum#1=0 %
     \else
       \def\PLS at AtBeginShipout{%
-        \global\setbox\AtBeginShipoutBox\vbox{%
+        \global\setbox\ShipoutBox\vbox{%
           \special{pdf: put @thispage <</Rotate #1>>}%
-          \box\AtBeginShipoutBox
+          \box\ShipoutBox
         }%
       }%
     \fi
@@ -584,26 +642,6 @@
 % \end{description}
 %
 %
-% \paragraph{Bundle.} All the packages of the bundle `pdflscape'
-% are also available in a TDS compliant ZIP archive. There
-% the packages are already unpacked and the documentation files
-% are generated. The files and directories obey the TDS standard.
-% \begin{description}
-% \item[\CTANinstall{install/macros/latex/contrib/pdflscape.tds.zip}]
-% \end{description}
-% \emph{TDS} refers to the standard ``A Directory Structure
-% for \TeX\ Files'' (\CTANpkg{tds}). Directories
-% with \xfile{texmf} in their name are usually organized this way.
-%
-% \subsection{Bundle installation}
-%
-% \paragraph{Unpacking.} Unpack the \xfile{pdflscape.tds.zip} in the
-% TDS tree (also known as \xfile{texmf} tree) of your choice.
-% Example (linux):
-% \begin{quote}
-%   |unzip pdflscape.tds.zip -d ~/texmf|
-% \end{quote}
-%
 % \subsection{Package installation}
 %
 % \paragraph{Unpacking.} The \xfile{.dtx} file is a self-extracting
@@ -620,6 +658,7 @@
 % \def\t{^^A
 % \begin{tabular}{@{}>{\ttfamily}l@{ $\rightarrow$ }>{\ttfamily}l@{}}
 %   pdflscape.sty & tex/latex/pdflscape/pdflscape.sty\\
+%   pdflscape-nometadata.sty & tex/latex/pdflscape/pdflscape-nometadata.sty\\
 %   pdflscape.pdf & doc/latex/pdflscape/pdflscape.pdf\\
 %   pdflscape.dtx & source/latex/pdflscape/pdflscape.dtx\\
 % \end{tabular}^^A
@@ -798,6 +837,10 @@
 %     Documentation updates.
 %   \item \xpackage{iftex} package.
 %   \end{Version}
+%   \begin{Version}{2022-10-28 v0.13}
+%   \item Made the package compatible with the PDF management.
+%   \item Removed the dependency to atbegshi.
+%   \end{Version}
 % \end{History}
 %
 % \PrintIndex

Added: trunk/Master/texmf-dist/tex/latex/pdflscape/pdflscape-nometadata.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/pdflscape/pdflscape-nometadata.sty	                        (rev 0)
+++ trunk/Master/texmf-dist/tex/latex/pdflscape/pdflscape-nometadata.sty	2022-10-29 19:49:11 UTC (rev 64851)
@@ -0,0 +1,253 @@
+%%
+%% This is file `pdflscape-nometadata.sty',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% pdflscape.dtx  (with options: `package')
+%% 
+%% This is a generated file.
+%% 
+%% Project: pdflscape
+%% Version: 2022-10-28 v0.13
+%% 
+%% Copyright (C)
+%%    2001, 2004, 2006-2008 Heiko Oberdiek
+%%    2016-2022 Oberdiek Package Support Group
+%% 
+%% This work may be distributed and/or modified under the
+%% conditions of the LaTeX Project Public License, either
+%% version 1.3c of this license or (at your option) any later
+%% version. This version of this license is in
+%%    https://www.latex-project.org/lppl/lppl-1-3c.txt
+%% and the latest version of this license is in
+%%    https://www.latex-project.org/lppl.txt
+%% and version 1.3 or later is part of all distributions of
+%% LaTeX version 2005/12/01 or later.
+%% 
+%% This work has the LPPL maintenance status "maintained".
+%% 
+%% The Current Maintainers of this work are
+%% Heiko Oberdiek and the Oberdiek Package Support Group
+%% https://github.com/ho-tex/pdflscape/issues
+%% 
+%% This work consists of the main source file pdflscape.dtx
+%% and the derived files
+%%    pdflscape.sty, pdflscape-nometadata.sty, pdflscape.pdf,
+%%    pdflscape.ins, pdflscape.drv,
+%% 
+\NeedsTeXFormat{LaTeX2e}
+\ProvidesPackage{pdflscape-nometadata}%
+  [2022-10-28 v0.13 Display of landscape pages in PDF (HO)]
+\let\PLS at option\@empty
+\let\PLS at driver\@empty
+\def\PLS at temp#1#2{%
+  \DeclareOption{#1}{%
+    \let\PLS at option\CurrentOption
+    \def\PLS at driver{#2}%
+  }%
+}
+\PLS at temp{pdftex}{pdftex}
+\PLS at temp{luatex}{pdftex}
+\PLS at temp{dvips}{dvips}
+\PLS at temp{dvipsone}{dvips}
+\PLS at temp{pctexps}{dvips}
+\PLS at temp{dvipdfm}{dvipdfm}
+\PLS at temp{dvipdfmx}{dvipdfm}
+\PLS at temp{xetex}{dvipdfm}
+\let\PLS at temp\@empty
+\DeclareOption*{%
+  \ifx\PLS at temp\@empty
+    \let\PLS at temp\CurrentOption
+  \else
+    \edef\PLS at temp{\PLS at temp,\CurrentOption}%
+  \fi
+}
+\ProcessOptions*
+\ifx\PLS at option\@empty
+\else
+  \expandafter\PassOptionsToPackage\expandafter{\PLS at option}{lscape}%
+\fi
+\ifx\PLS at temp\@empty
+\else
+  \expandafter\PassOptionsToPackage\expandafter{\PLS at temp}{lscape}%
+\fi
+\RequirePackage{iftex}[2019/11/07]%
+\RequirePackage{lscape}
+\def\PLS at temp{pdftex}
+\ifpdf
+  \ifx\PLS at driver\@empty
+    \let\PLS at driver\PLS at temp
+    \PackageInfo{pdflscape}{Auto-detected driver: \PLS at temp}%
+  \fi
+  \ifx\PLS at driver\PLS at temp
+  \else
+    \PackageError{pdflscape}{%
+      The driver option `\PLS at option' is not compatible\MessageBreak
+      with pdfTeX in PDF mode, using driver `pdftex' instead%
+    }\@ehc
+    \let\PLS at driver\PLS at temp
+  \fi
+\fi
+\def\PLS at temp{dvipdfm}
+\ifxetex
+  \ifx\PLS at driver\@empty
+    \let\PLS at driver\PLS at temp
+    \PackageInfo{pdflscape}{%
+      Auto-detected driver: \PLS at temp\space(xetex)%
+    }%
+  \fi
+  \ifx\PLS at driver\PLS at temp
+  \else
+    \PackageError{pdflscape}{%
+      The driver option `\PLS at option' is not compatible\MessageBreak
+      with XeTeX, using driver for XeTeX (dvipdfm) instead%
+    }\@ehc
+    \let\PLS at driver\PLS at temp
+  \fi
+\fi
+\def\PLS at temp#1#2{%
+  \ifx\PLS at driver\@empty
+    \begingroup
+      \def\PLS at temp{#1.def}%
+    \expandafter\endgroup
+    \ifx\PLS at temp\Gin at driver
+      \def\PLS at driver{#2}%
+      \PackageInfo{pdflscape}{%
+        Auto-detected driver: \PLS at driver\space(#1)%
+      }%
+    \fi
+  \fi
+}
+\PLS at temp{dvipdfm}{dvipdfm}
+\PLS at temp{dvipdfmx}{dvipdfm}
+\PLS at temp{dvips}{dvips}
+\PLS at temp{dvipsone}{dvips}
+\PLS at temp{pctexps}{dvips}
+\ifx\PLS at driver\@empty
+  \def\PLS at temp{dvips}%
+  \ifnum 1=0\ifx\Gin at PS@raw\@undefined
+            \else
+              \ifx\Gin at PS@raw\relax
+              \else
+                \ifx\Gin at PS@raw\@empty
+                \else
+                  1%
+                \fi
+              \fi
+            \fi
+            \space
+    \let\PLS at driver\PLS at temp
+    \PackageInfo{pdflscape}{%
+      Auto-detected driver: \PLS at temp\space(PostScript)%
+    }%
+  \fi
+\fi
+\ifx\PLS at driver\@empty
+  \PackageError{pdflscape}{%
+    Neither pdfTeX, PostScript, nor dvipdfm driver found%
+  }\@ehc
+\fi
+\ifx\pdfpageattr\@undefined
+  \ifx\pdfvariable\@undefined\else
+    \protected\edef\pdfpageattr{\pdfvariable pageattr}
+  \fi
+\fi
+\def\PLS at temp{pdftex}
+\ifx\PLS at temp\PLS at driver
+  \def\PLS at AddRotate#1{%
+    \ifnum#1=0 %
+    \else
+      \global\pdfpageattr\expandafter{%
+        \the\pdfpageattr
+        /Rotate #1%
+      }%
+    \fi
+  }%
+  \def\PLS at RemoveRotate{%
+    \begingroup
+      \global\pdfpageattr\expandafter{\expandafter}%
+      \expandafter\PLS@@RemoveRotate
+        \the\pdfpageattr /Rotate\@nil
+    \endgroup
+  }%
+  \def\PLS@@RemoveRotate#1/Rotate#2\@nil{%
+    \global\pdfpageattr\expandafter{\the\pdfpageattr#1}%
+    \ifx\\#2\\%
+    \else
+      \afterassignment\PLS@@RemoveRotate
+      \count0=#2\@nil
+    \fi
+  }%
+\fi
+\def\PLS at temp{dvips}
+\ifx\PLS at temp\PLS at driver
+  \AddToHook{shipout/before}{\PLS at AtBeginShipout}%
+  \let\PLS at AtBeginShipout\@empty
+  \def\PLS at AddRotate#1{%
+    \ifnum#1=0 %
+    \else
+      \def\PLS at AtBeginShipout{%
+        \global\setbox\ShipoutBox\vbox{%
+          \Gin at PS@raw{%
+            [{ThisPage}\string<\string</Rotate #1\string>\string>%
+            /PUT pdfmark%
+          }%
+          \box\ShipoutBox
+        }%
+      }%
+    \fi
+  }%
+  \def\PLS at RemoveRotate{\let\PLS at AtBeginShipout\@empty}%
+\fi
+\def\PLS at temp{dvipdfm}
+\ifx\PLS at temp\PLS at driver
+  \AddToHook{shipout/before}{\PLS at AtBeginShipout}%
+  \let\PLS at AtBeginShipout\@empty
+  \def\PLS at AddRotate#1{%
+    \ifnum#1=0 %
+    \else
+      \def\PLS at AtBeginShipout{%
+        \global\setbox\ShipoutBox\vbox{%
+          \special{pdf: put @thispage <</Rotate #1>>}%
+          \box\ShipoutBox
+        }%
+      }%
+    \fi
+  }%
+  \def\PLS at RemoveRotate{\let\PLS at AtBeginShipout\@empty}%
+\fi
+\g at addto@macro{\landscape}{\PLS at Rotate{90}}
+\g at addto@macro{\endlandscape}{\PLS at Rotate{0}}
+\def\PLS at Rotate#1{%
+  \begingroup
+    \PLS at CheckAngle{#1}%
+  \expandafter\endgroup
+  \expandafter\PLS at RemoveRotate
+  \expandafter\PLS at AddRotate\expandafter{\the\count@}%
+}
+\def\PLS at CheckAngle#1{%
+  \ifx\\#1\\%
+    \count@=0 %
+  \else
+    \count@=#1\relax
+  \fi
+  \@whilenum\count@>359\do{\advance\count@ -360 }%
+  \@whilenum\count@<-359\do{\advance\count@ 360 }%
+  \ifnum 1=0\ifnum\count@=0 \else
+            \ifnum\count@=90 \else
+            \ifnum\count@=-90 \else
+            \ifnum\count@=180 \else
+            \ifnum\count@=-180 \else
+            \ifnum\count@=270 \else
+            \ifnum\count@=-270 \else
+           1\fi\fi\fi\fi\fi\fi\fi\relax
+    \PackageError{pdflscape}{%
+      Invalid value \the\count@\space for /Rotate%
+    }\@ehc
+    \count@=0 %
+  \fi
+}
+\endinput
+%%
+%% End of file `pdflscape-nometadata.sty'.


Property changes on: trunk/Master/texmf-dist/tex/latex/pdflscape/pdflscape-nometadata.sty
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Modified: trunk/Master/texmf-dist/tex/latex/pdflscape/pdflscape.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/pdflscape/pdflscape.sty	2022-10-29 19:47:54 UTC (rev 64850)
+++ trunk/Master/texmf-dist/tex/latex/pdflscape/pdflscape.sty	2022-10-29 19:49:11 UTC (rev 64851)
@@ -4,16 +4,16 @@
 %%
 %% The original source files were:
 %%
-%% pdflscape.dtx  (with options: `package')
+%% pdflscape.dtx  (with options: `package-new')
 %% 
 %% This is a generated file.
 %% 
 %% Project: pdflscape
-%% Version: 2019/12/05 v0.12
+%% Version: 2022-10-28 v0.13
 %% 
 %% Copyright (C)
 %%    2001, 2004, 2006-2008 Heiko Oberdiek
-%%    2016-2019 Oberdiek Package Support Group
+%%    2016-2022 Oberdiek Package Support Group
 %% 
 %% This work may be distributed and/or modified under the
 %% conditions of the LaTeX Project Public License, either
@@ -31,225 +31,38 @@
 %% Heiko Oberdiek and the Oberdiek Package Support Group
 %% https://github.com/ho-tex/pdflscape/issues
 %% 
-%% 
 %% This work consists of the main source file pdflscape.dtx
 %% and the derived files
-%%    pdflscape.sty, pdflscape.pdf, pdflscape.ins, pdflscape.drv,
+%%    pdflscape.sty, pdflscape-nometadata.sty, pdflscape.pdf,
+%%    pdflscape.ins, pdflscape.drv,
 %% 
-\NeedsTeXFormat{LaTeX2e}
-\ProvidesPackage{pdflscape}%
-  [2019/12/05 v0.12 Display of landscape pages in PDF (HO)]
-\let\PLS at option\@empty
-\let\PLS at driver\@empty
-\def\PLS at temp#1#2{%
-  \DeclareOption{#1}{%
-    \let\PLS at option\CurrentOption
-    \def\PLS at driver{#2}%
-  }%
-}
-\PLS at temp{pdftex}{pdftex}
-\PLS at temp{luatex}{pdftex}
-\PLS at temp{dvips}{dvips}
-\PLS at temp{dvipsone}{dvips}
-\PLS at temp{pctexps}{dvips}
-\PLS at temp{dvipdfm}{dvipdfm}
-\PLS at temp{dvipdfmx}{dvipdfm}
-\PLS at temp{xetex}{dvipdfm}
-\let\PLS at temp\@empty
-\DeclareOption*{%
-  \ifx\PLS at temp\@empty
-    \let\PLS at temp\CurrentOption
-  \else
-    \edef\PLS at temp{\PLS at temp,\CurrentOption}%
-  \fi
-}
-\ProcessOptions*
-\ifx\PLS at option\@empty
-\else
-  \expandafter\PassOptionsToPackage\expandafter{\PLS at option}{lscape}%
-\fi
-\ifx\PLS at temp\@empty
-\else
-  \expandafter\PassOptionsToPackage\expandafter{\PLS at temp}{lscape}%
-\fi
-\RequirePackage{iftex}[2019/11/07]%
+\NeedsTeXFormat{LaTeX2e}[2020/10/01]
+\ProvidesExplPackage{pdflscape}{2022-10-27}{0.13}
+  {Display of landscape pages in PDF}%
+\@ifl at t@r\fmtversion{2022-06-01}
+  {
+    \IfDocumentMetadataTF {}{\RequirePackageWithOptions{pdflscape-nometadata}}
+    \IfDocumentMetadataTF {}{\endinput}
+  }
+  {\RequirePackageWithOptions{pdflscape-nometadata}}
+\DeclareOption*{\PassOptionsToPackage\CurrentOption{graphics}}
+\ProcessOptions
 \RequirePackage{lscape}
-\def\PLS at temp{pdftex}
-\ifpdf
-  \ifx\PLS at driver\@empty
-    \let\PLS at driver\PLS at temp
-    \PackageInfo{pdflscape}{Auto-detected driver: \PLS at temp}%
-  \fi
-  \ifx\PLS at driver\PLS at temp
-  \else
-    \PackageError{pdflscape}{%
-      The driver option `\PLS at option' is not compatible\MessageBreak
-      with pdfTeX in PDF mode, using driver `pdftex' instead%
-    }\@ehc
-    \let\PLS at driver\PLS at temp
-  \fi
-\fi
-\def\PLS at temp{dvipdfm}
-\ifxetex
-  \ifx\PLS at driver\@empty
-    \let\PLS at driver\PLS at temp
-    \PackageInfo{pdflscape}{%
-      Auto-detected driver: \PLS at temp\space(xetex)%
-    }%
-  \fi
-  \ifx\PLS at driver\PLS at temp
-  \else
-    \PackageError{pdflscape}{%
-      The driver option `\PLS at option' is not compatible\MessageBreak
-      with XeTeX, using driver for XeTeX (dvipdfm) instead%
-    }\@ehc
-    \let\PLS at driver\PLS at temp
-  \fi
-\fi
-\def\PLS at temp#1#2{%
-  \ifx\PLS at driver\@empty
-    \begingroup
-      \def\PLS at temp{#1.def}%
-    \expandafter\endgroup
-    \ifx\PLS at temp\Gin at driver
-      \def\PLS at driver{#2}%
-      \PackageInfo{pdflscape}{%
-        Auto-detected driver: \PLS at driver\space(#1)%
-      }%
-    \fi
-  \fi
-}
-\PLS at temp{dvipdfm}{dvipdfm}
-\PLS at temp{dvipdfmx}{dvipdfm}
-\PLS at temp{dvips}{dvips}
-\PLS at temp{dvipsone}{dvips}
-\PLS at temp{pctexps}{dvips}
-\ifx\PLS at driver\@empty
-  \def\PLS at temp{dvips}%
-  \ifnum 1=0\ifx\Gin at PS@raw\@undefined
-            \else
-              \ifx\Gin at PS@raw\relax
-              \else
-                \ifx\Gin at PS@raw\@empty
-                \else
-                  1%
-                \fi
-              \fi
-            \fi
-            \space
-    \let\PLS at driver\PLS at temp
-    \PackageInfo{pdflscape}{%
-      Auto-detected driver: \PLS at temp\space(PostScript)%
-    }%
-  \fi
-\fi
-\ifx\PLS at driver\@empty
-  \PackageError{pdflscape}{%
-    Neither pdfTeX, PostScript, nor dvipdfm driver found%
-  }\@ehc
-\fi
-\ifx\pdfpageattr\@undefined
-  \ifx\pdfvariable\@undefined\else
-    \protected\edef\pdfpageattr{\pdfvariable pageattr}
-  \fi
-\fi
-\def\PLS at temp{pdftex}
-\ifx\PLS at temp\PLS at driver
-  \def\PLS at AddRotate#1{%
-    \ifnum#1=0 %
-    \else
-      \global\pdfpageattr\expandafter{%
-        \the\pdfpageattr
-        /Rotate #1%
-      }%
-    \fi
-  }%
-  \def\PLS at RemoveRotate{%
-    \begingroup
-      \global\pdfpageattr\expandafter{\expandafter}%
-      \expandafter\PLS@@RemoveRotate
-        \the\pdfpageattr /Rotate\@nil
-    \endgroup
-  }%
-  \def\PLS@@RemoveRotate#1/Rotate#2\@nil{%
-    \global\pdfpageattr\expandafter{\the\pdfpageattr#1}%
-    \ifx\\#2\\%
-    \else
-      \afterassignment\PLS@@RemoveRotate
-      \count0=#2\@nil
-    \fi
-  }%
-\fi
-\def\PLS at temp{dvips}
-\ifx\PLS at temp\PLS at driver
-  \RequirePackage{atbegshi}%
-  \AtBeginShipout{\PLS at AtBeginShipout}%
-  \let\PLS at AtBeginShipout\@empty
-  \def\PLS at AddRotate#1{%
-    \ifnum#1=0 %
-    \else
-      \def\PLS at AtBeginShipout{%
-        \global\setbox\AtBeginShipoutBox\vbox{%
-          \Gin at PS@raw{%
-            [{ThisPage}\string<\string</Rotate #1\string>\string>%
-            /PUT pdfmark%
-          }%
-          \box\AtBeginShipoutBox
-        }%
-      }%
-    \fi
-  }%
-  \def\PLS at RemoveRotate{\let\PLS at AtBeginShipout\@empty}%
-\fi
-\def\PLS at temp{dvipdfm}
-\ifx\PLS at temp\PLS at driver
-  \RequirePackage{atbegshi}%
-  \AtBeginShipout{\PLS at AtBeginShipout}%
-  \let\PLS at AtBeginShipout\@empty
-  \def\PLS at AddRotate#1{%
-    \ifnum#1=0 %
-    \else
-      \def\PLS at AtBeginShipout{%
-        \global\setbox\AtBeginShipoutBox\vbox{%
-          \special{pdf: put @thispage <</Rotate #1>>}%
-          \box\AtBeginShipoutBox
-        }%
-      }%
-    \fi
-  }%
-  \def\PLS at RemoveRotate{\let\PLS at AtBeginShipout\@empty}%
-\fi
-\g at addto@macro{\landscape}{\PLS at Rotate{90}}
-\g at addto@macro{\endlandscape}{\PLS at Rotate{0}}
-\def\PLS at Rotate#1{%
-  \begingroup
-    \PLS at CheckAngle{#1}%
-  \expandafter\endgroup
-  \expandafter\PLS at RemoveRotate
-  \expandafter\PLS at AddRotate\expandafter{\the\count@}%
-}
-\def\PLS at CheckAngle#1{%
-  \ifx\\#1\\%
-    \count@=0 %
-  \else
-    \count@=#1\relax
-  \fi
-  \@whilenum\count@>359\do{\advance\count@ -360 }%
-  \@whilenum\count@<-359\do{\advance\count@ 360 }%
-  \ifnum 1=0\ifnum\count@=0 \else
-            \ifnum\count@=90 \else
-            \ifnum\count@=-90 \else
-            \ifnum\count@=180 \else
-            \ifnum\count@=-180 \else
-            \ifnum\count@=270 \else
-            \ifnum\count@=-270 \else
-           1\fi\fi\fi\fi\fi\fi\fi\relax
-    \PackageError{pdflscape}{%
-      Invalid value \the\count@\space for /Rotate%
-    }\@ehc
-    \count@=0 %
-  \fi
-}
+
+\tl_new:N\g__pdflscape_saverotate_tl
+\hook_gput_code:nnn {env/landscape/begin}{pdflscape}
+  {
+    \pdfmanagement_get:nnN {Page}{Rotate}\l_tmpa_tl
+    \tl_gset_eq:NN\g__pdflscape_saverotate_tl\l_tmpa_tl
+    \clearpage
+    \pdfmanagement_add:nnn{Page}{Rotate}{90}
+  }
+\hook_gput_code:nnn {env/landscape/after}{pdflscape}
+ {
+  \quark_if_no_value:NTF\g__pdflscape_saverotate_tl
+   {\pdfmanagement_remove:nn{Page}{Rotate}}
+   {\pdfmanagement_add:nnx{Page}{Rotate}{\g__pdflscape_saverotate_tl}}
+ }
 \endinput
 %%
 %% End of file `pdflscape.sty'.

Modified: trunk/Master/tlpkg/libexec/ctan2tds
===================================================================
--- trunk/Master/tlpkg/libexec/ctan2tds	2022-10-29 19:47:54 UTC (rev 64850)
+++ trunk/Master/tlpkg/libexec/ctan2tds	2022-10-29 19:49:11 UTC (rev 64851)
@@ -3168,6 +3168,7 @@
  'nwejm'	=> 'tex',
  'nomentbl'     => 'latex -translate-file=empty.tcx',   # no 8-bit
  'pbsheet'      => 'latex',  # requires interaction
+ 'pdflscape'	=> 'etex',
  'penrose'	=> 'etex',
  'powerdot'	=> 'latex',
  'thumb'        => 'latex -translate-file=empty.tcx',   # no 8-bit



More information about the tex-live-commits mailing list.