Merge branch 'mathsockets'

This commit is contained in:
Marcel Fabian Krüger 2025-02-17 08:47:34 +01:00
commit ca8bd83702
25 changed files with 2959 additions and 1544 deletions

19
CHANGELOG.md Normal file
View File

@ -0,0 +1,19 @@
# Changelog
All notable changes to the `luamml` package since the
2025-02-17 will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
this project uses date-based 'snapshot' version identifiers.
## [Unreleased]
## 2025-02-17
### Changed
- Ulrike Fischer, 2024-11-29
luamml-structelemwriter.lua: moved the actualtext for e.g. stretched braces from the structure element to the mc-chunk.
- Ulrike Fischer, 2024-03-03
luamml.dtx: add plug for mbox socket to correctly annotate them in math.
- Ulrike Fischer, 2024-11-29
luamml-structelemwriter.lua: use structnum instead of label when stashing.

View File

@ -3,6 +3,7 @@ local make_root = require'luamml-convert'.make_root
local save_result = require'luamml-tex'.save_result
local store_column = require'luamml-table'.store_column
local store_tag = require'luamml-table'.store_tag
local store_notag = require'luamml-table'.store_notag
local get_table = require'luamml-table'.get_table
local set_row_attribute = require'luamml-table'.set_row_attribute
local to_text = require'luamml-lr'
@ -125,9 +126,9 @@ funcid = luatexbase.new_luafunction'__luamml_amsmath_set_tag:'
token.set_lua('__luamml_amsmath_set_tag:', funcid, 'protected')
lua.get_functions_table()[funcid] = function()
if not last_tag then
texio.write_nl'WARNING: Tag extraction failed'
return
end
store_notag({[0] = 'mtd',''})
else
store_tag({[0] = 'mtd', last_tag})
last_tag = nil
end
end

View File

@ -54,7 +54,7 @@ end
local saved_array
funcid = luatexbase.new_luafunction'__luamml_array_finalize_array:'
funcid = luatexbase.new_luafunction'__luamml_array_save_array:'
token.set_lua('__luamml_array_save_array:', funcid)
lua.get_functions_table()[funcid] = function()
-- TODO: Error handling etc.

View File

@ -370,7 +370,8 @@ local function radical_to_table(radical, sub, cur_style, text_families)
elem, core = {[0] = 'msqrt', nucleus, }, nil
elseif kind == 'uroot' then
-- FIXME: Check that this is really a root
elem, core = {[0] = 'msqrt', nucleus, kernel_to_table(radical.degree, 7, text_families)}, nil
-- UF 2024-12-04: force use of only one return value
elem, core = {[0] = 'mroot', nucleus, (kernel_to_table(radical.degree, 7, text_families))}, nil
elseif kind == 'uunderdelimiter' then
elem, core = {[0] = 'munder', left, nucleus}, left
elseif kind == 'uoverdelimiter' then

View File

@ -7,19 +7,18 @@
% But they are almost identical to the original and only
% add luamml commands in appropriate places, so they would
% mostly disappear if there were enough hooks in amsmath.
% aligned and friends
\cs_set:Npn \start@aligned #1#2 {
\IfPackageAtLeastTF{latex-lab-testphase-math}{2025-01-24}
{}
{
\PackageInfo{luamml}{patching~\string\start@aligned}
% aligned and friends
\cs_set:Npn \start@aligned #1#2 {
\RIfM@
\else
\nonmatherr@ { \begin { \@currenvir } }
\fi
\savecolumn@ % Assumption: called inside a group
\luamml_annotate:en {
core = false
} {
\alignedspace@left
}
\UseTaggingSocket{ math/luamml/annotate/false } {}{ \alignedspace@left }
\ams@start@box {#1} \bgroup
\maxfields@ #2 \relax
\ifnum \maxfields@ > \m@ne
@ -42,9 +41,9 @@
\m@th
\displaystyle
{##}
\luamml_save:nNn {} \displaystyle {mtd}
\UseTaggingSocket{math/luamml/save/nNn}{ {} \displaystyle {mtd}}
$
\__luamml_amsmath_add_last_to_row:
\UseTaggingSocket{math/luamml/mtable/finalizecol}{last}
\tabskip \z@skip
& \column@plus
$
@ -54,25 +53,21 @@
{}
##
}
\luamml_save:nNn {} \displaystyle {mtd}
\UseTaggingSocket{math/luamml/save/nNn}{ {} \displaystyle {mtd}}
$
\__luamml_amsmath_add_last_to_row:
\UseTaggingSocket{math/luamml/mtable/finalizecol}{last}
\hfil
\tabskip\alignsep@
\crcr
\ams@return@opt@arg
}
\renewcommand \gathered [1] [c] {
}
\PackageInfo{luamml}{patching~gathered}
\renewcommand \gathered [1] [c] {
\RIfM@
\else
\nonmatherr@ { \begin {gathered} }
\fi
\luamml_annotate:en {
core = false
} {
\alignedspace@left
}
\UseTaggingSocket{ math/luamml/annotate/false } {}{ \alignedspace@left }
\ams@start@box {#1} \bgroup
\Let@
\chardef \dspbrk@context \@ne
@ -85,25 +80,24 @@
\m@th
\displaystyle
##
\luamml_save:nNn {} \displaystyle {mtd}
\UseTaggingSocket{math/luamml/save/nNn}{ {} \displaystyle {mtd}}
$
\__luamml_amsmath_add_last_to_row:
\UseTaggingSocket{math/luamml/mtable/finalizecol}{last}
\hfil
\crcr
\ams@return@opt@arg
}
\cs_set:Npn \endaligned {
}
\PackageInfo{luamml}{patching~\string\endaligned}
\cs_set:Npn \endaligned {
\crcr
\__luamml_amsmath_save_inner_table:n \@currenvir
\UseExpandableTaggingSocket{math/luamml/mtable/innertable/save}
\egroup
\restorecolumn@
\egroup
\__luamml_amsmath_finalize_inner_table:
}
% gather
\cs_set:Npn \gather@ #1 {
\UseTaggingSocket{math/luamml/mtable/innertable/finalize}
}
\PackageInfo{luamml}{patching~\string\gather@}
\cs_set:Npn \gather@ #1 {
\ingather@true
\let \split \insplit@
\let \tag \tag@in@align
@ -122,10 +116,10 @@
\m@th
\displaystyle
{##}
\luamml_save:nNn {} \displaystyle {mtd}
\UseTaggingSocket{math/luamml/save/nNn}{ {} \displaystyle {mtd}}
$
}
\__luamml_amsmath_add_box_to_row:
\UseTaggingSocket{math/luamml/mtable/finalizecol}{box}
\calc@shift@gather
\set@gather@field
\tabskip\@centering
@ -134,12 +128,14 @@
\strut@
{##}
}
\dim_compare:nNnF {0pt} = {
\dim_compare:nNnTF {0pt} = {
\box_wd:N \c_zero_int
} {
\__luamml_amsmath_set_tag:
}
{ \place@tag@gather }
{
\place@tag@gather
\UseTaggingSocket{math/luamml/mtable/tag/set}
}
\tabskip \iftagsleft@
\gdisplaywidth@
\else
@ -147,27 +143,32 @@
\span \fi
\crcr
#1
}
\cs_new_eq:NN \__luamml_amsmath_original_gmeasure:n \gmeasure@
\cs_set:Npn \gmeasure@ #1 {
}
% in latex lab, add the luamml_ignore to \measuring@true instead.
\PackageInfo{luamml}{patching~\string\gmeasure@}
\cs_new_eq:NN \__luamml_amsmath_original_gmeasure:n \gmeasure@
\cs_set:Npn \gmeasure@ #1 {
\exp_last_unbraced:Nno
\use_ii_i:nn
{ \luamml_ignore: }
{ \__luamml_amsmath_original_gmeasure:n {#1} }
}
}
\cs_set:Npn \endgather {
\PackageInfo{luamml}{patching~\string\endgather}
\cs_set:Npn \endgather {
\math@cr
\black@ \totwidth@
\__luamml_amsmath_finalize_table:n {gather}
\UseExpandableTaggingSocket{math/luamml/mtable/finalize} {gather}
\egroup
$$
\ignorespacesafterend
}
}
% align and friends
\cs_set:Npn \align@preamble {
\PackageInfo{luamml}{patching~\string\align@preamble}
\cs_set:Npn \align@preamble {
&
\hfil
\strut@
@ -180,14 +181,14 @@
\ifmeasuring@
\luamml_ignore:
\else
\luamml_save:nNn {} \displaystyle {mtd}
\UseTaggingSocket{math/luamml/save/nNn}{ {} \displaystyle {mtd}}
\fi
$
}
\ifmeasuring@
\savefieldlength@
\else
\__luamml_amsmath_add_box_to_row:
\UseTaggingSocket{math/luamml/mtable/finalizecol}{box}
\fi
\set@field
\tabskip\z@skip
@ -204,21 +205,21 @@
\ifmeasuring@
\luamml_ignore:
\else
\luamml_save:nNn {} \displaystyle {mtd}
\UseTaggingSocket{math/luamml/save/nNn}{ {} \displaystyle {mtd}}
\fi
$
}
\ifmeasuring@
\savefieldlength@
\else
\__luamml_amsmath_add_box_to_row:
\UseTaggingSocket{math/luamml/mtable/finalizecol}{box}
\fi
\set@field
\hfil
\tabskip\alignsep@
}
\cs_set:Npn \math@cr@@@align {
}
\PackageInfo{luamml}{patching~\string\math@cr@@@align}
\cs_set:Npn \math@cr@@@align {
\ifst@rred
\nonumber
\fi
@ -236,7 +237,7 @@
{ \make@display@tag }
}
\place@tag
\__luamml_amsmath_set_tag:
\UseTaggingSocket{math/luamml/mtable/tag/set}
\fi
\ifst@rred
\else
@ -244,21 +245,26 @@
\fi
\global \lineht@ \z@
\cr
}
}
\cs_set:Npn \maketag@@@ #1 {
% This was lost anyway, as the latex-lab code overwrites
% the definition again.
\PackageInfo{luamml}{patching~\string\maketag@@@}
\cs_set:Npn \maketag@@@ #1
{
\hbox {
\m@th
\normalfont
#1
\__luamml_amsmath_save_tag:
\UseTaggingSocket{math/luamml/mtable/tag/save}
}
}
\cs_set:Npn \endalign {
}
\PackageInfo{luamml}{patching~\string\endalign}
% this handled in latex-lab through \common@align@ending
\cs_set:Npn \endalign {
\math@cr
\black@ \totwidth@
\__luamml_amsmath_finalize_table:n {align}
\UseTaggingSocket{math/luamml/mtable/finalize} {align}
\egroup
\ifingather@
\restorealignstate@
@ -269,45 +275,49 @@
$$
\fi
\ignorespacesafterend
}
}
% For a more interesting one, let's consider multline:
\cs_new_eq:NN \__luamml_amsmath_original_multline:n \multline@
\cs_set:Npn \multline@ #1 {
\PackageInfo{luamml}{patching~\string\multline@}
% For a more interesting one, let's consider multline:
\cs_new_eq:NN \__luamml_amsmath_original_multline:n \multline@
\cs_set:Npn \multline@ #1 {
\__luamml_amsmath_original_multline:n {
\ifmeasuring@ \else
\__luamml_amsmath_set_row_columnalign:n {left}
\UseTaggingSocket{math/luamml/mtable/aligncol} {left}
\fi
#1
\ifmeasuring@ \else
\__luamml_amsmath_set_row_columnalign:n {right}
\UseTaggingSocket{math/luamml/mtable/aligncol} {right}
\fi
}
}
}
\cs_new_eq:NN \__luamml_amsmath_original_mmeasure:n \mmeasure@
\cs_set:Npn \mmeasure@ #1 {
%this is not move to latex-lab as the luamml_ignore is inserting with
% \measuringtrue
\PackageInfo{luamml}{patching~\string\mmeasure@}
\cs_new_eq:NN \__luamml_amsmath_original_mmeasure:n \mmeasure@
\cs_set:Npn \mmeasure@ #1 {
\exp_last_unbraced:Nno
\use_ii_i:nn
{ \luamml_ignore: }
{ \__luamml_amsmath_original_mmeasure:n {#1} }
}
}
% Luckily, {multline} uses \endmultline@math in exactly
% the spot where we have to set the flag.
% Less luckily, \endmultline@math sometimes get overwritten for the last line.
% But that isn't a problem since we want special behavior there anyway.
\cs_set:Npn \endmultline@math {
\luamml_save:nNn {} \displaystyle {mtd}
\PackageInfo{luamml}{patching~\string\endmultline@math}
\cs_set:Npn \endmultline@math {
\UseTaggingSocket{math/luamml/save/nNn}{{} \displaystyle {mtd}}
$
\__luamml_amsmath_add_last_to_row:
}
\cs_set:Npn \rendmultline@ {
\UseTaggingSocket{math/luamml/mtable/finalizecol}{last}
}
\PackageInfo{luamml}{patching~\string\rendmultline@}
\cs_set:Npn \rendmultline@ {
\iftag@
\luamml_save:nNn {} \displaystyle {mtd}
\UseTaggingSocket{math/luamml/save/nNn}{{} \displaystyle {mtd}}
$
\__luamml_amsmath_add_last_to_row:
\UseTaggingSocket{math/luamml/mtable/finalizecol}{last}
\let \endmultline@math \relax
\ifshifttag@
\hskip \multlinegap
@ -328,35 +338,30 @@
\hskip \multlinetaggap
\make@display@tag
\fi
\__luamml_amsmath_set_tag:
\UseTaggingSocket{math/luamml/mtable/tag/set}
\else
\hskip \multlinegap
\fi
\hfilneg
\math@cr
\__luamml_amsmath_finalize_table:n {multline}
\UseExpandableTaggingSocket {math/luamml/mtable/finalize} {multline}
\egroup
$$
}
\cs_set:Npn \lendmultline@ {
}
\PackageInfo{luamml}{patching~\string\lendmultline@}
\cs_set:Npn \lendmultline@ {
\hfilneg
\hskip\multlinegap
\math@cr
\__luamml_amsmath_finalize_table:n {multline}
\UseExpandableTaggingSocket {math/luamml/mtable/finalize} {multline}
%\__luamml_amsmath_finalize_table:n {multline}
\egroup
$$
}
% Finally some slightly different stuff.
% While {matrix} is covered by {array}, we still have {smallmatrix}:
\renewenvironment {smallmatrix} {
\luamml_annotate:en {
core = false
} {
\null
\,
}
\PackageInfo{luamml}{patching~smallmatrix}
\renewenvironment {smallmatrix} {
\UseTaggingSocket{ math/luamml/annotate/false } {} { \null\, }
\vcenter \bgroup
\Let@
\restore@math@cr
@ -370,9 +375,10 @@
\m@th
\scriptstyle
##
\luamml_save:nn {} {mtd} % No \scriptsize here since we want to add the mstyle nodes
% No \scriptsize here since we want to add the mstyle nodes
\UseTaggingSocket{math/luamml/save/nn}{ {} {mtd}}
$
\__luamml_amsmath_add_last_to_row:
\UseTaggingSocket{math/luamml/mtable/finalizecol}{last}
\hfil
&&
\thickspace
@ -381,37 +387,35 @@
\m@th
\scriptstyle
##
\luamml_save:nn {} {mtd} % No \scriptsize here since we want to add the mstyle nodes
% No \scriptsize here since we want to add the mstyle nodes
\UseTaggingSocket{math/luamml/save/nn}{ {} {mtd}}
$
\__luamml_amsmath_add_last_to_row:
\UseTaggingSocket{math/luamml/mtable/finalizecol}{last}
\hfil
\crcr
}{%
}{%
\crcr
\__luamml_amsmath_save_smallmatrix:
\UseExpandableTaggingSocket{math/luamml/mtable/smallmatrix/save}
\egroup
\egroup
\__luamml_amsmath_finalize_inner_table:
\luamml_annotate:en {
core = false
} {
\,
\UseTaggingSocket{math/luamml/mtable/innertable/finalize}
\UseTaggingSocket{math/luamml/annotate/false} {}{ \, }
}
}
% {cases} is defined by the kernel, but we patch the overwritten version by amsmath.
\cs_set:Npn \env@cases {
% {cases} is defined by the kernel, but we patch the overwritten version by amsmath.
\PackageInfo{luamml}{patching~\string\env@cases}
\cs_set:Npn \env@cases {
\let \@ifnextchar \new@ifnextchar
\left \lbrace
\def \arraystretch {1.2}
\array {@{}l@{\quad \luamml_ignore:}l@{}}
}
\cs_set:Npn \bBigg@ #1 #2 {
}
\PackageInfo{luamml}{patching~\string\bBigg@}
\cs_set:Npn \bBigg@ #1 #2 {
{
\ensuremath {
\Uvextensible height~#1 \big@size axis~exact~#2
}
}
}
}
} %end package test

