mathml/luamml-patches-array.sty

72 lines
1.4 KiB
TeX

\ProvidesExplPackage {luamml-patches-array} {2021-04-23} {0.0.1-alpha}
{Feel free to add a description here}
\lua_now:n { require'luamml-array' }
\cs_set:Npn \@classz {
\@classx
\@tempcnta \count@
\prepnext@tok
\@addtopreamble {
\ifcase \@chnum
\hfil
\hskip 1sp
\d@llarbegin
\__luamml_array_init_col:
\insert@column
\luamml_flag_save:
\d@llarend
\__luamml_array_finalize_col:w 0~
\do@row@strut
\hfil
\or
\hskip 1sp
\d@llarbegin
\__luamml_array_init_col:
\insert@column
\luamml_flag_save:
\d@llarend
\__luamml_array_finalize_col:w 1~
\do@row@strut
\hfil
\or
\hfil
\hskip 1sp
\d@llarbegin
\__luamml_array_init_col:
\insert@column
\luamml_flag_save:
\d@llarend
\__luamml_array_finalize_col:w 2~
\do@row@strut
\or
\setbox \ar@mcellbox \vbox \@startpbox { \@nextchar }
\insert@column
\@endpbox
\ar@align@mcell
\do@row@strut
\or
\vtop \@startpbox { \@nextchar }
\insert@column
\@endpbox
\do@row@strut
\or
\vbox \@startpbox { \@nextchar }
\insert@column
\@endpbox
\do@row@strut
\fi
}
\prepnext@tok
}
\cs_set:Npn \endarray {
\crcr
\__luamml_array_save_array:
\egroup
\egroup
\__luamml_array_finalize_array:
\@arrayright
\gdef \@preamble {}
}