|
From: Ethan A M. <merritt@u.washington.edu> - 2008-07-12 16:04:10
|
On Saturday 12 July 2008, Petr Mikulik wrote:
> > > > > bind Right "if (GPVAL_SPLOT) builtin_rotate_right; \
> > > > > else set xrange [GPVAL_X_MIN+100:GPVAL_X_MAX+100]; reread"
> > > > >
> > > > > I propose to move the "builtin_" functions from the default "bind" command
> > > > > among other functions callable from the command line.
> > > For other terminals, the behaviour does not make
> > > good sense. Then it can change the parameters but not call replot. I think
> > > the interactive terminals can be distinguished by presence of set_cursor()
> > > function.
> > >
> > > I think it could be useful to add flag GPVAL_TERM_INTERACTIVE = {0|1} in
> > > order to distinguish these terminals.
> >
> > I think that is the wrong mechanism.
> > If it is a terminal property it should be a terminal flag:
> >
> > if (term->flags | TERM_INTERACTIVE) ...
> >
> > except that there already is a global TBOOLEAN that would probably serve:
> >
> > if (mouse_setting.on) ...
>
> Then this needs a change to terminals -- I would agree on this.
I was thinking that you could simply have the new functions test whether mousing
is active:
arrow_right( ...)
{
if (!mouse_setting.on) return;
...
}
That would not need any change to the terminal drivers.
--
Ethan A Merritt
|