# HG changeset patch # User Rik # Date 1382448774 25200 # Node ID 132d9f543cc5175ec099f05d48123ffe624b6e2f # Parent 5b0036d89d4adcc6b37708b49e46c2f10360d72f print.m: 2nd fix for printing when using -F option (bug #40334) * scripts/plot/util/print.m: Apply fontsize attribute to non-axes objects first to avoid triggering legend fontsize callback which destroys objects in the list. diff -r 5b0036d89d4a -r 132d9f543cc5 scripts/plot/util/print.m --- a/scripts/plot/util/print.m Tue Oct 22 05:33:35 2013 -0400 +++ b/scripts/plot/util/print.m Tue Oct 22 06:32:54 2013 -0700 @@ -405,8 +405,12 @@ ## This is done to work around the bbox being whole numbers. fontsize = fontsize * opts.scalefontsize; endif - ## FIXME: sort needed so legend child objects are acted on first - set (sort (h(ishandle (h))), "fontsize", fontsize); + ## FIXME: legend child objects need to be acted on first. + ## or legend fontsize callback will destroy them. + hlist = h(ishandle (h)); + haxes = strcmp (get (hlist, "type"), "axes"); + set (hlist(! haxes), "fontsize", fontsize); + set (hlist(haxes), "fontsize", fontsize); endif endif