Problem with __plt_get_axis_arg__.m

Michael Goffioul michael.goffioul at gmail.com
Sun Dec 2 03:28:57 CST 2007


On 12/1/07, David Bateman <adb014 at gmail.com> wrote:
> I tried to copy the hggroup code you had in one of the other functions
> to __get_plt_axis__ so I'd say as JHandles is the only thing with
> hggroups at the moment, change it how you need it to be changed..

IIRC, I used the "ancestor" call, because the next statement was
something like "axes(h)", so I needed an axes object. I think that
__plt_get_axis_arg__ should not call ancestor, otherwise you screw
up the actual parent given as argument if it's not an axes object.
OTOH, functions that make use of the returned handle, should be
aware that it might not be an axes object. I see 2 possible ways to
deal with that:
1) use an additional output to __plt_get_axis_arg__ for the actual
axes object, so any function that needs an axes object can get
access to it
2) make "axes" function to call "ancestor" if the given handle is not
an axes object

Michael.


More information about the Octave-maintainers mailing list