[LON-CAPA-cvs] cvs: loncom /xml londefdef.pm

sakharuk lon-capa-cvs@mail.lon-capa.org
Thu, 19 Jun 2003 20:14:13 -0000


sakharuk		Thu Jun 19 16:14:13 2003 EDT

  Modified files:              
    /loncom/xml	londefdef.pm 
  Log:
  Final version (at least for today) which prints fine nested tables. My undef function works really well. The reason why Guy could not print nested tables was mystupid error - I've forgotten to remove a chunk which I added only for the testing purpose. Sorry for this and thanks to Guy for the notoce.
  
  
Index: loncom/xml/londefdef.pm
diff -u loncom/xml/londefdef.pm:1.142 loncom/xml/londefdef.pm:1.143
--- loncom/xml/londefdef.pm:1.142	Thu Jun 19 15:15:59 2003
+++ loncom/xml/londefdef.pm	Thu Jun 19 16:14:13 2003
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # Tags Default Definition Module 
 #
-# $Id: londefdef.pm,v 1.142 2003/06/19 19:15:59 sakharuk Exp $
+# $Id: londefdef.pm,v 1.143 2003/06/19 20:14:13 sakharuk Exp $
 # 
 #
 # Copyright Michigan State University Board of Trustees
@@ -1747,7 +1747,7 @@
 	    $Apache::londefdef::table[-1]{'vvinc'} = '';
 	}
 	$Apache::londefdef::table[-1]{'output'} = ' \noindent \begin{tabular} ';
-	$currentstring = '\keephidden{NEW TABLE ENTRY '.$textwidth.' }';
+	$currentstring = '\keephidden{NEW TABLE ENTRY}';
     }
     return $currentstring;
 }
@@ -1825,6 +1825,7 @@
 	} else {
 	    $currentstring .= $Apache::londefdef::table[-1]{'output'};
 	    pop @Apache::londefdef::table;
+	    undef @Apache::londefdef::table;
 	}
     }
     return $currentstring;
@@ -1912,7 +1913,7 @@
 		$Apache::londefdef::table[-1]{'TeXlength'} .= '0,';
 	    }        
 	}
-	for (my $in=0; $in<=$#{$Apache::londefdef::table[-1]{'include'}};$in++) {                                
+	for (my $in=0; $in<=$#{$Apache::londefdef::table[-1]{'include'}};$in++) {         
 	    $data=~s/\\keephidden\{NEW TABLE ENTRY\}/$Apache::londefdef::table[-1]{'include'}[$in]/;
 	}
 	@{ $Apache::londefdef::table[-1]{'rowdata'} }[$current_row] .= '\parbox{TOBECHANGEDONNUMBER}{'.$data.'} '.$Apache::londefdef::table[-1]{'vinc'};