View File

@ -1,37 +1,29 @@
\ProvidesExplPackage {luamml-patches-amstext} {2024-10-30} {0.2.0}
{Feel free to add a description here}
{patches of amstext commands}
\int_new:N \g__luamml_amsmath_text_struct_int
\cs_set:Npn \textdef@ #1 #2 #3 {
\int_if_odd:nTF { \int_div_truncate:nn { \l__luamml_flag_int } { 8 } } {
\int_gincr:N \g__luamml_amsmath_text_struct_int
\tag_struct_begin:n {
tag = mtext/mathml,
stash,
label = __luamml_amsmath_text_ \int_use:N \g__luamml_amsmath_text_struct_int
}
\tag_mc_begin:n {
tag = mtext
}
\AnnotateFormula {
nucleus = true,
struct = "__luamml_amsmath_text_ \int_use:N \g__luamml_amsmath_text_struct_int"
}
} {
\use:n
}
% This is the same definition as in latex-lab-amsmath. It can go with the
% 2025-06-01 release.
\IfPackageAtLeastTF{latex-lab-testphase-math}{2025-01-24}
{}
{
\hbox {
\PackageInfo{luamml}{patching~\string\text@}
\sys_if_engine_luatex:T
{
\everymath {#1}
\let \f@size #2
\selectfont
#3
\def\text@#1{
\tag_socket_use:nnn {math/luamml/hbox}{}
{{%
\ifcase\mathstyle
\hbox{{#1}}\or
\hbox{{#1}}\or
\hbox{{#1}}\or
\hbox{{#1}}\or
\hbox{{\let\f@size\sf@size\selectfont#1}}\or
\hbox{{\let\f@size\sf@size\selectfont#1}}\or
\hbox{{\let\f@size\ssf@size\selectfont#1}}\or
\hbox{{\let\f@size\ssf@size\selectfont#1}}\or
\ERROR
\fi
\check@mathfonts
}}}
}
}
}
\int_if_odd:nT { \int_div_truncate:nn { \l__luamml_flag_int } { 8 } } {
\tag_mc_end:
\tag_struct_end:
}
}

View File

@ -1,101 +0,0 @@
\ProvidesExplPackage {luamml-patches-array} {2024-10-30} {0.2.0}
{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
\cs_if_eq:NNTF \d@llarbegin \begingroup {
\insert@column
\d@llarend
} {
\__luamml_array_init_col:
\insert@column
\luamml_save:nn {} {mtd}
\d@llarend
\__luamml_array_finalize_col:w 0~
}
\do@row@strut
\hfil
\or
\hskip 1sp
\d@llarbegin
\cs_if_eq:NNTF \d@llarbegin \begingroup {
\insert@column
\d@llarend
} {
\__luamml_array_init_col:
\insert@column
\luamml_save:nn {} {mtd}
\d@llarend
\__luamml_array_finalize_col:w 1~
}
\do@row@strut
\hfil
\or
\hfil
\hskip 1sp
\d@llarbegin
\cs_if_eq:NNTF \d@llarbegin \begingroup {
\insert@column
\d@llarend
} {
\__luamml_array_init_col:
\insert@column
\luamml_save:nn {} {mtd}
\d@llarend
\__luamml_array_finalize_col:w 2~
}
\do@row@strut
\or
\setbox \ar@mcellbox \vbox \@startpbox { \@nextchar }
\insert@pcolumn
\@endpbox
\ar@align@mcell
\do@row@strut
\or
\vtop \@startpbox { \@nextchar }
\insert@pcolumn
\@endpbox
\do@row@strut
\or
\vbox \@startpbox { \@nextchar }
\insert@pcolumn
\@endpbox
\do@row@strut
\fi
}
\prepnext@tok
}
\IfPackageAtLeastTF {array} {2023/12/11} {
\cs_set:Npn \endarray {
\tbl_crcr:n{endarray}
\__luamml_array_save_array:
\egroup
\UseTaggingSocket{tbl/finalize}
\tbl_restore_outer_cell_data:
\egroup
\mode_if_math:T { \__luamml_array_finalize_array: }
\@arrayright
\gdef \@preamble {}
}
} {
\cs_new_eq:NN \insert@pcolumn \insert@column
\cs_set:Npn \endarray {
\crcr
\__luamml_array_save_array:
\egroup
\egroup
\mode_if_math:T { \__luamml_array_finalize_array: }
\@arrayright
\gdef \@preamble {}
}
}

View File

@ -1,7 +1,12 @@
\ProvidesExplPackage {luamml-patches-kernel} {2024-10-30} {0.2.0}
{Feel free to add a description here}
\cs_set:Npn \mathsm@sh #1 #2 {
\IfPackageAtLeastTF{latex-lab-testphase-math}{2025-01-24}
{}
{
\PackageInfo{luamml}{patching~\string\mathsm@sh}
\cs_set:Npn \mathsm@sh #1 #2 {
\setbox \z@ \hbox {
$
\m@th #1 {
@ -20,9 +25,10 @@
{}
\finsm@sh
}
}
}
\cs_set:Npn \mathph@nt #1 #2 {
\PackageInfo{luamml}{patching~\string\mathph@nt}
\cs_set:Npn \mathph@nt #1 #2 {
\setbox \z@ = \hbox {
$
\m@th
@ -45,8 +51,14 @@
} {
\finph@nt
}
}
}
\IfFileLoadedT {latex-lab-math.ltx} {
\RequirePackage{luamml-patches-lab-math}
}
}
% This is not moved to latex-lab for now. It doesn't work properly with structure elements
% active: the content is outside of the math.
\@ifpackageloaded {unicode-math} {} {
\cs_new:Npn \__luamml_kernel_define_character:Nnn #1#2#3 {
\cs_set:cpx { \cs_to_str:N #1 ~ } {
@ -70,7 +82,3 @@
\__luamml_kernel_define_character:Nnn \longleftrightarrow {3} {27f7}
\__luamml_kernel_define_character:Nnn \longmapsto {4} {27fc}
}
\IfFileLoadedT {latex-lab-math.ltx} {
\RequirePackage{luamml-patches-lab-math}
}

View File

@ -1,11 +1,17 @@
\ProvidesExplPackage {luamml-patches-lab-math} {2024-10-30} {0.2.0}
{Feel free to add a description here}
\AddToHook{begindocument} {
% This definition is identical to the one in latex-lab-math.
% The redefinition and the whole patch file can be removed in 2025-06-01
\IfPackageAtLeastTF{latex-lab-testphase-math}{2025-01-24}
{}
{
\AddToHook{begindocument} {
\PackageInfo{luamml}{patching~\string\common@align@ending}
\cs_set:Npn \common@align@ending {
\math@cr
\black@ \totwidth@
\__luamml_amsmath_finalize_table:n {align}
\UseExpandableTaggingSocket{math/luamml/mtable/finalize}{align}
\egroup
\ifingather@
\restorealignstate@
@ -17,4 +23,5 @@
\fi
\ignorespacesafterend
}
}
}

View File

@ -1,9 +1,11 @@
\ProvidesExplPackage {luamml-patches-mathtools} {2024-10-26} {0.2.0}
{Feel free to add a description here}
\RequirePackage{luamml-patches-amsmath}
% see https://github.com/latex3/tagging-project/issues/734
\renewcommand*\MT_mult_internal:n [1]{
\IfPackageAtLeastTF{latex-lab-testphase-math}{2025-01-24}
{}
{
\RequirePackage{luamml-patches-amsmath}
% see https://github.com/latex3/tagging-project/issues/734
\renewcommand*\MT_mult_internal:n [1]{
\MH_if_boolean:nF {outer_mult}{\alignedspace@left} %<-- requires amsmath 2016/11/05
\MT_next:
\bgroup
@ -25,11 +27,12 @@
\MH_fi:
\ialign\bgroup
\hfil\strut@$\m@th\displaystyle{}##
\luamml_save:nNn {} \displaystyle {mtd}
\UseTaggingSocket{math/luamml/save/nNn}{ {} \displaystyle {mtd}}
$
\__luamml_amsmath_add_last_to_row:
\UseTaggingSocket{math/luamml/mtable/finalizecol}{last}
\hfil
\crcr
\hfilneg
#1
}
}

View File

@ -6,6 +6,14 @@ local struct_end = token.create'tag_struct_end:'
local mc_begin = token.create'tag_mc_begin:n'
local mc_end = token.create'tag_mc_end:'
local catlatex = luatexbase.registernumber("catcodetable@latex")
ltx = ltx or {}
ltx.__tag = ltx.__tag or {}
ltx.__tag.struct = ltx.__tag.struct or {}
ltx.__tag.struct.luamml = ltx.__tag.struct.luamml or {}
ltx.__tag.struct.luamml.labels = ltx.__tag.struct.luamml.labels or {}
local function escape_name(name)
return name
end
@ -44,7 +52,7 @@ local attributes = setmetatable({}, {__index = function(t, k)
local attr_name = string.format('luamml_attr_%i', attribute_counter)
t[k] = attr_name
tex.runtoks(function()
tex.sprint(string.format('\\tagpdfsetup{newattribute={%s}{/O/NSO/NS %i 0 R',
tex.sprint(catlatex,string.format('\\tagpdfsetup{newattribute={%s}{/O/NSO/NS %i 0 R',
attr_name, mathml_ns_obj or get_mathml_ns_obj()))
-- tex.sprint(string.format('\\tagpdfsetup{newattribute={%s}{/O/MathML-3',
-- attr_name))
@ -81,28 +89,27 @@ local function write_elem(tree, stash)
table.sort(attrs)
if stash then
stash_cnt = stash_cnt + 1
stash = '__luamml_stashed_' .. stash_cnt
tree[':struct'] = stash
stash = ', stash, label = ' .. stash
tree[':structnum'] = get_ltx().tag.get_struct_num_next()
stash = ', stash, '
end
local attr_flag = i ~= 0 and ', attribute=' .. attributes[table.concat(attrs)]
tex.sprint(struct_begin, '{tag=' .. tree[0] .. '/mathml')
if stash then tex.sprint(stash) end
if attr_flag then tex.sprint(attr_flag) end
if tree[':actual'] then
tex.sprint(', actualtext = {')
tex.cprint(12, tree[':actual'])
tex.sprint'}'
end
tex.sprint'}'
for j = 1, i do attrs[j] = nil end
if tree[':nodes'] then
local n = tree[':nodes']
tex.runtoks(function()
if tree[':actual'] then
tex.sprint(mc_begin,'{tag=Span,actualtext=')
tex.cprint(12,tree[':actual'])
tex.sprint('}')
else
tex.sprint{mc_begin, string.format('{tag=%s}', tree[0])}
end
-- NOTE: This will also flush all previous sprint's... That's often annoying, but in this case actually intentional.
end)
local mct, mcc = tex.attribute[mc_type], tex.attribute[mc_cnt]
@ -115,7 +122,14 @@ local function write_elem(tree, stash)
end)
end
for _, elem in ipairs(tree) do
if type(elem) ~= 'string' then
if type(elem) ~= 'string' and not elem['tex:ignore'] then
if elem['intent']==':equationlabel' and ltx.__tag.struct.luamml.labels then
if #ltx.__tag.struct.luamml.labels > 0 then
-- print("CHECK LABEL STRUCTURE: ",table.serialize(elem), table.serialize(ltx.__tag.struct.luamml.labels))
local num= table.remove(ltx.__tag.struct.luamml.labels,1)
elem[1][#elem+1]={[':structnum']= num}
end
end
write_elem(elem)
end
end

View File

@ -63,6 +63,12 @@ local function store_tag(xml)
last_tag = nil
end
local function store_notag(xml)
local mml_row = store_get_row()
xml.intent = ':noequationlabel'
table.insert(mml_row, 1, xml)
end
local function set_row_attribute(name, value)
local mml_row = store_get_row()
mml_row[name] = value
@ -105,6 +111,7 @@ return {
store_column = store_column,
store_column_xml = store_column_xml,
store_tag = store_tag,
store_notag = store_notag,
set_row_attribute = set_row_attribute,
get_table = get_table,
}

View File

@ -48,7 +48,9 @@ local function write_elem(tree, indent)
out = out .. escape_text(elem)
is_string = true
else
if not elem['tex:ignore'] then
out = out .. write_elem(elem, inner_indent)
end
is_string = nil
end
end

View File

@ -37,6 +37,9 @@
\usepackage{csquotes,luacolor}
\MakeShortVerb{\|}
\RecordChanges
\ProvideDocElement[printtype=\textit{socket},idxtype=socket,idxgroup=Sockets]{Socket}{socketdecl}
\ProvideDocElement[printtype=\textit{plug},idxtype=plug,idxgroup=Plugs]{Plug}{plugdecl}
\begin{document}
\tracingmathml2
\DocInput{luamml.dtx}
@ -523,7 +526,443 @@
% \end{macrocode}
% \end{macro}
%
% \subsection{Sockets}
% In various places luamml has to add code to kernel commands. This is done through
% sockets which are predeclared in lttagging.
%
% \subsubsection{Save sockets}
% These sockets are wrappers around the \cs{luamml_save:...} commands
% They should be provided until 2025-06-01
% \begin{macrocode}
\str_if_exist:cF { l__socket_tagsupport/math/luamml/save/nn_plug_str }
{
\NewSocket{tagsupport/math/luamml/save/nn}{1}
\AssignSocketPlug{tagsupport/math/luamml/save/nn}{noop}
\NewSocket{tagsupport/math/luamml/save/nNn}{1}
\AssignSocketPlug{tagsupport/math/luamml/save/nNn}{noop}
}
% \end{macrocode}
%
% \begin{macrocode}
\NewSocketPlug{tagsupport/math/luamml/save/nNn}{luamml}
{
\luamml_save:nNn #1
}
\AssignSocketPlug{tagsupport/math/luamml/save/nNn}{luamml}
\NewSocketPlug{tagsupport/math/luamml/save/nn}{luamml}
{
\luamml_save:nn #1
}
\AssignSocketPlug{tagsupport/math/luamml/save/nn}{luamml}
% \end{macrocode}
%
% \subsubsection{sockets to annotate content}
%
% \begin{macrocode}
\str_if_exist:cF { l__socket_tagsupport/math/luamml/annotate/false_plug_str }
{
\NewSocket{tagsupport/math/luamml/annotate/false}{2}
\NewSocketPlug{tagsupport/math/luamml/annotate/false}{default}{#2}
\AssignSocketPlug{tagsupport/math/luamml/annotate/false}{default}
}
%<*luatex>
\NewSocketPlug{tagsupport/math/luamml/annotate/false}{luamml}
{
\luamml_annotate:en { core = false }
{
#2
}
}
\AssignSocketPlug{tagsupport/math/luamml/annotate/false}{luamml}
%</luatex>
% \end{macrocode}
% \subsubsection{socket plugs for the array package}
%
% The socket declaration can go with the 2025-06-01 release
% \begin{macrocode}
\str_if_exist:cF { l__socket_tagsupport/math/luamml/array/finalize_plug_str }
{
\NewSocket{tagsupport/math/luamml/array/save}{0}
\NewSocket{tagsupport/math/luamml/array/finalize}{0}
\NewSocket{tagsupport/math/luamml/array/initcol}{0}
\NewSocket{tagsupport/math/luamml/array/finalizecol}{1}
\AssignSocketPlug{tagsupport/math/luamml/array/finalizecol}{noop}
}
% \end{macrocode}
%
% The luamml support makes only sense with luatex.
% \begin{macrocode}
%<*luatex>
\AddToHook{package/array/after}{\lua_now:n { require'luamml-array' }}
% \end{macrocode}
% \begin{plugdecl}{tagsupport/math/luamml/array/save}
% The socket of this plug is used in \cs{endarray}.
% \begin{macrocode}
\NewSocketPlug{tagsupport/math/luamml/array/save}{luamml}
{
\__luamml_array_save_array:
}
% \end{macrocode}
% \end{plugdecl}
%
% \begin{plugdecl}{tagsupport/math/luamml/array/finalize}
% This socket of this plug is used in \cs{endarray}.
% \begin{macrocode}
\NewSocketPlug{tagsupport/math/luamml/array/finalize}{luamml}
{
\mode_if_math:T { \__luamml_array_finalize_array: }
}
% \end{macrocode}
% \end{plugdecl}
%
% \begin{plugdecl}{tagsupport/math/luamml/array/initcol}
% The socket of this plug is used in \cs{@classz}.
% \begin{macrocode}
\NewSocketPlug{tagsupport/math/luamml/array/initcol}{luamml}
{
\__luamml_array_init_col:
}
% \end{macrocode}
% \end{plugdecl}
%
%
% \begin{plugdecl}{tagsupport/math/luamml/array/finalizecol}
% The socket of this plug is used used in \cs{@classz}.
% \begin{macrocode}
\NewSocketPlug{tagsupport/math/luamml/array/finalizecol}{luamml}
{
\__luamml_array_finalize_col:w #1~
}
% \end{macrocode}
% \end{plugdecl}
% \begin{macrocode}
\AssignSocketPlug{tagsupport/math/luamml/array/save}{luamml}
\AssignSocketPlug{tagsupport/math/luamml/array/finalize}{luamml}
\AssignSocketPlug{tagsupport/math/luamml/array/initcol}{luamml}
\AssignSocketPlug{tagsupport/math/luamml/array/finalizecol}{luamml}
%</luatex>
% \end{macrocode}
% \subsubsection{amsmath alignments}
%
% This socket is used at the end of alignment cells and adds the content to
% the current row.
%
% \begin{macrocode}
\str_if_exist:cF { l__socket_tagsupport/math/luamml/mtable/finalizecol_plug_str }
{
\NewSocket{tagsupport/math/luamml/mtable/finalizecol}{1}
}
% \end{macrocode}
% \begin{macrocode}
%<*luatex>
\NewSocketPlug{tagsupport/math/luamml/mtable/finalizecol}{luamml}
{
\use:c{__luamml_amsmath_add_#1_to_row:}
}
\AssignSocketPlug{tagsupport/math/luamml/mtable/finalizecol}{luamml}
%</luatex>
% \end{macrocode}
%
% These sockets save an inner table
% \begin{macrocode}
\str_if_exist:cF { l__socket_tagsupport/math/luamml/mtable/innertable/save_plug_str }
{
\NewSocket{tagsupport/math/luamml/mtable/innertable/save}{0}
\NewSocket{tagsupport/math/luamml/mtable/smallmatrix/save}{0}
\NewSocket{tagsupport/math/luamml/mtable/innertable/finalize}{0}
}
% \end{macrocode}
% \begin{macrocode}
%<*luatex>
\NewSocketPlug{tagsupport/math/luamml/mtable/innertable/save}{luamml}
{
\__luamml_amsmath_save_inner_table:n \@currenvir
}
\AssignSocketPlug{tagsupport/math/luamml/mtable/innertable/save}{luamml}
\NewSocketPlug{tagsupport/math/luamml/mtable/smallmatrix/save}{luamml}
{
\__luamml_amsmath_save_smallmatrix:
}
\AssignSocketPlug{tagsupport/math/luamml/mtable/smallmatrix/save}{luamml}
\NewSocketPlug{tagsupport/math/luamml/mtable/innertable/finalize}{luamml}
{
\__luamml_amsmath_finalize_inner_table:
}
\AssignSocketPlug{tagsupport/math/luamml/mtable/innertable/finalize}{luamml}
%</luatex>
% \end{macrocode}
%
%
% This socket finalize the \texttt{mtable} in alignments like align or gather.
% It takes an argument, the environment.
% It should be used normally with \cs{UseExpandableTaggingSocket}.
% \begin{macrocode}
\str_if_exist:cF { l__socket_tagsupport/math/luamml/mtable/finalize_plug_str }
{
\NewSocket{tagsupport/math/luamml/mtable/finalize}{1}
\AssignSocketPlug{tagsupport/math/luamml/mtable/finalize}{noop}
}
% \end{macrocode}
%
% \begin{macrocode}
%<*luatex>
\NewSocketPlug{tagsupport/math/luamml/mtable/finalize}{luamml}
{
\__luamml_amsmath_finalize_table:n {#1}
}
\AssignSocketPlug{tagsupport/math/luamml/mtable/finalize}{luamml}
%</luatex>
% \end{macrocode}
%
% This socket adds attributes for the alignment in \texttt{multline}.
% It takes an argument, the alignment.
% \begin{macrocode}
\str_if_exist:cF { l__socket_tagsupport/math/luamml/mtable/aligncol_plug_str }
{
\NewSocket{tagsupport/math/luamml/mtable/aligncol}{1}
\AssignSocketPlug{tagsupport/math/luamml/mtable/aligncol}{noop}
}
% \end{macrocode}
%
% \begin{macrocode}
%<*luatex>
\NewSocketPlug{tagsupport/math/luamml/mtable/aligncol}{luamml}
{
\__luamml_amsmath_set_row_columnalign:n {#1}
}
\AssignSocketPlug{tagsupport/math/luamml/mtable/aligncol}{luamml}
%</luatex>
% \end{macrocode}
%
% \subsubsection{Tags and labels}
% These sockets save and set tags and labels in alignments.
% \begin{macrocode}
\str_if_exist:cF { l__socket_tagsupport/math/luamml/mtable/tag/save_plug_str }
{
\NewSocket{tagsupport/math/luamml/mtable/tag/save}{0}
\NewSocket{tagsupport/math/luamml/mtable/tag/set}{0}
}
% \end{macrocode}
% \begin{macrocode}
%<*luatex>
\NewSocketPlug{tagsupport/math/luamml/mtable/tag/save}{luamml}
{
\__luamml_amsmath_save_tag:
}
\AssignSocketPlug{tagsupport/math/luamml/mtable/tag/save}{luamml}
\NewSocketPlug{tagsupport/math/luamml/mtable/tag/set}{luamml}
{
\__luamml_amsmath_set_tag:
}
\AssignSocketPlug{tagsupport/math/luamml/mtable/tag/set}{luamml}
%</luatex>
% \end{macrocode}
%
% If math structure elements are created the Lbl-structure of a tag
% must be moved inside the math structure, typically as an additional column in an
% \texttt{mtable} with an intent \texttt{:equationlabel}.
%
% The luamml-code handles this by stashing the Lbl-structure, storing the
% structure number in an array and reusing it once it creates the math structure elements.
%
% This should only be done for specific environments, we define
% a constant to test:
% \begin{macrocode}
\str_if_exist:cF { l__socket_tagsupport/math/display/tag/begin_plug_str }
{
\NewSocket{tagsupport/math/display/tag/begin}{0}
\NewSocket{tagsupport/math/display/tag/end}{0}
}
% \end{macrocode}
%
% \begin{macrocode}
%<*luatex>
\clist_map_inline:nn
{
align,
align*,
alignat,
alignat*,
xalignat,
xalignat*,
% \end{macrocode}
% there is never a tag/label in xxalignat, so does it make sense to add a label column?
% Left out for now.
% \begin{macrocode}
%xxalignat,
flalign,
flalign*,
gather,
gather*,
% \end{macrocode}
% equation and multline have at most one tag, so we do not use a label column
% but rely on the external Lbl for now.
% \begin{macrocode}
%multline, % NO
%multline*, % NO
%equation, % NO
%equation*, % NO
% \end{macrocode}
% split has never a numbering so is ignored
% \begin{macrocode}
%split, % NO
}
{\tl_const:cn { c__luamml_label_#1_tl}{}}
% \end{macrocode}
%
%
% \begin{macrocode}
\NewSocketPlug{tagsupport/math/display/tag/begin}{luamml}
{
\tag_mc_end:
\bool_lazy_and:nnTF
{ \tl_if_exist_p:c { c__luamml_label_ \@currenvir _tl } }
{ \int_if_odd_p:n { \int_div_truncate:nn { \l__luamml_flag_int } { 8 } } }
{
%\typeout{Stash~and~move~\@currenvir\c_space_tl Lbl}
\tag_struct_begin:n {tag=Lbl,stash}
\directlua{table.insert(ltx.__tag.struct.luamml.labels,\tag_get:n{struct_num})}
}
{
\tag_struct_begin:n {tag=Lbl}
}
\tag_mc_begin:n {}
}
\AssignSocketPlug{tagsupport/math/display/tag/begin}{luamml}
%</luatex>
% \end{macrocode}
%
%
% \subsubsection{Horizontal boxes}
% This socket annotates an \cs{hbox} inside box commands used in math.
% We test for the socket until the release 2025-06-01.
% \begin{macrocode}
\str_if_exist:cF { l__socket_tagsupport/math/luamml/hbox_plug_str }
{
\NewSocket{tagsupport/math/luamml/hbox}{2}
\NewSocketPlug{tagsupport/math/luamml/hbox}{default}{#2}
\AssignSocketPlug{tagsupport/math/luamml/hbox}{default}
}
%<*luatex>
\NewSocketPlug{tagsupport/math/luamml/hbox}{luamml}
{
\bool_lazy_and:nnTF
{ \mode_if_math_p: }
{ \int_if_odd_p:n { \int_div_truncate:nn { \l__luamml_flag_int } { 8 } } }
{
\tag_struct_begin:n
{
tag=mtext,
stash,
}
\tag_mc_begin:n {}
\luamml_annotate:en
{
nucleus = true,
structnum=\tag_get:n{struct_num}
}
{ #2 }
\tag_mc_end:
\tag_struct_end:
}
{ #2 }
}
\AssignSocketPlug{tagsupport/math/luamml/hbox}{luamml}
%</luatex>
% \end{macrocode}
%
% \subsubsection{Artifact characters}
% Unicode characters like a root sign should be marked as artifacts
% to avoid duplication e.g. in derivation if mathml
% structure elements are used that imply the meaning.
% We test for the socket until the release 2025-06-01.
% \begin{macrocode}
\str_if_exist:cF { l__socket_tagsupport/math/luamml/artifact_plug_str }
{
\NewSocket{tagsupport/math/luamml/artifact}{0}
}
%<*luatex>
\NewSocketPlug{tagsupport/math/luamml/artifact}{luamml}
{
\int_if_odd:nT { \int_div_truncate:nn { \l__luamml_flag_int } { 8 } }
{
\tag_mc_begin:n{artifact}
}
}
\AssignSocketPlug{tagsupport/math/luamml/artifact}{luamml}
%</luatex>
% \end{macrocode}
%
% \subsubsection{Math phantom socket}
% This socket is used around \cs{finph@nt}.
% It should provided until 2025-06-01
% \begin{macrocode}
\str_if_exist:cF { l__socket_tagsupport/math/luamml/finph@nt_plug_str }
{
\NewSocket{tagsupport/math/luamml/finph@nt}{2}
\NewSocketPlug{tagsupport/math/luamml/finph@nt}{default}{#2}
\AssignSocketPlug{tagsupport/math/luamml/finph@nt}{default}
}
% \end{macrocode}
%
% \begin{macrocode}
%<*luatex>
\NewSocketPlug{tagsupport/math/luamml/finph@nt}{luamml}
{
\luamml_annotate:nen {1}
{
nucleus = true,
core =
{
[0] = 'mpadded',
\ifh@\else
width = 0,
\fi
\ifv@\else
height = 0, depth = 0,
\fi
consume_label'mathphant',
}
}
{ #2 }
}
\AssignSocketPlug{tagsupport/math/luamml/finph@nt}{luamml}
%</luatex>
% \end{macrocode}
% \subsubsection{Math smash socket}
% This socket is used around \cs{finsm@sh}.
% It should provided until 2025-06-01
% \begin{macrocode}
\str_if_exist:cF { l__socket_tagsupport/math/luamml/finsm@sh_plug_str }
{
\NewSocket{tagsupport/math/luamml/finsm@sh}{2}
\NewSocketPlug{tagsupport/math/luamml/finsm@sh}{default}{#2}
\AssignSocketPlug{tagsupport/math/luamml/finsm@sh}{default}
}
% \end{macrocode}
%
% \begin{macrocode}
%<*luatex>
\NewSocketPlug{tagsupport/math/luamml/finsm@sh}{luamml}
{
\luamml_annotate:nen {2}
{
nucleus = true,
core =
consume_label('mathsmash',
function(padded)
padded.height, padded.depth = 0, 0~
end),
}
{ #2 }
}
\AssignSocketPlug{tagsupport/math/luamml/finsm@sh}{luamml}
%</luatex>
% \end{macrocode}
% \subsection{Patching}
% For some packages, we ship with patches to make them more compatible and to
% demonstrate how other code can be patched to work with \texttt{luamml}.
@ -549,7 +988,7 @@
% \end{macrocode}
% \end{macro}
%
% We currently provide minimal patching for the kernel, \pkg{amsmath} and \pkg{array}.
% We currently provide minimal patching for the kernel, \pkg{amsmath}.
% Currently only the kernel code supports pdf\TeX, but it's planned to extend this.
% \begin{macrocode}
\RequirePackage { luamml-patches-kernel }
@ -557,7 +996,6 @@
\__luamml_patch_package:n {amstext}
\__luamml_patch_package:n {amsmath}
\__luamml_patch_package:n {mathtools}
\__luamml_patch_package:n {array}
%</luatex>
% \end{macrocode}

View File

@ -106,9 +106,6 @@
</mfrac>
<mo lspace="0" rspace="0">.</mo>
</math>
<math xmlns="http://www.w3.org/1998/Math/MathML">
<mi>𝑏</mi>
</math>
<math display="block" xmlns="http://www.w3.org/1998/Math/MathML">
<munder>
<mo lspace="0" movablelimits="true" rspace="0.167em">∑</mo>
@ -120,7 +117,7 @@
</munder>
<mover>
<mi>𝑏</mi>
<mo stretchy="false">_</mo>
<mo stretchy="true">.</mo>
</mover>
<msup>
<mi>𝑐</mi>

View File

@ -1,15 +1,21 @@
\DocumentMetadata{
uncompress,
pdfversion = 2.0,
testphase = phase-I,
testphase = {phase-III,table,math},
}
\input{regression-test}
\documentclass{article}
\usepackage[l3build]{luamml-demo}
\usepackage{unicode-math}
\begin{document}
\tagstructbegin{tag=Document}
\LuaMMLTagAF{} {
\ExplSyntaxOn
\luamml_set_filename:n {
\jobname .mml
}
\luamml_process:
\luamml_begin_single_file:
\ExplSyntaxOff
\[
\left(\begin{matrix}
1 & 0 & 0 \\
@ -22,18 +28,17 @@
2 & \mbox{else}
\end{cases}
\]
}
\LuaMMLTagAF{} {
\[
x = \frac{-b \pm \sqrt{b^2-4ac}}{2a}.
\]
}
\LuaMMLTagAF{} {
\[
\sum_a\underline c\dot bc'
\]
}
Es gilt \LuaMMLTagAF{}{$\sin(x)-\sin(x+2\pi)=0$}.
\tagstructend
Es gilt $\sin(x)-\sin(x+2\pi)=0$.
\ExplSyntaxOn
\luamml_end_single_file:
\ExplSyntaxOff
\end{document}

View File

@ -0,0 +1,33 @@
<math xmlns="http://www.w3.org/1998/Math/MathML">
<msqrt>
<mi>𝑥</mi>
</msqrt>
</math>
<math xmlns="http://www.w3.org/1998/Math/MathML">
<msqrt>
<msqrt>
<mi>𝑥</mi>
</msqrt>
</msqrt>
<mo lspace="0.222em" rspace="0.222em">+</mo>
<mn>2</mn>
</math>
<math xmlns="http://www.w3.org/1998/Math/MathML">
<mi>𝑥</mi>
<mo lspace="0.278em" rspace="0.278em">=</mo>
<msqrt>
<mroot>
<msup>
<mi>𝑦</mi>
<mn>2</mn>
</msup>
<mn>3</mn>
</mroot>
</msqrt>
</math>
<math xmlns="http://www.w3.org/1998/Math/MathML">
<mroot>
<mi>𝑦</mi>
<mn>3</mn>
</mroot>
</math>

View File

@ -0,0 +1,28 @@
\DocumentMetadata{
uncompress,
pdfversion = 2.0,
testphase = {phase-III,table,math},
}
\input{regression-test}
\documentclass{article}
\usepackage{unicode-math}
\begin{document}
\ExplSyntaxOn
\luamml_set_filename:n {
\jobname .mml
}
\luamml_process:
\luamml_begin_single_file:
\ExplSyntaxOff
$ \sqrt{x} $
$ \sqrt{\sqrt{x}} + 2 $
$ x = \sqrt{\sqrt[3]{y^2}} $
$\sqrt[3]{y}$
\end{document}

View File

@ -0,0 +1,22 @@
\ExplSyntaxOn
\sys_gset_rand_seed:n{42}
\ExplSyntaxOff
\DocumentMetadata{
uncompress,
pdfversion = 2.0,
testphase = {phase-III,math,table},
}
\input{regression-test}
\documentclass{article}
\usepackage{unicode-math}
\tagpdfsetup{math/mathml/structelem}
\begin{document}
$ \sqrt{x} $
$ \sqrt{\sqrt{x}} + 2 $
$ x = \sqrt{\sqrt[3]{y^2}} $
$\sqrt[3]{y}$
\end{document}

990
testfiles-lua/test_sqrt.tpf Normal file
View File

@ -0,0 +1,990 @@
%PDF-2.0
%ÌÕÁÔÅØÐÄÆ
22 0 obj
<< /Type /EmbeddedFile /Subtype /application#2Fmathml+xml /Params<</ModDate (D:20160520) >> /Length 88 >>
stream
<math xmlns="http://www.w3.org/1998/Math/MathML"> <msqrt> <mi>ð<>¥</mi> </msqrt> </math>
endstream
endobj
23 0 obj
<< /Type /Filespec /AFRelationship /Supplement /Desc (mathml-1) /F (mathml-1.xml) /UF <FEFF006D006100740068006D006C002D0031002E0078006D006C> /EF<</F 22 0 R/UF 22 0 R>> >>
endobj
24 0 obj
<< /Type /EmbeddedFile /Subtype /application#2Fmathml+xml /Params<</ModDate (D:20160520) >> /Length 161 >>
stream
<math xmlns="http://www.w3.org/1998/Math/MathML"> <msqrt> <msqrt> <mi>ð<>¥</mi> </msqrt> </msqrt> <mo lspace="0.222em" rspace="0.222em">+</mo> <mn>2</mn> </math>
endstream
endobj
25 0 obj
<< /Type /Filespec /AFRelationship /Supplement /Desc (mathml-2) /F (mathml-2.xml) /UF <FEFF006D006100740068006D006C002D0032002E0078006D006C> /EF<</F 24 0 R/UF 24 0 R>> >>
endobj
26 0 obj
<< /Type /EmbeddedFile /Subtype /application#2Fmathml+xml /Params<</ModDate (D:20160520) >> /Length 201 >>
stream
<math xmlns="http://www.w3.org/1998/Math/MathML"> <mi>ð<>¥</mi> <mo lspace="0.278em" rspace="0.278em">=</mo> <msqrt> <mroot> <msup> <mi>ð<>¦</mi> <mn>2</mn> </msup> <mn>3</mn> </mroot> </msqrt> </math>
endstream
endobj
27 0 obj
<< /Type /Filespec /AFRelationship /Supplement /Desc (mathml-3) /F (mathml-3.xml) /UF <FEFF006D006100740068006D006C002D0033002E0078006D006C> /EF<</F 26 0 R/UF 26 0 R>> >>
endobj
28 0 obj
<< /Type /EmbeddedFile /Subtype /application#2Fmathml+xml /Params<</ModDate (D:20160520) >> /Length 99 >>
stream
<math xmlns="http://www.w3.org/1998/Math/MathML"> <mroot> <mi>ð<>¦</mi> <mn>3</mn> </mroot> </math>
endstream
endobj
29 0 obj
<< /Type /Filespec /AFRelationship /Supplement /Desc (mathml-4) /F (mathml-4.xml) /UF <FEFF006D006100740068006D006C002D0034002E0078006D006C> /EF<</F 28 0 R/UF 28 0 R>> >>
endobj
35 0 obj
<< /Subtype /application#2Fx-tex/Type /EmbeddedFile /Params<</ModDate (D:20160520) >> /Length 11 >>
stream
$\sqrt {x}$
endstream
endobj
36 0 obj
<< /Type /Filespec /AFRelationship /Source /Desc (TeX source) /F (tag-AFfile1.tex) /UF <FEFF007400610067002D0041004600660069006C00650031002E007400650078> /EF<</F 35 0 R/UF 35 0 R>> >>
endobj
43 0 obj
<< /Subtype /application#2Fx-tex/Type /EmbeddedFile /Params<</ModDate (D:20160520) >> /Length 23 >>
stream
$\sqrt {\sqrt {x}} + 2$
endstream
endobj
44 0 obj
<< /Type /Filespec /AFRelationship /Source /Desc (TeX source) /F (tag-AFfile2.tex) /UF <FEFF007400610067002D0041004600660069006C00650032002E007400650078> /EF<</F 43 0 R/UF 43 0 R>> >>
endobj
50 0 obj
<< /O/NSO/NS 13 0 R/lspace(0.222em)/rspace(0.222em) >>
endobj
55 0 obj
<< /Subtype /application#2Fx-tex/Type /EmbeddedFile /Params<</ModDate (D:20160520) >> /Length 28 >>
stream
$x = \sqrt {\sqrt [3]{y^2}}$
endstream
endobj
56 0 obj
<< /Type /Filespec /AFRelationship /Source /Desc (TeX source) /F (tag-AFfile3.tex) /UF <FEFF007400610067002D0041004600660069006C00650033002E007400650078> /EF<</F 55 0 R/UF 55 0 R>> >>
endobj
60 0 obj
<< /O/NSO/NS 13 0 R/lspace(0.278em)/rspace(0.278em) >>
endobj
70 0 obj
<< /Subtype /application#2Fx-tex/Type /EmbeddedFile /Params<</ModDate (D:20160520) >> /Length 14 >>
stream
$\sqrt [3]{y}$
endstream
endobj
71 0 obj
<< /Type /Filespec /AFRelationship /Source /Desc (TeX source) /F (tag-AFfile4.tex) /UF <FEFF007400610067002D0041004600660069006C00650034002E007400650078> /EF<</F 70 0 R/UF 70 0 R>> >>
endobj
76 0 obj
<< /Type /Metadata /Subtype /XML /Length 11691 >>
stream
<?xpacket begin="" id="W5M0MpCehiHzreSzNTczkc9d"?>
<x:xmpmeta xmlns:x="adobe:ns:meta/">
<rdf:RDF xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#">
<rdf:Description rdf:about=""
xmlns:pdf="http://ns.adobe.com/pdf/1.3/"
xmlns:xmpRights="http://ns.adobe.com/xap/1.0/rights/"
xmlns:dc="http://purl.org/dc/elements/1.1/"
xmlns:photoshop="http://ns.adobe.com/photoshop/1.0/"
xmlns:xmp="http://ns.adobe.com/xap/1.0/"
xmlns:xmpMM="http://ns.adobe.com/xap/1.0/mm/"
xmlns:stEvt="http://ns.adobe.com/xap/1.0/sType/ResourceEvent#"
xmlns:pdfaid="http://www.aiim.org/pdfa/ns/id/"
xmlns:pdfuaid="http://www.aiim.org/pdfua/ns/id/"
xmlns:pdfx="http://ns.adobe.com/pdfx/1.3/"
xmlns:pdfxid="http://www.npes.org/pdfx/ns/id/"
xmlns:prism="http://prismstandard.org/namespaces/basic/3.0/"
xmlns:stFnt="http://ns.adobe.com/xap/1.0/sType/Font#"
xmlns:Iptc4xmpCore="http://iptc.org/std/Iptc4xmpCore/1.0/xmlns/"
xmlns:pdfaExtension="http://www.aiim.org/pdfa/ns/extension/"
xmlns:pdfaSchema="http://www.aiim.org/pdfa/ns/schema#"
xmlns:pdfaProperty="http://www.aiim.org/pdfa/ns/property#"
xmlns:pdfaType="http://www.aiim.org/pdfa/ns/type#"
xmlns:pdfaField="http://www.aiim.org/pdfa/ns/field#">
<pdfaExtension:schemas>
<rdf:Bag>
<rdf:li rdf:parseType="Resource">
<pdfaSchema:schema>XMP Media Management Schema</pdfaSchema:schema>
<pdfaSchema:prefix>xmpMM</pdfaSchema:prefix>
<pdfaSchema:namespaceURI>http://ns.adobe.com/xap/1.0/mm/</pdfaSchema:namespaceURI>
<pdfaSchema:property>
<rdf:Seq>
<rdf:li rdf:parseType="Resource">
<pdfaProperty:name>OriginalDocumentID</pdfaProperty:name>
<pdfaProperty:valueType>URI</pdfaProperty:valueType>
<pdfaProperty:category>internal</pdfaProperty:category>
<pdfaProperty:description>The common identifier for all versions and renditions of a document.</pdfaProperty:description>
</rdf:li>
</rdf:Seq>
</pdfaSchema:property>
</rdf:li>
<rdf:li rdf:parseType="Resource">
<pdfaSchema:schema>PDF/A Identification Schema</pdfaSchema:schema>
<pdfaSchema:prefix>pdfaid</pdfaSchema:prefix>
<pdfaSchema:namespaceURI>http://www.aiim.org/pdfa/ns/id/</pdfaSchema:namespaceURI>
<pdfaSchema:property>
<rdf:Seq>
<rdf:li rdf:parseType="Resource">
<pdfaProperty:name>year</pdfaProperty:name>
<pdfaProperty:valueType>Integer</pdfaProperty:valueType>
<pdfaProperty:category>internal</pdfaProperty:category>
<pdfaProperty:description>Year of standard</pdfaProperty:description>
</rdf:li>
<rdf:li rdf:parseType="Resource">
<pdfaProperty:name>rev</pdfaProperty:name>
<pdfaProperty:valueType>Integer</pdfaProperty:valueType>
<pdfaProperty:category>internal</pdfaProperty:category>
<pdfaProperty:description>Revision year of standard</pdfaProperty:description>
</rdf:li>
</rdf:Seq>
</pdfaSchema:property>
</rdf:li>
<rdf:li rdf:parseType="Resource">
<pdfaSchema:schema>PDF/UA Universal Accessibility Schema</pdfaSchema:schema>
<pdfaSchema:prefix>pdfuaid</pdfaSchema:prefix>
<pdfaSchema:namespaceURI>http://www.aiim.org/pdfua/ns/id/</pdfaSchema:namespaceURI>
<pdfaSchema:property>
<rdf:Seq>
<rdf:li rdf:parseType="Resource">
<pdfaProperty:name>part</pdfaProperty:name>
<pdfaProperty:valueType>Integer</pdfaProperty:valueType>
<pdfaProperty:category>internal</pdfaProperty:category>
<pdfaProperty:description>Part of ISO 14289 standard</pdfaProperty:description>
</rdf:li>
<rdf:li rdf:parseType="Resource">
<pdfaProperty:name>rev</pdfaProperty:name>
<pdfaProperty:valueType>Integer</pdfaProperty:valueType>
<pdfaProperty:category>internal</pdfaProperty:category>
<pdfaProperty:description>Revision of ISO 14289 standard</pdfaProperty:description>
</rdf:li>
</rdf:Seq>
</pdfaSchema:property>
</rdf:li>
<rdf:li rdf:parseType="Resource">
<pdfaSchema:schema>PDF/X ID Schema</pdfaSchema:schema>
<pdfaSchema:prefix>pdfxid</pdfaSchema:prefix>
<pdfaSchema:namespaceURI>http://www.npes.org/pdfx/ns/id/</pdfaSchema:namespaceURI>
<pdfaSchema:property>
<rdf:Seq>
<rdf:li rdf:parseType="Resource">
<pdfaProperty:name>GTS_PDFXVersion</pdfaProperty:name>
<pdfaProperty:valueType>Text</pdfaProperty:valueType>
<pdfaProperty:category>internal</pdfaProperty:category>
<pdfaProperty:description>ID of PDF/X standard</pdfaProperty:description>
</rdf:li>
</rdf:Seq>
</pdfaSchema:property>
</rdf:li>
<rdf:li rdf:parseType="Resource">
<pdfaSchema:schema>PRISM Basic Metadata</pdfaSchema:schema>
<pdfaSchema:prefix>prism</pdfaSchema:prefix>
<pdfaSchema:namespaceURI>http://prismstandard.org/namespaces/basic/3.0/</pdfaSchema:namespaceURI>
<pdfaSchema:property>
<rdf:Seq>
<rdf:li rdf:parseType="Resource">
<pdfaProperty:name>complianceProfile</pdfaProperty:name>
<pdfaProperty:valueType>Text</pdfaProperty:valueType>
<pdfaProperty:category>internal</pdfaProperty:category>
<pdfaProperty:description>PRISM specification compliance profile to which this document adheres</pdfaProperty:description>
</rdf:li>
<rdf:li rdf:parseType="Resource">
<pdfaProperty:name>publicationName</pdfaProperty:name>
<pdfaProperty:valueType>Text</pdfaProperty:valueType>
<pdfaProperty:category>external</pdfaProperty:category>
<pdfaProperty:description>Publication name</pdfaProperty:description>
</rdf:li>
<rdf:li rdf:parseType="Resource">
<pdfaProperty:name>aggregationType</pdfaProperty:name>
<pdfaProperty:valueType>Text</pdfaProperty:valueType>
<pdfaProperty:category>external</pdfaProperty:category>
<pdfaProperty:description>Publication type</pdfaProperty:description>
</rdf:li>
<rdf:li rdf:parseType="Resource">
<pdfaProperty:name>bookEdition</pdfaProperty:name>
<pdfaProperty:valueType>Text</pdfaProperty:valueType>
<pdfaProperty:category>external</pdfaProperty:category>
<pdfaProperty:description>Edition of the book in which the document was published</pdfaProperty:description>
</rdf:li>
<rdf:li rdf:parseType="Resource">
<pdfaProperty:name>volume</pdfaProperty:name>
<pdfaProperty:valueType>Text</pdfaProperty:valueType>
<pdfaProperty:category>external</pdfaProperty:category>
<pdfaProperty:description>Publication volume number</pdfaProperty:description>
</rdf:li>
<rdf:li rdf:parseType="Resource">
<pdfaProperty:name>number</pdfaProperty:name>
<pdfaProperty:valueType>Text</pdfaProperty:valueType>
<pdfaProperty:category>external</pdfaProperty:category>
<pdfaProperty:description>Publication issue number within a volume</pdfaProperty:description>
</rdf:li>
<rdf:li rdf:parseType="Resource">
<pdfaProperty:name>pageRange</pdfaProperty:name>
<pdfaProperty:valueType>Text</pdfaProperty:valueType>
<pdfaProperty:category>external</pdfaProperty:category>
<pdfaProperty:description>Page range for the document within the print version of its publication</pdfaProperty:description>
</rdf:li>
<rdf:li rdf:parseType="Resource">
<pdfaProperty:name>issn</pdfaProperty:name>
<pdfaProperty:valueType>Text</pdfaProperty:valueType>
<pdfaProperty:category>external</pdfaProperty:category>
<pdfaProperty:description>ISSN for the printed publication in which the document was published</pdfaProperty:description>
</rdf:li>
<rdf:li rdf:parseType="Resource">
<pdfaProperty:name>eIssn</pdfaProperty:name>
<pdfaProperty:valueType>Text</pdfaProperty:valueType>
<pdfaProperty:category>external</pdfaProperty:category>
<pdfaProperty:description>ISSN for the electronic publication in which the document was published</pdfaProperty:description>
</rdf:li>
<rdf:li rdf:parseType="Resource">
<pdfaProperty:name>isbn</pdfaProperty:name>
<pdfaProperty:valueType>Text</pdfaProperty:valueType>
<pdfaProperty:category>external</pdfaProperty:category>
<pdfaProperty:description>ISBN for the publication in which the document was published</pdfaProperty:description>
</rdf:li>
<rdf:li rdf:parseType="Resource">
<pdfaProperty:name>doi</pdfaProperty:name>
<pdfaProperty:valueType>Text</pdfaProperty:valueType>
<pdfaProperty:category>external</pdfaProperty:category>
<pdfaProperty:description>Digital Object Identifier for the document</pdfaProperty:description>
</rdf:li>
<rdf:li rdf:parseType="Resource">
<pdfaProperty:name>url</pdfaProperty:name>
<pdfaProperty:valueType>URL</pdfaProperty:valueType>
<pdfaProperty:category>external</pdfaProperty:category>
<pdfaProperty:description>URL at which the document can be found</pdfaProperty:description>
</rdf:li>
<rdf:li rdf:parseType="Resource">
<pdfaProperty:name>byteCount</pdfaProperty:name>
<pdfaProperty:valueType>Integer</pdfaProperty:valueType>
<pdfaProperty:category>internal</pdfaProperty:category>
<pdfaProperty:description>Approximate file size in octets</pdfaProperty:description>
</rdf:li>
<rdf:li rdf:parseType="Resource">
<pdfaProperty:name>pageCount</pdfaProperty:name>
<pdfaProperty:valueType>Integer</pdfaProperty:valueType>
<pdfaProperty:category>internal</pdfaProperty:category>
<pdfaProperty:description>Number of pages in the print version of the document</pdfaProperty:description>
</rdf:li>
<rdf:li rdf:parseType="Resource">
<pdfaProperty:name>subtitle</pdfaProperty:name>
<pdfaProperty:valueType>Text</pdfaProperty:valueType>
<pdfaProperty:category>external</pdfaProperty:category>
<pdfaProperty:description>Document's subtitle</pdfaProperty:description>
</rdf:li>
</rdf:Seq>
</pdfaSchema:property>
</rdf:li>
</rdf:Bag>
</pdfaExtension:schemas>
<pdf:Producer>luahbtex-NN.NN.NN</pdf:Producer>
<pdf:PDFVersion>2.0</pdf:PDFVersion>
<dc:type>
<rdf:Bag>
<rdf:li>Text</rdf:li>
</rdf:Bag>
</dc:type>
<dc:language>
<rdf:Bag>
<rdf:li>en</rdf:li>
</rdf:Bag>
</dc:language>
<dc:date>
<rdf:Seq>
<rdf:li>2016-05-20T09:00:00Z</rdf:li>
</rdf:Seq>
</dc:date>
<dc:format>application/pdf</dc:format>
<dc:source>test_sqrt.tex</dc:source>
<xmp:CreatorTool>LaTeX</xmp:CreatorTool>
<xmp:CreateDate>2016-05-20T09:00:00Z</xmp:CreateDate>
<xmp:ModifyDate>2016-05-20T09:00:00Z</xmp:ModifyDate>
<xmp:MetadataDate>2016-05-20T09:00:00Z</xmp:MetadataDate>
<xmpMM:DocumentID>uuid:d1433a12-c113-44c0-8c00-afe828e37deb</xmpMM:DocumentID>
<xmpMM:InstanceID>uuid:0a57c455-157a-4141-8c19-6237d832fc80</xmpMM:InstanceID>
<prism:complianceProfile>three</prism:complianceProfile>
<prism:pageCount>1</prism:pageCount>
</rdf:Description>
</rdf:RDF>
</x:xmpmeta>
<?xpacket end="w"?>
endstream
endobj
79 0 obj
<< /Length 2081 >>
stream
/opacity1 gs
/Artifact BMC
EMC
/Formula<</MCID 0>> BDC
BT
/F20 9.96264 Tf
1 0 0 1 148.712 664.413 Tm [<0C05>]TJ
ET
q
1 0 0 1 157.011 664.613 cm
[] 0 d 0 J 0.398 w 0 0 m 5.699 0 l S
Q
EMC
/mi<</MCID 1>> BDC
BT
/F20 9.96264 Tf
1 0 0 1 157.011 657.235 Tm [<0527>]TJ
ET
EMC
/Artifact BMC
EMC
/Formula<</MCID 2>> BDC
BT
/F20 9.96264 Tf
1 0 0 1 148.712 644.986 Tm [<0C09>]TJ
ET
q
1 0 0 1 158.675 653.255 cm
[] 0 d 0 J 0.398 w 0 0 m 13.998 0 l S
Q
BT
/F20 9.96264 Tf
1 0 0 1 158.675 651.412 Tm [<0C05>]TJ
ET
q
1 0 0 1 166.974 651.611 cm
[] 0 d 0 J 0.398 w 0 0 m 5.699 0 l S
Q
EMC
/mi<</MCID 3>> BDC
BT
/F20 9.96264 Tf
1 0 0 1 166.974 644.234 Tm [<0527>]TJ
ET
EMC
/mo<</MCID 4>> BDC
BT
/F20 9.96264 Tf
1 0 0 1 174.886 644.234 Tm [<000C>]TJ
ET
EMC
/mn<</MCID 5>> BDC
BT
/F20 9.96264 Tf
1 0 0 1 184.851 644.234 Tm [<0013>]TJ
ET
EMC
/Artifact BMC
EMC
/Formula<</MCID 6>> BDC
EMC
/mi<</MCID 7>> BDC
BT
/F20 9.96264 Tf
1 0 0 1 148.712 627.309 Tm [<0527>]TJ
ET
EMC
/mo<</MCID 8>> BDC
BT
/F20 9.96264 Tf
1 0 0 1 157.178 627.309 Tm [<001E>]TJ
ET
EMC
/Formula<</MCID 9>> BDC
BT
/F20 9.96264 Tf
1 0 0 1 167.697 628.648 Tm [<0C0A>]TJ
ET
q
1 0 0 1 177.659 639.905 cm
[] 0 d 0 J 0.398 w 0 0 m 20.272 0 l S
Q
EMC
/mn<</MCID 10>> BDC
BT
/F22 4.98132 Tf
1 0 0 1 180.429 631.686 Tm [<0258>]TJ
ET
EMC
/Formula<</MCID 11>> BDC
BT
/F20 9.96264 Tf
1 0 0 1 178.282 628 Tm [<0C09>]TJ
ET
q
1 0 0 1 188.244 636.269 cm
[] 0 d 0 J 0.398 w 0 0 m 9.687 0 l S
Q
EMC
/mi<</MCID 12>> BDC
BT
/F20 9.96264 Tf
1 0 0 1 188.244 627.309 Tm [<0528>]TJ
ET
EMC
/mn<</MCID 13>> BDC
BT
/F21 6.97385 Tf
1 0 0 1 193.405 630.188 Tm [<03F5>]TJ
ET
EMC
/Artifact BMC
EMC
/Formula<</MCID 14>> BDC
EMC
/mn<</MCID 15>> BDC
BT
/F22 4.98132 Tf
1 0 0 1 151.482 616.792 Tm [<0258>]TJ
ET
EMC
/Formula<</MCID 16>> BDC
BT
/F20 9.96264 Tf
1 0 0 1 149.335 620.379 Tm [<0C05>]TJ
ET
q
1 0 0 1 157.634 620.578 cm
[] 0 d 0 J 0.398 w 0 0 m 4.882 0 l S
Q
EMC
/mi<</MCID 17>> BDC
BT
/F20 9.96264 Tf
1 0 0 1 157.634 614.167 Tm [<0528>]TJ
ET
EMC
/Artifact BMC
EMC
/Artifact BMC
BT
/F15 9.96264 Tf
1 0 0 1 303.133 89.365 Tm [<0052>]TJ
ET
EMC
/Artifact BMC
EMC
endstream
endobj
78 0 obj
<< /Type /Page /Contents 79 0 R /Resources 77 0 R /MediaBox [ 0 0 612 792 ] /StructParents 0/Tabs /S /Parent 84 0 R >>
endobj
77 0 obj
<< /ExtGState 1 0 R /Font << /F20 80 0 R /F22 81 0 R /F21 82 0 R /F15 83 0 R >> >>
endobj
1 0 obj
<< /opacity1 <</ca 1/CA 1>> >>
endobj
85 0 obj
<< /Marked true >>
endobj
86 0 obj
<< /Names[(l3ef0001) 23 0 R (l3ef0002) 25 0 R (l3ef0003) 27 0 R (l3ef0004) 29 0 R] >>
endobj
6 0 obj
<< /Nums [0 [ 34 0 R 39 0 R 42 0 R 48 0 R 49 0 R 51 0 R 54 0 R 58 0 R 59 0 R 54 0 R 66 0 R 54 0 R 64 0 R 65 0 R 69 0 R 75 0 R 69 0 R 74 0 R]
] >>
endobj
87 0 obj
<< /Limits [(ID.002) (ID.038)]/Names [(ID.002) 21 0 R (ID.003) 30 0 R (ID.004) 31 0 R (ID.005) 32 0 R (ID.006) 33 0 R (ID.007) 34 0 R (ID.008) 37 0 R (ID.009) 38 0 R (ID.010) 39 0 R (ID.011) 40 0 R (ID.012) 41 0 R (ID.013) 42 0 R (ID.014) 45 0 R (ID.015) 46 0 R (ID.016) 47 0 R (ID.017) 48 0 R (ID.018) 49 0 R (ID.019) 51 0 R (ID.020) 52 0 R (ID.021) 53 0 R (ID.022) 54 0 R (ID.023) 57 0 R (ID.024) 58 0 R (ID.025) 59 0 R (ID.026) 61 0 R (ID.027) 62 0 R (ID.028) 63 0 R (ID.029) 64 0 R (ID.030) 65 0 R (ID.031) 66 0 R (ID.032) 67 0 R (ID.033) 68 0 R (ID.034) 69 0 R (ID.035) 72 0 R (ID.036) 73 0 R (ID.037) 74 0 R (ID.038) 75 0 R ] >>
endobj
88 0 obj
<< /Kids [87 0 R] >>
endobj
7 0 obj
<< /Artifact /NonStruct /DocumentFragment /Art /Aside /Note /H7 /H6 /H8 /H6 /H9 /H6 /H10 /H6 /Title /P /FENote /Note /Sub /Span /Em /Span /Strong /Span /title /P /part /P /section /H1 /subsection /H2 /subsubsection /H3 /paragraph /H4 /subparagraph /H5 /list /L /itemize /L /enumerate /L /description /L /quote /BlockQuote /quotation /BlockQuote /verbatim /P /item /LI /itemlabel /Lbl /itembody /LBody /footnote /Note /footnotemark /Lbl /footnotelabel /Lbl /text-unit /Part /text /P /theorem-like /Sect /codeline /Span /float /Note /figures /Sect /tables /Sect >>
endobj
89 0 obj
<< /justify <</O/Layout/TextAlign/Justify>>
/inline <</O/Layout/Placement/Inline>>
/TH-both <</O/Table/Scope/Both>>
/TH-row <</O/Table/Scope/Row>>
/TH-col <</O/Table/Scope/Column>>
>>
endobj
9 0 obj
<< /Type /Namespace /NS (http://iso.org/pdf/ssn) >>
endobj
11 0 obj
<< /Type /Namespace /NS (http://iso.org/pdf2/ssn) >>
endobj
13 0 obj
<< /Type /Namespace /NS (http://www.w3.org/1998/Math/MathML) >>
endobj
16 0 obj
<< /title [/Title 11 0 R] /part [/Title 11 0 R] /section [/H1 11 0 R] /subsection [/H2 11 0 R] /subsubsection [/H3 11 0 R] /paragraph [/H4 11 0 R] /subparagraph [/H5 11 0 R] /list [/L 11 0 R] /itemize [/L 11 0 R] /enumerate [/L 11 0 R] /description [/L 11 0 R] /quote [/BlockQuote 9 0 R] /quotation [/BlockQuote 9 0 R] /verbatim [/P 11 0 R] /item [/LI 11 0 R] /itemlabel [/Lbl 11 0 R] /itembody [/LBody 11 0 R] /footnote [/FENote 11 0 R] /footnotemark [/Lbl 11 0 R] /footnotelabel [/Lbl 11 0 R] /text-unit [/Part 11 0 R] /text [/P 11 0 R] /theorem-like [/Sect 11 0 R] /codeline [/Sub 11 0 R] /float [/Aside 11 0 R] /figures [/Sect 11 0 R] /tables [/Sect 11 0 R] >>
endobj
15 0 obj
<< /Type /Namespace /NS (https://www.latex-project.org/ns/dflt) /RoleMapNS 16 0 R >>
endobj
18 0 obj
<< /chapter [/H1 11 0 R] /section [/H2 11 0 R] /subsection [/H3 11 0 R] /subsubsection [/H4 11 0 R] /paragraph [/H5 11 0 R] /subparagraph [/H6 11 0 R] >>
endobj
17 0 obj
<< /Type /Namespace /NS (https://www.latex-project.org/ns/book) /RoleMapNS 18 0 R >>
endobj
19 0 obj
<< /Type /Namespace /NS (data:,C9B55C18-275C-494E-C10F-E4B83CD03F23) >>
endobj
8 0 obj
[ 9 0 R 11 0 R 13 0 R 15 0 R 17 0 R 19 0 R ]
endobj
21 0 obj
<< /Type /StructElem /S /Document /NS 11 0 R /P 5 0 R /K [32 0 R 40 0 R 52 0 R 67 0 R] /ID (ID.002) >>
endobj
30 0 obj
<< /Type /StructElem /S /Artifact /NS 15 0 R /P 5 0 R /ID (ID.003) >>
endobj
31 0 obj
<< /Type /StructElem /S /Artifact /NS 15 0 R /P 5 0 R /ID (ID.004) >>
endobj
32 0 obj
<< /Type /StructElem /S /text-unit /NS 15 0 R /P 21 0 R /K 33 0 R /ID (ID.005) >>
endobj
33 0 obj
<< /Type /StructElem /C /justify /S /text /NS 15 0 R /P 32 0 R /K [ 34 0 R ] /ID (ID.006) >>
endobj
34 0 obj
<< /Type /StructElem /C /inline /AF [23 0 R 36 0 R] /T <FEFF006D006100740068> /S /Formula /NS 11 0 R /P 33 0 R /K [<</Type /MCR /Pg 78 0 R /MCID 0>> 37 0 R] /ID (ID.007) >>
endobj
37 0 obj
<< /Type /StructElem /S /math /NS 13 0 R /P 34 0 R /K 38 0 R /ID (ID.008) >>
endobj
38 0 obj
<< /Type /StructElem /S /msqrt /NS 13 0 R /P 37 0 R /K 39 0 R /ID (ID.009) >>
endobj
39 0 obj
<< /Type /StructElem /S /mi /NS 13 0 R /P 38 0 R /K <</Type /MCR /Pg 78 0 R /MCID 1>> /ID (ID.010) >>
endobj
40 0 obj
<< /Type /StructElem /S /text-unit /NS 15 0 R /P 21 0 R /K 41 0 R /ID (ID.011) >>
endobj
41 0 obj
<< /Type /StructElem /C /justify /S /text /NS 15 0 R /P 40 0 R /K [ 42 0 R ] /ID (ID.012) >>
endobj
42 0 obj
<< /Type /StructElem /C /inline /AF [25 0 R 44 0 R] /T <FEFF006D006100740068> /S /Formula /NS 11 0 R /P 41 0 R /K [<</Type /MCR /Pg 78 0 R /MCID 2>> 45 0 R] /ID (ID.013) >>
endobj
45 0 obj
<< /Type /StructElem /S /math /NS 13 0 R /P 42 0 R /K [46 0 R 49 0 R 51 0 R] /ID (ID.014) >>
endobj
46 0 obj
<< /Type /StructElem /S /msqrt /NS 13 0 R /P 45 0 R /K 47 0 R /ID (ID.015) >>
endobj
47 0 obj
<< /Type /StructElem /S /msqrt /NS 13 0 R /P 46 0 R /K 48 0 R /ID (ID.016) >>
endobj
48 0 obj
<< /Type /StructElem /S /mi /NS 13 0 R /P 47 0 R /K <</Type /MCR /Pg 78 0 R /MCID 3>> /ID (ID.017) >>
endobj
49 0 obj
<< /Type /StructElem /A 50 0 R /S /mo /NS 13 0 R /P 45 0 R /K <</Type /MCR /Pg 78 0 R /MCID 4>> /ID (ID.018) >>
endobj
51 0 obj
<< /Type /StructElem /S /mn /NS 13 0 R /P 45 0 R /K <</Type /MCR /Pg 78 0 R /MCID 5>> /ID (ID.019) >>
endobj
52 0 obj
<< /Type /StructElem /S /text-unit /NS 15 0 R /P 21 0 R /K 53 0 R /ID (ID.020) >>
endobj
53 0 obj
<< /Type /StructElem /C /justify /S /text /NS 15 0 R /P 52 0 R /K [ 54 0 R ] /ID (ID.021) >>
endobj
54 0 obj
<< /Type /StructElem /C /inline /AF [27 0 R 56 0 R] /T <FEFF006D006100740068> /S /Formula /NS 11 0 R /P 53 0 R /K [<</Type /MCR /Pg 78 0 R /MCID 6>> <</Type /MCR /Pg 78 0 R /MCID 9>> <</Type /MCR /Pg 78 0 R /MCID 11>> 57 0 R] /ID (ID.022) >>
endobj
57 0 obj
<< /Type /StructElem /S /math /NS 13 0 R /P 54 0 R /K [58 0 R 59 0 R 61 0 R] /ID (ID.023) >>
endobj
58 0 obj
<< /Type /StructElem /S /mi /NS 13 0 R /P 57 0 R /K <</Type /MCR /Pg 78 0 R /MCID 7>> /ID (ID.024) >>
endobj
59 0 obj
<< /Type /StructElem /A 60 0 R /S /mo /NS 13 0 R /P 57 0 R /K <</Type /MCR /Pg 78 0 R /MCID 8>> /ID (ID.025) >>
endobj
61 0 obj
<< /Type /StructElem /S /msqrt /NS 13 0 R /P 57 0 R /K 62 0 R /ID (ID.026) >>
endobj
62 0 obj
<< /Type /StructElem /S /mroot /NS 13 0 R /P 61 0 R /K [63 0 R 66 0 R] /ID (ID.027) >>
endobj
63 0 obj
<< /Type /StructElem /S /msup /NS 13 0 R /P 62 0 R /K [64 0 R 65 0 R] /ID (ID.028) >>
endobj
64 0 obj
<< /Type /StructElem /S /mi /NS 13 0 R /P 63 0 R /K <</Type /MCR /Pg 78 0 R /MCID 12>> /ID (ID.029) >>
endobj
65 0 obj
<< /Type /StructElem /S /mn /NS 13 0 R /P 63 0 R /K <</Type /MCR /Pg 78 0 R /MCID 13>> /ID (ID.030) >>
endobj
66 0 obj
<< /Type /StructElem /S /mn /NS 13 0 R /P 62 0 R /K <</Type /MCR /Pg 78 0 R /MCID 10>> /ID (ID.031) >>
endobj
67 0 obj
<< /Type /StructElem /S /text-unit /NS 15 0 R /P 21 0 R /K 68 0 R /ID (ID.032) >>
endobj
68 0 obj
<< /Type /StructElem /C /justify /S /text /NS 15 0 R /P 67 0 R /K [ 69 0 R ] /ID (ID.033) >>
endobj
69 0 obj
<< /Type /StructElem /C /inline /AF [29 0 R 71 0 R] /T <FEFF006D006100740068> /S /Formula /NS 11 0 R /P 68 0 R /K [<</Type /MCR /Pg 78 0 R /MCID 14>> <</Type /MCR /Pg 78 0 R /MCID 16>> 72 0 R] /ID (ID.034) >>
endobj
72 0 obj
<< /Type /StructElem /S /math /NS 13 0 R /P 69 0 R /K 73 0 R /ID (ID.035) >>
endobj
73 0 obj
<< /Type /StructElem /S /mroot /NS 13 0 R /P 72 0 R /K [74 0 R 75 0 R] /ID (ID.036) >>
endobj
74 0 obj
<< /Type /StructElem /S /mi /NS 13 0 R /P 73 0 R /K <</Type /MCR /Pg 78 0 R /MCID 17>> /ID (ID.037) >>
endobj
75 0 obj
<< /Type /StructElem /S /mn /NS 13 0 R /P 73 0 R /K <</Type /MCR /Pg 78 0 R /MCID 15>> /ID (ID.038) >>
endobj
5 0 obj
<< /Type /StructTreeRoot /Namespaces 8 0 R /IDTree 88 0 R /ClassMap 89 0 R /ParentTree 6 0 R /RoleMap 7 0 R /K 21 0 R >>
endobj
90 0 obj
[ 82 [ 500 ] ]
endobj
92 0 obj
<< /Subtype /CIDFontType0C /Length 574 >>
[BINARY STREAM]
endobj
91 0 obj
<< /Type /FontDescriptor /FontName /JFRMQG+LMRoman10-Regular /Flags 4 /FontBBox [ -430 -290 1417 1127 ] /Ascent 1127 /CapHeight 683 /Descent -290 /ItalicAngle 0 /StemV 93 /XHeight 431 /FontFile3 92 0 R >>
endobj
93 0 obj
<< /Length 692 >>
stream
%!PS-Adobe-3.0 Resource-CMap
%%DocumentNeededResources: ProcSet (CIDInit)
%%IncludeResource: ProcSet (CIDInit)
%%BeginResource: CMap (TeX-JFRMQG-LMRoman10-Regular-0)
%%Title: (TeX-JFRMQG-LMRoman10-Regular-0 TeX JFRMQG-LMRoman10-Regular 0)
%%Version: 1.000
%%EndComments
/CIDInit /ProcSet findresource begin
12 dict begin
begincmap
/CIDSystemInfo
<< /Registry (TeX)
/Ordering (JFRMQG-LMRoman10-Regular)
/Supplement 0
>> def
/CMapName /TeX-Identity-JFRMQG-LMRoman10-Regular def
/CMapType 2 def
1 begincodespacerange
<0000> <FFFF>
endcodespacerange
0 beginbfrange
endbfrange
1 beginbfchar
<0052> <0031>
endbfchar
endcmap
CMapName currentdict /CMap defineresource pop
end
end
%%EndResource
%%EOF
endstream
endobj
83 0 obj
<< /Type /Font /Subtype /Type0 /Encoding /Identity-H /BaseFont /JFRMQG+LMRoman10-Regular /DescendantFonts [ 94 0 R ] /ToUnicode 93 0 R >>
endobj
94 0 obj
<< /Type /Font /Subtype /CIDFontType0 /BaseFont /JFRMQG+LMRoman10-Regular /FontDescriptor 91 0 R /W 90 0 R /CIDSystemInfo << /Registry (Adobe) /Ordering (Identity) /Supplement 0 >> >>
endobj
95 0 obj
[ 1013 [ 569 ] ]
endobj
97 0 obj
<< /Subtype /CIDFontType0C /Length 702 >>
[BINARY STREAM]
endobj
96 0 obj
<< /Type /FontDescriptor /FontName /MGWLKY+LatinModernMath-Regular /Flags 4 /FontBBox [ -1042 -3060 4082 3560 ] /Ascent 806 /CapHeight 683 /Descent -194 /ItalicAngle 0 /StemV 113 /XHeight 431 /FontFile3 97 0 R >>
endobj
98 0 obj
<< /Length 722 >>
stream
%!PS-Adobe-3.0 Resource-CMap
%%DocumentNeededResources: ProcSet (CIDInit)
%%IncludeResource: ProcSet (CIDInit)
%%BeginResource: CMap (TeX-MGWLKY-LatinModernMath-Regular-0)
%%Title: (TeX-MGWLKY-LatinModernMath-Regular-0 TeX MGWLKY-LatinModernMath-Regular 0)
%%Version: 1.000
%%EndComments
/CIDInit /ProcSet findresource begin
12 dict begin
begincmap
/CIDSystemInfo
<< /Registry (TeX)
/Ordering (MGWLKY-LatinModernMath-Regular)
/Supplement 0
>> def
/CMapName /TeX-Identity-MGWLKY-LatinModernMath-Regular def
/CMapType 2 def
1 begincodespacerange
<0000> <FFFF>
endcodespacerange
0 beginbfrange
endbfrange
1 beginbfchar
<03F5> <0032>
endbfchar
endcmap
CMapName currentdict /CMap defineresource pop
end
end
%%EndResource
%%EOF
endstream
endobj
82 0 obj
<< /Type /Font /Subtype /Type0 /Encoding /Identity-H /BaseFont /MGWLKY+LatinModernMath-Regular /DescendantFonts [ 99 0 R ] /ToUnicode 98 0 R >>
endobj
99 0 obj
<< /Type /Font /Subtype /CIDFontType0 /BaseFont /MGWLKY+LatinModernMath-Regular /FontDescriptor 96 0 R /W 95 0 R /CIDSystemInfo << /Registry (Adobe) /Ordering (Identity) /Supplement 0 >> >>
endobj
100 0 obj
[ 600 [ 681 ] ]
endobj
102 0 obj
<< /Subtype /CIDFontType0C /Length 743 >>
[BINARY STREAM]
endobj
101 0 obj
<< /Type /FontDescriptor /FontName /DPSGTM+LatinModernMath-Regular /Flags 4 /FontBBox [ -1042 -3060 4082 3560 ] /Ascent 806 /CapHeight 683 /Descent -194 /ItalicAngle 0 /StemV 153 /XHeight 431 /FontFile3 102 0 R >>
endobj
103 0 obj
<< /Length 722 >>
stream
%!PS-Adobe-3.0 Resource-CMap
%%DocumentNeededResources: ProcSet (CIDInit)
%%IncludeResource: ProcSet (CIDInit)
%%BeginResource: CMap (TeX-DPSGTM-LatinModernMath-Regular-0)
%%Title: (TeX-DPSGTM-LatinModernMath-Regular-0 TeX DPSGTM-LatinModernMath-Regular 0)
%%Version: 1.000
%%EndComments
/CIDInit /ProcSet findresource begin
12 dict begin
begincmap
/CIDSystemInfo
<< /Registry (TeX)
/Ordering (DPSGTM-LatinModernMath-Regular)
/Supplement 0
>> def
/CMapName /TeX-Identity-DPSGTM-LatinModernMath-Regular def
/CMapType 2 def
1 begincodespacerange
<0000> <FFFF>
endcodespacerange
0 beginbfrange
endbfrange
1 beginbfchar
<0258> <0033>
endbfchar
endcmap
CMapName currentdict /CMap defineresource pop
end
end
%%EndResource
%%EOF
endstream
endobj
81 0 obj
<< /Type /Font /Subtype /Type0 /Encoding /Identity-H /BaseFont /DPSGTM+LatinModernMath-Regular /DescendantFonts [ 104 0 R ] /ToUnicode 103 0 R >>
endobj
104 0 obj
<< /Type /Font /Subtype /CIDFontType0 /BaseFont /DPSGTM+LatinModernMath-Regular /FontDescriptor 101 0 R /W 100 0 R /CIDSystemInfo << /Registry (Adobe) /Ordering (Identity) /Supplement 0 >> >>
endobj
105 0 obj
[ 12 [ 778 ] 19 [ 500 ] 30 [ 778 ] 1319 [ 572 490 ] 3077 [ 833 ] 3081 [ 1000 1000 ] ]
endobj
107 0 obj
<< /Subtype /CIDFontType0C /Length 1511 >>
[BINARY STREAM]
endobj
106 0 obj
<< /Type /FontDescriptor /FontName /NDJELI+LatinModernMath-Regular /Flags 4 /FontBBox [ -1042 -3060 4082 3560 ] /Ascent 806 /CapHeight 683 /Descent -194 /ItalicAngle 0 /StemV 93 /XHeight 431 /FontFile3 107 0 R >>
endobj
108 0 obj
<< /Length 828 >>
stream
%!PS-Adobe-3.0 Resource-CMap
%%DocumentNeededResources: ProcSet (CIDInit)
%%IncludeResource: ProcSet (CIDInit)
%%BeginResource: CMap (TeX-NDJELI-LatinModernMath-Regular-0)
%%Title: (TeX-NDJELI-LatinModernMath-Regular-0 TeX NDJELI-LatinModernMath-Regular 0)
%%Version: 1.000
%%EndComments
/CIDInit /ProcSet findresource begin
12 dict begin
begincmap
/CIDSystemInfo
<< /Registry (TeX)
/Ordering (NDJELI-LatinModernMath-Regular)
/Supplement 0
>> def
/CMapName /TeX-Identity-NDJELI-LatinModernMath-Regular def
/CMapType 2 def
1 begincodespacerange
<0000> <FFFF>
endcodespacerange
0 beginbfrange
endbfrange
8 beginbfchar
<000C> <002B>
<0013> <0032>
<001E> <003D>
<0527> <D835DC65>
<0528> <D835DC66>
<0C05> <221A>
<0C09> <221A>
<0C0A> <221A>
endbfchar
endcmap
CMapName currentdict /CMap defineresource pop
end
end
%%EndResource
%%EOF
endstream
endobj
80 0 obj
<< /Type /Font /Subtype /Type0 /Encoding /Identity-H /BaseFont /NDJELI+LatinModernMath-Regular /DescendantFonts [ 109 0 R ] /ToUnicode 108 0 R >>
endobj
109 0 obj
<< /Type /Font /Subtype /CIDFontType0 /BaseFont /NDJELI+LatinModernMath-Regular /FontDescriptor 106 0 R /W 105 0 R /CIDSystemInfo << /Registry (Adobe) /Ordering (Identity) /Supplement 0 >> >>
endobj
84 0 obj
<< /Type /Pages /Count 1 /Kids [ 78 0 R ] >>
endobj
110 0 obj
<< /EmbeddedFiles 86 0 R >>
endobj
111 0 obj
<< /Type /Catalog /Pages 84 0 R /Names 110 0 R /MarkInfo 85 0 R/Lang (en)/Metadata 76 0 R/StructTreeRoot 5 0 R >>
endobj
112 0 obj
<< /Producer (LuaTeX)/Creator (TeX)/CreationDate (D:20160520090000Z)/ModDate (D:20160520090000Z) /Trapped /False >>
endobj
xref
0 113
0000000002 65535 f
0000017659 00000 n
0000000003 00000 f
0000000004 00000 f
0000000010 00000 f
0000025382 00000 n
0000017844 00000 n
0000018694 00000 n
0000020839 00000 n
0000019474 00000 n
0000000012 00000 f
0000019542 00000 n
0000000014 00000 f
0000019612 00000 n
0000000020 00000 f
0000020375 00000 n
0000019693 00000 n
0000020648 00000 n
0000020477 00000 n
0000020750 00000 n
0000000000 00000 f
0000020900 00000 n
0000000020 00000 n
0000000257 00000 n
0000000444 00000 n
0000000754 00000 n
0000000941 00000 n
0000001291 00000 n
0000001478 00000 n
0000001726 00000 n
0000021021 00000 n
0000021109 00000 n
0000021197 00000 n
0000021297 00000 n
0000021408 00000 n
0000001913 00000 n
0000002067 00000 n
0000021600 00000 n
0000021695 00000 n
0000021791 00000 n
0000021912 00000 n
0000022012 00000 n
0000022123 00000 n
0000002267 00000 n
0000002433 00000 n
0000022315 00000 n
0000022426 00000 n
0000022522 00000 n
0000022618 00000 n
0000022739 00000 n
0000002633 00000 n
0000022871 00000 n
0000022992 00000 n
0000023092 00000 n
0000023203 00000 n
0000002704 00000 n
0000002875 00000 n
0000023464 00000 n
0000023575 00000 n
0000023696 00000 n
0000003075 00000 n
0000023828 00000 n
0000023924 00000 n
0000024029 00000 n
0000024133 00000 n
0000024255 00000 n
0000024377 00000 n
0000024499 00000 n
0000024599 00000 n
0000024710 00000 n
0000003146 00000 n
0000003303 00000 n
0000024938 00000 n
0000025033 00000 n
0000025138 00000 n
0000025260 00000 n
0000003503 00000 n
0000017560 00000 n
0000017425 00000 n
0000015284 00000 n
0000034795 00000 n
0000031606 00000 n
0000029365 00000 n
0000027181 00000 n
0000035166 00000 n
0000017706 00000 n
0000017742 00000 n
0000018006 00000 n
0000018657 00000 n
0000019273 00000 n
0000025519 00000 n
0000026208 00000 n
0000025550 00000 n
0000026429 00000 n
0000027335 00000 n
0000027535 00000 n
0000028354 00000 n
0000027568 00000 n
0000028583 00000 n
0000029525 00000 n
0000029731 00000 n
0000030592 00000 n
0000029764 00000 n
0000030823 00000 n
0000031768 00000 n
0000031977 00000 n
0000033676 00000 n
0000032080 00000 n
0000033906 00000 n
0000034957 00000 n
0000035228 00000 n
0000035273 00000 n
0000035404 00000 n
trailer
<< /Size 113 /Root 111 0 R /Info 112 0 R /ID [ <2350CAD05F8A7AF0AA4058486855344F> <2350CAD05F8A7AF0AA4058486855344F> ] >>
startxref
35537
%%EOF

View File

@ -4,24 +4,16 @@
\DocumentMetadata{
uncompress,
pdfversion = 2.0,
testphase = phase-I,
testphase = {phase-III,math,table},
}
\input{regression-test}
\documentclass{article}
\usepackage[structelem]{luamml-demo}
\usepackage{unicode-math}
\tagpdfsetup{math/mathml/structelem}
\begin{document}
\tagstructbegin{tag=Document}
\tagstructbegin{tag=P}
\tagmcbegin{tag=P}
hello
\tagmcend
\tagstructend
\LuaMMLTagAF{} {
\[
\begin{pmatrix}
1 & 0 & 0 \\
@ -34,26 +26,22 @@ hello
2 & \text{else}
\end{cases}
\]
}
\LuaMMLTagAF{} {
\[
x = \frac{-b \pm \sqrt{b^2-4ac}}{2a}.
\]
}
\LuaMMLTagAF{} {
\[
\sum_a\underline c\dot bc'
\]
}
\LuaMMLTagAF{} {
\begin{align}
abc&=def & e^{\mathrm{i}\pi}&=-1\\
\Big(1+2&=3\Big)\\
5
\end{align}
}
Es gilt \LuaMMLTagAF{}{$\sin(x)-\sin(x+2\pi)=0$}.
\tagstructend
Es gilt $\sin(x)-\sin(x+2\pi)=0$.
\end{document}

File diff suppressed because it is too large Load Diff

View File

@ -17,10 +17,10 @@ endobj
<< /Type /Filespec /AFRelationship /Source /Desc (TeX source) /F (tag-AFfile1.tex) /UF <FEFF007400610067002D0041004600660069006C00650031002E007400650078> /EF<</F 29 0 R/UF 29 0 R>> >>
endobj
36 0 obj
<< /O/NSO/NS130R/lspace(0.278em)/rspace(0.278em) >>
<< /O/NSO/NS 13 0 R/lspace(0.278em)/rspace(0.278em) >>
endobj
39 0 obj
<< /O/NSO/NS130R/width(9.963pt) >>
<< /O/NSO/NS 13 0 R/width(9.963pt) >>
endobj
40 0 obj
<< /Type /Metadata /Subtype /XML /Length 16669 >>
@ -421,16 +421,16 @@ endobj
[ 23 0 R ]
endobj
50 0 obj
<< /Subtype /text#2Fplain/Type /EmbeddedFile /Params<</ModDate (D:20160520) >> /Length 33 >>
<< /Subtype /text#2Fplain/Type /EmbeddedFile /Params<</ModDate (D:20160520) >> /Length 115 >>
stream
PDF standard A-4F requires a file
The document was declared to be of type PDF/A-4f but hasn't any attachments. LaTeX therefore added this dummy file.
endstream
endobj
51 0 obj
<< /Type /Filespec /AFRelationship /Unspecified /Desc (note about PDF/A-4F) /F (readme.txt) /UF <FEFF0072006500610064006D0065002E007400780074> /EF<</F 50 0 R/UF 50 0 R>> >>
<< /Type /Filespec /AFRelationship /Unspecified /Desc (note about PDF/A-4F) /F (pdf-A4f.txt) /UF <FEFF007000640066002D004100340066002E007400780074> /EF<</F 50 0 R/UF 50 0 R>> >>
endobj
52 0 obj
<< /Names[(readme) 51 0 R] >>
<< /Names[(pdf-A4f) 51 0 R] >>
endobj
6 0 obj
<< /Nums [0 [ 34 0 R 35 0 R 37 0 R 31 0 R 32 0 R]
@ -463,13 +463,13 @@ endobj
<< /title [/Title 11 0 R] /part [/Title 11 0 R] /section [/H1 11 0 R] /subsection [/H2 11 0 R] /subsubsection [/H3 11 0 R] /paragraph [/H4 11 0 R] /subparagraph [/H5 11 0 R] /list [/L 11 0 R] /itemize [/L 11 0 R] /enumerate [/L 11 0 R] /description [/L 11 0 R] /quote [/BlockQuote 9 0 R] /quotation [/BlockQuote 9 0 R] /verbatim [/P 11 0 R] /item [/LI 11 0 R] /itemlabel [/Lbl 11 0 R] /itembody [/LBody 11 0 R] /footnote [/FENote 11 0 R] /footnotemark [/Lbl 11 0 R] /footnotelabel [/Lbl 11 0 R] /text-unit [/Part 11 0 R] /text [/P 11 0 R] /theorem-like [/Sect 11 0 R] /codeline [/Sub 11 0 R] /float [/Aside 11 0 R] /figures [/Sect 11 0 R] /tables [/Sect 11 0 R] >>
endobj
15 0 obj
<< /Type /Namespace /NS (https://www.latex-project.org/ns/dflt/2022) /RoleMapNS 16 0 R >>
<< /Type /Namespace /NS (https://www.latex-project.org/ns/dflt) /RoleMapNS 16 0 R >>
endobj
18 0 obj
<< /chapter [/H1 11 0 R] /section [/H2 11 0 R] /subsection [/H3 11 0 R] /subsubsection [/H4 11 0 R] /paragraph [/H5 11 0 R] /subparagraph [/H6 11 0 R] >>
endobj
17 0 obj
<< /Type /Namespace /NS (https://www.latex-project.org/ns/book/2022) /RoleMapNS 18 0 R >>
<< /Type /Namespace /NS (https://www.latex-project.org/ns/book) /RoleMapNS 18 0 R >>
endobj
19 0 obj
<< /Type /Namespace /NS (data:,C9B55C18-275C-494E-C10F-E4B83CD03F23) >>
@ -704,80 +704,80 @@ endobj
xref
0 73
0000000002 65535 f
0000021934 00000 n
0000021940 00000 n
0000000003 00000 f
0000000004 00000 f
0000000010 00000 f
0000026429 00000 n
0000022448 00000 n
0000022823 00000 n
0000024880 00000 n
0000023505 00000 n
0000026513 00000 n
0000022542 00000 n
0000022917 00000 n
0000024964 00000 n
0000023599 00000 n
0000000012 00000 f
0000023573 00000 n
0000023667 00000 n
0000000014 00000 f
0000023643 00000 n
0000023737 00000 n
0000000020 00000 f
0000024406 00000 n
0000023724 00000 n
0000024684 00000 n
0000024513 00000 n
0000024791 00000 n
0000024500 00000 n
0000023818 00000 n
0000024773 00000 n
0000024602 00000 n
0000024875 00000 n
0000000000 00000 f
0000024941 00000 n
0000025025 00000 n
0000000020 00000 n
0000003353 00000 n
0000025039 00000 n
0000025127 00000 n
0000025215 00000 n
0000025315 00000 n
0000025426 00000 n
0000025123 00000 n
0000025211 00000 n
0000025299 00000 n
0000025399 00000 n
0000025510 00000 n
0000003586 00000 n
0000003921 00000 n
0000025577 00000 n
0000025711 00000 n
0000025832 00000 n
0000025957 00000 n
0000026078 00000 n
0000025661 00000 n
0000025795 00000 n
0000025916 00000 n
0000026041 00000 n
0000026162 00000 n
0000004121 00000 n
0000026210 00000 n
0000026331 00000 n
0000004189 00000 n
0000004240 00000 n
0000021847 00000 n
0000021712 00000 n
0000020999 00000 n
0000035068 00000 n
0000032552 00000 n
0000029052 00000 n
0000035434 00000 n
0000021981 00000 n
0000022017 00000 n
0000022044 00000 n
0000022213 00000 n
0000022402 00000 n
0000022519 00000 n
0000022786 00000 n
0000023402 00000 n
0000026566 00000 n
0000028012 00000 n
0000026654 00000 n
0000028235 00000 n
0000029205 00000 n
0000029404 00000 n
0000031438 00000 n
0000029542 00000 n
0000031659 00000 n
0000032706 00000 n
0000032906 00000 n
0000034022 00000 n
0000032954 00000 n
0000034250 00000 n
0000035228 00000 n
0000035496 00000 n
0000035540 00000 n
0000026294 00000 n
0000026415 00000 n
0000004192 00000 n
0000004246 00000 n
0000021853 00000 n
0000021718 00000 n
0000021005 00000 n
0000035152 00000 n
0000032636 00000 n
0000029136 00000 n
0000035518 00000 n
0000021987 00000 n
0000022023 00000 n
0000022050 00000 n
0000022301 00000 n
0000022495 00000 n
0000022613 00000 n
0000022880 00000 n
0000023496 00000 n
0000026650 00000 n
0000028096 00000 n
0000026738 00000 n
0000028319 00000 n
0000029289 00000 n
0000029488 00000 n
0000031522 00000 n
0000029626 00000 n
0000031743 00000 n
0000032790 00000 n
0000032990 00000 n
0000034106 00000 n
0000033038 00000 n
0000034334 00000 n
0000035312 00000 n
0000035580 00000 n
0000035624 00000 n
trailer
<< /Size 73 /Root 72 0 R /ID [ <2350CAD05F8A7AF0AA4058486855344F> <2350CAD05F8A7AF0AA4058486855344F> ] >>
startxref
35690
35774
%%EOF

View File

@ -1,20 +1,3 @@
<math xmlns="http://www.w3.org/1998/Math/MathML">
<mstyle displaystyle="true" scriptlevel="0">
<mi>𝑎</mi>
<mo lspace="0.278em" rspace="0.278em">=</mo>
<mi>𝑏</mi>
</mstyle>
</math>
<math xmlns="http://www.w3.org/1998/Math/MathML">
<mi>𝑎</mi>
<mo lspace="0.278em" rspace="0.278em">=</mo>
<mi>𝑏</mi>
</math>
<math xmlns="http://www.w3.org/1998/Math/MathML">
<mi>𝑎</mi>
<mo lspace="0.278em" rspace="0.278em">=</mo>
<mi>𝑏</mi>
</math>
<math xmlns="http://www.w3.org/1998/Math/MathML">
<mi>𝑎</mi>
<mo lspace="0.278em" rspace="0.278em">=</mo>
@ -80,7 +63,6 @@
<mo lspace="0.278em" rspace="0.278em">=</mo>
<mi>𝑏</mi>
</math></mtext>
<mi />
</mtd>
</mtr>
<mtr>
@ -89,7 +71,6 @@
</mtd>
<mtd columnalign="left">
<mtext>else</mtext>
<mi />
</mtd>
</mtr>
</mtable>
@ -146,16 +127,12 @@
<math display="block" xmlns="http://www.w3.org/1998/Math/MathML">
<mtable columnalign="right left right left" columnspacing="0 .8em 0" displaystyle="true">
<mtr>
<mtd intent=":equationlabel">
<mtext>(1)</mtext>
</mtd>
<mtd>
<mi>𝑎</mi>
<mi>𝑏</mi>
<mi>𝑐</mi>
</mtd>
<mtd>
<mi />
<mo lspace="0.278em" rspace="0.278em">=</mo>
<mi>𝑑</mi>
<mi>𝑒</mi>
@ -171,16 +148,12 @@
</msup>
</mtd>
<mtd>
<mi />
<mo lspace="0.278em" rspace="0">=</mo>
<mo lspace="0.278em" rspace="0"></mo>
<mn>1</mn>
</mtd>
</mtr>
<mtr>
<mtd intent=":equationlabel">
<mtext>(2)</mtext>
</mtd>
<mtd>
<mo fence="true" lspace="0" maxsize="17.861pt" minsize="17.861pt" rspace="0" symmetric="true">(</mo>
<mn>1</mn>
@ -188,34 +161,20 @@
<mn>2</mn>
</mtd>
<mtd>
<mi />
<mo lspace="0.278em" rspace="0.278em">=</mo>
<mn>3</mn>
<mo fence="true" lspace="0" maxsize="17.861pt" minsize="17.861pt" rspace="0" symmetric="true">)</mo>
</mtd>
<mtd>
<mi />
</mtd>
<mtd>
<mi />
</mtd>
<mtd></mtd>
<mtd></mtd>
</mtr>
<mtr>
<mtd intent=":equationlabel">
<mtext>(3)</mtext>
</mtd>
<mtd>
<mn>5</mn>
</mtd>
<mtd>
<mi />
</mtd>
<mtd>
<mi />
</mtd>
<mtd>
<mi />
</mtd>
<mtd></mtd>
<mtd></mtd>
<mtd></mtd>
</mtr>
</mtable>
</math>

View File

@ -1,17 +1,21 @@
\DocumentMetadata{
uncompress,
pdfversion = 2.0,
testphase = phase-I,
testphase = {phase-III,table,math},
}
\input{regression-test}
\documentclass{article}
\usepackage[l3build]{luamml-demo}
\usepackage{unicode-math}
\begin{document}
\tagstructbegin{tag=Document}
\LuaMMLTagAF{} {
\ExplSyntaxOn
\luamml_set_filename:n {
\jobname .mml
}
\luamml_process:
\luamml_begin_single_file:
\ExplSyntaxOff
\[
\begin{pmatrix}
1 & 0 & 0 \\
@ -24,26 +28,21 @@
2 & \text{else}
\end{cases}
\]
}
\LuaMMLTagAF{} {
\[
x = \frac{-b \pm \sqrt{b^2-4ac}}{2a}.
\]
}
\LuaMMLTagAF{} {
\[
\sum_a\underline c\dot bc'
\]
}
\LuaMMLTagAF{} {
\begin{align}
abc&=def & e^{\mathrm{i}\pi}&=-1\\
\Big(1+2&=3\Big)\\
5
\end{align}
}
Es gilt \LuaMMLTagAF{}{$\sin(x)-\sin(x+2\pi)=0$}.
\tagstructend
Es gilt $\sin(x)-\sin(x+2\pi)=0$.
\end{document}