version 1.64, 2002/04/09 18:01:09
|
version 1.66, 2002/04/24 16:38:40
|
Line 156 my %gnuplot_defaults =
|
Line 156 my %gnuplot_defaults =
|
size => '40' |
size => '40' |
}, |
}, |
height => { |
height => { |
default => 200, |
default => 300, |
test => $int_test, |
test => $int_test, |
description => 'height of image (pixels)', |
description => 'height of image (pixels)', |
edit_type => 'entry', |
edit_type => 'entry', |
size => '10' |
size => '10' |
}, |
}, |
width => { |
width => { |
default => 200, |
default => 400, |
test => $int_test, |
test => $int_test, |
description => 'width of image (pixels)', |
description => 'width of image (pixels)', |
edit_type => 'entry', |
edit_type => 'entry', |
Line 190 my %gnuplot_defaults =
|
Line 190 my %gnuplot_defaults =
|
edit_type => 'onoff' |
edit_type => 'onoff' |
}, |
}, |
grid => { |
grid => { |
default => 'off', |
default => 'on', |
test => $onoff_test, |
test => $onoff_test, |
description => 'Display grid', |
description => 'Display grid', |
edit_type => 'onoff' |
edit_type => 'onoff' |
Line 209 my %gnuplot_defaults =
|
Line 209 my %gnuplot_defaults =
|
choices => ['small','medium','large'] |
choices => ['small','medium','large'] |
}, |
}, |
align => { |
align => { |
default => 'left', |
default => 'center', |
test => sub {$_[0]=~/^(left|right|center)$/}, |
test => sub {$_[0]=~/^(left|right|center)$/}, |
description => 'alignment for image in html', |
description => 'alignment for image in html', |
edit_type => 'choice', |
edit_type => 'choice', |
Line 306 my %tic_defaults =
|
Line 306 my %tic_defaults =
|
}, |
}, |
); |
); |
|
|
|
my @axis_edit_order = ('color','xmin','xmax','ymin','ymax'); |
my %axis_defaults = |
my %axis_defaults = |
( |
( |
color => { |
color => { |
Line 906 sub start_axis {
|
Line 907 sub start_axis {
|
$tagstack->[-1]); |
$tagstack->[-1]); |
} elsif ($target eq 'edit') { |
} elsif ($target eq 'edit') { |
$result .= &Apache::edit::tag_start($target,$token,'Plot Axes'); |
$result .= &Apache::edit::tag_start($target,$token,'Plot Axes'); |
$result .= &edit_attributes($target,$token,\%axis_defaults); |
$result .= &edit_attributes($target,$token,\%axis_defaults, |
|
\@axis_edit_order); |
} elsif ($target eq 'modified') { |
} elsif ($target eq 'modified') { |
my $constructtag=&Apache::edit::get_new_args |
my $constructtag=&Apache::edit::get_new_args |
($token,$parstack,$safeeval,keys(%axis_defaults)); |
($token,$parstack,$safeeval,keys(%axis_defaults)); |
Line 990 sub write_gnuplot_file {
|
Line 992 sub write_gnuplot_file {
|
$gnuplot_input .= "set output\n"; |
$gnuplot_input .= "set output\n"; |
} elsif ($target eq 'tex') { |
} elsif ($target eq 'tex') { |
$gnuplot_input .= "set term postscript eps monochrome\n"; |
$gnuplot_input .= "set term postscript eps monochrome\n"; |
$gnuplot_input .= "set output \"$filename.eps\"\n"; |
$gnuplot_input .= "set output \"/home/httpd/perl/tmp/$filename.eps\"\n"; |
} |
} |
# grid |
# grid |
$gnuplot_input .= 'set grid'.$/ if ($plot{'grid'} eq 'on'); |
$gnuplot_input .= 'set grid'.$/ if ($plot{'grid'} eq 'on'); |