texlive[71463] Master/texmf-dist: tabulary

commits+karl at tug.org commits+karl at tug.org
Mon Jun 10 19:41:37 CEST 2024


Revision: 71463
          https://tug.org/svn/texlive?view=revision&revision=71463
Author:   karl
Date:     2024-06-10 19:41:37 +0200 (Mon, 10 Jun 2024)
Log Message:
-----------
tabulary

Modified Paths:
--------------
    trunk/Master/texmf-dist/doc/latex/tabulary/tabulary.pdf
    trunk/Master/texmf-dist/source/latex/tabulary/tabulary.dtx
    trunk/Master/texmf-dist/tex/latex/tabulary/tabulary.sty

Added Paths:
-----------
    trunk/Master/texmf-dist/doc/latex/tabulary/README.txt
    trunk/Master/texmf-dist/tex/latex/tabulary/tabulary-v010.sty

Removed Paths:
-------------
    trunk/Master/texmf-dist/doc/latex/tabulary/README

Deleted: trunk/Master/texmf-dist/doc/latex/tabulary/README
===================================================================
--- trunk/Master/texmf-dist/doc/latex/tabulary/README	2024-06-09 23:41:30 UTC (rev 71462)
+++ trunk/Master/texmf-dist/doc/latex/tabulary/README	2024-06-10 17:41:37 UTC (rev 71463)
@@ -1,5 +0,0 @@
-The tabulary package:
-
-  The tabulary environment is similar to tabularx (tools) and tabular*
-  (LaTeX kernel) but uses a different column width allocation
-  algorithm.

Added: trunk/Master/texmf-dist/doc/latex/tabulary/README.txt
===================================================================
--- trunk/Master/texmf-dist/doc/latex/tabulary/README.txt	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/tabulary/README.txt	2024-06-10 17:41:37 UTC (rev 71463)
@@ -0,0 +1,5 @@
+The tabulary package:
+
+  The tabulary environment is similar to tabularx (tools) and tabular*
+  (LaTeX kernel) but uses a different column width allocation
+  algorithm.


Property changes on: trunk/Master/texmf-dist/doc/latex/tabulary/README.txt
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Modified: trunk/Master/texmf-dist/doc/latex/tabulary/tabulary.pdf
===================================================================
(Binary files differ)

