[LON-CAPA-cvs] cvs: loncom /xml/algebra algebra2tex.pl

albertel lon-capa-cvs@mail.lon-capa.org
Mon, 13 Mar 2006 19:22:37 -0000


albertel		Mon Mar 13 14:22:37 2006 EDT

  Modified files:              
    /loncom/xml/algebra	algebra2tex.pl 
  Log:
  - som enhancmenets and style
  
  
Index: loncom/xml/algebra/algebra2tex.pl
diff -u loncom/xml/algebra/algebra2tex.pl:1.3 loncom/xml/algebra/algebra2tex.pl:1.4
--- loncom/xml/algebra/algebra2tex.pl:1.3	Wed Jun  8 22:13:07 2005
+++ loncom/xml/algebra/algebra2tex.pl	Mon Mar 13 14:22:37 2006
@@ -7,14 +7,17 @@
 my $ret;
 
 foreach $str (@ARGV) {
-$ret = $parser -> parse($str);
-if ( ref($ret) ) {
-    print $parser -> tostring().$/;
-    print $parser -> normalize().$/;
-    print $parser -> tolatex().$/;
-} else {
-    print $parser->{htmlerror};
-}
-print "\n";
+    print($str.$/);
+    $ret = $parser->parse($str);
+    if ( ref($ret) ) {
+	print('1). '.$parser->tostring() .$/);
+	print('2). '.$parser->tolatex()  .$/);
+	print('3). '.$parser->normalize().$/);
+	print('4). '.$parser->tostring() .$/);
+	print('5). '.$parser->tolatex()  .$/);
+    } else {
+	print($parser->{htmlerror}.$/);
+    }
+    print "\n";
 }