[NTG-context] How to do this in ConTeXt

R S Ananda Murthy rsamurti at touchtelindia.net
Thu Jan 5 11:33:18 CET 2006


FabriceL. wrote:

> Hi,
>
>    Hans, it's so instructive to read yout post... I have learned from 
> this last post 2 new commands !
> However, I think the original poster wish a line who run to the right 
> margin, so I added to your code
> in the "defineenumeration" a "inbetween=\vskip-4pt{\hrule height 
> 1.5pt}\blank". This is not very elegant,
> but this works. By the way, I'm interested to know if there is a 
> better solution.
>
> > Hans wrote:
> > one of you has to wikify this answer ...
>
> I'm not sure how to do this, but I can try how this works.
> The complete code follows.
> FL.
>
> \setupcolors[state=start]
> \setupbackgrounds[text][text][background=color,backgroundcolor=darkred,backgroundoffset=3pt] 
>
>
> \defineenumeration
>  [example]
>  [way=bychapter,
>   separator=\compoundhyphen,
>   chapternumber=yes,
>   color=white,
>   command=\exampleframed,
>   inbetween=\vskip-4pt{\hrule height 1.5pt}\blank]
>
> \defineframed
>  [exampleframed]
>  [background=color,
>   backgroundcolor=black,
>   foregroundcolor=white,
>   style=bold,
>   frame=off]
>
> \starttext
>
> \chapter{One}
>
> \input tufte
>
> \startexample
>    \input tufte
> \stopexample
>
> \input tufte
>
> \stoptext
>
> _______________________________________________
> ntg-context mailing list
> ntg-context at ntg.nl
> http://www.ntg.nl/mailman/listinfo/ntg-context
>
>
Thank you FabriceL for your help. It worked.

Anand


More information about the ntg-context mailing list