ntg-context - mailing list for ConTeXt users
 help / color / mirror / Atom feed
* expansion problem with \getbuffer again (mkiv)
@ 2009-09-28 12:21 Peter Rolf
  2009-10-01 18:23 ` Hans Hagen
  0 siblings, 1 reply; 3+ messages in thread
From: Peter Rolf @ 2009-09-28 12:21 UTC (permalink / raw)
  To: mailing list for ConTeXt users

[-- Attachment #1: Type: text/plain, Size: 1584 bytes --]

Hi,

the attached example works with mkii, but breaks with mkiv. Here is the 
error message I get (beta 28.09.2009):

systems         : begin file test at line 1
! Missing \endgroup inserted.
<inserted text>
                \endgroup
<to be read again>
                   \vskip
\stopblankhandling ...ional \someblankdone \vskip
                                                  \blankskip \fi \endgroup
l.3 \stopblankhandling
                     
\dovspacing ...argument #1\else \s!default \fi ")}
                                                 
<to be read again>
                   \leavevmode
...
l.20 \setlayer[FOO]{\getbuffer[FOO]}
                                   
?
! Emergency stop.
<inserted text>
                \endgroup
<to be read again>
                   \vskip
\stopblankhandling ...ional \someblankdone \vskip
                                                  \blankskip \fi \endgroup
l.3 \stopblankhandling
                     
\dovspacing ...argument #1\else \s!default \fi ")}
                                                 
<to be read again>
                   \leavevmode
...
l.20 \setlayer[FOO]{\getbuffer[FOO]}
                                   
!  ==> Fatal error occurred, no output PDF file produced!MTXrun | run 1: 
luatex 
--fmt="r:/tex/texmf-cache/luatex-cache/context/d0b787cd25b9175dc4eaa276af366360/formats/cont-en" 
--lua="r:/tex/texmf-cache/luatex-cache/context/d0b787cd25b9175dc4eaa276af366360/formats/cont-en.lui" 
--backend=pdf "./test"
MTXrun | fatal error, return code: 1

-------------------------------------

Best wishes,  Peter

[-- Attachment #2: test.tex --]
[-- Type: text/plain, Size: 538 bytes --]

\starttext

\startbuffer[FOO]
%\startlocal
\defineparagraphs[SomePar][n=2]%,rule=on]%
%\setupparagraphs [SomePar][1][width=.5\hsize]%
%\setupparagraphs [SomePar][2][width=.4\hsize]%
%\CalloutFont\setupstrut\setupinterlinespace % right font must be set
%\setupwhitespace[small]%
\startSomePar
Speichern des\endgraf aktuellen Designs
\SomePar
Löschen (!)\endgraf der aktuellen\endgraf Designvorlage
\stopSomePar
%\stoplocal
\stopbuffer

\definelayer[FOO]

\setlayer[FOO]{\getbuffer[FOO]}
\flushlayer[FOO]

\stoptext

[-- Attachment #3: Type: text/plain, Size: 487 bytes --]

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: expansion problem with \getbuffer again (mkiv)
  2009-09-28 12:21 expansion problem with \getbuffer again (mkiv) Peter Rolf
@ 2009-10-01 18:23 ` Hans Hagen
  2009-10-01 19:05   ` Peter Rolf
  0 siblings, 1 reply; 3+ messages in thread
From: Hans Hagen @ 2009-10-01 18:23 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Peter Rolf wrote:
> Hi,
> 
> the attached example works with mkii, but breaks with mkiv. Here is the 
> error message I get (beta 28.09.2009):
> 
> systems         : begin file test at line 1
> ! Missing \endgroup inserted.
> <inserted text>
>                \endgroup
> <to be read again>
>                   \vskip
> \stopblankhandling ...ional \someblankdone \vskip
>                                                  \blankskip \fi \endgroup
> l.3 \stopblankhandling
>                     \dovspacing ...argument #1\else \s!default \fi ")}
>                                                 <to be read again>
>                   \leavevmode
> ....
> l.20 \setlayer[FOO]{\getbuffer[FOO]}
>                                   ?
> ! Emergency stop.
> <inserted text>
>                \endgroup
> <to be read again>
>                   \vskip
> \stopblankhandling ...ional \someblankdone \vskip
>                                                  \blankskip \fi \endgroup
> l.3 \stopblankhandling
>                     \dovspacing ...argument #1\else \s!default \fi ")}
>                                                 <to be read again>
>                   \leavevmode
> ....
> l.20 \setlayer[FOO]{\getbuffer[FOO]}
>                                   !  ==> Fatal error occurred, no output 
> PDF file produced!MTXrun | run 1: luatex 
> --fmt="r:/tex/texmf-cache/luatex-cache/context/d0b787cd25b9175dc4eaa276af366360/formats/cont-en" 
> --lua="r:/tex/texmf-cache/luatex-cache/context/d0b787cd25b9175dc4eaa276af366360/formats/cont-en.lui" 
> --backend=pdf "./test"
> MTXrun | fatal error, return code: 1

here is a patch (can't update right now, in the middle of something else)

\def\startblankhandling
   {\par
    \ifvmode
      \expandafter\dostartblankhandling
    \else
      \expandafter\nostartblankhandling
    \fi}

\def\nostartblankhandling#1\stopblankhandling
   {}

\def\dostartblankhandling
   {\begingroup
    \setfalse\someblankdone
    \the\everybeforeblankhandling}


-----------------------------------------------------------------
                                           Hans Hagen | PRAGMA ADE
               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
      tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
                                              | www.pragma-pod.nl
-----------------------------------------------------------------
___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: expansion problem with \getbuffer again (mkiv)
  2009-10-01 18:23 ` Hans Hagen
