[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Line colors different...
From: |
John W. Eaton |
Subject: |
Line colors different... |
Date: |
Wed, 7 Mar 2007 15:29:23 -0500 |
On 7-Mar-2007, Daniel J Sebald wrote:
| Run Søren's script several times:
|
| figure
| hold on
| f = sin(0:0.1:2*pi);
| plot(f)
| plot(1+f)
| hold off
|
| and the color of the lines is different in each plot. First blue/green, then
red/cyan, then purple/yellow, etc.
|
| I would think that each plot would go back to blue/green.
I think the following patch will make the behavior more like Matlab.
jwe
scripts/ChangeLog:
2007-03-07 John W. Eaton <address@hidden>
* plot/newplot.m: Always reset next line color.
Index: scripts/plot/newplot.m
===================================================================
RCS file: /cvs/octave/scripts/plot/newplot.m,v
retrieving revision 1.4
diff -u -u -r1.4 newplot.m
--- scripts/plot/newplot.m 16 Feb 2007 00:43:40 -0000 1.4
+++ scripts/plot/newplot.m 7 Mar 2007 20:28:32 -0000
@@ -24,6 +24,7 @@
function newplot ()
if (nargin == 0)
+ __next_line_color__ (true);
cf = gcf ();
fnp = get (cf, "nextplot");
switch (fnp)
@@ -42,7 +43,6 @@
case "add"
case "replacechildren"
case "replace"
- __next_line_color__ (true);
__uiobject_axes_init__ (ca, "replace");
otherwise
error ("newplot: unrecognized nextplot property for current axes");