Mercurial > hg > octave-terminal
changeset 4717:7fa16e369904
[project @ 2004-01-23 03:15:53 by jwe]
author | jwe |
---|---|
date | Fri, 23 Jan 2004 03:15:53 +0000 |
parents | fe25e290fafb |
children | ab71705f294f |
files | scripts/ChangeLog scripts/plot/__errcomm__.m scripts/plot/__errplot__.m scripts/plot/__plt__.m scripts/plot/plot_border.m |
diffstat | 5 files changed, 25 insertions(+), 13 deletions(-) [+] |
line wrap: on
line diff
--- a/scripts/ChangeLog +++ b/scripts/ChangeLog @@ -1,5 +1,10 @@ 2004-01-22 John W. Eaton <jwe@bevo.che.wisc.edu> + * plot/__errcomm__.m: Cope with nargin now being a function. + * plot/__errplot__.m: Likewise. + * plot/__plt__.m: Likewise. + * plot/plot_border.m: Likewise. + * Makefile.in (distclean, maintainer-clean): Remove DOCSTRINGS, not $(DOCSTRINGS).
--- a/scripts/plot/__errcomm__.m +++ b/scripts/plot/__errcomm__.m @@ -31,11 +31,13 @@ function __errcomm__ (caller, varargin) - if (nargin < 3) + nargs = nargin (); + + if (nargs < 3) usage ("%s (...)", caller); endif - nargin--; + nargs--; save_hold = ishold; unwind_protect if (! ishold) @@ -43,9 +45,9 @@ endif hold on; k = 1; - while (nargin) + while (nargs) a = varargin{k++}; - nargin--; + nargs--; if (isvector (a)) a = a(:); elseif (ismatrix (a)) @@ -56,8 +58,7 @@ sz = size (a); ndata = 1; arg1 = a; - while (nargin) - nargin--; + while (nargs--) a = varargin{k++}; if (isstr (a)) fmt = a;
--- a/scripts/plot/__errplot__.m +++ b/scripts/plot/__errplot__.m @@ -35,7 +35,9 @@ function __errplot__ (varargin) - if (nargin < 3) # atleast two data arguments needed + nargs = nargin (); + + if (nargs < 3) # atleast two data arguments needed usage ("__errplot__ (arg1, ..., fmt)"); endif @@ -43,7 +45,7 @@ ndata = 0; k = 1; - while (nargin--) + while (nargs--) a = varargin{k++}; if (! isstr (a)) ndata++;
--- a/scripts/plot/__plt__.m +++ b/scripts/plot/__plt__.m @@ -25,11 +25,13 @@ function __plt__ (caller, varargin) - if (nargin == 2) + nargs = nargin (); + + if (nargs == 2) __plt1__ (varargin{1}, ""); - elseif (nargin > 2) + elseif (nargs > 2) first_plot = 1; hold_state = ishold (); @@ -38,13 +40,13 @@ k = 1; x = varargin{k++}; - nargin = nargin - 2; + nargs -= 2; x_set = 1; y_set = 0; ## Gather arguments, decode format, and plot lines. - while (nargin-- > 0) + while (nargs-- > 0) fmt = ""; new = varargin{k++};