Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.postscript > #1035

Looping over all defined colours

Path csiph.com!usenet.pasdenom.info!weretis.net!feeder4.news.weretis.net!news.mixmin.net!feed.xsnews.nl!border-1.ams.xsnews.nl!feeder.xennanews.com!feeder3!nf38.xennanews.com!not-for-mail
From Cecil Westerhof <Cecil@decebal.nl>
Newsgroups comp.lang.postscript
Subject Looping over all defined colours
Organization Decebal Computing
X-Homepage http://www.decebal.nl/
Date Sun, 11 Nov 2012 11:34:20 +0100
Message-ID <87pq3kl977.fsf@Compaq.site.inet> (permalink)
User-Agent Gnus/5.13 (Gnus v5.13) Emacs/23.3 (gnu/linux)
Cancel-Lock sha1:963/ShdZCA2GBZTf7TOTbsUy7Ao=
MIME-Version 1.0
Content-Type text/plain; charset=us-ascii
X-Complaints-To abuse@xennanews.com
Lines 31
NNTP-Posting-Host 84.53.123.169 (84.53.123.169)
NNTP-Posting-Date Sun, 11 Nov 2012 11:37:25 +0100
Xref csiph.com comp.lang.postscript:1035

Show key headers only | View raw


Someone on this mailing-list showed met the simple way down to declare
a lot of colours at once. I wold like to do something with all those
colours. Is there a way to iterate the colours?

/colors <<
  /colorBlack   { 0   0   0   }
  /colorBlue    { 0   0   1   }
  /colorCyan    { 0   1   1   } % aqua
  /colorFuchsia { 1   0   1   }
  /colorGray    { .5  .5  .5  }
  /colorGreen   { 0   .5  0   }
  /colorIndigo  { .31 0   .5  }
  /colorLime    { 0   1   0   }
  /colorMaroon  { .5  0   0   }
  /colorNavy    { 0   0   .5  }
  /colorOlive   { .5  .5  0   }
  /colorOrange  { 1   .56 0   }
  /colorPurple  { .5  0   .5  }
  /colorRed     { 1   0   0   }
  /colorSilver  { .75 .75 .75 }
  /colorTeal    { 0   .5  .5  }
  /colorViolet  { .94 .5  .94  }
  /colorWhite   { 1   1   1   }
  /colorYellow  { 1   1   0   }
>> def
colors begin

-- 
Cecil Westerhof
Senior Software Engineer
LinkedIn: http://www.linkedin.com/in/cecilwesterhof

Back to comp.lang.postscript | Previous | Next — Next in thread | Find similar | Unroll thread


Thread

Looping over all defined colours Cecil Westerhof <Cecil@decebal.nl> - 2012-11-11 11:34 +0100
  Re: Looping over all defined colours Don Lancaster <don@tinaja.com> - 2012-11-11 09:52 -0800
  Re: Looping over all defined colours Cecil Westerhof <Cecil@decebal.nl> - 2012-11-17 14:50 +0100

csiph-web