diff options
author | Karl Berry <karl@freefriends.org> | 2011-11-25 00:13:53 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2011-11-25 00:13:53 +0000 |
commit | ffc8e17b8078900ab7932786f99a36a7f3b1166c (patch) | |
tree | 4e6b90567c8ee8bff06b06a3868c14b7e9f06eef /Master/texmf-dist/source/latex/l3experimental/xcoffins | |
parent | 3c7032087650de924a1aead943de992a2c689248 (diff) |
l3experimental 2966 (19nov11)
git-svn-id: svn://tug.org/texlive/trunk@24655 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/source/latex/l3experimental/xcoffins')
-rw-r--r-- | Master/texmf-dist/source/latex/l3experimental/xcoffins/xcoffins.dtx | 59 |
1 files changed, 58 insertions, 1 deletions
diff --git a/Master/texmf-dist/source/latex/l3experimental/xcoffins/xcoffins.dtx b/Master/texmf-dist/source/latex/l3experimental/xcoffins/xcoffins.dtx index 103934d5fe8..30a58c18817 100644 --- a/Master/texmf-dist/source/latex/l3experimental/xcoffins/xcoffins.dtx +++ b/Master/texmf-dist/source/latex/l3experimental/xcoffins/xcoffins.dtx @@ -36,7 +36,7 @@ % %<*driver|package> \RequirePackage{xparse} -\GetIdInfo$Id: xcoffins.dtx 2895 2011-10-09 15:58:19Z joseph $ +\GetIdInfo$Id: xcoffins.dtx 2963 2011-11-15 22:06:41Z joseph $ {L3 Experimental design-level coffins} %</driver|package> %<*driver> @@ -583,6 +583,47 @@ % coffin is therefore analogous to carrying out an alignment where the % \enquote{parent} coffin is the current insertion point. % \end{function} +% +% \section{Measuring coffins} +% +% There are places in the design process where it is useful to be able to +% measure coffins outside of pole-setting procedures. +% +% \begin{function}{\CoffinDepth} +% \begin{syntax} +% \cs{CoffinDepth} \meta{coffin} +% \end{syntax} +% Calculates the depth (below the baseline) of the \meta{coffin} +% in a form suitable for use in a \meta{dimension expression}, for example +% |\setlength{\mylength}{\CoffinDepth\ExampleCoffin}|. +% \end{function} +% +% \begin{function}{\CoffinHeight} +% \begin{syntax} +% \cs{CoffinHeight} \meta{coffin} +% \end{syntax} +% Calculates the height (above the baseline) of the \meta{coffin} +% in a form suitable for use in a \meta{dimension expression}, for example +% |\setlength{\mylength}{\CoffinHeight\ExampleCoffin}|. +% \end{function} +% +% \begin{function}{\CoffinTotalHeight} +% \begin{syntax} +% \cs{CoffinTotalHeight} \meta{coffin} +% \end{syntax} +% Calculates the total height of the \meta{coffin} +% in a form suitable for use in a \meta{dimension expression}, for example +% |\setlength{\mylength}{\CoffinTotalHeight\ExampleCoffin}|. +% \end{function} +% +% \begin{function}{\CoffinWidth} +% \begin{syntax} +% \cs{CoffinHeight} \meta{coffin} +% \end{syntax} +% Calculates the width of the \meta{coffin} in a form +% suitable for use in a \meta{dimension expression}, for example +% |\setlength{\mylength}{\CoffinWidth\ExampleCoffin}|. +% \end{function} % % \section{Diagnostic functions} % @@ -839,6 +880,22 @@ % \end{macro} % \end{macro} % \end{macro} +% +% \begin{macro}{\CoffinDepth, \CoffinHeight, \CoffinTotalHeigth, \CoffinWidth} +% Nothing too complex, except that the total height is set up as an +% expression so that it will act correctly if prefixed with a negative +% sign, \emph{etc.} +% \begin{macrocode} +\NewDocumentCommand \CoffinDepth { m } + { \coffin_dp:N #1 } +\NewDocumentCommand \CoffinHeight { m } + { \coffin_ht:N #1 } +\NewDocumentCommand \CoffinTotalHeight { m } + { \dim_eval:w \coffin_ht:N #1 + \coffin_dp:N #1 \dim_eval_end: } +\NewDocumentCommand \CoffinWidth { m } + { \coffin_wd:N #1 } +% \end{macrocode} +% \end{macro} % % \begin{macro}{\DisplayCoffinHandles} % Displaying all of the handles is a bit easier, as there is no need |