problem with interaction of plotyy/clf/delete
David Bateman
David.Bateman at motorola.com
Mon Nov 24 04:02:09 CST 2008
Ben Abbott wrote:
> As deleting one axis of plotyy group results in the other axis being
> deleted, the clf() function results in an attempt to delete an axis a
> second time.
>
> demo plotyy
> clf
>
> error: delete: invalid graphics object (= -15.2239)
> error: called from:
> error: /Users/bpabbott/Development/mercurial/octave-3.1.51/scripts/
> miscellaneous/delete.m at line 40, column 1
> error: /Users/bpabbott/Development/mercurial/octave-3.1.51/scripts/
> plot/clf.m at line 78, column 1
>
> How should this be resolved?
>
> Shall delete() or __go_delete__ be modified ?
>
> As the existence of the parent is already verified by __go_delete__ it
> seems that it would be appropriate the check that a call back hasn't
> deleted one of the figure's children.
>
Yes that might be an idea, but how do you verify that the callback did
the deleting and its not just an invalid handle? What I'd suggest doing
is check the validity of all handles to be deleted first in
F__go_delete__ and then in the main loop if the handle doesn't exist
just ignore it..
> I took a shot at changing graphics.cc to fix the problem, but it
> persists (my c++ skills are practically non-existent). I expect a
> proper solution is trivial, but still beyond me :-(
>
Try the attached
D.
--
David Bateman David.Bateman at motorola.com
Motorola Labs - Paris +33 1 69 35 48 04 (Ph)
Parc Les Algorithmes, Commune de St Aubin +33 6 72 01 06 33 (Mob)
91193 Gif-Sur-Yvette FRANCE +33 1 69 35 77 01 (Fax)
The information contained in this communication has been classified as:
[x] General Business Information
[ ] Motorola Internal Use Only
[ ] Motorola Confidential Proprietary
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: patch8845
Url: https://www-old.cae.wisc.edu/pipermail/bug-octave/attachments/20081124/12f664b3/attachment.ksh
More information about the Bug-octave
mailing list