Modified: trunk/Master/texmf-dist/source/latex/tabulary/tabulary.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/tabulary/tabulary.dtx	2024-06-09 23:41:30 UTC (rev 71462)
+++ trunk/Master/texmf-dist/source/latex/tabulary/tabulary.dtx	2024-06-10 17:41:37 UTC (rev 71463)
@@ -1,9 +1,9 @@
 % \iffalse
 %%
 %% File `tabulary.dtx'.
-%% Copyright (C) 1995 1996 2003 2008 David Carlisle
+%% Copyright (C) 1995 1996 2003 2008 2024 David Carlisle
 %% This file may be distributed under the terms of the LPPL.
-%% See 00readme.txt for details.
+%% See README.txt for details.
 %%
 %
 %<*dtx>
@@ -13,7 +13,7 @@
 %<package>\ProvidesPackage{tabulary}
 % \fi
 %         \ProvidesFile{tabulary.dtx}
-          [2014/06/11 v0.10 tabulary package (DPC)]
+          [2024/06/04 v0.11 tabulary package (DPC)]
 %
 % \iffalse
 %<*driver>
@@ -35,7 +35,6 @@
 \end{document}
 %</driver>
 % \fi
-% \CheckSum{1346}
 %
 % \changes{v0.1}{1995/10/08}
 %      {Initial version}
@@ -51,6 +50,14 @@
 %      {Rename S to J and `hide' s (until it works)}
 % \changes{v0.10}{2014/06/21}
 %      {support \cs{cellcolor} see  http://tex.stackexchange.com/a/185851/1090}
+% \changes{v0.11}{2024/06/04}
+%      {Update to match latest array package (rollback to v0.10 for older releases)}
+% \changes{v0.11}{2024/06/04}
+%      {Restore LaTeX counters after trial typesetting gh/12}
+% \changes{v0.11}{2024/06/04}
+%      {Handle p and b columns like m gh/38}
+% \changes{v0.11}{2024/06/04}
+%      {use \cs{hskip}1sp to match array 2.3i from 1996}
 %
 % \section{User Documentation}
 %
@@ -218,11 +225,18 @@
 %<*package>
 %    \end{macrocode}
 %
+% Rollback.
 %    \begin{macrocode}
-\RequirePackage{array}
+\DeclareRelease{v0.10}{1995/10/08}{tabulary-v010.sty}
+\DeclareCurrentRelease{}{2024-06-01}
 %    \end{macrocode}
 %
+% This version needs a current array package
 %    \begin{macrocode}
+\RequirePackage{array}[2024/05/23]
+%    \end{macrocode}
+%
+%    \begin{macrocode}
 \catcode`\Z=14
 %    \end{macrocode}
 %
@@ -349,11 +363,12 @@
 %  \begin{macro}{\TY at mkpream}
 %    TY version.
 %    \begin{macrocode}
+\ExplSyntaxOn
 \def\TY at mkpream{%
     \def\@addamp{%
       \if at firstamp \@firstampfalse \else
       \global\advance\TY at count\@ne
-      \edef\@preamble{\@preamble &}\fi
+      \edef\@preamble{\@preamble & \noexpand\tbl_update_cell_data:}\fi
       \TY at width\xdef{0pt}}%
 %    \end{macrocode}
 %
@@ -373,7 +388,7 @@
 %
 %    \begin{macrocode}
     \def\@classv{\save at decl
-      \expandafter\NC at ecs\@nextchar\extracolsep{}\extracolsep\@@@
+      \expandafter\NC at ecs\@nextchar\extracolsep{}\extracolsep\@@__tbl
       \sbox\z@{\d at llarbegin\@nextchar\d at llarend}%
       \TY at subwidth{\wd\z@}%
       \@addtopreamble{\d at llarbegin\the at toks\the\count@\relax\d at llarend}%
@@ -386,6 +401,7 @@
 %
 %    \begin{macrocode}
   \TY@@mkpream}
+\ExplSyntaxOff
 %    \end{macrocode}
 %  \end{macro}
 %
@@ -478,7 +494,17 @@
 % row is hidden by an hline or something.
 %    \begin{macrocode}
 \def\endtabulary{%
+  \SuspendTagging {tabulary}%
   \gdef\@halignto{}%
+%    \end{macrocode}
+%
+% Save values of counters, to reset after the trial
+%    \begin{macrocode}
+  \def\@elt##1{\global\value{##1}\the\value{##1}\relax}%
+  \edef\TY at ckpt{\cl@@ckpt}%
+%    \end{macrocode}
+%
+%    \begin{macrocode}
   \expandafter\TY at tab\the\toks@
   \crcr\omit
   {\xdef\TY at save@row{}%
@@ -489,6 +515,7 @@
     \repeat}\TY at save@row
   \endarray\global\setbox1=\lastbox\setbox0=\vbox{\unvbox1
     \unskip\global\setbox1=\lastbox}\egroup
+  \ResumeTagging {tabulary}%
 %    \end{macrocode}
 % Check that |\tymin| is not too large.
 %    \begin{macrocode}
@@ -563,6 +590,11 @@
     \let\TY at box\TY at box@v
 %    \end{macrocode}
 %
+% Restore counter values.
+%    \begin{macrocode}
+    \TY at ckpt
+%    \end{macrocode}
+%
 % Run a second tabular, and for the star form, unbox it.
 %    \begin{macrocode}
   {\expandafter\TY at final\the\toks@\endTY at final}%
@@ -744,7 +776,7 @@
   \let\raggedleft\indent
   \let\arraybackslash\relax
   \prepnext at tok
-  \ifnum\@chnum<4 
+  \ifnum\@chnum<6
     \global\expandafter\let\csname TY at F\the\TY at count\endcsname\z@
   \fi
   \ifnum\@chnum=6
@@ -752,14 +784,19 @@
   \fi
   \@addtopreamble{%
     \ifcase\@chnum
-      \hfil \d at llarbegin\insert at column\d at llarend \hfil \or
-      \kern\z@
-       \d at llarbegin \insert at column \d at llarend \hfil \or
-      \hfil\kern\z@ \d at llarbegin \insert at column \d at llarend \or
-      $\vcenter\@startpbox{\@nextchar}\insert at column \@endpbox $\or
-      \vtop \@startpbox{\@nextchar}\insert at column \@endpbox \or
-      \vbox \@startpbox{\@nextchar}\insert at column \@endpbox \or
-      \d at llarbegin \insert at column \d at llarend \or% dubious "s" case
+      \hfil\hskip1sp%
+      \d at llarbegin\insert at column\d at llarend\do at row@strut\hfil \or
+      \hskip1sp%
+       \d at llarbegin \insert at column \d at llarend\do at row@strut\hfil \or
+       \hfil\hskip1sp%
+       \d at llarbegin \insert at column \d at llarend\do at row@strut \or
+    \setbox\ar at mcellbox\vbox
+    \@startpbox{\@nextchar}\insert at pcolumn \@endpbox
+    \ar at align@mcell
+    \do at row@strut\or
+      \vtop \@startpbox{\@nextchar}\insert at pcolumn \@endpbox \or
+      \vbox \@startpbox{\@nextchar}\insert at pcolumn \@endpbox \or
+      \d at llarbegin \insert at column \d at llarend \do at row@strut \or% dubious "s" case
       \TY at box\centering\or
       \TY at box\raggedright\or
       \TY at box\raggedleft\or
@@ -777,14 +814,16 @@
 %    \begin{macrocode}
 \def\TY at box#1{%
   \ifx\centering#1%
-      \hfil \d at llarbegin\insert at column\d at llarend \hfil \else
+    \hfil\hskip1sp%
+    \d at llarbegin\insert at column\d at llarend\do at row@strut \hfil \else
   \ifx\raggedright#1%
-        \kern\z@%<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
-      \d at llarbegin \insert at column \d at llarend \hfil \else
+      \hskip1sp%
+      \d at llarbegin \insert at column \d at llarend\do at row@strut \hfil \else
   \ifx\raggedleft#1%
-      \hfil\kern\z@ \d at llarbegin \insert at column \d at llarend \else
+    \hfil\hskip1sp%
+    \kern\z@ \d at llarbegin \insert at column \d at llarend\do at row@strut \else
   \ifx\relax#1%
-       \d at llarbegin \insert at column \d at llarend
+       \d at llarbegin \insert at column \d at llarend\do at row@strut
   \fi  \fi  \fi  \fi}
 %    \end{macrocode}
 % \end{macro}
@@ -796,7 +835,7 @@
 \def\TY at box@v#1{%
       \vtop \@startpbox{\csname TY at F\the\TY at count\endcsname}%
               #1\arraybackslash\tyformat
-                              \insert at column\@endpbox}
+                              \insert at pcolumn\@endpbox}
 %    \end{macrocode}
 %  \end{macro}
 %
@@ -896,7 +935,7 @@
   \let\arraybackslash\relax
   \prepnext at tok
 \expandafter\CT at extract\the\toks\@tempcnta\columncolor!\@nil
-  \ifnum\@chnum<4
+  \ifnum\@chnum<6
     \global\expandafter\let\csname TY at F\the\TY at count\endcsname\z@
   \fi
   \ifnum\@chnum=6
@@ -910,10 +949,13 @@
       \kern\z@%<<<<<<<<<<<<<<<<<<<<<<<<<<<
        \d at llarbegin \insert at column \d at llarend \hfill \or
       \hfill\kern\z@ \d at llarbegin \insert at column \d at llarend \or
-      $\vcenter\@startpbox{\@nextchar}\insert at column \@endpbox $\or
-      \vtop \@startpbox{\@nextchar}\insert at column \@endpbox \or
-      \vbox \@startpbox{\@nextchar}\insert at column \@endpbox \or
-      \d at llarbegin \insert at column \d at llarend \or% dubious s case
+    \setbox\ar at mcellbox\vbox
+    \@startpbox{\@nextchar}\insert at pcolumn \@endpbox
+    \ar at align@mcell
+    \do at row@strut \or
+      \vtop \@startpbox{\@nextchar}\insert at pcolumn \@endpbox \or
+      \vbox \@startpbox{\@nextchar}\insert at pcolumn \@endpbox \or
+      \d at llarbegin \insert at pcolumn \d at llarend \or% dubious s case
       \TY at box\centering\or
       \TY at box\raggedright\or
       \TY at box\raggedleft\or
@@ -999,9 +1041,40 @@
 %    \end{macrocode}
 %  \end{macro}
 %
+% \begin{macro}{\tblcrcrn}^^A L3 name
+%  Patch to ensure |\tbl_crcr:n| ends with |\crcr|.
+% (Will be fixed in later \LaTeX\ releases.
 %    \begin{macrocode}
+%<package>
+%    \end{macrocode}
+%
+%    \begin{macrocode}
+\ExplSyntaxOn
+\cs_set:Npn \@tempa #1 {
+     \int_compare:nNnT \g__tbl_col_int > 0
+         {
+           \tbl_count_missing_cells:n {#1}
+           \cr
+         }
+       }
+\ifx\@tempa\tbl_crcr:n
+\cs_set:Npn \tbl_crcr:n #1 {
+     \int_compare:nNnT \g__tbl_col_int > 0
+         {
+           \tbl_count_missing_cells:n {#1}
+         }
+     \crcr
+   }
+\fi   
+\let\@tempa\@undefined
+\ExplSyntaxOff
+%    \end{macrocode}
+%
+%    \begin{macrocode}
 %</package>
 %    \end{macrocode}
+% \end{macro}
+% 
 % \PrintIndex
 % \Finale
 %

Added: trunk/Master/texmf-dist/tex/latex/tabulary/tabulary-v010.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/tabulary/tabulary-v010.sty	                        (rev 0)
+++ trunk/Master/texmf-dist/tex/latex/tabulary/tabulary-v010.sty	2024-06-10 17:41:37 UTC (rev 71463)
@@ -0,0 +1,455 @@
+%%
+%% This is an old release of `tabulary.sty' used during rollback operations.
+%% Do not use this file directly.
+%% ==============================
+%%
+%% This is file `tabulary.sty',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% tabulary.dtx  (with options: `package')
+%% DRAFT VERSION
+%%
+%% File `tabulary.dtx'.
+%% Copyright (C) 1995 1996 2003 2008 David Carlisle
+%% This file may be distributed under the terms of the LPPL.
+%% See 00readme.txt for details.
+%%
+\NeedsTeXFormat{LaTeX2e}
+\ProvidesPackage{tabulary}
+          [2014/06/11 v0.10 tabulary package (DPC)]
+\RequirePackage{array}[=v2.5]
+\catcode`\Z=14
+\DeclareOption{debugshow}{\catcode`\Z=9\relax}
+\ProcessOptions
+\def\arraybackslash{\let\\=\@arraycr}
+\def\@finalstrut#1{%
+  \unskip\ifhmode\nobreak\fi\vrule\@width\z@\@height\z@\@depth\dp#1}
+\newcount\TY at count
+\def\tabulary{%
+  \let\TY at final\tabular
+  \let\endTY at final\endtabular
+  \TY at tabular}
+\def\TY at tabular#1{%
+  \edef\TY@{\@currenvir}%
+  {\ifnum0=`}\fi
+  \@ovxx\TY at linewidth
+  \@ovyy\TY at tablewidth
+  \count@\z@
+  \@tempswatrue
+  \@whilesw\if at tempswa\fi{%
+  \advance\count@\@ne
+  \expandafter\ifx\csname TY at F\the\count@\endcsname\relax
+    \@tempswafalse
+  \else
+    \expandafter\let\csname TY at SF\the\count@\expandafter\endcsname
+                     \csname TY at F\the\count@\endcsname
+    \global\expandafter\let\csname TY at F\the\count@\endcsname\relax
+    \expandafter\let\csname TY at S\the\count@\expandafter\endcsname
+                     \csname TY@\the\count@\endcsname
+  \fi}%
+    \global\TY at count\@ne
+    \TY at width\xdef{0pt}%
+    \global\TY at tablewidth\z@
+    \global\TY at linewidth#1\relax
+Z\message{^^J^^JTable^^J%
+Z        Target Width: \the\TY at linewidth^^J%
+Z        \string\tabcolsep: \the\tabcolsep\space
+Z        \string\arrayrulewidth: \the\arrayrulewidth\space
+Z        \string\doublerulesep: \the\doublerulesep^^J%
+Z        \string\tymin: \the\tymin\space
+Z        \string\tymax: \the\tymax^^J}%
+    \let\@classz\TY at classz
+    \let\verb\TX at verb
+    \toks@{}\TY at get@body}
+\let\TY@@mkpream\@mkpream
+\def\TY at mkpream{%
+    \def\@addamp{%
+      \if at firstamp \@firstampfalse \else
+      \global\advance\TY at count\@ne
+      \edef\@preamble{\@preamble &}\fi
+      \TY at width\xdef{0pt}}%
+    \def\@acol{%
+      \TY at subwidth\col at sep
+      \@addtopreamble{\hskip\col at sep}}%
+    \let\@arrayrule\TY at arrayrule
+    \let\@classvi\TY at classvi
+    \def\@classv{\save at decl
+      \expandafter\NC at ecs\@nextchar\extracolsep{}\extracolsep\@@@
+      \sbox\z@{\d at llarbegin\@nextchar\d at llarend}%
+      \TY at subwidth{\wd\z@}%
+      \@addtopreamble{\d at llarbegin\the at toks\the\count@\relax\d at llarend}%
+      \prepnext at tok}%
+  \global\let\@mkpream\TY@@mkpream
+  \TY@@mkpream}
+\def\TY at arrayrule{%
+  \TY at subwidth\arrayrulewidth
+  \@addtopreamble \vline}
+\def\TY at classvi{\ifcase \@lastchclass
+  \@acol \or
+  \TY at subwidth\doublerulesep
+  \@addtopreamble{\hskip \doublerulesep}\or
+  \@acol \or
+  \@classvii
+  \fi}
+\def\TY at tab{%
+  \setbox\z@\hbox\bgroup
+  \let\[$\let\]$%
+  \let\equation$\let\endequation$%
+    \col at sep\tabcolsep
+    \let\d at llarbegin\begingroup\let\d at llarend\endgroup
+    \let\@mkpream\TY at mkpream
+      \def\multicolumn##1##2##3{\multispan##1\relax}%
+    \CT at start\TY at tabarray}
+\def\TY at tabarray{\@ifnextchar[{\TY at array}{\@array[t]}}
+\def\TY at array[#1]{\@array[t]}
+\def\TY at width#1{%
+  \expandafter#1\csname TY@\the\TY at count\endcsname}
+\def\TY at subwidth#1{%
+  \TY at width\dimen@
+  \advance\dimen at -#1\relax
+  \TY at width\xdef{\the\dimen@}%
+  \global\advance\TY at linewidth-#1\relax}
+\def\endtabulary{%
+  \gdef\@halignto{}%
+  \expandafter\TY at tab\the\toks@
+  \crcr\omit
+  {\xdef\TY at save@row{}%
+     \loop
+    \advance\TY at count\m at ne
+    \ifnum\TY at count>\z@
+    \xdef\TY at save@row{\TY at save@row&\omit}%
+    \repeat}\TY at save@row
+  \endarray\global\setbox1=\lastbox\setbox0=\vbox{\unvbox1
+    \unskip\global\setbox1=\lastbox}\egroup
+  \dimen@\TY at linewidth
+  \divide\dimen@\TY at count
+  \ifdim\dimen@<\tymin
+    \TY at warn{tymin too large (\the\tymin), resetting to \the\dimen@}%
+    \tymin\dimen@
+  \fi
+  \setbox\tw@=\hbox{\unhbox\@ne
+    \loop
+\@tempdima=\lastskip
+\ifdim\@tempdima>\z@
+Z   \message{ecs=\the\@tempdima^^J}%
+   \global\advance\TY at linewidth-\@tempdima
+\fi
+    \unskip
+    \setbox\tw@=\lastbox
+    \ifhbox\tw@
+Z     \message{Col \the\TY at count: Initial=\the\wd\tw@\space}%
+      \ifdim\wd\tw@>\tymax
+        \wd\tw@\tymax
+Z       \message{> max\space}%
+Z     \else
+Z       \message{ \@spaces\space}%
+      \fi
+  \TY at width\dimen@
+Z \message{\the\dimen@\space}%
+  \advance\dimen@\wd\tw@
+Z \message{Final=\the\dimen@\space}%
+   \TY at width\xdef{\the\dimen@}%
+      \ifdim\dimen@<\tymin
+Z        \message{< tymin}%
+         \global\advance\TY at linewidth-\dimen@
+         \expandafter\xdef\csname TY at F\the\TY at count\endcsname
+                                                        {\the\dimen@}%
+       \else
+      \expandafter\ifx\csname TY at F\the\TY at count\endcsname\z@
+Z        \message{***}%
+         \global\advance\TY at linewidth-\dimen@
+         \expandafter\xdef\csname TY at F\the\TY at count\endcsname
+                                                        {\the\dimen@}%
+        \else
+Z        \message{> tymin}%
+         \global\advance\TY at tablewidth\dimen@
+         \global\expandafter\let\csname TY at F\the\TY at count\endcsname
+                                                               \maxdimen
+       \fi\fi
+       \advance\TY at count\m at ne
+    \repeat}%
+    \TY at checkmin
+    \TY at checkmin
+    \TY at checkmin
+    \TY at checkmin
+    \TY at count\z@
+    \let\TY at box\TY at box@v
+  {\expandafter\TY at final\the\toks@\endTY at final}%
+  \count@\z@
+  \@tempswatrue
+  \@whilesw\if at tempswa\fi{%
+  \advance\count@\@ne
+  \expandafter\ifx\csname TY at SF\the\count@\endcsname\relax
+    \@tempswafalse
+  \else
+    \global\expandafter\let\csname TY at F\the\count@\expandafter\endcsname
+                   \csname TY at SF\the\count@\endcsname
+    \global\expandafter\let\csname TY@\the\count@\expandafter\endcsname
+                   \csname TY at S\the\count@\endcsname
+  \fi}%
+  \TY at linewidth\@ovxx
+  \TY at tablewidth\@ovyy
+    \ifnum0=`{\fi}}
+\def\TY at checkmin{%
+  \let\TY at checkmin\relax
+\ifdim\TY at tablewidth>\z@
+  \Gscale at div\TY at ratio\TY at linewidth\TY at tablewidth
+ \ifdim\TY at tablewidth <\TY at linewidth
+   \def\TY at ratio{1}%
+ \fi
+\else
+  \TY at warn{No suitable columns!}%
+  \def\TY at ratio{1}%
+\fi
+\count@\z@
+Z \message{^^JLine Width: \the\TY at linewidth,
+Z             Natural Width: \the\TY at tablewidth,
+Z             Ratio: \TY at ratio^^J}%
+\@tempdima\z@
+\loop
+\ifnum\count@<\TY at count
+\advance\count@\@ne
+  \ifdim\csname TY at F\the\count@\endcsname>\tymin
+    \dimen@\csname TY@\the\count@\endcsname
+    \dimen@\TY at ratio\dimen@
+    \ifdim\dimen@<\tymin
+Z     \message{Column \the\count@\space ->}%
+      \global\expandafter\let\csname TY at F\the\count@\endcsname\tymin
+      \global\advance\TY at linewidth-\tymin
+      \global\advance\TY at tablewidth-\csname TY@\the\count@\endcsname
+      \let\TY at checkmin\TY@@checkmin
+    \else
+      \expandafter\xdef\csname TY at F\the\count@\endcsname{\the\dimen@}%
+      \advance\@tempdima\csname TY at F\the\count@\endcsname
+    \fi
+  \fi
+Z \dimen@\csname TY at F\the\count@\endcsname\message{\the\dimen@, }%
+\repeat
+Z \message{^^JTotal:\the\@tempdima^^J}%
+}
+\let\TY@@checkmin\TY at checkmin
+\newdimen\TY at linewidth
+\def\tyformat{\everypar{{\nobreak\hskip\z at skip}}}
+\newdimen\tymin
+\tymin=10pt
+\newdimen\tymax
+\tymax=2\textwidth
+\def\@testpach{\@chclass
+ \ifnum \@lastchclass=6 \@ne \@chnum \@ne \else
+  \ifnum \@lastchclass=7 5 \else
+   \ifnum \@lastchclass=8 \tw@ \else
+    \ifnum \@lastchclass=9 \thr@@
+   \else \z@
+   \ifnum \@lastchclass = 10 \else
+   \edef\@nextchar{\expandafter\string\@nextchar}%
+   \@chnum
+   \if \@nextchar c\z@ \else
+    \if \@nextchar l\@ne \else
+     \if \@nextchar r\tw@ \else
+   \if \@nextchar C7 \else
+    \if \@nextchar L8 \else
+     \if \@nextchar R9 \else
+     \if \@nextchar J10 \else
+   \z@ \@chclass
+   \if\@nextchar |\@ne \else
+    \if \@nextchar !6 \else
+     \if \@nextchar @7 \else
+      \if \@nextchar <8 \else
+       \if \@nextchar >9 \else
+  10
+  \@chnum
+  \if \@nextchar m\thr@@\else
+   \if \@nextchar p4 \else
+    \if \@nextchar b5 \else
+   \z@ \@chclass \z@ \@preamerr \z@ \fi \fi \fi \fi\fi \fi \fi\fi \fi
+     \fi  \fi  \fi  \fi  \fi  \fi \fi \fi \fi \fi \fi}
+\def\TY at classz{%
+  \@classx
+  \@tempcnta\count@
+  \ifx\TY at box\TY at box@v
+    \global\advance\TY at count\@ne
+  \fi
+  \let\centering c%
+  \let\raggedright\noindent
+  \let\raggedleft\indent
+  \let\arraybackslash\relax
+  \prepnext at tok
+  \ifnum\@chnum<4
+    \global\expandafter\let\csname TY at F\the\TY at count\endcsname\z@
+  \fi
+  \ifnum\@chnum=6
+    \global\expandafter\let\csname TY at F\the\TY at count\endcsname\z@
+  \fi
+  \@addtopreamble{%
+    \ifcase\@chnum
+      \hfil \d at llarbegin\insert at column\d at llarend \hfil \or
+      \kern\z@
+       \d at llarbegin \insert at column \d at llarend \hfil \or
+      \hfil\kern\z@ \d at llarbegin \insert at column \d at llarend \or
+      $\vcenter\@startpbox{\@nextchar}\insert at column \@endpbox $\or
+      \vtop \@startpbox{\@nextchar}\insert at column \@endpbox \or
+      \vbox \@startpbox{\@nextchar}\insert at column \@endpbox \or
+      \d at llarbegin \insert at column \d at llarend \or% dubious "s" case
+      \TY at box\centering\or
+      \TY at box\raggedright\or
+      \TY at box\raggedleft\or
+      \TY at box\relax
+    \fi}\prepnext at tok}
+\def\TY at box#1{%
+  \ifx\centering#1%
+      \hfil \d at llarbegin\insert at column\d at llarend \hfil \else
+  \ifx\raggedright#1%
+        \kern\z@%<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
+      \d at llarbegin \insert at column \d at llarend \hfil \else
+  \ifx\raggedleft#1%
+      \hfil\kern\z@ \d at llarbegin \insert at column \d at llarend \else
+  \ifx\relax#1%
+       \d at llarbegin \insert at column \d at llarend
+  \fi  \fi  \fi  \fi}
+\def\TY at box@v#1{%
+      \vtop \@startpbox{\csname TY at F\the\TY at count\endcsname}%
+              #1\arraybackslash\tyformat
+                              \insert at column\@endpbox}
+\newdimen\TY at tablewidth
+\def\Gscale at div#1#2#3{%
+  \setlength\dimen@{#3}%
+  \ifdim\dimen@=\z@
+    \PackageError{graphics}{Division by 0}\@eha
+    \dimen@#2%
+  \fi
+  \edef\@tempd{\the\dimen@}%
+  \setlength\dimen@{#2}%
+  \count at 65536\relax
+  \ifdim\dimen@<\z@
+    \dimen at -\dimen@
+    \count at -\count@
+  \fi
+  \loop
+    \ifdim\dimen@<8192\p@
+      \dimen@\tw@\dimen@
+      \divide\count@\tw@
+  \repeat
+  \dimen at ii=\@tempd\relax
+  \divide\dimen at ii\count@
+  \divide\dimen@\dimen at ii
+  \edef#1{\strip at pt\dimen@}}
+\long\def\TY at get@body#1\end
+  {\toks@\expandafter{\the\toks@#1}\TY at find@end}
+\def\TY at find@end#1{%
+  \def\@tempa{#1}%
+  \ifx\@tempa\TY@\def\@tempa{\end{#1}}\expandafter\@tempa
+  \else\toks@\expandafter
+    {\the\toks@\end{#1}}\expandafter\TY at get@body\fi}
+\def\TY at warn{%
+  \PackageWarning{tabulary}}
+\catcode`\Z=11
+\AtBeginDocument{
+\@ifpackageloaded{colortbl}{%
+\expandafter\def\expandafter\@mkpream\expandafter#\expandafter1%
+  \expandafter{%
+    \expandafter\let\expandafter\CT at setup\expandafter\relax
+    \expandafter\let\expandafter\CT at color\expandafter\relax
+    \expandafter\let\expandafter\CT at do@color\expandafter\relax
+    \expandafter\let\expandafter\color\expandafter\relax
+    \expandafter\let\expandafter\CT at column@color\expandafter\relax
+    \expandafter\let\expandafter\CT at row@color\expandafter\relax
+    \expandafter\let\expandafter\CT at cell@color\expandafter\relax
+    \@mkpream{#1}}
+\let\TY@@mkpream\@mkpream
+\def\TY at classz{%
+  \@classx
+  \@tempcnta\count@
+  \ifx\TY at box\TY at box@v
+    \global\advance\TY at count\@ne
+  \fi
+  \let\centering c%
+  \let\raggedright\noindent
+  \let\raggedleft\indent
+  \let\arraybackslash\relax
+  \prepnext at tok
+\expandafter\CT at extract\the\toks\@tempcnta\columncolor!\@nil
+  \ifnum\@chnum<4
+    \global\expandafter\let\csname TY at F\the\TY at count\endcsname\z@
+  \fi
+  \ifnum\@chnum=6
+    \global\expandafter\let\csname TY at F\the\TY at count\endcsname\z@
+  \fi
+  \@addtopreamble{%
+    \setbox\z@\hbox\bgroup\bgroup
+    \ifcase\@chnum
+      \hskip\stretch{.5}\kern\z@
+      \d at llarbegin\insert at column\d at llarend\hskip\stretch{.5}\or
+      \kern\z@%<<<<<<<<<<<<<<<<<<<<<<<<<<<
+       \d at llarbegin \insert at column \d at llarend \hfill \or
+      \hfill\kern\z@ \d at llarbegin \insert at column \d at llarend \or
+      $\vcenter\@startpbox{\@nextchar}\insert at column \@endpbox $\or
+      \vtop \@startpbox{\@nextchar}\insert at column \@endpbox \or
+      \vbox \@startpbox{\@nextchar}\insert at column \@endpbox \or
+      \d at llarbegin \insert at column \d at llarend \or% dubious s case
+      \TY at box\centering\or
+      \TY at box\raggedright\or
+      \TY at box\raggedleft\or
+      \TY at box\relax
+    \fi
+ \egroup\egroup
+\begingroup
+  \CT at setup
+  \CT at column@color
+  \CT at row@color
+  \CT at cell@color
+  \CT at do@color
+\endgroup
+        \@tempdima\ht\z@
+        \advance\@tempdima\minrowclearance
+        \vrule\@height\@tempdima\@width\z@
+\unhbox\z@
+}\prepnext at tok}%
+    \def\TY at arrayrule{%
+      \TY at subwidth\arrayrulewidth
+      \@addtopreamble{{\CT at arc@\vline}}}%
+    \def\TY at classvi{\ifcase \@lastchclass
+      \@acol \or
+      \TY at subwidth\doublerulesep
+      \ifx\CT at drsc@\relax
+        \@addtopreamble{\hskip\doublerulesep}%
+      \else
+        \@addtopreamble{{\CT at drsc@\vrule\@width\doublerulesep}}%
+      \fi\or
+      \@acol \or
+      \@classvii
+      \fi}%
+}{%
+\let\CT at start\relax
+}
+}
+{\uccode`\*=`\ %
+\uppercase{\gdef\TX at verb{%
+  \leavevmode\null\TX at vwarn
+  {\ifnum0=`}\fi\ttfamily\let\\\ignorespaces
+  \@ifstar{\let~*\TX at vb}{\TX at vb}}}}
+\def\TX at vb#1{\def\@tempa##1#1{\toks@{##1}\edef\@tempa{\the\toks@}%
+    \expandafter\TX at v\meaning\@tempa\\ \\\ifnum0=`{\fi}}\@tempa!}
+\def\TX at v#1!{\afterassignment\TX at vfirst\let\@tempa= }
+\begingroup
+\catcode`\*=\catcode`\#
+\catcode`\#=12
+\gdef\TX at vfirst{%
+  \if\@tempa#%
+    \def\@tempb{\TX at v@#}%
+  \else
+    \let\@tempb\TX at v@
+    \if\@tempa\space~\else\@tempa\fi
+  \fi
+  \@tempb}
+\gdef\TX at v@*1 *2{%
+  \TX at v@hash*1##\relax\if*2\\\else~\expandafter\TX at v@\fi*2}
+\gdef\TX at v@hash*1##*2{*1\ifx*2\relax\else#\expandafter\TX at v@hash\fi*2}
+\endgroup
+\def\TX at vwarn{%
+  \@warning{\noexpand\verb may be unreliable inside tabularx/y}%
+  \global\let\TX at vwarn\@empty}
+\endinput
+%%
+%% End of file `tabulary.sty'.


Property changes on: trunk/Master/texmf-dist/tex/latex/tabulary/tabulary-v010.sty
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Modified: trunk/Master/texmf-dist/tex/latex/tabulary/tabulary.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/tabulary/tabulary.sty	2024-06-09 23:41:30 UTC (rev 71462)
+++ trunk/Master/texmf-dist/tex/latex/tabulary/tabulary.sty	2024-06-10 17:41:37 UTC (rev 71463)
@@ -8,14 +8,16 @@
 %% DRAFT VERSION
 %%
 %% File `tabulary.dtx'.
-%% Copyright (C) 1995 1996 2003 2008 David Carlisle
+%% Copyright (C) 1995 1996 2003 2008 2024 David Carlisle
 %% This file may be distributed under the terms of the LPPL.
-%% See 00readme.txt for details.
+%% See README.txt for details.
 %%
 \NeedsTeXFormat{LaTeX2e}
 \ProvidesPackage{tabulary}
-          [2014/06/11 v0.10 tabulary package (DPC)]
-\RequirePackage{array}
+          [2024/06/04 v0.11 tabulary package (DPC)]
+\DeclareRelease{v0.10}{1995/10/08}{tabulary-v010.sty}
+\DeclareCurrentRelease{}{2024-06-01}
+\RequirePackage{array}[2024/05/23]
 \catcode`\Z=14
 \DeclareOption{debugshow}{\catcode`\Z=9\relax}
 \ProcessOptions
@@ -60,11 +62,12 @@
     \let\verb\TX at verb
     \toks@{}\TY at get@body}
 \let\TY@@mkpream\@mkpream
+\ExplSyntaxOn
 \def\TY at mkpream{%
     \def\@addamp{%
       \if at firstamp \@firstampfalse \else
       \global\advance\TY at count\@ne
-      \edef\@preamble{\@preamble &}\fi
+      \edef\@preamble{\@preamble & \noexpand\tbl_update_cell_data:}\fi
       \TY at width\xdef{0pt}}%
     \def\@acol{%
       \TY at subwidth\col at sep
@@ -72,7 +75,7 @@
     \let\@arrayrule\TY at arrayrule
     \let\@classvi\TY at classvi
     \def\@classv{\save at decl
-      \expandafter\NC at ecs\@nextchar\extracolsep{}\extracolsep\@@@
+      \expandafter\NC at ecs\@nextchar\extracolsep{}\extracolsep\@@__tbl
       \sbox\z@{\d at llarbegin\@nextchar\d at llarend}%
       \TY at subwidth{\wd\z@}%
       \@addtopreamble{\d at llarbegin\the at toks\the\count@\relax\d at llarend}%
@@ -79,6 +82,7 @@
       \prepnext at tok}%
   \global\let\@mkpream\TY@@mkpream
   \TY@@mkpream}
+\ExplSyntaxOff
 \def\TY at arrayrule{%
   \TY at subwidth\arrayrulewidth
   \@addtopreamble \vline}
@@ -108,7 +112,10 @@
   \TY at width\xdef{\the\dimen@}%
   \global\advance\TY at linewidth-#1\relax}
 \def\endtabulary{%
+  \SuspendTagging {tabulary}%
   \gdef\@halignto{}%
+  \def\@elt##1{\global\value{##1}\the\value{##1}\relax}%
+  \edef\TY at ckpt{\cl@@ckpt}%
   \expandafter\TY at tab\the\toks@
   \crcr\omit
   {\xdef\TY at save@row{}%
@@ -119,6 +126,7 @@
     \repeat}\TY at save@row
   \endarray\global\setbox1=\lastbox\setbox0=\vbox{\unvbox1
     \unskip\global\setbox1=\lastbox}\egroup
+  \ResumeTagging {tabulary}%
   \dimen@\TY at linewidth
   \divide\dimen@\TY at count
   \ifdim\dimen@<\tymin
@@ -172,6 +180,7 @@
     \TY at checkmin
     \TY at count\z@
     \let\TY at box\TY at box@v
+    \TY at ckpt
   {\expandafter\TY at final\the\toks@\endTY at final}%
   \count@\z@
   \@tempswatrue
@@ -272,7 +281,7 @@
   \let\raggedleft\indent
   \let\arraybackslash\relax
   \prepnext at tok
-  \ifnum\@chnum<4
+  \ifnum\@chnum<6
     \global\expandafter\let\csname TY at F\the\TY at count\endcsname\z@
   \fi
   \ifnum\@chnum=6
@@ -280,14 +289,19 @@
   \fi
   \@addtopreamble{%
     \ifcase\@chnum
-      \hfil \d at llarbegin\insert at column\d at llarend \hfil \or
-      \kern\z@
-       \d at llarbegin \insert at column \d at llarend \hfil \or
-      \hfil\kern\z@ \d at llarbegin \insert at column \d at llarend \or
-      $\vcenter\@startpbox{\@nextchar}\insert at column \@endpbox $\or
-      \vtop \@startpbox{\@nextchar}\insert at column \@endpbox \or
-      \vbox \@startpbox{\@nextchar}\insert at column \@endpbox \or
-      \d at llarbegin \insert at column \d at llarend \or% dubious "s" case
+      \hfil\hskip1sp%
+      \d at llarbegin\insert at column\d at llarend\do at row@strut\hfil \or
+      \hskip1sp%
+       \d at llarbegin \insert at column \d at llarend\do at row@strut\hfil \or
+       \hfil\hskip1sp%
+       \d at llarbegin \insert at column \d at llarend\do at row@strut \or
+    \setbox\ar at mcellbox\vbox
+    \@startpbox{\@nextchar}\insert at pcolumn \@endpbox
+    \ar at align@mcell
+    \do at row@strut\or
+      \vtop \@startpbox{\@nextchar}\insert at pcolumn \@endpbox \or
+      \vbox \@startpbox{\@nextchar}\insert at pcolumn \@endpbox \or
+      \d at llarbegin \insert at column \d at llarend \do at row@strut \or% dubious "s" case
       \TY at box\centering\or
       \TY at box\raggedright\or
       \TY at box\raggedleft\or
@@ -295,19 +309,21 @@
     \fi}\prepnext at tok}
 \def\TY at box#1{%
   \ifx\centering#1%
-      \hfil \d at llarbegin\insert at column\d at llarend \hfil \else
+    \hfil\hskip1sp%
+    \d at llarbegin\insert at column\d at llarend\do at row@strut \hfil \else
   \ifx\raggedright#1%
-        \kern\z@%<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<
-      \d at llarbegin \insert at column \d at llarend \hfil \else
+      \hskip1sp%
+      \d at llarbegin \insert at column \d at llarend\do at row@strut \hfil \else
   \ifx\raggedleft#1%
-      \hfil\kern\z@ \d at llarbegin \insert at column \d at llarend \else
+    \hfil\hskip1sp%
+    \kern\z@ \d at llarbegin \insert at column \d at llarend\do at row@strut \else
   \ifx\relax#1%
-       \d at llarbegin \insert at column \d at llarend
+       \d at llarbegin \insert at column \d at llarend\do at row@strut
   \fi  \fi  \fi  \fi}
 \def\TY at box@v#1{%
       \vtop \@startpbox{\csname TY at F\the\TY at count\endcsname}%
               #1\arraybackslash\tyformat
-                              \insert at column\@endpbox}
+                              \insert at pcolumn\@endpbox}
 \newdimen\TY at tablewidth
 \def\Gscale at div#1#2#3{%
   \setlength\dimen@{#3}%
@@ -366,7 +382,7 @@
   \let\arraybackslash\relax
   \prepnext at tok
 \expandafter\CT at extract\the\toks\@tempcnta\columncolor!\@nil
-  \ifnum\@chnum<4
+  \ifnum\@chnum<6
     \global\expandafter\let\csname TY at F\the\TY at count\endcsname\z@
   \fi
   \ifnum\@chnum=6
@@ -380,10 +396,13 @@
       \kern\z@%<<<<<<<<<<<<<<<<<<<<<<<<<<<
        \d at llarbegin \insert at column \d at llarend \hfill \or
       \hfill\kern\z@ \d at llarbegin \insert at column \d at llarend \or
-      $\vcenter\@startpbox{\@nextchar}\insert at column \@endpbox $\or
-      \vtop \@startpbox{\@nextchar}\insert at column \@endpbox \or
-      \vbox \@startpbox{\@nextchar}\insert at column \@endpbox \or
-      \d at llarbegin \insert at column \d at llarend \or% dubious s case
+    \setbox\ar at mcellbox\vbox
+    \@startpbox{\@nextchar}\insert at pcolumn \@endpbox
+    \ar at align@mcell
+    \do at row@strut \or
+      \vtop \@startpbox{\@nextchar}\insert at pcolumn \@endpbox \or
+      \vbox \@startpbox{\@nextchar}\insert at pcolumn \@endpbox \or
+      \d at llarbegin \insert at pcolumn \d at llarend \or% dubious s case
       \TY at box\centering\or
       \TY at box\raggedright\or
       \TY at box\raggedleft\or
@@ -446,6 +465,26 @@
 \def\TX at vwarn{%
   \@warning{\noexpand\verb may be unreliable inside tabularx/y}%
   \global\let\TX at vwarn\@empty}
+
+\ExplSyntaxOn
+\cs_set:Npn \@tempa #1 {
+     \int_compare:nNnT \g__tbl_col_int > 0
+         {
+           \tbl_count_missing_cells:n {#1}
+           \cr
+         }
+       }
+\ifx\@tempa\tbl_crcr:n
+\cs_set:Npn \tbl_crcr:n #1 {
+     \int_compare:nNnT \g__tbl_col_int > 0
+         {
+           \tbl_count_missing_cells:n {#1}
+         }
+     \crcr
+   }
+\fi
+\let\@tempa\@undefined
+\ExplSyntaxOff
 \endinput
 %%
 %% End of file `tabulary.sty'.



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