At 10:24 PM 2/10/2002 +1100, Daniel Pittman wrote:
I have, currently:

>\def\step{
>\ifFirstStep
>   \FirstStepfalse
>   \starttabulate[|p(.4\hsize)|p|]
>\else
>   \NC \NR
>\fi
>}
>
>The intention is that each recipe has a title, some arbitrary amount
>(possibly no) leading material, then a series of steps, such that:
>
>\recipe(title)
>... stuff about the recipe ...
>\step
>... first step ...
>\step
>... second step ....
>\end
>
>
>When I try to run the TeX file, however, I get the following output:

that kind of trickery will probably interfere with table lookahead (baked 
into tex), so i would opt for:

\definetabulate
   [recipe]
   [|l|l|l|]

\setuptabulate
   [recipe]
   [inner=\setquicktabulate\step,before=]

\startrecipe
\step first step  \\ next \\ more  \\
\step second step \\ bla  \\ again \\
\step last step   \\ next \\ oeps  \\
\stoprecipe

\definehead[recipe][subsubsubject]
\setuphead[recipe][after=,style=bold]

\def\StartRecipe#1%
   {\recipe{#1}\startrecipe}

\StartRecipe{whatever}
\step first step  \\ next \\ more  \\
\step second step \\ bla  \\ again \\
\step last step   \\ next \\ oeps  \\
\stoprecipe


 > Also, it didn't seem to be possible to use buffers within a macro at

right, limitation by design

>all; they didn't pick up any content no matter what I put in them.
>
>This failed:
>
>\setupbuffer[test]
>\hidebuffers[test]
>
>\def\test{\begintest This is a test \endtest}
>
>\test
>
>\getbuffer[test]

In your case you could store teh text into a macro -)

You can however fill a buffer in the following way:

\def\test{\setbuffer[test]This is a test\endbuffer}

\test

\getbuffer[test]

There is also \definebuffer as well as the undocumented \dostartbuffer

\def\GrabCrap{\dostartbuffer[crap][GrabCrap][NoMoreCrap]}

\GrabCrap
believe it or not
but this works
\NoMoreCrap

\getbuffer[crap]
-------------------------------------------------------------------------
                                   Hans Hagen | PRAGMA ADE | [EMAIL PROTECTED]
                       Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
  tel: +31 (0)38 477 53 69 | fax: +31 (0)38 477 53 74 | www.pragma-ade.com
-------------------------------------------------------------------------
                                   fall-back web server: 
www.pragma-pod.nl
-------------------------------------------------------------------------

Reply via email to