From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/15579 Path: main.gmane.org!not-for-mail From: "dr. Hans van der Meer" Newsgroups: gmane.comp.tex.context Subject: Re: textbackground Date: Sun, 27 Jun 2004 10:38:52 +0200 Sender: ntg-context-admin@ntg.nl Message-ID: <6B62B759-C815-11D8-9564-003065568054@science.uva.nl> References: <02953FC4-C76F-11D8-A876-003065568054@science.uva.nl> <40DDBCDA.1080406@wxs.nl> Reply-To: ntg-context@ntg.nl NNTP-Posting-Host: deer.gmane.org Mime-Version: 1.0 (Apple Message framework v618) Content-Type: text/plain; charset=US-ASCII; format=flowed Content-Transfer-Encoding: 7bit X-Trace: sea.gmane.org 1088325842 5291 80.91.224.253 (27 Jun 2004 08:44:02 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Sun, 27 Jun 2004 08:44:02 +0000 (UTC) Original-X-From: ntg-context-admin@ntg.nl Sun Jun 27 10:43:52 2004 Return-path: Original-Received: from ref.vet.uu.nl ([131.211.172.13] helo=ref.ntg.nl) by deer.gmane.org with esmtp (Exim 3.35 #1 (Debian)) id 1BeVGS-0000ZI-00 for ; Sun, 27 Jun 2004 10:43:52 +0200 Original-Received: from ref.ntg.nl (localhost.localdomain [127.0.0.1]) by ref.ntg.nl (Postfix) with ESMTP id 6857910B1D; Sun, 27 Jun 2004 10:43:45 +0200 (MEST) Original-Received: from smtp.science.uva.nl (smtp.science.uva.nl [146.50.4.84]) by ref.ntg.nl (Postfix) with ESMTP id EFA8410AE1 for ; Sun, 27 Jun 2004 10:39:20 +0200 (MEST) Original-Received: from 118-197.uva.surfnetthuis.nl [145.98.118.197] by smtp.science.uva.nl with ESMTP (sendmail 8.11.6p2/config 11.35). id i5R8dJA24217; Sun, 27 Jun 2004 10:39:19 +0200 X-Organisation: Faculty of Science, University of Amsterdam, The Netherlands X-URL: http://www.science.uva.nl/ In-Reply-To: <40DDBCDA.1080406@wxs.nl> Original-To: ntg-context@ntg.nl X-Mailer: Apple Mail (2.618) X-Virus-Scanned: by amavisd-new Errors-To: ntg-context-admin@ntg.nl X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.0.13 Precedence: bulk List-Help: List-Post: List-Subscribe: , List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: Xref: main.gmane.org gmane.comp.tex.context:15579 X-Report-Spam: http://spam.gmane.org/gmane.comp.tex.context:15579 On 26-jun-04, at 20:13, Hans Hagen Outside wrote: > dr. Hans van der Meer wrote: > >> Hans, >> >> I definitely see problems with the >> \starttextbackground[]-\stoptextbackground environment (discussed in >> the "displays"-brochure). >> >> When the textbackground falls at a page crossing -- i.e. starts at >> the top of a page -- the coloring extends backwards on the page just >> left. >> It can be remedied by putting a \null just in front of >> \starttextbackground. The extra vertical space this introduces just >> manages to constrain the background to its own page. However, this is >> not a general solution, on other places the extra vertical space is >> certainly not wanted. >> >> I cannot find the exact nature of the problem. I suspect it has to do >> with the \output-routines, but these are not my speciality, to say >> the least. So, not much help there, >> >> Also, the \starttextbackground does not respect footnotes, these are >> colored. In contrast, the old \startbackground-\stopbackground does >> respect footnotes. The coloring stops at the footnote and restarts at >> the next page. I should like that for \starttextbackground as well. > > can you make me a minimal example of where things go wrong (keep in > mind that there are two methods, tex and paragraph) > with respect to footnotes, maybe i can make that an option (there are > more exceptions) > Hans > Here is the smallest one I could construct that shows the page crossing effect. I used the "location=paragraph". With "location=text" I did not experiment. Here follows the code: % testing textbackgroundcolor \setupbodyfont[12pt] % using the default cmr font \setuppapersize[S6][S6] \setuplayout[width=middle,location=middle,header=0pt,footer=4ex] \setuppagenumbering[location={footer,inright},alternative=singlesided] % \setupcolors [state=start] \definecolor [lavender] [r=.901961,g=.901961,b=.980392] \definecolor [lavenderblush] [r=1,g=.941176,b=.960784] % general page coloring \setupbackgrounds[page][background=color,backgroundcolor=lavenderblush] % % special background coloring for parts of the text \definetextbackground[A][frame=off,location=paragraph, backgroundcolor=lavender,backgroundoffset=0pt] \starttext % \dorecurse{10}{Some text that must fill a portion of the page. }\par \dorecurse{10}{Some text that must fill a portion of the page. }\par \dorecurse{10}{Some text that must fill a portion of the page. }\par % % WITH 8 AND 9 IN THE NEXT RECURSION THE FIRST PARAGRAPH ON PAGE 2 HAS % THE BACKGROUND COLORED BUT THE WHITESPACE BELOW THE LAST PARAGRAPH ON % PAGE 1 IS COLORED TOO. % CHANGE THE 8/9 TO 10 AND THE COLORING ON PAGE 1 DISPAPPEARS. % I HAVE BECOME ACROSS SITUATIONS WERE THE COLORING EXTENDED STILL % FURTHER BACK OVER MORE PRECEDING PARAGRAPHS, BUT IT IS DIFFICULT TO % CONSTRUCT A MINIMAL EXAMPLE FOR THAT. \dorecurse{9}{Some text that must fill a portion of the page. }\par % % THIS SHOULD COLOR THE FIRST PARAGRAPH ON PAGE 2 \starttextbackground[A] \dorecurse{5}{Text with the background. } \stoptextbackground \dorecurse{10}{Some text that must fill a portion of the page. }\par % \stoptext I hope you can find what causes it, because I like the effects. Keeping footnotes free from the coloring would be very great if it could be accomplished (same as for interposed floats), like: -- text on page containing reference to footnote, not colored background -- text on page with colored background -- footnote not colored (or perhaps the same coloring as where the reference occurs?) -- text on next page goes on with colored background Hans van der Meer