--- loncom/xml/lonplot.pm 2004/09/09 19:48:21 1.102 +++ loncom/xml/lonplot.pm 2004/09/13 13:34:06 1.103 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # Dynamic plot # -# $Id: lonplot.pm,v 1.102 2004/09/09 19:48:21 albertel Exp $ +# $Id: lonplot.pm,v 1.103 2004/09/13 13:34:06 matthew Exp $ # # Copyright Michigan State University Board of Trustees # @@ -1030,7 +1030,7 @@ sub write_gnuplot_file { } # set term if ($target eq 'web') { - $gnuplot_input .= 'set term gif '; + $gnuplot_input .= 'set term '.$weboutputformat .' '; $gnuplot_input .= 'transparent ' if ($plot{'transparent'} eq 'on'); $gnuplot_input .= $plot{'font'} . ' '; $gnuplot_input .= 'size '.$plot{'width'}.','.$plot{'height'}.' '; @@ -1123,7 +1123,11 @@ sub write_gnuplot_file { my $label; foreach $label (@labels) { $gnuplot_input .= 'set label "'.$label->{'text'}.'" at '. - $label->{'xpos'}.','.$label->{'ypos'}.' '.$label->{'justify'}.' font "Helvetica,'.$pt.'pt"'.$/ ; + $label->{'xpos'}.','.$label->{'ypos'}.' '.$label->{'justify'}; + if ($target eq 'tex') { + $gnuplot_input .=' font "Helvetica,'.$pt.'pt"' ; + } + $gnuplot_input .= $/; } if ($target eq 'tex') { $gnuplot_input .="set size 1,".$plot{'height'}/$plot{'width'}*1.38;