# HG changeset patch # User Markus Mützel # Date 1653587267 -7200 # Node ID bb9c7512e090b7ea276d64e5e6a3658d51026dbb # Parent 8629bb61ef1765f9c72f59a981c95b7104ce6a33# Parent 0938366560cf20f2c6f43da3d2a718cae4a5915e maint: Merge stable to default. diff -r 8629bb61ef17 -r bb9c7512e090 scripts/plot/util/subplot.m --- a/scripts/plot/util/subplot.m Thu May 26 13:12:31 2022 -0400 +++ b/scripts/plot/util/subplot.m Thu May 26 19:47:47 2022 +0200 @@ -288,7 +288,7 @@ ## appdata "__subplotposition__", use the existing axes. found = true; hsubplot = child; - else + elseif (exist ("rows", "var")) ## Check if this axes is a subplot with the same layout and ## index as the requested one rcn = getappdata (child, "__subplotrcn__"); @@ -648,6 +648,18 @@ %! delete (hf); %! end_unwind_protect +## Mixed rcn and position mode +%!test <*62526> +%! hf = figure ("visible", "off"); +%! unwind_protect +%! h1 = subplot (2, 2, 1); +%! h2 = subplot ("position", [0.5 0.5 0.3 0.3]); +%! h3 = subplot (223); +%! assert (get (hf, "children"), [h3; h2; h1]); +%! unwind_protect_cleanup +%! delete (hf); +%! end_unwind_protect + ## Align mode %!test %! hf = figure ("visible", "off");