version 1.86, 2003/08/26 21:52:46
|
version 1.87, 2003/08/28 20:38:25
|
Line 113 my $words_test = sub {$_[0]=~s/\s+/
|
Line 113 my $words_test = sub {$_[0]=~s/\s+/
|
################################################################### |
################################################################### |
my @gnuplot_edit_order = |
my @gnuplot_edit_order = |
qw/alttag bgcolor fgcolor height width font transparent grid samples |
qw/alttag bgcolor fgcolor height width font transparent grid samples |
border align texwidth/; |
border align texwidth plottype/; |
|
|
my $gnuplot_help_text = <<"ENDPLOTHELP"; |
my $gnuplot_help_text = <<"ENDPLOTHELP"; |
<p> |
<p> |
Line 230 my %gnuplot_defaults =
|
Line 230 my %gnuplot_defaults =
|
edit_type => 'entry', |
edit_type => 'entry', |
size => '5' |
size => '5' |
}, |
}, |
|
plottype => { |
|
default => 'Cartesian', |
|
test => sub {$_[0]=~/^(Polar|Cartesian)$/}, |
|
description => 'Plot type:', |
|
edit_type => 'choice', |
|
choices => ['Polar','Cartesian'] |
|
}, |
); |
); |
|
|
my %key_defaults = |
my %key_defaults = |
Line 1021 sub write_gnuplot_file {
|
Line 1028 sub write_gnuplot_file {
|
$gnuplot_input .= "set output \"/home/httpd/perl/tmp/". |
$gnuplot_input .= "set output \"/home/httpd/perl/tmp/". |
&Apache::lonnet::unescape($filename).".eps\"\n"; |
&Apache::lonnet::unescape($filename).".eps\"\n"; |
} |
} |
|
# cartesian or polar? |
|
if (lc($plot{'plottype'}) eq 'polar') { |
|
$gnuplot_input .= 'set polar'.$/; |
|
} else { |
|
# Assume Cartesian |
|
} |
# grid |
# grid |
$gnuplot_input .= 'set grid'.$/ if ($plot{'grid'} eq 'on'); |
$gnuplot_input .= 'set grid'.$/ if ($plot{'grid'} eq 'on'); |
# border |
# border |