Re:

by Noone Special <pfarabee(at)indy.net>

 Date:  Tue, 7 Apr 1998 08:37:01 -0500 (EST)
 To:  hwg-graphics(at)mail.hwg.org
 In-Reply-To:  fredonia
  todo: View Thread, Original
On Tue, 7 Apr 1998, Michael Gerholdt wrote:

> I wrote:
> I'm surprised that Netscape, with its palette, goes anywhere but to white
> with eeeeee. Can anyone explain why?

The "Netscape" or "web-safe" palette consists of:

all colors having combinations of six values for each R,G,or B value
the six colors are:
0   (00)
51  (33)
102 (66)
153 (99)
204 (CC)
255 (FF)

If you notice, each value increases by 51 (255/5) so that the palette
ends up being an even spread of color from black to white.

Also notice that since there are 6 colors, that means that the palette is
only 216 colors total (6 x 6 x 6 = 216)

This leaves 40 colors for the browser to do with what it wishes.  One of
those uses (in many browsers) is for 'extra' background colors.
Apparently the extra color technique for background colors only works with
lighter colors for some reason.  And since the colors are not truely part
of the palette, they may not be supported on all versions of all browsers.

Actually, to think about it logically for a moment, one possible reason
that the lighter colors work at all is because maybe they are included in the
browser as colors used for it's own graphics (The 'N' logo, that wonderful
"c0c0c0" background that used to be the default way back when.. etc ;) So
in fact, we might not actually be fooling the browser into giving us NEW
colors, but simply into using the ones it ALREADY has allocated for it's
own uses.

HWG: hwg-graphics mailing list archives, maintained by Webmasters @ IWA

This page is part of a preserved archive of archives.hwg.org. The site is no longer active and its content is not maintained. For enquiries about this archive, write to archive(at)iwanet.org.