in reply to Coloring IRC logs nicely
Precalculate 64 colors based on your color distance formula. As nicks show up, draw from the pool. As nicks /part, recycle that color. If 64 colors result in some colors being indistinguishable, use other attributes such as italics or underline. For this, you'll need a viewer that can handle these other attributes. If 64 isn't a big enough number, stay out of #cybersex in the future (just kidding).
This sounds like a job for object orientation too, where individuals are object instances, and the underlying class handles the details of keeping track of allocating display attributes to the individuals, as well as the details of outputting the proper sequences to display individual's attributes.
Dave
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Coloring IRC logs nicely
by iblech (Friar) on Aug 19, 2004 at 17:12 UTC | |
by davido (Cardinal) on Aug 19, 2004 at 17:59 UTC | |
by icerunner (Beadle) on Aug 20, 2004 at 08:33 UTC | |
by iblech (Friar) on Aug 20, 2004 at 15:15 UTC |