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

albertel lon-capa-cvs@mail.lon-capa.org
Wed, 19 Feb 2003 17:48:05 -0000


albertel		Wed Feb 19 12:48:05 2003 EDT

  Modified files:              
    /loncom/xml	lonxml.pm 
  Log:
  - retabinate
  
  
Index: loncom/xml/lonxml.pm
diff -u loncom/xml/lonxml.pm:1.237 loncom/xml/lonxml.pm:1.238
--- loncom/xml/lonxml.pm:1.237	Wed Feb 19 10:20:35 2003
+++ loncom/xml/lonxml.pm	Wed Feb 19 12:48:05 2003
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # XML Parser Module 
 #
-# $Id: lonxml.pm,v 1.237 2003/02/19 15:20:35 sakharuk Exp $
+# $Id: lonxml.pm,v 1.238 2003/02/19 17:48:05 albertel Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -458,19 +458,19 @@
 sub latex_special_symbols {
     my ($current_token,$stack,$parstack,$where)=@_;
     if ($where eq 'header') {
-      $current_token =~ s/(\\|_|^)/ /g;
-      $current_token =~ s/(\$|%|\#|&|\{|\})/\\$1/g;
+	$current_token =~ s/(\\|_|\^)/ /g;
+	$current_token =~ s/(\$|%|\#|&|\{|\})/\\$1/g;
     } else {
-     $current_token=~s/\\ /\\char92 /g;
-     $current_token=~s/\^/\\char94 /g;
-     $current_token=~s/\~/\\char126 /g;
-     $current_token=~s/(&[^a-z\#])/\\$1/g;
-     $current_token=~s/([^&])\#/$1\\#/g;
-     $current_token=~s/(\$|_|{|})/\\$1/g;
-     $current_token=~s/\\char92 /\\texttt{\\char92}/g;
-     $current_token=~s/(>|<)/\$$1\$/g; #more or less
-     if ($current_token=~m/\d%/) {$current_token =~ s/(\d)%/$1\\%/g;} #percent after digit
-     if ($current_token=~m/\s%/) {$current_token =~ s/(\s)%/$1\\%/g;} #persent after space
+	$current_token=~s/\\ /\\char92 /g;
+	$current_token=~s/\^/\\char94 /g;
+	$current_token=~s/\~/\\char126 /g;
+	$current_token=~s/(&[^a-z\#])/\\$1/g;
+	$current_token=~s/([^&])\#/$1\\#/g;
+	$current_token=~s/(\$|_|{|})/\\$1/g;
+	$current_token=~s/\\char92 /\\texttt{\\char92}/g;
+	$current_token=~s/(>|<)/\$$1\$/g; #more or less
+	if ($current_token=~m/\d%/) {$current_token =~ s/(\d)%/$1\\%/g;} #percent after digit
+	if ($current_token=~m/\s%/) {$current_token =~ s/(\s)%/$1\\%/g;} #persent after space
     }
     return $current_token;
 }