Use leaner TeX syntax (follow-up to #11319)

Because it is cool.  And avoids overhead.  Matter of principle.
This commit is contained in:
Jean-François B
2023-04-11 20:40:34 +02:00
parent 509cc4533c
commit b95fc0e88b
10 changed files with 24 additions and 24 deletions

View File

@@ -24,14 +24,14 @@
<% endif -%>
\makeatletter
<%- if table.align in ('center', 'default') %>
\setlength\LTleft{\@totalleftmargin plus1fill}
\setlength\LTright{\dimexpr\columnwidth-\@totalleftmargin-\linewidth\relax plus1fill}
\LTleft \@totalleftmargin plus1fill
\LTright\dimexpr\columnwidth-\@totalleftmargin-\linewidth\relax plus1fill
<%- elif table.align == 'left' %>
\setlength\LTleft{\@totalleftmargin}
\setlength\LTright{\dimexpr\columnwidth-\@totalleftmargin-\linewidth\relax plus1fill}
\LTleft \@totalleftmargin
\LTright\dimexpr\columnwidth-\@totalleftmargin-\linewidth\relax plus1fill
<%- elif table.align == 'right' %>
\setlength\LTleft{\@totalleftmargin plus1fill}
\setlength\LTright{\dimexpr\columnwidth-\@totalleftmargin-\linewidth\relax}
\LTleft \@totalleftmargin plus1fill
\LTright\dimexpr\columnwidth-\@totalleftmargin-\linewidth\relax
<%- endif %>
\makeatother
\begin{longtable}<%= table.get_colspec() %>

View File

@@ -5,8 +5,8 @@
\sphinxthistablewithglobalstyle
\sphinxthistablewithborderlessstyle
\makeatletter
\setlength\LTleft{\@totalleftmargin plus1fill}
\setlength\LTright{\dimexpr\columnwidth-\@totalleftmargin-\linewidth\relax plus1fill}
\LTleft \@totalleftmargin plus1fill
\LTright\dimexpr\columnwidth-\@totalleftmargin-\linewidth\relax plus1fill
\makeatother
\begin{longtable}{ll}
\sphinxtoprule

View File

@@ -4,8 +4,8 @@
\sphinxatlongtablestart
\sphinxthistablewithglobalstyle
\makeatletter
\setlength\LTleft{\@totalleftmargin plus1fill}
\setlength\LTright{\dimexpr\columnwidth-\@totalleftmargin-\linewidth\relax}
\LTleft \@totalleftmargin plus1fill
\LTright\dimexpr\columnwidth-\@totalleftmargin-\linewidth\relax
\makeatother
\begin{longtable}{|l|l|}
\sphinxtoprule

View File

@@ -4,8 +4,8 @@
\sphinxatlongtablestart
\sphinxthistablewithglobalstyle
\makeatletter
\setlength\LTleft{\@totalleftmargin plus1fill}
\setlength\LTright{\dimexpr\columnwidth-\@totalleftmargin-\linewidth\relax plus1fill}
\LTleft \@totalleftmargin plus1fill
\LTright\dimexpr\columnwidth-\@totalleftmargin-\linewidth\relax plus1fill
\makeatother
\begin{longtable}{|l|l|}
\sphinxthelongtablecaptionisattop

View File

@@ -4,8 +4,8 @@
\sphinxatlongtablestart
\sphinxthistablewithglobalstyle
\makeatletter
\setlength\LTleft{\@totalleftmargin plus1fill}
\setlength\LTright{\dimexpr\columnwidth-\@totalleftmargin-\linewidth\relax plus1fill}
\LTleft \@totalleftmargin plus1fill
\LTright\dimexpr\columnwidth-\@totalleftmargin-\linewidth\relax plus1fill
\makeatother
\begin{longtable}{|*{2}{\X{1}{2}|}}
\sphinxtoprule

View File

@@ -4,8 +4,8 @@
\sphinxatlongtablestart
\sphinxthistablewithglobalstyle
\makeatletter
\setlength\LTleft{\@totalleftmargin plus1fill}
\setlength\LTright{\dimexpr\columnwidth-\@totalleftmargin-\linewidth\relax plus1fill}
\LTleft \@totalleftmargin plus1fill
\LTright\dimexpr\columnwidth-\@totalleftmargin-\linewidth\relax plus1fill
\makeatother
\begin{longtable}{|*{3}{\X{1}{3}|}}
\sphinxtoprule

View File

@@ -4,8 +4,8 @@
\sphinxatlongtablestart
\sphinxthistablewithglobalstyle
\makeatletter
\setlength\LTleft{\@totalleftmargin plus1fill}
\setlength\LTright{\dimexpr\columnwidth-\@totalleftmargin-\linewidth\relax plus1fill}
\LTleft \@totalleftmargin plus1fill
\LTright\dimexpr\columnwidth-\@totalleftmargin-\linewidth\relax plus1fill
\makeatother
\begin{longtable}{|*{2}{\X{1}{2}|}}
\sphinxtoprule

View File

@@ -4,8 +4,8 @@
\sphinxatlongtablestart
\sphinxthistablewithglobalstyle
\makeatletter
\setlength\LTleft{\@totalleftmargin plus1fill}
\setlength\LTright{\dimexpr\columnwidth-\@totalleftmargin-\linewidth\relax plus1fill}
\LTleft \@totalleftmargin plus1fill
\LTright\dimexpr\columnwidth-\@totalleftmargin-\linewidth\relax plus1fill
\makeatother
\begin{longtable}{|\X{30}{100}|\X{70}{100}|}
\noalign{\phantomsection\label{\detokenize{longtable:namedlongtable}}\label{\detokenize{longtable:mylongtable}}}%

View File

@@ -4,8 +4,8 @@
\sphinxatlongtablestart
\sphinxthistablewithglobalstyle
\makeatletter
\setlength\LTleft{\@totalleftmargin plus1fill}
\setlength\LTright{\dimexpr\columnwidth-\@totalleftmargin-\linewidth\relax plus1fill}
\LTleft \@totalleftmargin plus1fill
\LTright\dimexpr\columnwidth-\@totalleftmargin-\linewidth\relax plus1fill
\makeatother
\begin{longtable}{|\X{30}{100}|\X{70}{100}|}
\sphinxtoprule

View File

@@ -5,8 +5,8 @@
\sphinxthistablewithglobalstyle
\sphinxthistablewithvlinesstyle
\makeatletter
\setlength\LTleft{\@totalleftmargin plus1fill}
\setlength\LTright{\dimexpr\columnwidth-\@totalleftmargin-\linewidth\relax plus1fill}
\LTleft \@totalleftmargin plus1fill
\LTright\dimexpr\columnwidth-\@totalleftmargin-\linewidth\relax plus1fill
\makeatother
\begin{longtable}{|c|c|}
\sphinxtoprule