Mercurial > hg > octave-avbm
changeset 9427:7b74a7fd4761
axis: return 4-element vector for 2-d view
author | John W. Eaton <jwe@octave.org> |
---|---|
date | Thu, 09 Jul 2009 15:22:21 -0400 |
parents | 40da70ba1fc6 |
children | b317debeb828 |
files | scripts/ChangeLog scripts/plot/axis.m |
diffstat | 2 files changed, 10 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/scripts/ChangeLog +++ b/scripts/ChangeLog @@ -1,5 +1,8 @@ 2009-07-09 John W. Eaton <jwe@octave.org> + * plot/axis.m: Return 4-element vector for 2-d view. + From David Woodburn <david.woodburn@gmail.com>. + * sparse/nonzeros.m: Always return a column vector. New tests. 2009-06-25 Ben Abbott <bpabbott@mac.com>
--- a/scripts/plot/axis.m +++ b/scripts/plot/axis.m @@ -141,8 +141,13 @@ else xlim = get (ca, "xlim"); ylim = get (ca, "ylim"); - zlim = get (ca, "zlim"); - curr_axis = [xlim, ylim, zlim]; + view = get (ca, "view"); + if (view(2) == 90) + curr_axis = [xlim, ylim]; + else + zlim = get (ca, "zlim"); + curr_axis = [xlim, ylim, zlim]; + endif endif elseif (ischar (ax))