9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
From: pmarin <pmarin.mail@gmail.com>
To: fernanbolando@mailc.net,
	Fans of the OS Plan 9 from Bell Labs <9fans@9fans.net>
Subject: Re: [9fans] where to get color troff?
Date: Tue, 12 Apr 2011 14:31:29 +0200	[thread overview]
Message-ID: <BANLkTinke78oyysHSwUvKj1w8-Cb3CYzRQ@mail.gmail.com> (raw)
In-Reply-To: <BANLkTin5d=0oe3tTWYS+UyAJu+zXGJHFXQ@mail.gmail.com>

/sys/src/cmd/postscript/mcolor/

On Tue, Apr 12, 2011 at 10:24 AM, Fernan Bolando
<fernanbolando@mailc.net> wrote:
>
>
> On Tue, Apr 12, 2011 at 3:33 PM, Sape Mullender <sape@plan9.bell-labs.com>
> wrote:
>>
>> > On Tue, Apr 12, 2011 at 2:38 PM, Peter A. Cejchan <tyapca7@gmail.com>
>> > wrote:
>> >
>> >> do you mean 'graph', or 'chart' ?
>> >> ++pac
>> >>
>> >
>> > right now it's mostly charts.
>>
>> I use these macros for generating color:
>>
>> .de CL
>> \\X'PS \\$1 \\$2 \\$3 setrgbcolor'\\c
>> ..
>> .de BK
>> \\X'PS 0 0 0 setrgbcolor'\\c
>> ..
>> .de EM
>> \\$3\\X'PS 1 0 0 setrgbcolor'\\$1\\X'PS 0 0 0 setrgbcolor'\\$2
>> ..
>>
>> They only work if you generate postscript (you can, of course, turn that
>> into pdf as well).
>> .CL r g b
>> sets the color to the rgb values (0 0 0 being black, 1 1 1 being white,
>> 0.5 0.5 0.5 being middle grey)
>> .BK
>> sets the color to black.
>> .EM "string1" "string2" "string3"
>> (emphasis), where strings 2 and 3 are optional prints string3 in the
>> current
>> color, followed by string1 in red and string2 in black (with no space
>> between
>> strings 3, 1 and 2 — they work as .B or .I in the .ms macro package.
>>
>>        Sape
>>
>
> Wow cool it worked. thanks a lot
>
>
>



  reply	other threads:[~2011-04-12 12:31 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-04-12  6:09 Fernan Bolando
2011-04-12  6:38 ` Peter A. Cejchan
2011-04-12  7:16   ` Fernan Bolando
2011-04-12  7:33     ` Sape Mullender
2011-04-12  8:24       ` Fernan Bolando
2011-04-12 12:31         ` pmarin [this message]
2011-05-14  0:43       ` Jeff Sickel
2011-05-16 13:36         ` Russ Cox
2011-05-16 14:56           ` Jeff Sickel

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=BANLkTinke78oyysHSwUvKj1w8-Cb3CYzRQ@mail.gmail.com \
    --to=pmarin.mail@gmail.com \
    --cc=9fans@9fans.net \
    --cc=fernanbolando@mailc.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).