summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/source/latex/expl3/l3box.dtx
diff options
context:
space:
mode:
Diffstat (limited to 'Master/texmf-dist/source/latex/expl3/l3box.dtx')
-rw-r--r--Master/texmf-dist/source/latex/expl3/l3box.dtx52
1 files changed, 48 insertions, 4 deletions
diff --git a/Master/texmf-dist/source/latex/expl3/l3box.dtx b/Master/texmf-dist/source/latex/expl3/l3box.dtx
index 6f3c0b21c1b..8da3021541b 100644
--- a/Master/texmf-dist/source/latex/expl3/l3box.dtx
+++ b/Master/texmf-dist/source/latex/expl3/l3box.dtx
@@ -36,7 +36,7 @@
\RequirePackage{l3names}
%</driver|package>
%\fi
-\GetIdInfo$Id: l3box.dtx 1919 2010-05-22 05:56:38Z will $
+\GetIdInfo$Id: l3box.dtx 2015 2010-09-03 17:45:09Z mittelba $
{L3 Experimental Box module}
%\iffalse
%<*driver>
@@ -400,7 +400,18 @@
% "\vbox:n" \Arg{contents}
% \end{syntax}
% Places a "vbox" of natural size with baseline equal to the baseline
-% of the last line in the box.
+% of the last object in the box, i.e., if the last object is a line of text
+% the box has the same depth as that line; otherwise the depth will be zero.
+% \end{function}
+%
+% \begin{function}{%
+% \vbox_top:n |
+% }
+% \begin{syntax}
+% "\vbox_top:n" \Arg{contents}
+% \end{syntax}
+% Same as "\vbox:n" except that the reference point will be at the baseline
+% of the first object in the box not the last.
% \end{function}
%
% \begin{function}{%
@@ -413,7 +424,24 @@
% "\vbox_set:Nn" <box> \Arg{contents}
% \end{syntax}
% Sets <box> to be a vertical mode box containing \m{contents}. It has
-% its natural size. "\vbox_gset:Nn" does it globally.
+% its natural size and the reference point will be at the baseline of the
+% last object in the box. "\vbox_gset:Nn" does it globally.
+% \end{function}
+%
+%
+% \begin{function}{%
+% \vbox_set_top:Nn |
+% \vbox_set_top:cn |
+% \vbox_gset_top:Nn |
+% \vbox_gset_top:cn |
+% }
+% \begin{syntax}
+% "\vbox_set_top:Nn" <box> \Arg{contents}
+% \end{syntax}
+% Sets <box> to be a vertical mode box containing \m{contents}. It has
+% its natural size (usually a small height and a larger depth)
+% and the reference point will be at the baseline of the
+% first object in the box. "\vbox_gset_top:Nn" does it globally.
% \end{function}
%
%
@@ -736,10 +764,12 @@
% \subsection{Vertical boxes}
%
%
-% \begin{macro}{\vbox:n}
+% \begin{macro}{\vbox:n,
+% \vbox_top:n}
% Put a vertical box directly into the input stream.
% \begin{macrocode}
\cs_new_protected_nopar:Npn \vbox:n {\tex_vbox:D \scan_stop:}
+\cs_new_protected_nopar:Npn \vbox_top:n {\tex_vtop:D \scan_stop:}
% \end{macrocode}
% \end{macro}
%
@@ -755,6 +785,20 @@
% \end{macro}
% \end{macro}
%
+%
+% \begin{macro}{\vbox_set_top:Nn,\vbox_set_top:cn}
+% \begin{macro}{\vbox_gset_top:Nn,\vbox_gset_top:cn}
+% Storing material in a vertical box with a natural height and reference
+% point at the baseline of the first object in the box.
+% \begin{macrocode}
+\cs_new_protected:Npn \vbox_set_top:Nn #1#2 {\tex_setbox:D #1 \tex_vtop:D {#2}}
+\cs_generate_variant:Nn \vbox_set_top:Nn {cn}
+\cs_new_protected_nopar:Npn \vbox_gset_top:Nn {\pref_global:D \vbox_set_top:Nn}
+\cs_generate_variant:Nn \vbox_gset_top:Nn {cn}
+% \end{macrocode}
+% \end{macro}
+% \end{macro}
+%
% \begin{macro}{\vbox_set_to_ht:Nnn,\vbox_set_to_ht:cnn}
% \begin{macro}{\vbox_gset_to_ht:Nnn,\vbox_gset_to_ht:cnn,\vbox_gset_to_ht:ccn}
% Storing material in a vertical box with a specified height.