Brian Kahne wrote:

Hi,

I'm new to Context, so hopefully this isn't a completely obvious question, but I was wondering whether it was possible to have framed text split across a page. In this particular case, I have a code sample that I want to be framed and have a different background color than the rest of the text, so I have it surrounded by \startframedtext and \stopframedtext. Is it possible to use \splitfloat to split this if the code sample is too large to fit on a single page? If so, what would be the syntax? If not, is there another mechanism?

the following background mechanism splits across pages, works over columns, can be used nested, can be applied for very dirty tricks, etc

\setupcolors[state=start]

\starttext

\definetextbackground[more][state=start,backgroundcolor=red] % 
location=paragraph
\definetextbackground[test][state=start,backgroundcolor=green]

\page \placefigure[left]{}{}

\starttextbackground[test]
  \readfile{ward}{}{}
  \starttextbackground[more]
    \readfile{ward}{}{}
  \stoptextbackground
  \readfile{ward}{}{}
\stoptextbackground

\page \placefigure[right]{}{}

\starttextbackground[test]
  \readfile{ward}{}{}
  \starttextbackground[more]
    \readfile{ward}{}{}
  \stoptextbackground
  \readfile{ward}{}{}
\stoptextbackground

\stoptext


----------------------------------------------------------------- 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 -----------------------------------------------------------------

Attachment: test.pdf
Description: Adobe PDF document

_______________________________________________
ntg-context mailing list
ntg-context@ntg.nl
http://www.ntg.nl/mailman/listinfo/ntg-context

Reply via email to