-
-
Notifications
You must be signed in to change notification settings - Fork 266
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1431 from latex3/tabular-math-grab
Support token-by-token math grabbing for tabulars
- Loading branch information
Showing
4 changed files
with
334 additions
and
18 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,47 @@ | ||
|
||
\ExplSyntaxOn | ||
\debug_on:n { check-declarations , deprecation } | ||
\ExplSyntaxOff | ||
|
||
|
||
\DocumentMetadata{testphase={phase-III,math}} | ||
|
||
\DebugBlocksOn | ||
|
||
\documentclass{article} | ||
\usepackage{array} | ||
|
||
\input{regression-test} | ||
|
||
|
||
\ExplSyntaxOn | ||
\cs_gset_protected:Npn \__math_grab_dollar:w { \__math_grab_dollar_loop: } | ||
\math_processor:n | ||
{ | ||
\TYPE {-----------------------------------} | ||
\TYPE { Math~env~#1 } | ||
\TYPE {\unexpanded{#2}} | ||
} | ||
\ExplSyntaxOff | ||
|
||
|
||
\begin{document} | ||
|
||
|
||
\START | ||
|
||
$y = mx + c$ | ||
|
||
\begin{tabular}{>{$}c<{$} >{$}c<{$}} | ||
a & b \\ | ||
c \\ | ||
d | ||
\end{tabular} | ||
|
||
\begin{tabular}{>{$}c<{$} >{$}c<{$}} | ||
x+\begin{minipage}[t]{1cm}some\\thing\end{minipage} \\ | ||
\shortstack{a\\b} & c \\ % ok | ||
\parbox{2cm}{a\\b} Z \\ % ok | ||
\end{tabular} | ||
|
||
\end{document} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,93 @@ | ||
This is a generated file for the l3build validation system. | ||
Don't change this file in any respect. | ||
----------------------------------- | ||
Math env math | ||
y=mx+c | ||
====>first-result=macro:->y=mx+c | ||
====>first-tmpmathcontent=macro:-> | ||
====>formula has no subparts | ||
----------------------------------- | ||
Math env math | ||
a | ||
====>first-result=macro:->a | ||
====>first-tmpmathcontent=macro:-> | ||
====>formula has no subparts | ||
----------------------------------- | ||
Math env math | ||
b | ||
====>first-result=macro:->b | ||
====>first-tmpmathcontent=macro:-> | ||
====>formula has no subparts | ||
----------------------------------- | ||
Math env math | ||
c | ||
====>first-result=macro:->c | ||
====>first-tmpmathcontent=macro:-> | ||
====>formula has no subparts | ||
----------------------------------- | ||
Math env math | ||
d | ||
====>first-result=macro:->d | ||
====>first-tmpmathcontent=macro:-> | ||
====>formula has no subparts | ||
----------------------------------- | ||
Math env math | ||
x+\begin {minipage}[t]{1cm}some\\thing\end {minipage} | ||
====>first-result=macro:->x+\begin {minipage}[t]{1cm}some\\thing\end {minipage} | ||
====>first-tmpmathcontent=macro:-> | ||
====>formula has no subparts | ||
Package tagpdf Warning: Parent-Child 'P/' --> 'Div/pdf2'. | ||
(tagpdf) Relation is not allowed (struct 15, /text --> struct | ||
(tagpdf) 17) on line ... | ||
Package tagpdf Warning: Parent-Child 'P/' --> 'text-unit/user'. | ||
(tagpdf) Relation is not allowed (struct 17, /Div --> struct | ||
(tagpdf) 18) on line ... | ||
Package tagpdf Warning: Parent-Child 'P/' --> 'text/user'. | ||
(tagpdf) Relation is not allowed (struct 18, /text-unit --> | ||
(tagpdf) struct 19) on line ... | ||
Package tagpdf Warning: Parent-Child 'P/' --> 'text/user'. | ||
(tagpdf) Relation is not allowed (struct 15, /text --> struct | ||
(tagpdf) 20) on line ... | ||
----------------------------------- | ||
Math env math | ||
\protect \shortstack {a\\b} | ||
====>first-result=macro:->\protect \shortstack {a\\b} | ||
====>first-tmpmathcontent=macro:-> | ||
====>formula has no subparts | ||
----------------------------------- | ||
Math env math | ||
c | ||
====>first-result=macro:->c | ||
====>first-tmpmathcontent=macro:-> | ||
====>formula has no subparts | ||
----------------------------------- | ||
Math env math | ||
\protect \parbox {2cm}{a\\b}Z | ||
====>first-result=macro:->\protect \parbox {2cm}{a\\b}Z | ||
====>first-tmpmathcontent=macro:-> | ||
====>formula has no subparts | ||
Package tagpdf Warning: Parent-Child 'P/' --> 'Div/pdf2'. | ||
(tagpdf) Relation is not allowed (struct 15, /text --> struct | ||
(tagpdf) 24) on line ... | ||
Package tagpdf Warning: Parent-Child 'P/' --> 'text-unit/user'. | ||
(tagpdf) Relation is not allowed (struct 24, /Div --> struct | ||
(tagpdf) 25) on line ... | ||
Package tagpdf Warning: Parent-Child 'P/' --> 'text/user'. | ||
(tagpdf) Relation is not allowed (struct 25, /text-unit --> | ||
(tagpdf) struct 26) on line ... | ||
Package tagpdf Warning: Parent-Child 'P/' --> 'text/user'. | ||
(tagpdf) Relation is not allowed (struct 15, /text --> struct | ||
(tagpdf) 27) on line ... | ||
[1 | ||
] (mathcapture-019.aux) | ||
Package tagpdf Info: Finalizing the tagging structure: | ||
(tagpdf) Writing out ~27 structure objects | ||
(tagpdf) with ~27 'MC' leaf nodes. | ||
(tagpdf) Be patient if there are lots of objects! | ||
Package tagpdf Info: writing ParentTree | ||
Package tagpdf Info: writing IDTree | ||
Package tagpdf Info: writing RoleMap | ||
Package tagpdf Info: writing ClassMap | ||
Package tagpdf Info: writing NameSpaces | ||
Package tagpdf Info: writing StructElems | ||
Package tagpdf Info: writing Root |