[LON-CAPA-cvs] cvs: loncom /interface lonprintout.pm printout.pl
raeburn
raeburn at source.lon-capa.org
Wed Oct 16 13:48:08 EDT 2024
raeburn Wed Oct 16 17:48:08 2024 EDT
Modified files:
/loncom/interface printout.pl lonprintout.pm
Log:
- Make top margin consistent for papertype of letter when printing portrait
format on papertype of letter on RHEL7, RHEL8 and RHEL9 etc.
- Discontinue practice of setting papertype to a4 when letter was selected.
- Modify topmargin for two column pages for papertype of letter to keep
top margin consistent with what it was before (for RHEL7 and older).
Index: loncom/interface/printout.pl
diff -u loncom/interface/printout.pl:1.172 loncom/interface/printout.pl:1.173
--- loncom/interface/printout.pl:1.172 Thu Jul 11 15:24:01 2024
+++ loncom/interface/printout.pl Wed Oct 16 17:48:08 2024
@@ -1,7 +1,7 @@
#!/usr/bin/perl
# CGI-script to run LaTeX, dvips, ps2ps, ps2pdf etc.
#
-# $Id: printout.pl,v 1.172 2024/07/11 15:24:01 raeburn Exp $
+# $Id: printout.pl,v 1.173 2024/10/16 17:48:08 raeburn Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -447,12 +447,10 @@
$new_name_file =~ s/\.dvi/\.ps/;
# Explicitly include a switch for papertype, otherwise dvips will default
# to whatever is listed first in config.ps (which in most cases is a4).
-# Historically (since 2004) LON-CAPA printing expected to use the default,
-# i.e., a papertype of a4, when the user selected letter [8 1/2 x 11 in]
-# in the Layout options, so I follow that convention if $papera is letter.
- my $papera=$paper;
- if ($papera eq 'letter') {$papera='a4';}
- if ($papera ne '') {$papera='-t'.$papera;}
+ my $papera;
+ unless ($paper eq '') {
+ $papera='-t'.$paper;
+ }
my $extra_ps_header = $perlvar{'lonLib'} .'/includepsheader.ps';
my $comma = "dvips $papera -h $extra_ps_header -Ppdf -G0 -o $new_name_file";
&busy_wait_command("$comma $name_file 1>/dev/null 2>/dev/null",
Index: loncom/interface/lonprintout.pm
diff -u loncom/interface/lonprintout.pm:1.694 loncom/interface/lonprintout.pm:1.695
--- loncom/interface/lonprintout.pm:1.694 Mon Apr 17 18:36:31 2023
+++ loncom/interface/lonprintout.pm Wed Oct 16 17:48:08 2024
@@ -1,7 +1,7 @@
# The LearningOnline Network
# Printout
#
-# $Id: lonprintout.pm,v 1.694 2023/04/17 18:36:31 raeburn Exp $
+# $Id: lonprintout.pm,v 1.695 2024/10/16 17:48:08 raeburn Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -1861,11 +1861,11 @@
('letter' => {
'book' => {
'1' => [ '7.1 in','9.8 in', '-0.57 in','-0.57 in','0.275 in'],
- '2' => ['3.66 in','9.8 in', '-0.57 in','-0.57 in','0.275 in']
+ '2' => ['3.66 in','9.8 in', '-0.57 in','-0.57 in','-0.4 in']
},
'album' => {
'1' => [ '8.8 in', '6.8 in','-0.55 in', '-0.55 in','0.394 in'],
- '2' => [ '4.8 in', '6.8 in','-0.5 in', '-1.0 in','3.5 in']
+ '2' => [ '4.8 in', '6.8 in','-0.5 in', '-1.0 in','3.25 in']
},
},
'legal' => {
More information about the LON-CAPA-cvs
mailing list