Mercurial > octave
changeset 26341:0990e4093c25 stable
legend.m: Deprecate numeric arguments for position.
* NEWS: Announce change, and replacement of using strings.
* legend.m: Add warning if a numeric argument for position is found.
author | Rik <rik@octave.org> |
---|---|
date | Tue, 01 Jan 2019 08:49:40 -0800 |
parents | b880c6426424 |
children | 050ec530e6e4 |
files | NEWS scripts/plot/appearance/legend.m |
diffstat | 2 files changed, 4 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/NEWS Sun Dec 30 18:00:03 2018 +0100 +++ b/NEWS Tue Jan 01 08:49:40 2019 -0800 @@ -164,6 +164,9 @@ Matlab compatible. If necessary use the "-loose" option to reproduce figures as they appeared in previous versions of Octave. + ** Specifying legend position with a numeric argument is deprecated and + will be removed in Octave 7.0. Use a string argument instead. + ** It is now possible to use files and folders containing Unicode characters in Windows.
--- a/scripts/plot/appearance/legend.m Sun Dec 30 18:00:03 2018 +0100 +++ b/scripts/plot/appearance/legend.m Tue Jan 01 08:49:40 2019 -0800 @@ -208,6 +208,7 @@ if (nargs > 0) pos = varargin{nargs}; if (isnumeric (pos) && isscalar (pos) && pos == fix (pos)) + warning ("legend: specifying location with a numeric argument is obsolete and will be removed from a future version of Octave, use a string specification instead"); if (pos >= -1 && pos <= 4) location = [{"northeastoutside", "best", "northeast", "northwest", "southwest", "southeast"}] {pos + 2};