groff
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Groff] colored background?


From: Tadziu Hoffmann
Subject: Re: [Groff] colored background?
Date: Fri, 22 Feb 2008 18:07:42 +0100
User-agent: Mutt/1.5.16 (2007-06-09)

> > I ask because for program listings and other "verbatim"
> > output, dblatex and the DocBook XSL stylesheets for FO
> > output cause the output to be rendered with a light-gray
> > background. That really helps to set the program listing
> > off from the rest of text.

> (Personally, I find it looks ugly compared to the plain white
> background used by Brian Kernighan, W. Richard Stevens, etc.)

Yes, usually it's a "Hey! Look what my word processor can do!"
gimmick.  But I guess it's also useful for conference posters
or the like.  Or maybe for "Danger!" or "Important" notices.

Here is something to play around with, maybe you'll find it
useful:


.\"
.de BB
.br
.in +2n
.ll -2n
.gcolor red
.di BX
..
.de EB
.br
.di
.in
.ll
.gcolor
.nr BW \\n(dl-\\n(.i
.nr BH \\n(dn+.5v
.ne \\n(BHu+.5v
\M[yellow]\h'1n'\v'-.5v'\D'P \\n(BWu 0 0 \\n(BHu -\\n(BWu 0 0 -\\n(BHu'\M[]
.in 0
.sp -.5v
.nf
.BX
.in
.sp .5v
.fi
..
.sp 3c
.ll 4c
Some text.
Some text.
Some text.
Some text.
.in +1n
Some text.
Some text.
Some text.
Some text.
.BB
Text in a box.
Text in a box.
Text in a box.
Text in a box.
.EB
More text.
More text.
More text.
More text.
.in -1n
More text.
More text.
More text.
More text.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]