barnett@crdgw1.crd.ge.com (Bruce G. Barnett) (04/27/89)
Do you get confused with too many windows?
Can't keep track of which icon goes with which program?
If you have a color system, try this:
#!/usr/NeWS/bin/psh
% From: Bruce G. Barnett (barnett@crd.ge.com)
% Program: colorframes.ps Apr 27, 1989
% This program assigns a random color ONCE to each new window frame and icon.
%
% Details:
% This program will change the variable FrameFillColor to a procedure
% that the first time it is used randomly selects a color. making sure
% it is not too dark, and stores the color in the instance variables
% FrameFillColor and IconFillColor.
%
LiteWindow begin
/FrameFillColor { % change variable to a procedure
3 { random dup .1 le { .3 add } if } repeat % get 3 random values > .1
rgbcolor dup % convert into a rgbcolor, make two copies
/FrameFillColor 1 index def % save 1 into instance var FrameFillColor
/IconFillColor 1 index def % save other into instance var IconFillColor
} def
end
--
Bruce G. Barnett <barnett@crdgw1.ge.com> a.k.a. <barnett@[192.35.44.4]>
uunet!steinmetz!barnett, <barnett@steinmetz.ge.com>