______________________ -----Ursprüngliche Nachricht----- Von: ntg-context-bounces@ntg.nl [mailto:ntg-context-bounces@ntg.nl] Im Auftrag von Wolfgang Schuster Gesendet: Mittwoch, 21. Januar 2009 00:08 An: mailing list for ConTeXt users Betreff: Re: [NTG-context] backgrounds: help needed Am 20.01.2009 um 23:51 schrieb Alan BRASLAU:
I, too, do not understand the \definetextbackground \starttextbackground \stoptextbackground commands, even though I tried looking at "details.pdf" (and core- pgr.tex). My particular problem is rather classic, that of illustrating examples, set off from the main text. I first used \defineframedtext [example] [width=fit,background=screen,backgroundscreen=0.7] \startexample ... \stopexample and this is appropriate if the example is short enough to fit on one page. However, a long example (many paragraphs) that spans more than one page runs off the bottom. Textbackground seems more appropriate, so I tried \definetextbackground [example] [location=paragraph,backgroundcolor=middlegray,frame=off] \definestartstop [example] [before={\starttextbackground[example]},after=\stoptextbackground] but this does not work. I tried other variants (such as adding state=start, ...) with no success. Does anyone have suggestions on where to look for further documentation or examples of use?
This works for me. \setupcolors[state=start] \definetextbackground [example] [location=paragraph, background=color, backgroundcolor=middlegray, frame=off] \starttext \input knuth \startexample \dorecurse{4}{\input knuth\par} \stopexample \input knuth \stoptext Wolfgang For me this works only with context 2008-10-31. It doesn't work with the beta from 2008-01-18 (no background). Greetings Thomas ____________________________________________________________________________ _______ 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 ____________________________________________________________________________ _______