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

sakharuk lon-capa-cvs@mail.lon-capa.org
Wed, 06 Mar 2002 20:37:38 -0000


sakharuk		Wed Mar  6 15:37:38 2002 EDT

  Modified files:              
    /loncom/xml	londefdef.pm 
  Log:
  added externallink tag for CBI
  
  
Index: loncom/xml/londefdef.pm
diff -u loncom/xml/londefdef.pm:1.47 loncom/xml/londefdef.pm:1.48
--- loncom/xml/londefdef.pm:1.47	Wed Mar  6 15:27:00 2002
+++ loncom/xml/londefdef.pm	Wed Mar  6 15:37:38 2002
@@ -2,7 +2,7 @@
 # The LearningOnline Network with CAPA
 # Tags Default Definition Module 
 #
-# $Id: londefdef.pm,v 1.47 2002/03/06 20:27:00 matthew Exp $
+# $Id: londefdef.pm,v 1.48 2002/03/06 20:37:38 sakharuk Exp $
 # 
 #
 # Copyright Michigan State University Board of Trustees
@@ -50,7 +50,7 @@
 
 BEGIN {
 
-    &Apache::lonxml::register('Apache::londefdef',('m','html','head','map','select','option','input','textarea','form','meta','title','body','center','b','strong','table','dt','h1','h2','h3','h4','h5','h6','cite','i','address','dd','dl','dir','ol','ul','menu','dfn','kbd','tt','code','em','q','p','br','big','small','basefont','font','s','sub','strike','sup','hr','a','li','u','output','param','applet','img','embed','tr','td','allow','frameset','pre','insert'));
+    &Apache::lonxml::register('Apache::londefdef',('m','html','head','map','select','option','input','textarea','form','meta','title','body','center','b','strong','table','dt','h1','h2','h3','h4','h5','h6','cite','i','address','dd','dl','dir','ol','ul','menu','dfn','kbd','tt','code','em','q','p','br','big','small','basefont','font','s','sub','strike','sup','hr','a','li','u','output','param','applet','img','embed','tr','td','allow','frameset','pre','insert','externallink'));
 
 }
 
@@ -115,14 +115,6 @@
                                &Apache::lonxml::fontsettings();     
 	    } elsif ($target eq 'tex') {
 	      $currentstring .= '\documentclass[letterpaper]{article}
-                                 \setlength{\oddsidemargin}{-40pt}
-                                 \setlength{\evensidemargin}{-60pt}
-                                 \setlength{\topmargin}{200pt}
-                                 \setlength{\textwidth}{4.4in}
-                                 \setlength{\textheight}{6.8in}
-                                 \setlength{\parindent}{20pt}
-                                 \setlength{\marginparwidth}{90pt}
-                                 \setlength{\textfloatsep}{8pt plus 2.0pt minus 4.0pt}
                                  \newcommand{\keephidden}[1]{}           
                                  \usepackage[dvips]{graphicx}
                                  \usepackage{epsfig}';
@@ -1358,7 +1350,7 @@
 	      }
 	      $file=~s/(\.gif|\.jpg)$/\.eps/;
 	      if ($path) {
-		$currentstring = '\graphicspath{{'.$path.'}}\fbox{\includegraphics{'.$file.'}}';
+		$currentstring = '\graphicspath{{'.$path.'/}}\fbox{\includegraphics{'.$file.'}}';
 	      } else {
 		$currentstring = 'See the image at \tt{'.$src.'}';
 	      }
@@ -1522,6 +1514,24 @@
            return $currentstring;
 	}
         sub end_insert {
+	    my ($target,$token) = @_;
+            my $currentstring = '';
+            if ($target eq 'web') {
+	       $currentstring .= '';
+	    }
+           return $currentstring;
+	}
+#-- <externallink>
+	sub start_externallink {
+	    my ($target,$token,$tagstack,$parstack,$parser,$safeeval) = @_;
+            my $currentstring = '';
+            if ($target eq 'web') {
+		my $display = &Apache::lonxml::get_param('display',$parstack,$safeeval);
+	       $currentstring .= '<b>'.$display.'</b>';;
+	    }
+           return $currentstring;
+	}
+        sub end_externallink {
 	    my ($target,$token) = @_;
             my $currentstring = '';
             if ($target eq 'web') {