On 28-Nov-2007, David Bateman wrote:
| That is, as you say rather convoluted, and hard to understand. It also
| doesn't handle the majority of cases, which are more like
|
| [h, varargin] = __plt_get_axis_arg__ ("foo", varargin{:});
| oldh = gca ();
| unwind_protect
| axes(h);
| tmp = someplot(h, varargin{:});
| unwind_protect_cleanup
| axes (oldh);
| end_unwind_protect
|
| Note that "axes" is called before the plot command. Therefore the issue
| has to be handled in axes. Unfortunately "axes" which no arguments
| already has another meaning and so "axes(ax_arg{:})" won't be.. I think
| I prefer the ax = NaN meaning the current axes as its much simpler.
OK, then please check in your changes.
Also, I think I noticed a bug. After executing the following
commands,
line ();
axes ();
I think the figure window should be displaying an empty axes object,
but it still has the line. Do you see the same? I don't see why this
is happening, because after the call to axes,
get (gca (), 'children')
returns [](0x0). Hmm. Also, doing this
axes ();
line ();
doesn't display the line, although
get (get (gca (), 'children'), 'type')
returns "line". Also, an explicit
drawnow ()
does not fix the display. I guess something is not setting the
__modified__ property for the figure when it should.
jwe