@@ -68,7 +68,7 @@ \chapter{盒子}\label{boxes}\index{盒子|(}
68
68
\item [\cs {unhcopy} \cs {unvcopy}] 与 \cs {unhbox}、\cs {unvbox} 的行为相同,但不清空寄存器。
69
69
% \item [\cs{ht} \cs{dp} \cs{wd}]
70
70
% Height/depth/width of the box in a box register.
71
- \item [\cs {ht} \cs {dp} \cs {wd}] 返回盒子寄存器中盒子的高度 、深度、宽度。
71
+ \item [\cs {ht} \cs {dp} \cs {wd}] 返回及设置盒子寄存器中盒子的高度 、深度、宽度。
72
72
% \item [\cs{boxmaxdepth}]
73
73
% Maximum allowed depth of boxes.
74
74
% Plain \TeX\ default:~\cs{maxdimen}.
@@ -84,7 +84,7 @@ \chapter{盒子}\label{boxes}\index{盒子|(}
84
84
% \mdqon
85
85
% a horizontal/""vertical box overfull.
86
86
% \mdqoff
87
- \item [\cs {hfuzz} \cs {vfuzz}] 该命令表示一个水平盒子或竖直盒子超出指定尺寸的阈值 ;当超过该阈值时,\TeX 会考虑将其认定为溢出的(overfull)盒子。
87
+ \item [\cs {hfuzz} \cs {vfuzz}] 该命令表示水平或竖直盒子的尺寸超出指定尺寸的阈值 ;当超过该阈值时,\TeX 会考虑将其认定为溢出的(overfull)盒子。
88
88
% \item [\cs{hbadness} \cs{vbadness}]
89
89
% Amount of tolerance before \TeX\ reports an underfull
90
90
% \mdqon
@@ -268,7 +268,7 @@ \subsection{\cs{setbox}、\cs{box} 和 \cs{copy} 的用法}
268
268
% since in effect they contribute a partial
269
269
% horizontal or vertical list (see also Chapter~\ref{hvmode}).
270
270
% See below for more information on unboxing registers.
271
- 通过 \cs {unhbox} 和 \cs {unvbox} 及其拷贝版本 \cs {unhcopy} 和 \cs {unvcopy} 解包盒子寄存器中的内容是可行的。不同于 \cs {box} 可以在任何模式下使用,解包盒子的操作只能用在恰当的模式下——因为解包盒子会形成一个部分的水平盒子或竖直盒子 (参见第~\ref {hvmode }~章)。后文有关于解包盒子寄存器的更多信息。
271
+ 通过 \cs {unhbox} 和 \cs {unvbox} 及其拷贝版本 \cs {unhcopy} 和 \cs {unvcopy} 解包盒子寄存器中的内容是可行的。不同于 \cs {box} 可以在任何模式下使用,解包盒子的操作只能用在恰当的模式下——因为解包盒子会形成一个部分的水平列表或竖直列表 (参见第~\ref {hvmode }~章)。后文有关于解包盒子寄存器的更多信息。
272
272
273
273
% %\spoint Testing: \cs{ifvoid}, \cs{ifhbox}, \cs{ifvbox}
274
274
% \subsection{Testing: \cs{ifvoid}, \cs{ifhbox}, \cs{ifvbox}}
@@ -373,7 +373,7 @@ \subsection{已创建的水平盒子的尺寸}
373
373
\hbox{\hskip-1cm}
374
374
\end {verbatim }
375
375
% is negative. By way of example,
376
- 具体距离来说 :
376
+ 具体举例来说 :
377
377
\begin {disp }\verb >a\hbox{\kern-1em b}-- >\end {disp }
378
378
% gives as output
379
379
的输出是
@@ -396,7 +396,7 @@ \subsection{已创建的水平盒子的尺寸}
396
396
% is not allowed in a horizontal box, and
397
397
% \cs{par}, although allowed,
398
398
% does not do anything inside a horizontal box.
399
- \cs {raise} 和 \cs {lower} 命令是在 \cs {hbox} 内调整元素水平位置的唯一方法(当然,除了在 \cs {hbox} 中嵌套一个新的 \cs {vbox});\TeX 不允许在水平盒子中使用竖直命令(\gr {vertical command},例如 \cs {vskip}), 此外,虽然我们可以在水平盒子中使用 \cs {par},但它却不会有任何作用。
399
+ \cs {raise} 和 \cs {lower} 命令是在 \cs {hbox} 内调整元素水平位置的唯一方法(当然,除了在 \cs {hbox} 中嵌套一个新的 \cs {vbox});\TeX 不允许在水平盒子中使用竖直命令(\gr {vertical command},例如 \cs {vskip}); 此外,虽然我们可以在水平盒子中使用 \cs {par},但它却不会有任何作用。
400
400
401
401
% %\spoint Dimensions of created vertical boxes
402
402
% \subsection{Dimensions of created vertical boxes}
@@ -476,7 +476,7 @@ \subsection{已创建的竖直盒子的尺寸}
476
476
% natural height of the box. If the box had a \n{to} or
477
477
% \n{spread} specification, any glue is set anew to take
478
478
% the new height into account.
479
- 关于竖直盒子,还有一个限制:如果 \cs {vbox} 或者 \cs {vtop} 的深度超出 \csidx {boxmaxdepth},则盒子的参考点会下移这一超出的数值。具体来说,超出限制的深度 ,会被加在盒子自身的高度之上。如果盒子有 \n {to} 或者 \n {spread} 声明符,则相关的伸缩胶都会被重新设置,以将追加的高度考虑在内。
479
+ 关于竖直盒子,还有一个限制:如果 \cs {vbox} 或者 \cs {vtop} 的深度超出 \csidx {boxmaxdepth},则盒子的参考点会下移这一超出的数值。具体来说,超出限制的那一部分深度 ,会被加在盒子自身的高度之上。如果盒子有 \n {to} 或者 \n {spread} 声明符,则相关的伸缩胶都会被重新设置,以将追加的高度考虑在内。
480
480
481
481
% Ordinarily,
482
482
% \cs{boxmaxdepth} is set to the maximum dimension
@@ -600,7 +600,7 @@ \subsection{预先指定尺寸}
600
600
% Any glue
601
601
% in the box is then set in order to reach the required size.
602
602
% Prescribing the size of the box is done by
603
- 盒子的尺寸可以通过尺寸说明符(\gr {box specification})来指定盒子的尺寸 ;具体语法可见上文。盒子中的伸缩胶会依需求缩放,使得盒子的尺寸达到上述设定值。预先指定盒子的尺寸的方法是:
603
+ 盒子的尺寸可以通过尺寸说明符(\gr {box specification})来指定 ;具体语法可见上文。盒子中的伸缩胶会依需求缩放,使得盒子的尺寸达到上述设定值。预先指定盒子的尺寸的方法是:
604
604
\begin {disp }
605
605
\cs {hbox} \n {to} \gr {dimen} \n {\lb ...\rb },
606
606
\cs {vbox} \n {to} \gr {dimen} \n {\lb ...\rb }
@@ -612,7 +612,7 @@ \subsection{预先指定尺寸}
612
612
% is necessary \rdash is present, the resulting box will be underfull
613
613
% or overfull respectively. Error reporting for over/underfull
614
614
% boxes is treated below.
615
- 如果盒子中有可以拉伸或收缩的伸缩胶,则这些伸缩胶会被拉伸或收缩,以将盒子的尺寸调整至指定的大小。与伸缩胶伸缩相关的是所谓的劣度值(见第~\ref {glue }~章)。如果伸缩胶能够提供的拉伸和收缩值不足所需 ,则得到的盒子会欠满或溢出。后文有关于欠满和溢出的报错的相关讨论。
615
+ 如果盒子中有可以拉伸或收缩的伸缩胶,则这些伸缩胶会被拉伸或收缩,以将盒子的尺寸调整至指定的大小。与伸缩胶伸缩相关的是所谓的劣度值(见第~\ref {glue }~章)。如果伸缩胶能够提供的拉伸或收缩值不足所需 ,则得到的盒子会欠满或溢出。后文有关于欠满和溢出的报错的相关讨论。
616
616
617
617
% Another command to let a box have a size other than
618
618
% the natural size is
@@ -709,7 +709,7 @@ \subsection{移动盒子}
709
709
710
710
% Only boxes can be shifted thus; these operations cannot
711
711
% be applied to, for instance, characters or rules.
712
- 注意,只有盒子能用上述命令来移动,因此 ,这些命令不能用于字符或标尺。
712
+ 注意,上述命令只能用来移动盒子,特别地 ,这些命令不能用于字符或标尺。
713
713
714
714
% \subsection{Box dimensions and box placement}
715
715
\subsection {盒子的尺寸与盒子的摆放 }
@@ -738,7 +738,7 @@ \subsection{盒子的尺寸与盒子的摆放}
738
738
% putting a new current position for the enclosed vertical list there,
739
739
% and place its components using the algorithm for vertical
740
740
% lists below.
741
- \item 如果元素是水平盒子,则对其内容递归地调用该算法;如果元素是竖直盒子,按盒子的高度向上移动当前位置,而后按照后文所述的有关竖直盒子的算法防止盒子内竖直列表中的元素 。
741
+ \item 如果元素是水平盒子,则对其内容递归地调用该算法;如果元素是竖直盒子,按盒子的高度向上移动当前位置,而后按照后文所述的有关竖直盒子的算法放置盒子内竖直列表中的元素 。
742
742
% \item Move the current position (on the reference line)
743
743
% to the right by the width of the component.
744
744
\item 按当前元素的宽度,沿着参考线向右移动当前位置。
@@ -763,7 +763,7 @@ \subsection{盒子的尺寸与盒子的摆放}
763
763
% its reference point can be found below the current position
764
764
% by the height of the box. Put the current position for that
765
765
% box there, and use the above algorithm for horizontal lists.
766
- \item 如果元素是竖直盒子,则对其内容递归地调用该算法;如果元素是水平盒子,按盒子的高度向下移动当前位置,而后按照前文所述的有关竖直盒子的算法防止盒子内水平列表中的元素 。
766
+ \item 如果元素是竖直盒子,则对其内容递归地调用该算法;如果元素是水平盒子,按盒子的高度向下移动当前位置,而后按照前文所述的有关竖直盒子的算法放置盒子内水平列表中的元素 。
767
767
% \item Go down by the height plus depth of the box
768
768
% (that is, starting at the upper left corner of the box)
769
769
% on the reference line,
@@ -801,7 +801,7 @@ \subsection{盒子与反向伸缩胶}
801
801
% The \cs{hss} glue is equivalent to \verb>\hskip 0pt plus 1fil minus 1fil>,
802
802
% which absorbs any positive or negative width
803
803
% of the argument of \cs{llap} or \cs{rlap}.
804
- 这两个命令允许其中的内容基于当前位置向左或向右突出。这里,\cs {hss} 伸缩胶等价于 \cs {hskip 0pt plus 1fil minus 1fil},它能吸收 \cs {llap} 或 \cs {rlap} 的参数的任意正负宽度 。
804
+ 这两个命令允许其中的内容基于当前位置向左或向右突出。这里,\cs {hss} 伸缩胶等价于 \cs {hskip 0pt plus 1fil minus 1fil},它能吸收 \cs {llap} 或 \cs {rlap} 的参数中的任意正负宽度 。
805
805
806
806
\begin {example }
807
807
% The sequence
@@ -1078,7 +1078,7 @@ \section{盒子中的文本}
1078
1078
% (see page~\pageref{v:com:list}), or at the end
1079
1079
% of the box, the paragraph is broken into lines using the
1080
1080
% current values of parameters such as~\cs{hsize}.
1081
- 竖直盒子相对来水就要复杂得多了 。在竖直盒子中,一旦遇到字符或其他任何水平命令(\gram {horizontal command},见第~\pageref {h:com:list }~页),\TeX 就会开始在非受限水平模式构建段落;也就是说,仿佛这一段落是直属于页面的一部分。而当遇到竖直命令(\gram {vertical command},见第~\pageref {v:com:list }~页)或盒子结束时,\TeX 会使用当前的参数值(例如 \cs {hsize})将该段落分段成行。
1081
+ 竖直盒子相对来说就要复杂得多了 。在竖直盒子中,一旦遇到字符或其他任何水平命令(\gram {horizontal command},见第~\pageref {h:com:list }~页),\TeX 就会开始在非受限水平模式构建段落;也就是说,仿佛这一段落是直属于页面的一部分。而当遇到竖直命令(\gram {vertical command},见第~\pageref {v:com:list }~页)或盒子结束时,\TeX 会使用当前的参数值(例如 \cs {hsize})将该段落分段成行。
1082
1082
1083
1083
% Thus
1084
1084
因此,下列代码的\emph {不会 }输出宽度为 3 厘米的段落(如果 $ \text {\cs {hsize}} > \text {\n {3cm}}$ ,则水平盒子会溢出):
@@ -1142,7 +1142,7 @@ \subsection{忘掉 \cs{box}}
1142
1142
% The reason for this is that there exists
1143
1143
% no separate \cs{boxdef} command, so \cs{chardef} is
1144
1144
% used (see Chapter~\ref{alloc}).
1145
- 在 \cs {newcount}\cs {foo} 之后,我们就可以单独用 \cs {foo} 来访问这个计数器了。但是,对于盒子来说则必须使用 \cs {box}\cs {foo} 来访问相应的盒子。其原因在于,不存在单独的 \cs {boxdef} 命令,而是用 \cs {chardef} 命令来代替(详见第~\ref {alloc }~章)。
1145
+ 在 \cs {newcount}\cs {foo} 之后,我们就可以单独用 \cs {foo} 来访问这个计数器了。但是,对于盒子来说则必须使用 \cs {box}\cs {foo} 来访问相应的盒子。其原因在于,\TeX 中不存在单独的 \cs {boxdef} 命令,而是用 \cs {chardef} 命令来代替(详见第~\ref {alloc }~章)。
1146
1146
1147
1147
\begin {example }
1148
1148
% Suppose \verb.\newbox\foo. allocates box register~25; then
0 commit comments