|
From: Hans-Bernhard B. <br...@ph...> - 2005-03-10 14:20:32
|
Ethan Merritt wrote:
> How about a terminal entry point (*term->layer)((int) layernumber)
> that the core code would call at each stage of the plot process, once
> per layer?
[...]
> enum layer { LAYER_PLOT_BACKGROUND, LAYER_AXES, LAYER_BACK_LABELS,
> LAYER_PLOT_LINES, LAYER_FRONT_RECTANGLES, LAYER_FRONT_LABELS, ... }
This idea certainly has a nicer ring to it than the current situation.
What I'm a little bit worried about is, as always, the conceptual
clarity of our terminal layer API. So far, the terminal API is,
essentially, just a rather generic vector drawing API --- all the way to
the old "gnuplot library" which exported this API for generic usage.
A new API entry like the above would, effectively, specialize the
interface to gnuplot as the client, and kill all remaining hopes of one
day splitting up the program into well-separated layers of functionality.
I don't thus think that *naming* the layers would be a good idea at all.
Let them have numbers, and export those to the user interface in some
way the users can (hopefully) understand.
|