version 1.166, 2010/08/23 03:57:48
|
version 1.171, 2010/09/01 21:29:51
|
Line 179 ENDTABLE
|
Line 179 ENDTABLE
|
} |
} |
if ($target eq 'tex' and $Apache::lonhomework::type ne 'exam') { |
if ($target eq 'tex' and $Apache::lonhomework::type ne 'exam') { |
if($env{'form.pdfFormFields'} ne 'yes') { |
if($env{'form.pdfFormFields'} ne 'yes') { |
$result .= ' \renewcommand{\labelenumi}{\Alph{enumi}.} |
$result .= ' \begin{itemize} '; |
\begin{enumerate} '; |
|
} else { |
} else { |
$result .= "\\\\"; |
$result .= "\\\\"; |
} |
} |
Line 327 sub end_foilgroup {
|
Line 326 sub end_foilgroup {
|
} |
} |
if ($target eq 'tex' and $Apache::lonhomework::type ne 'exam') { |
if ($target eq 'tex' and $Apache::lonhomework::type ne 'exam') { |
if($env{'form.pdfFormFields'} ne 'yes') { |
if($env{'form.pdfFormFields'} ne 'yes') { |
$result .= '\end{enumerate}'; |
$result .= '\end{itemize}'; |
} else { |
} else { |
$result .= "\\\\"; |
$result .= "\\\\"; |
} |
} |
Line 452 sub displayfoils {
|
Line 451 sub displayfoils {
|
$text='<b>'.$value.':</b> '.$text; |
$text='<b>'.$value.':</b> '.$text; |
} |
} |
} else { |
} else { |
$text='•'.$text; |
if (@whichopt > 1) { |
|
$text='•'.$text; |
|
} |
} |
} |
$result.=$text."\n"; |
$result.=$text."\n"; |
} |
} |
Line 467 sub displayfoils {
|
Line 468 sub displayfoils {
|
my $internal_counter=$Apache::lonxml::counter; |
my $internal_counter=$Apache::lonxml::counter; |
my $checkboxopt=&check_box_opt($target,$checkboxvalue,@opt); |
my $checkboxopt=&check_box_opt($target,$checkboxvalue,@opt); |
if ($checkboxopt) { |
if ($checkboxopt) { |
$result.='<br />'.&mt('Select all that are <b>[_1]</b>.',$checkboxopt); |
$result.='<br />'.&mt('Choices: ').'<b>'.$opt[0].','.$opt[1].'</b>. '. |
|
&mt('Select all that are <b>[_1]</b>.',$checkboxopt); |
} |
} |
foreach $name (@whichopt) { |
foreach $name (@whichopt) { |
my $text=$Apache::response::foilgroup{$name.'.text'}; |
my $text=$Apache::response::foilgroup{$name.'.text'}; |
Line 542 sub displayfoils {
|
Line 544 sub displayfoils {
|
} |
} |
if ($text=~s|<drawoptionlist\s*/>|$optionlist|) { |
if ($text=~s|<drawoptionlist\s*/>|$optionlist|) { |
if ($Apache::lonhomework::type ne 'exam') { |
if ($Apache::lonhomework::type ne 'exam') { |
$text='•'.$text; |
if (@whichopt > 1) { |
|
$text='•'.$text; |
|
} |
} |
} |
} else { |
} else { |
if ($Apache::lonhomework::type ne 'exam') { |
if ($Apache::lonhomework::type ne 'exam') { |
Line 691 sub bubbles {
|
Line 695 sub bubbles {
|
|
|
$current_length += (length($opt[$ind])+length($alphabet[$ind])+4)*2; |
$current_length += (length($opt[$ind])+length($alphabet[$ind])+4)*2; |
if ($current_length<($textwidth-$leftmargin) and $ind!=$number_of_bubbles) { |
if ($current_length<($textwidth-$leftmargin) and $ind!=$number_of_bubbles) { |
$line.='\hskip 1pc {\small \textbf{'.$alphabet[$ind].'}}$\bigcirc$\hskip -1 mm & \hskip -3 mm {\small '.$opt[$ind].'} & '; |
$line.='\hskip 4 mm {\small \textbf{'.$alphabet[$ind].'}}$\bigcirc$\hskip -1 mm & \hskip -3 mm {\small '.$opt[$ind].'} & '; |
$head.='lr'; |
$head.='lr'; |
} else { |
} else { |
$line=~s/\&\s*$//; |
$line=~s/\&\s*$//; |
$result.='\vskip -2 mm\noindent\setlength{\tabcolsep}{2 mm}\begin{tabular}{'.$head.'}'.$line.'\\\\\end{tabular}\vskip 0 mm'; |
$result.='\vskip -1 mm\noindent\setlength{\tabcolsep}{2 mm}\renewcommand{\arraystretch}{1.25}\begin{tabular}{'.$head.'}'.$line.'\\\\\end{tabular}\vskip 0 mm'; |
$line = '\hskip -1 mm {\small \textbf{'.$alphabet[$ind].'}}$\bigcirc$\hskip -1 mm & \hskip -3 mm {\small '.$opt[$ind].'} & ';; |
$line = '\hskip 4 mm {\small \textbf{'.$alphabet[$ind].'}}$\bigcirc$\hskip -1 mm & \hskip -3 mm {\small '.$opt[$ind].'} & ';; |
$head ='lr'; |
$head ='lr'; |
$current_length = (length($opt[$ind])+length($alphabet[$ind]))*2; |
$current_length = (length($opt[$ind])+length($alphabet[$ind]))*2; |
} |
} |