>
> From: Petr Mikulik <mikulik@...>
> Date: 2005/10/07 Fri PM 06:03:11 EDT
> To: Bastian Maerkisch <bmaerkisch@...>
> CC: gnuplot-beta@...
> Subject: Re: Win32: change pointstyle
>
> > This patch aims to increase consistency between the windows
> > terminal and other terminals:
> > The order of the pointstyles is changed. It is now the same
> > as in gd.trm, pdf.trm, post.trm and possibly others.
> > And default colors are now taken from web_color_rgbs[], as
> > do gd.trm and pdf.trm. Btw. terminals are not very consistent
> > here: gd.trm uses all web colors, pdf only the first 12
> > and postscript uses 9 or so. win.trm uses 15 different colors ...
>
> There was an effort before 4.0 to unify colors and pointtypes "as much as
> possible". It would be great if this effort continues. Colors are still not
> well unified as you've found.
I agree with this. It doesn't bother me too much because I think the most popular colors of the few terminals I use are about the same. But it can be annoying to find that a line is yellow when working in a window terminal and brown when when making a hard copy.
Would it be too much to devise some kind of color table lookup for each terminal? Then have some kind of "get_color(term,..., char *color)"? E.g.,
lookup_table {
{"r$ed", 1},
{"y$ellow", 2},
{"m$agenta", 3}
...
};
Then, when a user issues a command requiring a color s/he can say "yellow", "green", etc. Gnuplot then does a
if (!(color_number = get_color(term, user_char_string)) {
printf("sorry user, don't know that color");
errorout();
}
That way, all the headache of color matching is left to the person creating the terminal driver.
Of course, we'd have a "show term colors", etc. There'd be variations on this naturally. The one down side would be a user utilizing colors for one terminal that are not in another terminal. Switching to the new terminal would cause faults.
Dan
|