texlive[56491] Master/texmf-dist: bxpapersize (30sep20)

commits+karl at tug.org commits+karl at tug.org
Wed Sep 30 23:28:23 CEST 2020


Revision: 56491
          http://tug.org/svn/texlive?view=revision&revision=56491
Author:   karl
Date:     2020-09-30 23:28:23 +0200 (Wed, 30 Sep 2020)
Log Message:
-----------
bxpapersize (30sep20)

Modified Paths:
--------------
    trunk/Master/texmf-dist/doc/latex/bxpapersize/LICENSE
    trunk/Master/texmf-dist/doc/latex/bxpapersize/README.md
    trunk/Master/texmf-dist/tex/latex/bxpapersize/bxpapersize.sty

Modified: trunk/Master/texmf-dist/doc/latex/bxpapersize/LICENSE
===================================================================
--- trunk/Master/texmf-dist/doc/latex/bxpapersize/LICENSE	2020-09-30 21:27:38 UTC (rev 56490)
+++ trunk/Master/texmf-dist/doc/latex/bxpapersize/LICENSE	2020-09-30 21:28:23 UTC (rev 56491)
@@ -1,6 +1,6 @@
 The MIT License
 
-Copyright (c) 2019 Takayuki YATO (aka. "ZR")
+Copyright (c) 2016-2020 Takayuki YATO (aka. "ZR")
 
 Permission is hereby granted, free of charge, to any person obtaining a copy
 of this software and associated documentation files (the "Software"), to deal

Modified: trunk/Master/texmf-dist/doc/latex/bxpapersize/README.md
===================================================================
--- trunk/Master/texmf-dist/doc/latex/bxpapersize/README.md	2020-09-30 21:27:38 UTC (rev 56490)
+++ trunk/Master/texmf-dist/doc/latex/bxpapersize/README.md	2020-09-30 21:28:23 UTC (rev 56491)
@@ -53,6 +53,9 @@
 
 #### Priority
 
+**Important**: The `priority` option is not (yet) supported under the
+new LaTeX kernel 2020-10-01.
+
   * `priority=<value>`: In DVI mode, this decides the priority of the
     ‘papersize’ specials issued by this package relative to the
     ‘papersize’ specials issued by others.
@@ -135,6 +138,9 @@
 Revision History
 ----------------
 
+  * Version 0.5  ‹2020/10/01›
+      - Support LaTeX kernel 2020/10/01.
+        (But priority setting is not yet supported.)
   * Version 0.4  ‹2019/10/05›
       - Load pxatbegshi to properly handle pTeX tate mode.
       - Remove (experimental) `adjustmag` option.

Modified: trunk/Master/texmf-dist/tex/latex/bxpapersize/bxpapersize.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/bxpapersize/bxpapersize.sty	2020-09-30 21:27:38 UTC (rev 56490)
+++ trunk/Master/texmf-dist/tex/latex/bxpapersize/bxpapersize.sty	2020-09-30 21:28:23 UTC (rev 56491)
@@ -1,7 +1,7 @@
 %%
 %% This is file 'bxpapersize.sty'.
-%% 
-%% Copyright (c) 2019 Takayuki YATO (aka. "ZR")
+%%
+%% Copyright (c) 2016-2020 Takayuki YATO (aka. "ZR")
 %%   GitHub:   https://github.com/zr-tex8r
 %%   Twitter:  @zr_tex8r
 %%
@@ -10,7 +10,7 @@
 
 %% package declaration
 \NeedsTeXFormat{LaTeX2e}
-\ProvidesPackage{bxpapersize}[2019/10/05 v0.4]
+\ProvidesPackage{bxpapersize}[2020/10/01 v0.5]
 
 %% preparation
 \def\bxpr at pkgname{bxpapersize}
@@ -63,6 +63,15 @@
 %% unique tokens
 \def\bxpr at end{\bxpr at end@}
 
+%% switch 'bxpr at new@hook at system'
+% Whether the new hook management system is present.
+\newif\ifbxpr at new@hook at system
+\ifx\AddToHook\@undefined\else
+  \PackageInfo\bxpr at pkgname
+   {Detected the new LaTeX kernel (2020-10-01)\@gobble}
+  \bxpr at new@hook at systemtrue
+\fi
+
 %% \bxpr at pagewidth / \bxpr at pageheight
 %% \bxpr at horigin / \bxpr at vorigin
 \ifluatex           % LuaTeX
@@ -280,6 +289,15 @@
 
 % if priority is not middle...
 \ifnum\bxpr at priority=\bxpr at priority@@default\else
+\ifbxpr at new@hook at system %----
+  \PackageWarningNoLine\bxpr at pkgname
+   {!!!!!!!!!! WARNING !!!!!!!!!!\MessageBreak
+    You use the new LaTeX kernel (2020-10-01)!\MessageBreak
+    Unfortunately, priority setting is not yet\MessageBreak
+    available on the new kernel, and thus\MessageBreak
+    will be ignored}
+  \let\bxpr at priority\bxpr at priority@@default
+\else %----
   \ifcase\bxpr at mode % dvi
     \ifptex
       \RequirePackage{pxatbegshi}[]
@@ -288,6 +306,7 @@
     \PackageWarningNoLine\bxpr at pkgname
      {The priority setting will be ignored in PDF mdoe}
   \fi
+\fi %----
 \fi
 
 %--------------------------------------- page hook
@@ -296,6 +315,9 @@
 % Placed at the head of the begin-docuemnt hook.
 \@onlypreamble\bxpr at begindoc@first at hook
 \let\bxpr at begindoc@first at hook\@empty
+\ifbxpr at new@hook at system %----
+\AddToHook{begindocument/before}{\bxpr at begindoc@first at hook}
+\else %----
 \begingroup
   \toks@\expandafter{\@begindocumenthook}
   \xdef\@begindocumenthook{%
@@ -302,13 +324,18 @@
     \noexpand\bxpr at begindoc@first at hook
     \the\toks@}
 \endgroup
+\fi %----
 
 %% \bxpr at begindoc@last at hook
 % Placed after the begin-docuemnt hook.
 \def\bxpr at begindoc@last at hook{%
   \let\bxpr at begindoc@last at hook\@undefined}
+\ifbxpr at new@hook at system %----
+\AddToHook{begindocument/end}{\bxpr at begindoc@last at hook}
+\else %----
 \g at addto@macro\document{%
   \bxpr at begindoc@last at hook}
+\fi %----
 
 %% add hook for every page
 \g at addto@macro\bxpr at begindoc@first at hook{%



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