--- loncom/interface/lonprintout.pm 2018/01/15 00:51:42 1.661 +++ loncom/interface/lonprintout.pm 2019/02/17 03:42:24 1.669 @@ -1,7 +1,7 @@ # The LearningOnline Network # Printout # -# $Id: lonprintout.pm,v 1.661 2018/01/15 00:51:42 raeburn Exp $ +# $Id: lonprintout.pm,v 1.669 2019/02/17 03:42:24 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -847,8 +847,9 @@ sub set_font_size { if ($font_size ne '') { $text =~ s/\\begin\{document}/\\begin{document}{\\$font_size/; + $text =~ s/\\end\{document}/}\\end{document}/; + } - $text =~ s/\\end\{document}/}\\end{document}/; return $text; @@ -1233,7 +1234,7 @@ sub is_valid_alpha_code { sub is_code_valid { my ($code_value, $code_option) = @_; my ($code_type, $code_length) = ('letter', 6); # defaults. - my @lines = &Apache::grades::get_scantronformat_file(); + my @lines = &Apache::lonnet::get_scantronformat_file(); foreach my $line (@lines) { my ($name, $type, $length) = (split(/:/, $line))[0,2,4]; if($name eq $code_option) { @@ -1957,7 +1958,7 @@ sub latex_corrections { $result =~ s/(\\end\{document})/\\strut\\vspace\*{-4 mm}\\newline $copyright $end_of_student $1/; } $result =~ s/\$number_of_columns/$number_of_columns/g; - $result =~ s/(\\end\{longtable}\s*)(\\strut\\newline\\noindent\\makebox\[\\textwidth\/$number_of_columns\]\[b\]{\\hrulefill})/$2$1/g; + $result =~ s/(\\end\{longtable}\s*)(\\strut\\newline\\noindent\\makebox\[\\textwidth\/$number_of_columns\]\[b\]\{\\hrulefill})/$2$1/g; $result =~ s/(\\end\{longtable}\s*)\\strut\\newline/$1/g; #-- LaTeX corrections my $first_comment = index($result,'