--- loncom/interface/lonprintout.pm 2006/01/27 22:07:10 1.418 +++ loncom/interface/lonprintout.pm 2006/02/14 20:34:34 1.422 @@ -1,7 +1,7 @@ # The LearningOnline Network # Printout # -# $Id: lonprintout.pm,v 1.418 2006/01/27 22:07:10 foxr Exp $ +# $Id: lonprintout.pm,v 1.422 2006/02/14 20:34:34 albertel Exp $ # # Copyright Michigan State University Board of Trustees # @@ -751,7 +751,6 @@ sub details_for_menu { sub latex_corrections { my ($number_of_columns,$result,$selectionmade,$answer_mode) = @_; - # $result =~ s/\\includegraphics{/\\includegraphics\[width=\\minipagewidth\]{/g; $result =~ s/\$number_of_columns/$number_of_columns/g; if ($selectionmade eq '1' || $answer_mode eq 'only') { @@ -781,7 +780,6 @@ sub latex_corrections { } $result =~ s/(\\end{tabular})\s*\\vskip 0 mm/$1/g; $result =~ s/(\\begin{enumerate})\s*\\noindent/$1/g; - return $result; } @@ -906,10 +904,7 @@ sub unsupported { } else { $result.=$currentURL; } - # TODO: /2 used to be /$number_of_columns which we don'thave - # access to and therefore now causes latex to fail. - # need to figure out exactly what we should divide by. - $result.= '\vskip 0.5mm\noindent\makebox[\textwidth/2][b]{\hrulefill} \end{document}'; + $result.= '\vskip 0.5mm\noindent\makebox[\textwidth/$number_of_columns][b]{\hrulefill} \end{document}'; return $result; } @@ -1423,8 +1418,7 @@ ENDPART $person,$type, \%moreenv,\@master_seq, $flag_latex_header_remove, - $LaTeXwidth, - $number_of_columns); + $LaTeXwidth); $resources_printed .= ":"; $print_array[$i].=$output; $student_names[$i].=$person.':'.$fullname.'_END_'; @@ -1456,6 +1450,7 @@ ENDPART } my %moreenv = ('textwidth' => &get_textwidth($helper,$LaTeXwidth)); $moreenv{'problem_split'} = $parmhash{'problem_stream_switch'}; + $moreenv{'instructor_comments'}='hide'; my $seed=time+($$<<16)+($$); my @allcodes; if ($old_name) { @@ -1729,7 +1724,7 @@ sub get_CODE { sub print_resources { my ($r,$helper,$person,$type,$moreenv,$master_seq,$remove_latex_header, - $LaTeXwidth,$number_of_columns)=@_; + $LaTeXwidth)=@_; my $current_output = ''; my $printed = ''; my ($username,$userdomain,$usersection) = split /:/,$person; @@ -1807,7 +1802,8 @@ sub print_resources { } else { $rendered =~ s/\\end{document}//; } - $current_output .= $rendered.'\vskip 0.5mm\noindent\makebox[\textwidth/'.$number_of_columns.'][b]{\hrulefill}\strut \vskip 0 mm \strut '; + $current_output .= $rendered.'\vskip 0.5mm\noindent\makebox[\textwidth/$number_of_columns][b]{\hrulefill}\strut \vskip 0 mm \strut '; + } else { my $rendered = &unsupported($res_url,$helper->{'VARS'}->{'LATEX_TYPE'},$curresline); if ($remove_latex_header ne 'NO') {