Mercurial > hg > octave-nkf
annotate scripts/plot/newplot.m @ 10334:db540cb0e959
improve shadowed function checking
author | Jaroslav Hajek <highegg@gmail.com> |
---|---|
date | Thu, 18 Feb 2010 08:40:17 +0100 |
parents | 4516a0c97ced |
children | 62ebba45054e |
rev | line source |
---|---|
8920 | 1 ## Copyright (C) 2005, 2006, 2007, 2008 John W. Eaton |
6257 | 2 ## |
3 ## This file is part of Octave. | |
4 ## | |
5 ## Octave is free software; you can redistribute it and/or modify it | |
6 ## under the terms of the GNU General Public License as published by | |
7016 | 7 ## the Free Software Foundation; either version 3 of the License, or (at |
8 ## your option) any later version. | |
6257 | 9 ## |
10 ## Octave is distributed in the hope that it will be useful, but | |
11 ## WITHOUT ANY WARRANTY; without even the implied warranty of | |
12 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | |
13 ## General Public License for more details. | |
14 ## | |
15 ## You should have received a copy of the GNU General Public License | |
7016 | 16 ## along with Octave; see the file COPYING. If not, see |
17 ## <http://www.gnu.org/licenses/>. | |
6257 | 18 |
19 ## -*- texinfo -*- | |
20 ## @deftypefn {Function File} {} newplot () | |
9672
43a07df0ed4c
document graphics structures
Michael D. Godfrey <godfrey@isl.stanford.edu>
parents:
8920
diff
changeset
|
21 ## Prepare graphics engine to produce a new plot. This function is |
43a07df0ed4c
document graphics structures
Michael D. Godfrey <godfrey@isl.stanford.edu>
parents:
8920
diff
changeset
|
22 ## called at the beginning of all high-level plotting functions. |
43a07df0ed4c
document graphics structures
Michael D. Godfrey <godfrey@isl.stanford.edu>
parents:
8920
diff
changeset
|
23 ## It is not normally required in user programs. |
6257 | 24 ## @end deftypefn |
25 | |
26 function newplot () | |
27 | |
28 if (nargin == 0) | |
6394 | 29 __next_line_color__ (true); |
10135
4516a0c97ced
Handle linestyleorder. Remove @ markers. Treat edgecolor, markeredgecolor and markerfacecolor correctly in scatter.
David Bateman <dbateman@free.fr>
parents:
9672
diff
changeset
|
30 __next_line_style__ (true); |
6257 | 31 cf = gcf (); |
32 fnp = get (cf, "nextplot"); | |
33 switch (fnp) | |
6314 | 34 ## FIXME -- probably we should do more than validate the nextplot |
35 ## property value... | |
6257 | 36 case "new" |
37 case "add" | |
38 case "replacechildren" | |
39 case "replace" | |
40 otherwise | |
41 error ("newplot: unrecognized nextplot property for current figure"); | |
42 endswitch | |
43 ca = gca (); | |
44 anp = get (ca, "nextplot"); | |
45 switch (anp) | |
46 case "add" | |
47 case "replacechildren" | |
48 case "replace" | |
6405 | 49 __go_axes_init__ (ca, "replace"); |
6419 | 50 __request_drawnow__ (); |
6257 | 51 otherwise |
52 error ("newplot: unrecognized nextplot property for current axes"); | |
53 endswitch | |
54 else | |
55 print_usage (); | |
56 endif | |
8252
b12a2975bf7e
newplot.m: delete stray debugging code
John W. Eaton <jwe@octave.org>
parents:
8228
diff
changeset
|
57 |
6257 | 58 endfunction |