{smallmatrix}
This commit is contained in:
parent
d4c6d493d2
commit
cb5def2cb1
@ -63,6 +63,19 @@ do
|
||||
saved = mml_table
|
||||
end
|
||||
|
||||
funcid = luatexbase.new_luafunction'__luamml_amsmath_save_smallmatrix:'
|
||||
token.set_lua('__luamml_amsmath_save_smallmatrix:', funcid)
|
||||
lua.get_functions_table()[funcid] = function()
|
||||
-- TODO: Error handling etc
|
||||
local mml_table = get_table()
|
||||
mml_table.align = 'axis'
|
||||
mml_table.columnalign = 'center'
|
||||
mml_table.columnspacing = '0.278em'
|
||||
mml_table.rowspacing = string.format('%.3fpt', tex.lineskip.width/65781.76)
|
||||
saved = {[0] = 'mpadded', width = '+0.333em', lspace = '0.167em', mml_table}
|
||||
saved = mml_table
|
||||
end
|
||||
|
||||
funcid = luatexbase.new_luafunction'__luamml_amsmath_finalize_inner_table:'
|
||||
token.set_lua('__luamml_amsmath_finalize_inner_table:', funcid)
|
||||
lua.get_functions_table()[funcid] = function()
|
||||
|
@ -348,6 +348,57 @@
|
||||
$$
|
||||
}
|
||||
|
||||
% Finally some slightly different stuff.
|
||||
% While {matrix} is covered by {array}, we still have {smallmatrix}:
|
||||
\renewenvironment {smallmatrix} {
|
||||
\luamml_annotate:en {
|
||||
core = false
|
||||
} {
|
||||
\null
|
||||
\,
|
||||
}
|
||||
\vcenter \bgroup
|
||||
\Let@
|
||||
\restore@math@cr
|
||||
\default@tag
|
||||
\baselineskip 6 \ex@
|
||||
\lineskip 1.5 \ex@
|
||||
\lineskiplimit \lineskip
|
||||
\ialign \bgroup
|
||||
\hfil
|
||||
$
|
||||
\m@th
|
||||
\scriptstyle
|
||||
##
|
||||
\luamml_flag_save:n {mtd} % No \scriptsize here since we want to add the mstyle nodes
|
||||
$
|
||||
\__luamml_amsmath_add_last_to_row:
|
||||
\hfil
|
||||
&&
|
||||
\thickspace
|
||||
\hfil
|
||||
$
|
||||
\m@th
|
||||
\scriptstyle
|
||||
##
|
||||
\luamml_flag_save:n {mtd} % No \scriptsize here since we want to add the mstyle nodes
|
||||
$
|
||||
\__luamml_amsmath_add_last_to_row:
|
||||
\hfil
|
||||
\crcr
|
||||
}{%
|
||||
\crcr
|
||||
\__luamml_amsmath_save_smallmatrix:
|
||||
\egroup
|
||||
\egroup
|
||||
\__luamml_amsmath_finalize_inner_table:
|
||||
\luamml_annotate:en {
|
||||
core = false
|
||||
} {
|
||||
\,
|
||||
}
|
||||
}
|
||||
|
||||
\cs_set:Npn \bBigg@ #1 #2 {
|
||||
{
|
||||
\ensuremath {
|
||||
|
Loading…
Reference in New Issue
Block a user