changeset 33341:8e6e656b6f61

maint: merge stable to default
author Rik <rik@octave.org>
date Fri, 05 Apr 2024 17:18:42 -0700
parents abdb846bafe8 (current diff) fa8a486773fd (diff)
children c2dbaa9dca4f
files
diffstat 1 files changed, 6 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/scripts/plot/appearance/legend.m	Sun Jan 21 19:34:01 2024 +0100
+++ b/scripts/plot/appearance/legend.m	Fri Apr 05 17:18:42 2024 -0700
@@ -207,6 +207,12 @@
   ##        lock once that bug is properly fixed.
   mlock ();
 
+  ## legend() requires root property to be invisible.
+  if (strcmp (get (groot, 'showhiddenhandles'), 'on'))
+    cleanup = onCleanup (@() set (groot, 'showhiddenhandles', 'on'));
+    set (groot, 'showhiddenhandles', 'off');
+  endif
+
   opts = parse_opts (varargin{:});
 
   hl = opts.legend_handle;