\input luaotfload.sty
\catcode`\@=11
\pageheight 23mm
\pagewidth 67mm
\hoffset -1in
\voffset -1in
\advance\hoffset 2mm
\hsize 63mm
\vsize 23mm
\topskip\z@
\baselineskip 17.5\p@
\abovedisplayskip\z@
\abovedisplayshortskip\z@
\belowdisplayskip\z@
\belowdisplayshortskip\z@
\def\@textmode{mode=harf;script=latn;language=DFLT;+tlig}
\font\fourteenbf="MinionPro-BoldCapt.otf:\@textmode" at 14\p@
\fourteenbf
\def\N{\vrule width 2\p@}
\def\n{\vrule width 1\p@}
\def\E#1{\hbox to 8mm {\hss#1\strut\hss}}
\setbox\strutbox\hbox{%
\vrule height.7\baselineskip depth.3\baselineskip width\z@}
$$
%
\tabskip\z@
\vbox{\halign{%
\N \E{#}\n & \E{#}\n & \E{#}\n & \E{#}\n & \E{#}\n &%
\E{#}\n & \E{#}\N \cr
\noalign{\hrule height 2\p@}
1 & 2 & 3 & 4 & 5 & 6 & Ø \cr%
\noalign{\hrule height 1\p@}
& & & & & & \cr
\noalign{\hrule height 2\p@}
}}
%
$$
\bye
请查看 MWE。数字未位于单元格的中心。
- 我究竟做错了什么?
- 是否可以将整个表格垂直置于页面中央?
答案1
您需要考虑在表格单元格中添加的空白。
\input luaotfload.sty
\catcode`\@=11
\pageheight 23mm
\pagewidth 67mm
\hoffset -1in
\voffset -1in
\advance\hoffset 2mm
\hsize 63mm
\vsize 23mm
\topskip\z@
\baselineskip 17.5\p@
\abovedisplayskip\z@
\abovedisplayshortskip\z@
\belowdisplayskip\z@
\belowdisplayshortskip\z@
\def\@textmode{}%mode=harf;script=latn;language=DFLT;+tlig}
%\font\fourteenbf="MinionPro-BoldCapt.otf:\@textmode" at 14\p@
\let\fourteenbf\relax
\fourteenbf
\def\N{\vrule width 2\p@}
\def\n{\vrule width 1\p@}
\def\E#1{\hbox to 8mm {\unskip\hss\ignorespaces#1\unskip\strut\hss\ignorespaces}}
\setbox\strutbox\hbox{%
\vrule height.7\baselineskip depth.3\baselineskip width\z@}
$$
%
\tabskip\z@
\vbox{\halign{%
\N \E{#}\n & \E{#}\n & \E{#}\n & \E{#}\n & \E{#}\n &%
\E{#}\n & \E{#}\N \cr
\noalign{\hrule height 2\p@}
1 & 2 & 3 & 4 & 5 & 6 & Ø \cr%
\noalign{\hrule height 1\p@}
& & & & & & \cr
\noalign{\hrule height 2\p@}
}}
%
$$
\bye