diff scripts/plot/hold.m @ 11928:553874dbba84 release-3-0-x

Fix for hold with no figures/axes.
author David Bateman <dbateman@free.fr>
date Tue, 21 Oct 2008 21:59:59 -0400
parents 965bb17961f0
children
line wrap: on
line diff
--- a/scripts/plot/hold.m	Fri Jan 16 09:48:08 2009 +0100
+++ b/scripts/plot/hold.m	Tue Oct 21 21:59:59 2008 -0400
@@ -69,6 +69,9 @@
   endif
 
   if (isfigure (h))
+    if (isempty (get (h, "currentaxes")))
+      set (h, "currentaxes", __go_axes__ (h))
+    endif
     axes_objs = findobj (h, "type", "axes");
     h = [h; axes_objs];
   endif