[LON-CAPA-cvs] cvs: loncom /auth lonlogin.pm lonroles.pm /interface loncommon.pm londropadd.pm lonhelp.pm lonmenu.pm lonprintout.pm
www
lon-capa-cvs-allow@mail.lon-capa.org
Tue, 17 Apr 2007 15:45:04 -0000
This is a MIME encoded message
--www1176824704
Content-Type: text/plain
www Tue Apr 17 11:45:04 2007 EDT
Modified files:
/loncom/auth lonlogin.pm lonroles.pm
/loncom/interface loncommon.pm londropadd.pm lonhelp.pm lonmenu.pm
lonprintout.pm
Log:
* increase character contrast by default (white background)
* labels
* fix some &mt()s
* css on roles screen
--www1176824704
Content-Type: text/plain
Content-Disposition: attachment; filename="www-20070417114504.txt"
Index: loncom/auth/lonlogin.pm
diff -u loncom/auth/lonlogin.pm:1.92 loncom/auth/lonlogin.pm:1.93
--- loncom/auth/lonlogin.pm:1.92 Sat Apr 7 15:15:03 2007
+++ loncom/auth/lonlogin.pm Tue Apr 17 11:44:58 2007
@@ -1,7 +1,7 @@
# The LearningOnline Network
# Login Screen
#
-# $Id: lonlogin.pm,v 1.92 2007/04/07 19:15:03 raeburn Exp $
+# $Id: lonlogin.pm,v 1.93 2007/04/17 15:44:58 www Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -484,15 +484,15 @@
<table border=0 cellspacing=0 cellpadding=0>
<tr><td bgcolor="$sidebg" colspan=2><img src="$iconpath/$lt{'auth'}" alt="User Authentication" /></td></tr>
<tr>
- <td bgcolor="$mainbg"><br /><font size=-1><b> $lt{'un'}:</b></font></td>
+ <td bgcolor="$mainbg"><br /><font size=-1><b> <label for="uname">$lt{'un'}</label>:</b></font></td>
<td bgcolor="$mainbg"><br /><input type="text" name="uname" size="10" value="$authusername" /></td>
</tr>
<tr>
- <td bgcolor="$mainbg"><font size=-1><b> $lt{'pw'}:</b></font></td>
+ <td bgcolor="$mainbg"><font size=-1><b> <label for="upass$now">$lt{'pw'}</label>:</b></font></td>
<td bgcolor="$mainbg"><input type="password" name="upass$now" size="10" /></td>
</tr>
<tr>
- <td bgcolor="$mainbg"><font size=-1><b> $lt{'dom'}:</b></font></td>
+ <td bgcolor="$mainbg"><font size=-1><b> <label for="udom">$lt{'dom'}</label>:</b></font></td>
<td bgcolor="$mainbg"><input type="text" name="udom" size="10" value="$authdomain" /></td>
</tr>
<tr>
Index: loncom/auth/lonroles.pm
diff -u loncom/auth/lonroles.pm:1.176 loncom/auth/lonroles.pm:1.177
--- loncom/auth/lonroles.pm:1.176 Fri Mar 2 18:17:48 2007
+++ loncom/auth/lonroles.pm Tue Apr 17 11:44:58 2007
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# User Roles Screen
#
-# $Id: lonroles.pm,v 1.176 2007/03/02 23:17:48 albertel Exp $
+# $Id: lonroles.pm,v 1.177 2007/04/17 15:44:58 www Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -438,18 +438,18 @@
}
# -------------------------------------------------------- Choice or no choice?
if ($nochoose) {
- $r->print("<h2>".&mt('Sorry ...')."</h2>\n".
- &mt('This action is currently not authorized.').
+ $r->print("<h2>".&mt('Sorry ...')."</h2>\n<span class='LC_error'>".
+ &mt('This action is currently not authorized.').'</span>'.
&Apache::loncommon::end_page());
return OK;
} else {
if ($advanced) {
- $r->print(&mt("Your home server is ").
+ $r->print('<span class="LC_rolesinfo">'.&mt("Your home server is ").
&Apache::lonnet::hostname(&Apache::lonnet::homeserver
($env{'user.name'},$env{'user.domain'})).
"<br />\n");
$r->print(&mt(
- "Author and Co-Author roles are not available on servers other than their respective home servers."));
+ "Author and Co-Author roles are not available on servers other than their respective home servers.").'</span>');
}
if (($ENV{'REDIRECT_QUERY_STRING'}) && ($fn)) {
$fn.='?'.$ENV{'REDIRECT_QUERY_STRING'};
@@ -461,9 +461,9 @@
}
if ($env{'user.adv'}) {
$r->print(
- '<br /><label>'.&mt('Show all roles').': <input type="checkbox" name="showall"');
+ '<br /><span class="LC_rolesinfo"><label>'.&mt('Show all roles').': <input type="checkbox" name="showall"');
if ($env{'form.showall'}) { $r->print(' checked="checked" '); }
- $r->print(' /></label><input type="submit" value="'.&mt('Display').'" />');
+ $r->print(' /></label><input type="submit" value="'.&mt('Display').'" /></span>');
}
my (%roletext,%sortrole,%roleclass);
@@ -648,7 +648,7 @@
unless (($advanced) || ($nochoose)) {
$r->print("<h2>".&mt('Select a Course to Enter')."</h2>\n");
}
- $r->print('<br /><table><tr>');
+ $r->print('<br /><table id="LC_rolesmenu"><tr>');
unless ($nochoose) { $r->print('<th> </th>'); }
$r->print('<th>'.&mt('User Role').'</th><th>'.&mt('Extent').
'</th><th>'.&mt('Start').'</th><th>'.&mt('End').'</th></tr>'."\n");
@@ -730,8 +730,8 @@
$r->print('<td> </td>');
}
}
- $r->print('<td colspan="3"><font color="'.$tfont.'">'.&mt('No role specified').
- '</font></td><td><font color="'.$tfont.'">'.$tremark.
+ $r->print('<td colspan="3"><font color="'.$tfont.'"><span class="LC_rolesinfo">'.&mt('No role specified').
+ '</font></span></td><td><font color="'.$tfont.'">'.$tremark.
' </font></td></tr>'."\n");
$r->print('</table>');
@@ -835,7 +835,7 @@
sub build_roletext {
my ($trolecode,$tdom,$trest,$tstatus,$tryagain,$advanced,$tremark,$tbg,$tfont,$trole,$twhere,$tpstart,$tpend,$nochoose,$button,$switchserver) = @_;
- my $roletext='<tr bgcolor="'.$tbg.'">';
+ my $roletext='<tr bgcolor="'.$tbg.'" class="LC_rolesmenu_'.$tstatus.'">';
my $is_dc=($trolecode =~ m/^dc\./);
my $rowspan=($is_dc) ? ''
: ' rowspan="2" ';
@@ -845,8 +845,8 @@
$buttonname=~s/\W//g;
if (!$button) {
if ($switchserver) {
- $roletext.='<td'.$rowspan.'><a href="/adm/switchserver?'.
- $switchserver.'">'.&mt('Switch Server').'</a></td>';
+ $roletext.='<td'.$rowspan.'><span class="LC_rolesinfo"><a href="/adm/switchserver?'.
+ $switchserver.'">'.&mt('Switch Server').'</a></span></td>';
} else {
$roletext.=('<td'.$rowspan.'> </td>');
}
@@ -878,8 +878,8 @@
'</font></td><td><font color="'.$tfont.'">'.$tpend.
'</font></td></tr>';
if (!$is_dc) {
- $roletext.='<tr bgcolor="'.$tbg.'"><td colspan="4"><font color="'.$tfont.'">'.$tremark.
- ' </font></td></tr><tr><td colspan="5" height="3"></td></tr>'."\n";
+ $roletext.='<tr bgcolor="'.$tbg.'"><td colspan="4"><font color="'.$tfont.'"><span class="LC_rolesinfo">'.$tremark.
+ '</span> </font></td></tr><tr><td colspan="5" height="3"></td></tr>'."\n";
}
return $roletext;
}
@@ -1032,10 +1032,9 @@
' <td colspan="5">';
my $selectlink = &courselink($dcdom,$rowtype);
my $ccrole = &Apache::lonnet::plaintext('cc');
- $output.= '<font color="#002200">'.$ccrole.'</font>'.
- ' <b>'.$selectlink.'</b>'.
- ' from '.&mt('Domain').' '.$dcdom.'<br />';
- $output .= '</tr><tr><td colspan="5" height="3"></td></tr>'."\n";
+ $output.= '<span class="LC_rolesinfo">'.
+ &mt('[_1]: [_2] from domain [_3]',$ccrole,$selectlink,$dcdom).
+ '</span><br /></tr><tr><td colspan="5" height="3"></td></tr>'."\n";
return $output;
}
Index: loncom/interface/loncommon.pm
diff -u loncom/interface/loncommon.pm:1.525 loncom/interface/loncommon.pm:1.526
--- loncom/interface/loncommon.pm:1.525 Mon Apr 16 19:25:04 2007
+++ loncom/interface/loncommon.pm Tue Apr 17 11:45:02 2007
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# a pile of common routines
#
-# $Id: loncommon.pm,v 1.525 2007/04/16 23:25:04 albertel Exp $
+# $Id: loncommon.pm,v 1.526 2007/04/17 15:45:02 www Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -240,7 +240,7 @@
formname and elementname specify the name of the html form and the name
of the element the selection from the search results will be placed in.
-
+=back
=cut
sub browser_and_searcher_javascript {
@@ -3375,7 +3375,7 @@
my $pgbg = $bgcolor || &designparm($function.'.pgbg',$domain);
my %design = ( 'style' => 'margin-top: 0px',
- 'bgcolor' => $pgbg,
+ 'bgcolor' => '#ffffff',
'text' => $font,
'alink' => &designparm($function.'.alink',$domain),
'vlink' => &designparm($function.'.vlink',$domain),
@@ -3786,7 +3786,7 @@
}
table#LC_menubuttons_mainmenu {
- background: $pgbg;
+ width: 100%;
border: 0px;
border-spacing: 1px;
padding: 0px 1px;
@@ -3851,20 +3851,27 @@
font-size: smaller;
}
+.LC_menubuttons_link {
+ text-decoration: none;
+}
+
.LC_menubuttons_category {
color: $font;
+ background: $pgbg;
font-family: $sans;
font-size: larger;
font-weight: bold;
}
td.LC_menubuttons_text {
+ width: 90%;
color: $font;
font-family: $sans;
}
+
td.LC_menubuttons_img {
- background: $tabbg;
}
+
.LC_current_location {
font-family: $sans;
background: $tabbg;
@@ -3874,6 +3881,35 @@
font-weight: bold;
}
+.LC_rolesmenu_is {
+ font-family: $sans;
+}
+
+.LC_rolesmenu_selected {
+ font-family: $sans;
+}
+
+.LC_rolesmenu_future {
+ font-family: $sans;
+}
+
+
+.LC_rolesmenu_will {
+ font-family: $sans;
+}
+
+.LC_rolesmenu_will_not {
+ font-family: $sans;
+}
+
+.LC_rolesmenu_expired {
+ font-family: $sans;
+}
+
+.LC_rolesinfo {
+ font-family: $sans;
+}
+
table.LC_aboutme_port {
border: 0px;
border-collapse: collapse;
Index: loncom/interface/londropadd.pm
diff -u loncom/interface/londropadd.pm:1.157 loncom/interface/londropadd.pm:1.158
--- loncom/interface/londropadd.pm:1.157 Fri Mar 2 20:40:28 2007
+++ loncom/interface/londropadd.pm Tue Apr 17 11:45:03 2007
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# Handler to drop and add students in courses
#
-# $Id: londropadd.pm,v 1.157 2007/03/03 01:40:28 albertel Exp $
+# $Id: londropadd.pm,v 1.158 2007/04/17 15:45:03 www Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -949,9 +949,9 @@
<input type="hidden" name="state" value="gotusername" />
<h3>$lt{'eos'}</h3>
<table>
-<tr><th>$lt{'usr'}:</th>
+<tr><th><label for="cuname">$lt{'usr'}</label>:</th>
<td><input type="text" name="cuname" size="15" /></td></tr>
-<tr><th>$lt{'dom'}:</th>
+<tr><th><label for="cudomain">$lt{'dom'}</label>:</th>
<td>$domform</td></tr>
<tr><th> </th>
<td>
@@ -1022,17 +1022,17 @@
$user_data_html = <<END;
<h3>$lt{'udf'} $username\@$domain</h3>
<table>
-<tr><th>$lt{'fn'}:</th>
+<tr><th><label for="cfirst">$lt{'fn'}</label>:</th>
<td><input type="text" name="cfirst" size="15"></td></tr>
-<tr><th>$lt{'mn'}:</th>
+<tr><th><label for="cmiddle">$lt{'mn'}</label>:</th>
<td><input type="text" name="cmiddle" size="15"></td></tr>
-<tr><th>$lt{'ln'}:</th>
+<tr><th><label for="clast">$lt{'ln'}</label>:</th>
<td><input type="text" name="clast" size="15"></td></tr>
-<tr><th>$lt{'gen'}:</th>
+<tr><th><label for="cgen">$lt{'gen'}</label>:</th>
<td><input type="text" name="cgen" size="5"> </td></tr>
-<tr><th>$lt{'hs'}:</th>
+<tr><th><label for="lcserver">$lt{'hs'}</label>:</th>
<td>$homeserver_form</td></tr>
-<tr><th>$lt{'mail'}:</th>
+<tr><th><label for="emailaddress">$lt{'mail'}</label>:</th>
<td><input type="text" name="emailaddress" size="20" /></td></tr>
</table>
<h3>$lt{'pswd'}</h3>
@@ -1062,23 +1062,23 @@
<h3>$lt{'udf'} $username\@$domain</h3>
<input type="hidden" name="lcserver" value="default" />
<table>
-<tr><th>$lt{'fn'}:</th>
+<tr><th><label for="cfirst">$lt{'fn'}</label>:</th>
<td>
<input type="text" name="cfirst" value="$uenv{'firstname'}" size="15" />
</td></tr>
-<tr><th>$lt{'mn'}:</th>
+<tr><th><label for="cmiddle">$lt{'mn'}</label>:</th>
<td>
<input type="text" name="cmiddle" value="$uenv{'middlename'}" size="15" />
</td></tr>
-<tr><th>$lt{'ln'}:</th>
+<tr><th><label for="clast">$lt{'ln'}</label>:</th>
<td>
<input type="text" name="clast"value="$uenv{'lastname'}" size="15" />
</td></tr>
-<tr><th>$lt{'gen'}:</th>
+<tr><th><label for="cgen">$lt{'gen'}</label>:</th>
<td>
<input type="text" name="cgen" value="$uenv{'generation'}" size="5" />
</td></tr>
-<tr><th>$lt{'mail'}:</th>
+<tr><th><label for="emailaddress">$lt{'mail'}</label>:</th>
<td>
<input type="text" name="emailaddress" value="$uenv{'permanentemail'}" size="20" />
</td></tr>
Index: loncom/interface/lonhelp.pm
diff -u loncom/interface/lonhelp.pm:1.34 loncom/interface/lonhelp.pm:1.35
--- loncom/interface/lonhelp.pm:1.34 Fri Dec 1 16:47:25 2006
+++ loncom/interface/lonhelp.pm Tue Apr 17 11:45:03 2007
@@ -1,6 +1,6 @@
# The LearningOnline Network with CAPA
#
-# $Id: lonhelp.pm,v 1.34 2006/12/01 21:47:25 albertel Exp $
+# $Id: lonhelp.pm,v 1.35 2007/04/17 15:45:03 www Exp $
#
# .tex help system web server handler
#
@@ -81,7 +81,7 @@
my $uri = $r->uri;
$r->print(<<FOOTER);
<hr /><form action="$uri" method="post">
-$search: <input type="text" name="searchterm" size="40" /><input type="submit" value="$query" />
+<label>$search: <input type="text" name="searchterm" size="40" /></label><input type="submit" value="$query" />
</form>
<br />
$bugs
Index: loncom/interface/lonmenu.pm
diff -u loncom/interface/lonmenu.pm:1.214 loncom/interface/lonmenu.pm:1.215
--- loncom/interface/lonmenu.pm:1.214 Fri Apr 13 16:22:15 2007
+++ loncom/interface/lonmenu.pm Tue Apr 17 11:45:03 2007
@@ -1,7 +1,7 @@
# The LearningOnline Network with CAPA
# Routines to control the menu
#
-# $Id: lonmenu.pm,v 1.214 2007/04/13 20:22:15 albertel Exp $
+# $Id: lonmenu.pm,v 1.215 2007/04/17 15:45:03 www Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -866,19 +866,19 @@
$inlineremote[$idx]="\n<tr>".
'<td class="LC_menubuttons_img" align="left">'.
'<a href="javascript:'.$act.';">'.$pic.'</a></td>
- <td class="LC_menubuttons_text" align="left">'.$text.'</td>';
+ <td class="LC_menubuttons_text" align="left"><a class="LC_menubuttons_link" href="javascript:'.$act.';"><span class="LC_menubuttons_inline_text">'.$text.'</span></a></td>';
} else {
$inlineremote[$idx]="\n<tr>".
'<td class="LC_menubuttons_img" align="left">'.
'<a href="javascript:'.$act.';">'.$pic.
'</a></td><td class="LC_menubuttons_text" colspan="3">'.
- $desc.'</td></tr>';
+ '<a class="LC_menubuttons_link" href="javascript:'.$act.';"><span class="LC_menubuttons_inline_text">'.$desc.'</span></a></td></tr>';
}
} else {
# Inline Menu
$inlineremote[$idx]=
- '<a href="javascript:'.$act.';">'.$pic.
- '</a><span class="LC_menubuttons_inline_text">'.$desc.'</span>';
+ '<a class="LC_menubuttons_link" href="javascript:'.$act.';">'.$pic.
+ '<span class="LC_menubuttons_inline_text">'.$desc.'</span></a>';
}
}
return '';
Index: loncom/interface/lonprintout.pm
diff -u loncom/interface/lonprintout.pm:1.496 loncom/interface/lonprintout.pm:1.497
--- loncom/interface/lonprintout.pm:1.496 Mon Jan 22 05:38:32 2007
+++ loncom/interface/lonprintout.pm Tue Apr 17 11:45:03 2007
@@ -2,7 +2,7 @@
# The LearningOnline Network
# Printout
#
-# $Id: lonprintout.pm,v 1.496 2007/01/22 10:38:32 foxr Exp $
+# $Id: lonprintout.pm,v 1.497 2007/04/17 15:45:03 www Exp $
#
# Copyright Michigan State University Board of Trustees
#
@@ -2798,7 +2798,10 @@
if (($perm{'pav'} and &Apache::lonnet::allowed('vgr',$env{'request.course.id'})) or
($helper->{VARS}->{'construction'} eq '1')) {
- addMessage("<hr width='33%' /><table><tr><td align='right'>Print: </td><td>");
+ addMessage("<hr width='33%' /><table><tr><td align='right'>".
+ '<label for="ANSWER_TYPE_forminput">'.
+ &mt('Print').
+ "</label>: </td><td>");
$paramHash = Apache::lonhelper::getParamHash();
$paramHash->{'variable'} = 'ANSWER_TYPE';
$helper->declareVar('ANSWER_TYPE');
@@ -2814,10 +2817,16 @@
if ($perm{'pav'}) {
if (!$startedTable) {
- addMessage("<hr width='33%' /><table><tr><td align='right'>LaTeX mode: </td><td>");
+ addMessage("<hr width='33%' /><table><tr><td align='right'>".
+ '<label for="LATEX_TYPE_forminput">'.
+ &mt('LaTeX mode').
+ "</label>: </td><td>");
$startedTable = 1;
} else {
- addMessage("<tr><td align='right'>LaTeX mode: </td><td>");
+ addMessage("<tr><td align='right'>".
+ '<label for="LATEX_TYPE_forminput">'.
+ &mt('LaTeX mode').
+ "</label>: </td><td>");
}
$paramHash = Apache::lonhelper::getParamHash();
$paramHash->{'variable'} = 'LATEX_TYPE';
@@ -2833,7 +2842,10 @@
}
Apache::lonhelper::dropdown->new();
- addMessage("</td></tr><tr><td align='right'>Print Table of Contents: </td><td>");
+ addMessage("</td></tr><tr><td align='right'>".
+ '<label="TABLE_CONTENTS_forminput">'.
+ &mt('Print Table of Contents').
+ "</label>: </td><td>");
$paramHash = Apache::lonhelper::getParamHash();
$paramHash->{'variable'} = 'TABLE_CONTENTS';
$helper->declareVar('TABLE_CONTENTS');
@@ -2844,7 +2856,10 @@
addMessage("</td></tr>");
if (not $helper->{VARS}->{'construction'}) {
- addMessage("<tr><td align='right'>Print Index: </td><td>");
+ addMessage("<tr><td align='right'>".
+ '<label for="TABLE_INDEX_forminput">'.
+ &mt('Print Index').
+ "</label>: </td><td>");
$paramHash = Apache::lonhelper::getParamHash();
$paramHash->{'variable'} = 'TABLE_INDEX';
$helper->declareVar('TABLE_INDEX');
@@ -2853,7 +2868,10 @@
['Yes', 'yes'] ];
Apache::lonhelper::dropdown->new();
addMessage("</td></tr>");
- addMessage("<tr><td align='right'>Print Discussions: </td><td>");
+ addMessage("<tr><td align='right'>".
+ '<label for="PRINT_DISCUSSIONS_forminput">'.
+ &mt('Print Discussions').
+ "</label>: </td><td>");
$paramHash = Apache::lonhelper::getParamHash();
$paramHash->{'variable'} = 'PRINT_DISCUSSIONS';
$helper->declareVar('PRINT_DISCUSSIONS');
@@ -2875,14 +2893,21 @@
if ($helper->{'VARS'}->{'construction'}) {
my $stylevalue=$env{'construct.style'};
+ my $randseedtext=&mt("Use random seed");
+ my $stylefiletext=&mt("Use style file");
+
my $xmlfrag .= <<"RNDSEED";
- <message><tr><td align='right'>Use random seed: </td><td></message>
+ <message><tr><td align='right'>
+ <label for="curseed_forminput">$randseedtext</label>:
+ </td><td></message>
<string variable="curseed" size="15" maxlength="15">
<defaultvalue>
return $helper->{VARS}->{'curseed'};
</defaultvalue>
</string>
- <message></td></tr><tr><td align="right">Use style file:</td><td></message>
+ <message></td></tr><tr><td align="right">
+ <label for="style_file_value">$stylefiletext</label>:
+ </td><td></message>
<message><input type="text" size="40" name="style_file_value" value="$stylevalue" /> <a href="javascript:openbrowser('helpform','style_file_value','sty')">Select style file</a> </td><tr><td></message>
<choices allowempty="1" multichoice="true" variable="showallfoils">
<choice computer="1">Show all foils?</choice>
--www1176824704--