r22228 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r22227‎ | r22228 | r22229 >
Date:18:33, 17 May 2007
Author:brion
Status:old
Tags:
Comment:
* Right-align diff line numbers in RTL language display
Use .diff-lineno class instead of hardcoding a <strong> and an alignment. Leaving default alignment does the right thing in both LTR and RTL; forcing left was unnecessary.
Also swapping alignment for the +/- marker column to improve look on RTL.
Modified paths:
  • /trunk/phase3/RELEASE-NOTES (modified) (history)
  • /trunk/phase3/includes/DefaultSettings.php (modified) (history)
  • /trunk/phase3/includes/DifferenceEngine.php (modified) (history)
  • /trunk/phase3/skins/common/diff.css (modified) (history)

Diff [purge]

Index: trunk/phase3/skins/common/diff.css
@@ -11,6 +11,12 @@
1212 td.diff-marker {
1313 text-align: right;
1414 }
 15+.rtl td.diff-marker {
 16+ text-align: left;
 17+}
 18+td.diff-lineno {
 19+ font-weight: bold;
 20+}
1521 td.diff-addedline {
1622 background: #cfc;
1723 font-size: smaller;
Index: trunk/phase3/includes/DifferenceEngine.php
@@ -1734,8 +1734,8 @@
17351735 }
17361736
17371737 function _block_header( $xbeg, $xlen, $ybeg, $ylen ) {
1738 - $r = '<tr><td colspan="2" align="left"><strong><!--LINE '.$xbeg."--></strong></td>\n" .
1739 - '<td colspan="2" align="left"><strong><!--LINE '.$ybeg."--></strong></td></tr>\n";
 1738+ $r = '<tr><td colspan="2" class="diff-lineno"><!--LINE '.$xbeg."--></td>\n" .
 1739+ '<td colspan="2" class="diff-lineno"><!--LINE '.$ybeg."--></td></tr>\n";
17401740 return $r;
17411741 }
17421742
Index: trunk/phase3/includes/DefaultSettings.php
@@ -1125,7 +1125,7 @@
11261126 * to ensure that client-side caches don't keep obsolete copies of global
11271127 * styles.
11281128 */
1129 -$wgStyleVersion = '70';
 1129+$wgStyleVersion = '71';
11301130
11311131
11321132 # Server-side caching:
Index: trunk/phase3/RELEASE-NOTES
@@ -64,6 +64,7 @@
6565 and the dupes removed from the default skin files.
6666 Skins can still override the default rules.
6767 * (bug 1229) Balance columns in diff display evenly
 68+* Right-align diff line numbers in RTL language display
6869
6970
7071 == MediaWiki API changes since 1.10 ==