|
From: Ethan M. <merritt@u.washington.edu> - 2006-04-17 17:31:18
|
On Monday 17 April 2006 09:10 am, Per Persson wrote:
>
> > If I'm reading that right, it means that
> > plot <foo> with boxes lt 1 fillstyle pattern 2
> > and
> > plot <foo> with boxes lt 2 fillstyle pattern 1
> > produce the same output, which is a surprising result.
>
> In the above examples, in AquaTerm I
> get boxes with red outline (lt 1) and blue fill (pattern 2) in the
> first case and green outline (lt 2) and green fill (pattern 1).
That's a surprising result also.
All other terminals would draw the outline and the fill in the
same color, with the fill modulated either by an actual pattern
or by the fill density.
It is possible to mix different outline (border) colors and
fill colors, but in order to do so the syntax is:
fillstyle {pattern <n> | solid <density>} bordercolor <lt>
> Wouldn't cycling through colours give a better visual appearance than
> shades of the outline color (effectively mapping "pattern x" to
> "solid <y>")?
Cycling through colors is what "fillstyle solid" already does.
So if that is the effect you want, it's easy to achieve.
As you pointed out, "fillstyle pattern" is mostly intended for
monochrome plots. But if it is to be implemented in color, to me it
makes sense that it do something different from "fillstyle solid".
> OK, I've fixed that. Before I commit anything though, when are
> TC_DEFAULT, TC_LINESTYLE, and TC_Z used? I couldn't find any clear
> docs on that.
These values are used by the core code, but are never passed to
the terminal driver routines. The are essentially place-holders
that indicate how the color will eventually be calculated before
passing it to term->set_color().
TC_DEFAULT is, or will be, used by the core routines to allow
individual plot elements to jointly adhere to a global style setting.
So far it is only used by the brand new "set object" code, but
my intent is to add similar processing to "set arrow", "set label",
and so on. The idea is that if an individual label, say, is marked
TC_DEFAULT then its color will be taken from a global value set by
"set style label <default_color_spec>". If you change this global
default, then all the corresponding labels change color at the same
time. Otherwise you would have to change them one by one.
TC_LINESTYLE is very similar to this, and perhaps TC_DEFAULT
should be collapsed into a subset or special case of this one.
It tells the core routines that the object properties (color in
this case, but it could be pointstyle or something else) is to
be taken from line *style* <n> rather than from line *type* <n>.
TC_Z is used during parsing to indicate that the color will come
from the object's Z value. This is the default "palette" coloring
option. The color is not known yet at the time the object
properties are parsed, because it will depend on the eventual
Z value.
--
Ethan A Merritt
Biomolecular Structure Center
University of Washington, Seattle WA
|