@ 2009-10-01 19:05   ` Peter Rolf
  0 siblings, 0 replies; 3+ messages in thread
From: Peter Rolf @ 2009-10-01 19:05 UTC (permalink / raw)
  To: mailing list for ConTeXt users

Hans Hagen schrieb:
> Peter Rolf wrote:
>> Hi,
>>
>> the attached example works with mkii, but breaks with mkiv. Here is 
>> the error message I get (beta 28.09.2009):
>>
>> systems         : begin file test at line 1
>> ! Missing \endgroup inserted.
>> <inserted text>
>>                \endgroup
>> <to be read again>
>>                   \vskip
>> \stopblankhandling ...ional \someblankdone \vskip
>>                                                  \blankskip \fi 
>> \endgroup
>> l.3 \stopblankhandling
>>                     \dovspacing ...argument #1\else \s!default \fi ")}
>>                                                 <to be read again>
>>                   \leavevmode
>> ....
>> l.20 \setlayer[FOO]{\getbuffer[FOO]}
>>                                   ?
>> ! Emergency stop.
>> <inserted text>
>>                \endgroup
>> <to be read again>
>>                   \vskip
>> \stopblankhandling ...ional \someblankdone \vskip
>>                                                  \blankskip \fi 
>> \endgroup
>> l.3 \stopblankhandling
>>                     \dovspacing ...argument #1\else \s!default \fi ")}
>>                                                 <to be read again>
>>                   \leavevmode
>> ....
>> l.20 \setlayer[FOO]{\getbuffer[FOO]}
>>                                   !  ==> Fatal error occurred, no 
>> output PDF file produced!MTXrun | run 1: luatex 
>> --fmt="r:/tex/texmf-cache/luatex-cache/context/d0b787cd25b9175dc4eaa276af366360/formats/cont-en" 
>> --lua="r:/tex/texmf-cache/luatex-cache/context/d0b787cd25b9175dc4eaa276af366360/formats/cont-en.lui" 
>> --backend=pdf "./test"
>> MTXrun | fatal error, return code: 1
>
> here is a patch (can't update right now, in the middle of something else)
>
Thanks Hans! As a nice side effect my other problem

http://archive.contextgarden.net/message/20090924.150300.aabab18c.en.html

is also history now. All colors are at the right places again.


> \def\startblankhandling
>   {\par
>    \ifvmode
>      \expandafter\dostartblankhandling
>    \else
>      \expandafter\nostartblankhandling
>    \fi}
>
> \def\nostartblankhandling#1\stopblankhandling
>   {}
>
> \def\dostartblankhandling
>   {\begingroup
>    \setfalse\someblankdone
>    \the\everybeforeblankhandling}
>
>
> -----------------------------------------------------------------
>                                           Hans Hagen | PRAGMA ADE
>               Ridderstraat 27 | 8061 GH Hasselt | The Netherlands
>      tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com
>                                              | www.pragma-pod.nl
> -----------------------------------------------------------------
> ___________________________________________________________________________________ 
>
> If your question is of interest to others as well, please add an entry 
> to the Wiki!
>
> maillist : ntg-context@ntg.nl / 
> http://www.ntg.nl/mailman/listinfo/ntg-context
> webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
> archive  : https://foundry.supelec.fr/projects/contextrev/
> wiki     : http://contextgarden.net
> ___________________________________________________________________________________ 
>
>

___________________________________________________________________________________
If your question is of interest to others as well, please add an entry to the Wiki!

maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context
webpage  : http://www.pragma-ade.nl / http://tex.aanhet.net
archive  : https://foundry.supelec.fr/projects/contextrev/
wiki     : http://contextgarden.net
___________________________________________________________________________________


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2009-10-01 19:05 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2009-09-28 12:21 expansion problem with \getbuffer again (mkiv) Peter Rolf
2009-10-01 18:23 ` Hans Hagen
2009-10-01 19:05   ` Peter Rolf

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).