--- loncom/xml/lonplot.pm 2002/01/15 16:21:39 1.40 +++ loncom/xml/lonplot.pm 2002/01/21 16:41:31 1.42 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # Dynamic plot # -# $Id: lonplot.pm,v 1.40 2002/01/15 16:21:39 matthew Exp $ +# $Id: lonplot.pm,v 1.42 2002/01/21 16:41:31 matthew Exp $ # # Copyright Michigan State University Board of Trustees # @@ -29,13 +29,8 @@ # 12/17 12/18 12/19 12/20 12/21 12/27 12/28 12/30 12/31 Matthew # 01/01/02 Matthew # 01/02 01/03 01/04 01/07 01/08 01/09 Matthew +# 01/21 Matthew -# Current issues -# 1. Gnuplot is unable to vary the color or linestyle of plots. -# The key does not know this so it is misleading for the user. -# Multiple s can be plotted with varying line styles and -# colors. -# package Apache::lonplot; use strict; @@ -380,7 +375,6 @@ sub start_key { ($token,$parstack,$safeeval,keys(%key_defaults)); if ($constructtag) { $result = &Apache::edit::rebuild_tag($token); - $result.= &Apache::edit::handle_insert(); } } return $result; @@ -413,6 +407,7 @@ sub start_title { &Apache::edit::editfield('',$text,'',60,1); } elsif ($target eq 'modified') { my $text=$$parser[-1]->get_text("/title"); + $result.=&Apache::edit::rebuild_tag($token); $result.=&Apache::edit::modifiedfield($token); } return $result; @@ -444,6 +439,7 @@ sub start_xlabel { &Apache::edit::editfield('',$text,'',60,1); } elsif ($target eq 'modified') { my $text=$$parser[-1]->get_text("/xlabel"); + $result.=&Apache::edit::rebuild_tag($token); $result.=&Apache::edit::modifiedfield($token); } return $result; @@ -476,6 +472,7 @@ sub start_ylabel { &Apache::edit::editfield('',$text,'',60,1); } elsif ($target eq 'modified') { my $text=$$parser[-1]->get_text("/ylabel"); + $result.=&Apache::edit::rebuild_tag($token); $result.=&Apache::edit::modifiedfield($token); } return $result; @@ -511,12 +508,9 @@ sub start_label { &Apache::edit::start_spanning_row(). &Apache::edit::editfield('',$text,'',60,1); } elsif ($target eq 'modified') { - my $constructtag=&Apache::edit::get_new_args + &Apache::edit::get_new_args ($token,$parstack,$safeeval,keys(%label_defaults)); - if ($constructtag) { - $result = &Apache::edit::rebuild_tag($token); - $result.= &Apache::edit::handle_insert(); - } + $result.=&Apache::edit::rebuild_tag($token); my $text=$$parser[-1]->get_text("/label"); $result.=&Apache::edit::modifiedfield($token); } @@ -588,7 +582,7 @@ sub start_function { &Apache::edit::start_spanning_row(). &Apache::edit::editfield('',$text,'',60,1); } elsif ($target eq 'modified') { - # Why do I do this? + $result.=&Apache::edit::rebuild_tag($token); my $text=$$parser[-1]->get_text("/function"); $result.=&Apache::edit::modifiedfield($token); } @@ -663,6 +657,7 @@ sub start_data { &Apache::edit::start_spanning_row(). &Apache::edit::editfield('',$text,'',60,1); } elsif ($target eq 'modified') { + $result.=&Apache::edit::rebuild_tag($token); my $text=$$parser[-1]->get_text("/data"); $result.=&Apache::edit::modifiedfield($token); } @@ -694,7 +689,6 @@ sub start_axis { ($token,$parstack,$safeeval,keys(%axis_defaults)); if ($constructtag) { $result = &Apache::edit::rebuild_tag($token); - $result.= &Apache::edit::handle_insert(); } } return $result; @@ -959,12 +953,13 @@ sub insert_label { sub insert_curve { my $result; - $result .= ' \n"; } sub insert_function {