diff scripts/plot/private/__stem__.m @ 11313:988d2bd6bacd

__stem__.m: Each stem hggroup should have its own baseline.
author Ben Abbott <bpabbott@mac.com>
date Fri, 03 Dec 2010 18:23:45 -0500
parents 95c3e38098bf
children fd0a3ac60b0e
line wrap: on
line diff
--- a/scripts/plot/private/__stem__.m
+++ b/scripts/plot/private/__stem__.m
@@ -99,15 +99,13 @@
                         ms, "linestyle", "none", "markerfacecolor",
                         fc, "parent", hg); 
 
-        if (i == 1)
-          x_axis_range = get (ax, "xlim");
-          h_baseline = line (x_axis_range, [0, 0], "color", [0, 0, 0]);
-          set (h_baseline, "handlevisibility", "off");
-          set (h_baseline, "xliminclude", "off");
-          addlistener (ax, "xlim", @update_xlim);
-          addlistener (h_baseline, "ydata", @update_baseline);
-          addlistener (h_baseline, "visible", @update_baseline);
-        endif
+        x_axis_range = get (ax, "xlim");
+        h_baseline = line (x_axis_range, [0, 0], "color", [0, 0, 0]);
+        set (h_baseline, "handlevisibility", "off");
+        set (h_baseline, "xliminclude", "off");
+        addlistener (ax, "xlim", @update_xlim);
+        addlistener (h_baseline, "ydata", @update_baseline);
+        addlistener (h_baseline, "visible", @update_baseline);
       endif
 
       ## Setup the hggroup and listeners.