changeset 21859:ec3adcec1337

Fix "inverthardcopy" for transparent axes and plotyy (bug #48161). * plotyy.m: Only set the second axes color to "none" * print.m: When using "inverthardcopy" don't change the color of transparent axes to white
author Pantxo Diribarne <pantxo.diribarne@gmail.com>
date Thu, 09 Jun 2016 16:41:39 +0200
parents 25b117822bfd
children f2b5499e8662
files scripts/plot/draw/plotyy.m scripts/plot/util/print.m
diffstat 2 files changed, 3 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/scripts/plot/draw/plotyy.m	Fri Jun 10 18:36:05 2016 -0700
+++ b/scripts/plot/draw/plotyy.m	Thu Jun 09 16:41:39 2016 +0200
@@ -112,7 +112,7 @@
 
   h1 = feval (fun1, x1, y1);
 
-  set (ax(1), "color", "none", "ycolor", getcolor (h1(1)), "xlim", xlim);
+  set (ax(1), "ycolor", getcolor (h1(1)), "xlim", xlim);
 
   set (gcf (), "nextplot", "add");
 
--- a/scripts/plot/util/print.m	Fri Jun 10 18:36:05 2016 -0700
+++ b/scripts/plot/util/print.m	Thu Jun 09 16:41:39 2016 +0200
@@ -396,7 +396,8 @@
     if (do_hardcopy)
       ## Set background to white for all top-level axes objects
       hax = findall (opts.figure, "-depth", 1, "type", "axes",
-                                  "-not", "tag", "legend");
+                                  "-not", "tag", "legend",
+                                  "-not", "color", "none");
       m = numel (props);
       for n = 1:numel(hax)
         props(m+n).h = hax(n);