else
local pid = getid(p)
if pid == id_sub_mlist then
- if getlist(p) then
- setfield(p, 'head', conv_jchar_to_hbox(getlist(p), sty))
+ if getfield(p, 'head') then
+ setfield(p, 'head', conv_jchar_to_hbox(getfield(p, 'head'), sty))
end
elseif pid == id_mchar then
local fam = has_attr(p, attr_jfam) or -1
if get_attr_icflag(p) == icflag_table.PACKED then
s = s .. ' (packed)'
end
- print_fn(s)
- local q = p.head
- debug_depth=debug_depth.. '.'
- while q do
- debug_show_node_X(q, print_fn); q = node_next(q)
+ print_fn(s); debug_depth=debug_depth.. '.'
+ for q in node.traverse(p.head) do
+ debug_show_node_X(q, print_fn)
end
debug_depth=k
elseif pt == 'glue' then
elseif pt=='math_char' then
s = base .. ' fam: ' .. p.fam .. ' , char = ' .. utf.char(p.char)
print_fn(s)
- elseif pt=='sub_box' then
+ elseif pt=='sub_box' or pt=='sub_mlist' then
print_fn(base)
if p.head then
- debug_depth = k .. '.'; debug_show_node_X(p.head, print_fn);
+ debug_depth = k .. '.';
+ for q in node.traverse(p.head) do
+ debug_show_node_X(q, print_fn)
+ end
end
else
print_fn(base)