--- loncom/homework/edit.pm 2004/03/30 08:20:49 1.81 +++ loncom/homework/edit.pm 2004/06/03 16:42:02 1.82 @@ -1,7 +1,7 @@ # The LearningOnline Network with CAPA # edit mode helpers # -# $Id: edit.pm,v 1.81 2004/03/30 08:20:49 albertel Exp $ +# $Id: edit.pm,v 1.82 2004/06/03 16:42:02 www Exp $ # # Copyright Michigan State University Board of Trustees # @@ -25,9 +25,7 @@ # # http://www.lon-capa.org/ # -# 3/20 Guy -# 01/10/02 Matthew -# 03/06/02 Matthew + package Apache::edit; use strict; @@ -486,15 +484,21 @@ END } sub editfield { - my ($tag,$data,$description,$minwidth,$minheight)=@_; + my ($tag,$data,$description,$minwidth,$minheight,$usehtmlarea)=@_; my ($rows,$cols)=&textarea_sizes(\$data); + $rows+=3; # make room for HTMLarea if ($cols > 80) { $cols = 80; } if ($cols < $minwidth ) { $cols = $minwidth; } if ($rows < $minheight) { $rows = $minheight; } if ($description) { $description="
".$description."
"; } + if ($usehtmlarea) { + push @Apache::lonxml::htmlareafields,'homework_edit_'. + $Apache::lonxml::curdepth; + } return $description."\n".'   '."\n"; }