--- loncom/interface/lonprintout.pm 2005/01/04 14:00:28 1.343.2.1 +++ loncom/interface/lonprintout.pm 2005/07/26 10:50:32 1.380 @@ -1,7 +1,7 @@ -# The LearningOnline Network +# The LearningOnline Network # Printout # -# $Id: lonprintout.pm,v 1.343.2.1 2005/01/04 14:00:28 albertel Exp $ +# $Id: lonprintout.pm,v 1.380 2005/07/26 10:50:32 foxr Exp $ # # Copyright Michigan State University Board of Trustees # @@ -42,8 +42,7 @@ use Apache::lonratedt; use POSIX qw(strftime); use Apache::lonlocal; -my $LaTeXwidth = 0; - +my $resources_printed = ''; # Compare two students by name. The students are in the form # returned by the helper: @@ -432,8 +431,8 @@ sub character_chart { my %page_formats= ('letter' => { 'book' => { - '1' => [ '7.1 in','10.0 in', '-0.57 in','-0.57 in','1 cm'], - '2' => ['3.66 in','10.0 in', '-0.57 in','-0.57 in','1 cm'] + '1' => [ '7.1 in','9.8 in', '-0.57 in','-0.57 in','0.7 cm'], + '2' => ['3.66 in','9.8 in', '-0.57 in','-0.57 in','0.7 cm'] }, 'album' => { '1' => [ '8.8 in', '6.8 in','-40 pt in', '-60 pt','1 cm'], @@ -446,8 +445,8 @@ my %page_formats= '2' => ['3.16 in','13 in','-0.57 in','-0.57 in','-0.5 in'] }, 'album' => { - '1' => [], - '2' => [] + '1' => ['12 in','7.1 in',,'-0.57 in','-0.57 in','-0.5 in'], + '2' => ['6.0 in','7.1 in','-1 in','-1 in','5 in'] }, }, 'tabloid' => { @@ -456,8 +455,8 @@ my %page_formats= '2' => ['4.9 in','16 in','-0.57 in','-0.57 in','-0.5 in'] }, 'album' => { - '1' => [], - '2' => [] + '1' => ['16 in','9.8 in','-0.57 in','-0.57 in','-0.5 in'], + '2' => ['16 in','4.9 in','-0.57 in','-0.57 in','-0.5 in'] }, }, 'executive' => { @@ -537,8 +536,8 @@ sub page_format { sub get_name { my ($uname,$udom)=@_; - if (!defined($uname)) { $uname=$ENV{'user.name'}; } - if (!defined($udom)) { $udom=$ENV{'user.domain'}; } + if (!defined($uname)) { $uname=$env{'user.name'}; } + if (!defined($udom)) { $udom=$env{'user.domain'}; } my $plainname=&Apache::loncommon::plainname($uname,$udom); if ($plainname=~/^\s*$/) { $plainname=$uname.'@'.$udom; } $plainname=&Apache::lonxml::latex_special_symbols($plainname,'header'); @@ -547,8 +546,8 @@ sub get_name { sub get_course { my $courseidinfo; - if (defined($ENV{'request.course.id'})) { - $courseidinfo = &Apache::lonxml::latex_special_symbols(&Apache::lonnet::unescape($ENV{'course.'.$ENV{'request.course.id'}.'.description'}),'header'); + if (defined($env{'request.course.id'})) { + $courseidinfo = &Apache::lonxml::latex_special_symbols(&Apache::lonnet::unescape($env{'course.'.$env{'request.course.id'}.'.description'}),'header'); } return $courseidinfo; } @@ -610,7 +609,7 @@ sub page_cleanup { sub details_for_menu { my ($helper)=@_; - my $postdata=$ENV{'form.postdata'}; + my $postdata=$env{'form.postdata'}; if (!$postdata) { $postdata=$helper->{VARS}{'postdata'}; } my $name_of_resource = &Apache::lonnet::gettitle($postdata); my $symbolic = &Apache::lonnet::symbread($postdata); @@ -621,9 +620,9 @@ sub details_for_menu { $map =~ m|([^/]+)$|; $name_of_sequence = $1; } - my $name_of_map = &Apache::lonnet::gettitle($ENV{'request.course.uri'}); + my $name_of_map = &Apache::lonnet::gettitle($env{'request.course.uri'}); if ($name_of_map =~ /^\s*$/) { - $ENV{'request.course.uri'} =~ m|([^/]+)$|; + $env{'request.course.uri'} =~ m|([^/]+)$|; $name_of_map = $1; } return ($name_of_resource,$name_of_sequence,$name_of_map); @@ -651,7 +650,8 @@ sub latex_corrections { $first_comment = index($result,'