changeset 24410:66977aecf3c0

Fix error when setting "units" property on hggroup w/gnuplot (bug #39394). * __gnuplot_draw_axes__.m: Only change obj "units" property to "data" if it is a text object.
author Rik <rik@octave.org>
date Wed, 13 Dec 2017 11:17:57 -0800
parents ca0ebd1d0da1
children a51a92186a1f
files scripts/plot/util/private/__gnuplot_draw_axes__.m
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/scripts/plot/util/private/__gnuplot_draw_axes__.m	Wed Dec 13 10:14:28 2017 -0800
+++ b/scripts/plot/util/private/__gnuplot_draw_axes__.m	Wed Dec 13 11:17:57 2017 -0800
@@ -513,7 +513,7 @@
       obj.zdata = double (obj.zdata);
     endif
 
-    if (isfield (obj, "units"))
+    if (strcmp (obj.type, "text"))
       units = obj.units;
       unwind_protect
         set (h_obj, "units", "data");