changeset 6310:cf8894bbc49d

[project @ 2007-02-15 19:59:27 by jwe]
author jwe
date Thu, 15 Feb 2007 19:59:27 +0000
parents 6a60e68fc4b1
children e2a1aca62551
files scripts/ChangeLog scripts/image/imshow.m scripts/plot/__uiobject_draw_axes__.m
diffstat 3 files changed, 6 insertions(+), 5 deletions(-) [+]
line wrap: on
line diff
--- a/scripts/ChangeLog	Thu Feb 15 09:49:27 2007 +0000
+++ b/scripts/ChangeLog	Thu Feb 15 19:59:27 2007 +0000
@@ -1,5 +1,7 @@
 2007-02-15  Daniel J Sebald  <daniel.sebald@ieee.org>
 
+	* image/imshow.m: Don't restore old colormap.
+
 	* plot/__uiobject_image_ctor__.m: Set xdata and ydata properties.
 	* image/__img__.m: New file containing common parts of image.m and
 	imshow.m.
--- a/scripts/image/imshow.m	Thu Feb 15 09:49:27 2007 +0000
+++ b/scripts/image/imshow.m	Thu Feb 15 19:59:27 2007 +0000
@@ -97,7 +97,7 @@
   ## Set other default parameters.
   isindexed = false;
   initial_magnification = 100;
-  old_colormap = color_map = colormap ();
+  color_map = colormap ();
   
   ## Handle the rest of the arguments.
   narg = 1;
@@ -149,9 +149,8 @@
   dim = ndims (im);
   if (dim == 2)
     im = round ((size (color_map, 1) - 1) * im);
+    image (im, initial_magnification/100);
     colormap (color_map);
-    image (im, initial_magnification/100);
-    colormap (old_colormap);
   elseif (dim == 3 && size (im, 3) == 3)
     __img__ ([] , [], im);
     ## FIXME -- needed anymore for a special case?
--- a/scripts/plot/__uiobject_draw_axes__.m	Thu Feb 15 09:49:27 2007 +0000
+++ b/scripts/plot/__uiobject_draw_axes__.m	Thu Feb 15 19:59:27 2007 +0000
@@ -47,7 +47,7 @@
     endif
 
     if (strcmp (axis_obj.dataaspectratiomode, "manual"))
-      r = axis_obj.dataaspectratio
+      r = axis_obj.dataaspectratio;
       fprintf (plot_stream, "set size ratio %g;\n", -r(2)/r(1));
     else
       fputs (plot_stream, "set size noratio;\n");
@@ -804,7 +804,7 @@
   style = "lines";
   if (isempty (lt))
     if (! isempty (pt))
-      style = "points"
+      style = "points";
     endif
   elseif (! isempty (pt))
     style = "linespoints";