--- loncom/interface/lonprintout.pm 2011/06/22 11:00:47 1.595 +++ loncom/interface/lonprintout.pm 2011/09/13 21:43:03 1.596 @@ -2,7 +2,7 @@ # The LearningOnline Network # Printout # -# $Id: lonprintout.pm,v 1.595 2011/06/22 11:00:47 foxr Exp $ +# $Id: lonprintout.pm,v 1.596 2011/09/13 21:43:03 raeburn Exp $ # # Copyright Michigan State University Board of Trustees # @@ -2928,17 +2928,24 @@ ENDPART my $code_option=$helper->{'VARS'}->{'CODE_OPTION'}; my @lines = &Apache::grades::get_scantronformat_file(); - my ($code_type,$code_length)=('letter',6); + my ($code_type,$code_length,$bubbles_per_row)=('letter',6,10); foreach my $line (@lines) { - my ($name,$type,$length) = (split(/:/,$line))[0,2,4]; + chomp($line); + my ($name,$type,$length,$bubbles_per_item) = + (split(/:/,$line))[0,2,4,17]; if ($name eq $code_option) { $code_length=$length; if ($type eq 'number') { $code_type = 'number'; } + chomp($bubbles_per_item); + if (($bubbles_per_item ne '') && ($bubbles_per_item > 0)) { + $bubbles_per_row = $bubbles_per_item; + } } } my %moreenv = ('textwidth' => &get_textwidth($helper,$LaTeXwidth)); $moreenv{'problem_split'} = $parmhash{'problem_stream_switch'}; $moreenv{'instructor_comments'}='hide'; + $moreenv{'bubbles_per_row'} = $bubbles_per_row; my $seed=time+($$<<16)+($$); my @allcodes; if ($old_name) { @@ -3265,7 +3272,7 @@ sub print_resources { ($print_type eq 'incomplete_problems_selpeople_course')) { $print_incomplete = 1; } - if ($person =~ 'anon') { + if ($person eq 'anonymous') { $namepostfix .="Name: "; $fullname = "CODE - ".$moreenv->{'CODE'}; }