我在使用嵌套在 Context 中的表时遇到了麻烦embeddedxtables
(警告“这对我来说都很新,所以请原谅任何明显的失误......)
我试图简化我的例子来说明我遇到的问题,因此可能感觉有点做作。
这是我不明白的:
C21
为什么包含和的嵌套表没有C22
出现?(我尝试在这里使用embeddedxtable
而不是xtable
,但这会阻止文件编译)。为什么内部表格没有
mybuffer1
出现在旁边的第一个 xtable 中B1
?为什么周围的整个外表皮
mybuffer2
根本没有出现?
谢谢您的见解!
\def\OuterTable[#1]{
\startembeddedxtable
\startxrow
\startxcell A1 \stopxcell
\startxcell A2 \stopxcell
\stopxrow
\startxrow
\startxcell B1 \stopxcell
\startxcell \getbuffer[#1] \stopxcell
\stopxrow
\startxrow
\startxcell C1 \stopxcell
\startxcell
\startxtable
\startxrow
\startxcell C21 \stopxcell
\startxcell C22 \stopxcell
\stopxrow
\stopxtable
\stopxcell
\stopxrow
\stopembeddedxtable
}
\startbuffer[mybuffer1]
Text from buffer that precedes my table
\startxtable
\startxrow
\startxcell B21 \stopxcell
\startxcell B22 \stopxcell
\stopxrow
\stopxtable
Text from buffer that comes after table
\stopbuffer
\startbuffer[mybuffer2]
Text from buffer that precedes my table
\startembeddedxtable
\startxrow
\startxcell B21 \stopxcell
\startxcell B22 \stopxcell
\stopxrow
\stopembeddedxtable
Text from buffer that comes after table
\stopbuffer
\starttext
Inner table using xtable
\OuterTable[mybuffer1]
\blank
Inner table using embeddedxtable (nothing shows up but space is used on the page)
\OuterTable[mybuffer2]
\blank
The buffer works fine when we don't go through a macro: \\
\startxtable
\startxrow
\startxcell B1 \stopxcell
\startxcell \getbuffer[mybuffer1] \stopxcell
\stopxrow
\startxrow
\startxcell B1' \stopxcell
\startxcell \getbuffer[mybuffer2] \stopxcell
\stopxrow
\stopxtable
\stoptext