[NTG-context] Parallel output of source data

Wolfgang Schuster schuster.wolfgang at gmail.com
Tue Jul 3 09:07:23 CEST 2018


Hi Lukas,

when you create the buffer with the grabbufferdata-command you already set
the delimiter for the environment with the third argument, in the 
example below
this is the \stopcontentexport command.

To have different start/stop-commands for your environment means you have
to change all names in the implementation of the contentxport-environment.

%%%%%%
\unexpanded\def\bH{....}

\def\dobH[#1]%
    {...
     \grabbufferdata[...][bH][eH]}

\def\eH
   {....}
%%%%%%

Wolfgang
> Procházka Lukáš Ing. <mailto:LPr at pontex.cz>
> 3. Juli 2018 um 08:52
> Hello,
>
> I tried to \let shortcuts for \startcontentexport and 
> \stopcontentexport, but Ctx run fails.
>
> I guess this is a basic misunderstanding, but - why?
>
> ----
> \unexpanded\def\startcontentexport{\dosingleempty\dostartcontentexport}
>
> \def\dostartcontentexport[#1]%
> {\iffirstargument
>   \edef\contentexportfile{#1}%
>   \else
>   \let\contentexportfile\empty
>   \fi
>   \grabbufferdata[contentexport][startcontentexport][stopcontentexport]
> }
>
> \def\stopcontentexport{%
>   
> \doifsomething{\contentexportfile}{\savebuffer[list=contentexport,prefix=no,file=\contentexportfile]}% 
>
>   \getbufferdata[contentexport]
> }
>
> \let\bX=\startcontentexport % <---- Use of these two "shortcuts" is 
> not possible,
> \let\eX=\stopcontentexport  % <---- I'm getting : ! TeX capacity 
> exceeded, sorry [input stack size=10000]
>
> \starttext
>
>   A
>
>   \startcontentexport[t~.out.mkiv]
>     Hello!
>     \startitemize
>     \item Item
>     \stopitemize
>   \stopcontentexport
>
>   B
>
>   \bX[t2~.out.mkiv]
>     Ahoj
>   \eX
>
> \stoptext
> ----
>
> HSo how to define "shortcuts" properly?
>
> Best regards,
>
> Lukas
>
>
> ___________________________________________________________________________________
> If your question is of interest to others as well, please add an entry 
> to the Wiki!
>
> maillist : ntg-context at ntg.nl / 
> http://www.ntg.nl/mailman/listinfo/ntg-context
> webpage : http://www.pragma-ade.nl / http://context.aanhet.net
> archive : https://bitbucket.org/phg/context-mirror/commits/
> wiki : http://contextgarden.net
> ___________________________________________________________________________________

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mailman.ntg.nl/pipermail/ntg-context/attachments/20180703/d8a36536/attachment.html>


More information about the ntg-context mailing list