[plt-scheme] [scribble] boxing/highlighting in scheme code

From: Matthew Flatt (mflatt at cs.utah.edu)
Date: Fri Apr 30 18:23:40 EDT 2010

Forms like `schemeblock' recognize `code:hilite' and treat it
specially:

 @schemeblock[
  (+ 1 (code:hilite +inf.0))
 ]

At Fri, 30 Apr 2010 18:18:41 -0400, Eric Tanter wrote:
> Hi,
> 
> Is there a way when typesetting a block of scheme code to insert a box or a 
> shading/highlighting on a portion of it, in order to attract the attention of 
> the reader on that portion?
> 
> For instance, something like:
> 
> @schemeblock[
> (define (foo x)
>   (if (null? x) '()
>       @highlight[
>       (if (eq? (car x) ...)
>           ...
>           ...)
>       ]))
> 
> would highlight the "what-we-do-when-the-arg-is-a-non-empty-list" part of the 
> code.
> 
> Thanks,
> 
> -- Éric
> _________________________________________________
>   For list-related administrative tasks:
>   http://list.cs.brown.edu/mailman/listinfo/plt-scheme


Posted on the users mailing list.