--- loncom/interface/lonprintout.pm 2011/09/15 16:02:18 1.598 +++ loncom/interface/lonprintout.pm 2011/10/26 02:09:42 1.601 @@ -2,7 +2,7 @@ # The LearningOnline Network # Printout # -# $Id: lonprintout.pm,v 1.598 2011/09/15 16:02:18 raeburn Exp $ +# $Id: lonprintout.pm,v 1.601 2011/10/26 02:09:42 www Exp $ # # Copyright Michigan State University Board of Trustees # @@ -355,7 +355,7 @@ sub generate_code_selector { - Bubble sheet type: + Bubblesheet type: $bubble_types @@ -471,7 +471,7 @@ sub incomplete { # $helper - The helper we need $helper->{'VARS'}->{'symb'} # to construct the navmap and the iteration. # $seq - The original set of resources to print -# (really an array of resource names +# (really an array of resource names (array of symb's). # $who - Student/domain for whome the sequence will be generated. # # Implicit inputs: @@ -486,6 +486,7 @@ sub master_seq_to_person_seq { my ($username, $userdomain, $usersection) = split(/:/, $who); + # Toss the sequence up into a hash so that we have O(1) lookup time. # on the items that come out of the user's list of resources. # @@ -515,7 +516,8 @@ sub master_seq_to_person_seq { my $curres; while ($curres = $iterator->next()) { # - # Only process resources..that re not removed by randomout... + # Only process resources..that are not removed by randomout... + # and are selected for printint as well. # if (! exists $nonResourceItems{$curres} && ! $curres->randomout()) { my $symb = $curres->symb(); @@ -1927,7 +1929,7 @@ sub print_page_in_course { } else { $texversion.='\vskip 0 mm \noindent\textbf{Prints from construction space - there is no title.}\vskip 0 mm '; my $URLpath=$urlp; - $URLpath=~s/~([^\/]+)/public_html\/$1\/$1/; + #$URLpath=~s/~([^\/]+)/public_html\/$1\/$1/; $texversion.=&path_to_problem($URLpath,$LaTeXwidth); } $texversion.='\vskip 1 mm '.$answer.'\end{document}'; @@ -2047,7 +2049,7 @@ sub recently_generated { # A reference to a page break hash. # # -# use Data::Dumper; +use Data::Dumper; # sub dump_helper_vars { # my ($helper) = @_; # my $helpervars = Dumper($helper->{'VARS'}); @@ -2267,10 +2269,12 @@ sub print_construction_sequence { # IF sequence, recurse: if ($urlp =~ /\.sequence$/) { +# +# FIXME: this does not work for co-authors my $sequence_url = $urlp; my $domain = $env{'user.domain'}; # Constr. space only on local my $user = $env{'user.name'}; - +# FIXME: the substitutions below do not seem to make sense $sequence_url =~ s/^\/res\/$domain/\/home/; $sequence_url =~ s/^(\/home\/$user)/$1\/public_html/; # $sequence_url =~ s|\/~([^\/]+)\/|\/home\/$1\/public_html\/|; @@ -2513,6 +2517,7 @@ ENDPART } else { $texversion.='\vskip 0 mm \noindent\textbf{Prints from construction space - there is no title.}\vskip 0 mm '; my $URLpath=$cleanURL; +# FIXME: unclear URL path, not sure when this would occur $URLpath=~s/~([^\/]+)/public_html\/$1\/$1/; $texversion.=&path_to_problem($URLpath,$LaTeXwidth); } @@ -2548,7 +2553,7 @@ ENDPART && $currentURL=~/\.(sequence|page)$/ && $helper->{'VARS'}->{'construction'} eq '1') { #printing content of sequence from the construction space - +# FIXME: unclear how this would work $currentURL=~s|\/~([^\/]+)\/|\/home\/$1\/public_html\/|; $result .= &print_construction_sequence($currentURL, $helper, %form, $LaTeXwidth); @@ -3265,6 +3270,7 @@ sub print_resources { my ($username,$userdomain,$usersection) = split /:/,$person; my $fullname = &get_name($username,$userdomain); my $namepostfix = "\\\\"; # Both anon and not anon should get the same vspace. + # # Figure out if we need to filter the output by # the incomplete problems for that person @@ -4175,7 +4181,7 @@ CHOOSE_STUDENTS1 - Bubble sheet type: + Bubblesheet type: $codechoice