Diff for /loncom/homework/edit.pm between versions 1.11 and 1.12

version 1.11, 2001/06/16 18:35:27 version 1.12, 2001/06/16 20:33:33
Line 44  sub tag_end { Line 44  sub tag_end {
     } else {      } else {
       if ($description ne '') { $result.="</td></tr><tr><td>$description"; }        if ($description ne '') { $result.="</td></tr><tr><td>$description"; }
     }      }
     $result.="</td><td>&nbsp;</td><td>&nbsp;</td></tr>".&end_table()."\n";      $result.="</tr>".&end_table()."\n";
   }    }
   return $result;    return $result;
 }  }
Line 64  sub start_table { Line 64  sub start_table {
     $color = $Apache::edit::colorlist[$Apache::edit::colordepth];      $color = $Apache::edit::colorlist[$Apache::edit::colordepth];
   }    }
   $Apache::edit::colordepth++;    $Apache::edit::colordepth++;
   my $result="<table bgcolor=\"$color\" width=\"100%\" border=\"10\">";    my $result="<table bgcolor=\"$color\" width=\"100%\" border=\"5\">";
   return $result;    return $result;
 }  }
   
Line 191  sub insert_startouttext { Line 191  sub insert_startouttext {
   return "\n<startouttext />\n<endouttext />";    return "\n<startouttext />\n<endouttext />";
 }  }
   
   # Returns a 1 if the toekn has been modified and you should rebuild the tag
   # side-effects, will modify the $token if new values are found
   sub get_new_args {
     my ($token,$parstack,$safeeval,@args)=@_;
     my $rebuild=0;
     foreach my $arg (@args) {
       my $value=&Apache::lonxml::get_param($arg,$parstack,$safeeval);
       my $newvalue=$ENV{"form.$Apache::lonxml::curdepth.$arg"};
       &Apache::lonxml::debug(" for:$arg: cur is :$value: new is :$newvalue:");
       if ($value ne $newvalue) {
         $token->[2]->{$arg}=$newvalue;
         $rebuild=1;
       }
     }
     return $rebuild;
   }
   
   sub rebuild_tag {
     my ($token) = @_;
     my $result;
     if ($token->[0] eq 'S') {
       $result = '<'.$token->[1];
       while (my ($key,$val)= each(%{$token->[2]})) {
         &Apache::lonxml::debug("setting :$key: to  :$val:");
         $result.=' '.$key.'="'.$val.'"';
       }
       $result.=">";
     } elsif ( $token->[0] eq 'E' ) {
       $result = '</'.$token->[1].'>';
     }
     return $result;
   }
 1;  1;
 __END__  __END__

Removed from v.1.11  
changed lines
  Added in v.1.12


FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>