[LON-CAPA-cvs] cvs: loncom /homework inputtags.pm /localize/localize de.pm

christianto christianto at source.lon-capa.org
Tue Jul 12 08:55:55 EDT 2011


christianto		Tue Jul 12 12:55:55 2011 EDT

  Modified files:              
    /loncom/homework	inputtags.pm 
    /loncom/localize/localize	de.pm 
  Log:
  optimize localization in submission text and tries for pdf and screen output
  
  
Index: loncom/homework/inputtags.pm
diff -u loncom/homework/inputtags.pm:1.291 loncom/homework/inputtags.pm:1.292
--- loncom/homework/inputtags.pm:1.291	Fri Jun 10 17:10:17 2011
+++ loncom/homework/inputtags.pm	Tue Jul 12 12:55:50 2011
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # input  definitons
 #
-# $Id: inputtags.pm,v 1.291 2011/06/10 17:10:17 www Exp $
+# $Id: inputtags.pm,v 1.292 2011/07/12 12:55:50 christianto Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -1436,28 +1436,30 @@
     if ( $tries eq '' ) { $tries = '0'; }
     if ( $maxtries eq '' ) { $maxtries = '2'; } 
     if ( $maxtries eq 'con_lost' ) { $maxtries = '0'; } 
-    my $tries_text= &get_tries_text();;
+    my $tries_text= &get_tries_text();
     if ($showbutton) {
 	if ($target eq 'tex') {
 	    if ($env{'request.state'} ne "construct"
 		&& $Apache::lonhomework::type ne 'exam'
 		&& $env{'form.suppress_tries'} ne 'yes') {
-		$trystr = ' {\vskip 1 mm \small \textit{'.$tries_text.'} '.
-		    $tries.'/'.$maxtries.'} \vskip 2 mm ';
+		$trystr ='{\vskip 1 mm \small '
+                        .&mt('[_1]'.$tries_text.'[_2] [_3]'
+				,'\textit{','}',$tries.'/'.$maxtries ) 
+                        .'} \vskip 2 mm';
 	    } else {
 		$trystr = '\vskip 0 mm ';
 	    }
 	} else {
-	    $trystr = '<td><span class="LC_nobreak">'.&mt($tries_text)." $tries";
+	    my $trial =$tries;
 	    if ($Apache::lonhomework::parsing_a_task) {
 	    } elsif($env{'request.state'} ne 'construct') {
-		$trystr.="/".&Apache::lonhtmlcommon::direct_parm_link($maxtries,$env{'request.symb'},'maxtries',$id,$target);
+		$trial.="/".&Apache::lonhtmlcommon::direct_parm_link($maxtries,$env{'request.symb'},'maxtries',$id,$target);
 	    } else {
 		if (defined($Apache::inputtags::params{'maxtries'})) {
-		    $trystr.="/".$Apache::inputtags::params{'maxtries'};
+		    $trial.="/".$Apache::inputtags::params{'maxtries'};
 		}
 	    }
-	    $trystr.="</span></td>";
+	    $trystr = '<td><span class="LC_nobreak">'.&mt($tries_text.' [_1]',$trial).'</span.</td>';
 	}
     }
 
Index: loncom/localize/localize/de.pm
diff -u loncom/localize/localize/de.pm:1.420 loncom/localize/localize/de.pm:1.421
--- loncom/localize/localize/de.pm:1.420	Fri Jun 10 15:28:50 2011
+++ loncom/localize/localize/de.pm	Tue Jul 12 12:55:55 2011
@@ -1,7 +1,7 @@
 # The LearningOnline Network with CAPA
 # German Localization Lexicon
 #
-# $Id: de.pm,v 1.420 2011/06/10 15:28:50 bisitz Exp $
+# $Id: de.pm,v 1.421 2011/07/12 12:55:55 christianto Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -600,6 +600,12 @@
    'Tries'
 => 'Versuche',
 
+   '[_1]Tries[_2] [_3]'
+=> '[_1]Versuche[_2] [_3]',
+
+   'Tries [_1]'
+=> 'Versuche [_1]',
+
    'Submit Answer'
 => 'Antwort einreichen',
 
@@ -4504,6 +4510,12 @@
    'Submissions'
 => 'Einreichungen',
 
+   '[_1]Submissions[_2] [_3]'
+=> '[_1]Einreichungen[_2] [_3]',
+
+   'Submissions [_1]',
+=> 'Einreichungen [_1]',
+
    'Submit Modifications'
 => 'Veränderungen einreichen',
 




More information about the LON-CAPA-cvs mailing list