[LON-CAPA-cvs] cvs: loncom /xml londefdef.pm
foxr
lon-capa-cvs@mail.lon-capa.org
Tue, 12 Jul 2005 21:05:51 -0000
foxr Tue Jul 12 17:05:51 2005 EDT
Modified files:
/loncom/xml londefdef.pm
Log:
Replace \newline with \\ in <table></endtable> since if the table
is in a <div>, \endline screws up the alignment generated in tex
mode by the div tag.
Bug 3536
Index: loncom/xml/londefdef.pm
diff -u loncom/xml/londefdef.pm:1.280 loncom/xml/londefdef.pm:1.281
--- loncom/xml/londefdef.pm:1.280 Mon Jul 11 06:27:58 2005
+++ loncom/xml/londefdef.pm Tue Jul 12 17:05:49 2005
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# Tags Default Definition Module
#
-# $Id: londefdef.pm,v 1.280 2005/07/11 10:27:58 foxr Exp $
+# $Id: londefdef.pm,v 1.281 2005/07/12 21:05:49 foxr Exp $
#
#
# Copyright Michigan State University Board of Trustees
@@ -1948,7 +1948,9 @@
$Apache::londefdef::table[-1]{'vvinc'} = '';
}
if ($#Apache::londefdef::table==0) {
- $Apache::londefdef::table[-1]{'output'}='\strut\newline\strut\setlength{\tabcolsep}{1 mm}';
+ # Note that \newline seems to destroy the alignment envs.
+ # $Apache::londefdef::table[-1]{'output'}='\strut\newline\strut\setlength{\tabcolsep}{1 mm}';
+ $Apache::londefdef::table[-1]{'output'}='\strut'.'\\\\'."\n".'\strut\setlength{\tabcolsep}{1 mm}';
}
$Apache::londefdef::table[-1]{'output'}.=' \noindent \begin{tabular} ';
$Apache::londefdef::table[-1]{'TeXlen'}=[];
@@ -2171,7 +2173,9 @@
}
$output.=' \\\\ '.$Apache::londefdef::table[-1]{'hinc'}.' ';
}
- $Apache::londefdef::table[-1]{'output'} .= $header_of_table.$Apache::londefdef::table[-1]{'hinc'}.$output.'\end{tabular}\strut\newline\strut ';
+ # Note that \newline destroys alignment env's produced by e.g. <div>
+ # $Apache::londefdef::table[-1]{'output'} .= $header_of_table.$Apache::londefdef::table[-1]{'hinc'}.$output.'\end{tabular}\strut\newline\strut ';
+ $Apache::londefdef::table[-1]{'output'} .= $header_of_table.$Apache::londefdef::table[-1]{'hinc'}.$output.'\end{tabular}\strut'.'\\\\'."\n".'\strut ';
if ($#Apache::londefdef::table > 0) {
my $inmemory = $Apache::londefdef::table[-1]{'output'};
pop @Apache::londefdef::table;