changeset 11113:a8ac114ec9ab

Stylefixes, replace end by endif.
author Thorsten Meyer <thorsten.meyier@gmx.de>
date Mon, 18 Oct 2010 20:40:12 +0200
parents 8ea4cf59c41b
children f7079e3b0227
files scripts/ChangeLog scripts/general/gradient.m scripts/linear-algebra/normest.m scripts/plot/__gnuplot_print__.m scripts/plot/__print_parse_opts__.m scripts/plot/daspect.m scripts/plot/gnuplot_drawnow.m scripts/plot/pbaspect.m scripts/plot/print.m scripts/signal/periodogram.m
diffstat 10 files changed, 25 insertions(+), 18 deletions(-) [+]
line wrap: on
line diff
--- a/scripts/ChangeLog
+++ b/scripts/ChangeLog
@@ -1,3 +1,10 @@
+2010-10-18  Thorsten Meyer  <thorsten.meyier@gmx.de>
+
+	* general/gradient.m, linear-algebra/normest.m,	plot/__gnuplot_print__.m,
+	plot/__print_parse_opts__.m, plot/daspect.m,
+	plot/gnuplot_drawnow.m, plot/pbaspect.m, plot/print.m,
+	signal/periodogram.m: Style fix, replace end by endfor.
+
 2010-10-18  Marco Caliari <marco.caliari@univr.it>
 
 	* polynomial/polyval.m: Use Horner's method.
--- a/scripts/general/gradient.m
+++ b/scripts/general/gradient.m
@@ -122,7 +122,7 @@
     ## have spacing value for each dimension
     if (length(varargin) != nd)
       error ("gradient: dimensions and number of spacing values do not match.");
-    end
+    endif
     for i = 1:nd
       if (isscalar (varargin{i}))
         d{i} = varargin{i} * ones (sz(i) - 1, 1);
--- a/scripts/linear-algebra/normest.m
+++ b/scripts/linear-algebra/normest.m
@@ -66,7 +66,7 @@
       x = rand (ncols, 1);
     else
       x = x / normx;
-    end
+    endif
     y = A' * x;
     n = norm (y);
     c += 1;
--- a/scripts/plot/__gnuplot_print__.m
+++ b/scripts/plot/__gnuplot_print__.m
@@ -41,7 +41,7 @@
     else
       opts.fontsize = axesfontsize;
     endif
-  end
+  endif
   ## The axes-label and tick-label spacing is determined by
   ## the font spec given in "set terminal ..."
   gp_opts = font_spec (opts);
--- a/scripts/plot/__print_parse_opts__.m
+++ b/scripts/plot/__print_parse_opts__.m
@@ -253,7 +253,7 @@
                        && (! isdir (arg_st.name)));
         if (! file_exists)
           arg_st.append_to_file = false;
-        end
+        endif
       else
         arg_st.append_to_file = false;
         warning ("print.m: appended output requires ghostscript to be installed.")
--- a/scripts/plot/daspect.m
+++ b/scripts/plot/daspect.m
@@ -57,7 +57,7 @@
             return
           else
             error ("daspect: only one output is allowed.")
-          end
+          endif
         case {"manual"}
           set (hax, "dataaspectratiomode", "manual");
         case {"auto"}
@@ -74,13 +74,13 @@
     endif
   elseif (nargout == 0)
     print_usage ();
-  end
+  endif
 
   if (nargout == 1)
     varargout{1} = get (hax, "dataaspectratio");
   elseif (nargout > 1)
     error ("daspect: only one output is allowed.")
-  end
+  endif
 
 endfunction
 
--- a/scripts/plot/gnuplot_drawnow.m
+++ b/scripts/plot/gnuplot_drawnow.m
@@ -86,7 +86,7 @@
                                    term, dumb_tmp_file);
     else
       enhanced = gnuplot_set_term (plot_stream (1), new_stream, h, term);
-    end
+    endif
     __go_draw_figure__ (h, plot_stream (1), enhanced, mono);
     fflush (plot_stream (1));
     if (strcmp (term, "dumb"))
@@ -102,9 +102,9 @@
         if (a(1)==12)
           ## avoid ^L at the beginning
           a = a(2:end);
-        end
+        endif
         puts (a);
-      end
+      endif
       unlink (dumb_tmp_file);
     endif
   else
@@ -221,7 +221,7 @@
             else
               ## Use the gnuplot default.
               size_str = "";
-            end
+            endif
           case {"aqua", "fig", "corel"}
             size_str = sprintf ("size %g %g", gnuplot_size);
           case "dxf"
--- a/scripts/plot/pbaspect.m
+++ b/scripts/plot/pbaspect.m
@@ -57,7 +57,7 @@
             return
           else
             error ("pbaspect: only one output is allowed.")
-          end
+          endif
         case {"manual"}
           set (hax, "plotboxaspectratiomode", "manual");
         case {"auto"}
@@ -74,13 +74,13 @@
     endif
   elseif (nargout == 0)
     print_usage ();
-  end
+  endif
 
   if (nargout == 1)
     varargout{1} = get (hax, "plotboxaspectratio");
   elseif (nargout > 1)
     error ("pbaspect: only one output is allowed.")
-  end
+  endif
 
 endfunction
 
--- a/scripts/plot/print.m
+++ b/scripts/plot/print.m
@@ -592,10 +592,10 @@
     cmd = opts.lpr_binary;
     if (! isempty (opts.lpr_options))
       cmd = sprintf ("%s %s", cmd, opts.lpr_options);
-    end
+    endif
     if (! isempty (opts.printer))
       cmd = sprintf ("%s -P %s", cmd, opts.printer);
-    end
+    endif
   elseif (isempty (opts.lpr_binary))
     error ("print:nolpr", "print.m: 'lpr' not found in EXEC_PATH.")
   endif
--- a/scripts/signal/periodogram.m
+++ b/scripts/signal/periodogram.m
@@ -137,7 +137,7 @@
     rr = rem (length (x), nfft);
     if (rr)
       x = [x(:); (zeros (nfft-rr, 1))];
-    end
+    endif
     x = sum (reshape (x, nfft, []), 2);
   endif
 
@@ -182,7 +182,7 @@
       plot (f, 10*log10 (Pxx));
       xlabel ("frequency [Hz]");
       ylabel ("Power density [dB/Hz]");
-    end
+    endif
     grid on;
     title ("Periodogram Power Spectral Density Estimate");
   else