|
From: Ethan A M. <sf...@us...> - 2013-04-19 18:56:56
|
On Thursday, April 18, 2013 11:26:31 pm Christoph Bersch wrote:
> Am 18.04.2013 22:40, schrieb Ethan A Merritt:
> > On Thursday, April 18, 2013 12:06:59 pm Christoph Bersch wrote:
> >>
> >> * I would suggest, that the information, whether clipping is necessary,
> >> and to which rectangle it should be clipped is provided by a
> >> terminal-independent function.
> >
> > The current clipping area is maintained in the global structure
> > gadgets.h:extern BoundingBox *clip_area; /* Current clipping box */
>
> Yes, I saw this, but didn't know if this information was supposed to be
> transparent to the terminal drivers.
The word "transparent" has unfortunately become ambiguous in
[American] English. I don't know whether you mean "supposed to be
easily inspected by terminal drivers" or "supposed to be invisible
to terminal drivers".
As it stands, the clip_area structure is only used by the higher level code.
No existing driver refers to it. I would say that if it becomes desirable
to pass explicit clipping information to a terminal driver, then a new
terminal entry point should be created for that purpose. But so far that
has not been necessary. I think it is preferable to have the core
code do the clipping so that the result is not terminal-dependent.
> Yes, in my case it was something like:
> set xrange[0:10]
> set yrange[-1.2:1.2]
> set object circle at graph 0, first 1 radius 0.1
> plot cos(x)
>
> And specifying this circle center with screen coordinates is somewhat
> fiddly.
I'm OK with the idea of adding a TBOOLEAN clip property for "set object".
Nevertheless I think that "plot ... with {circles|ellipses}" should
continue to always clip to the graph boundary, just as line or points
are always limited to the graph interior.
Ethan
|