From: Brion Vibber Date: Tue, 15 May 2007 21:24:56 +0000 (+0000) Subject: * (bug 1438) Fix for diff table layout on very wide lines for Gecko and X-Git-Tag: 1.31.0-rc.0~52902 X-Git-Url: https://git.cyclocoop.org/%7B%24www_url%7Dadmin/compta/banques/?a=commitdiff_plain;h=6213efe0173d2561178a30356dc8e071c4b44708;p=lhc%2Fweb%2Fwiklou.git * (bug 1438) Fix for diff table layout on very wide lines for Gecko and Opera-based browsers (incomplete, does not fix KHTML or MSIE) This adds a
inside the for diff content cells, and declares the style for these
s to have overflow: auto. In Gecko (tested Firefox 2.0) and Opera (tested 9.10 and over) this does two things: * The table layout treats the cells as the requested width instead of bloating out to the widest line of content, so the table stays visible on screen * The individual cells that are too long get horizontal scroll bars Unfortunately this doesn't have the hoped-for effects in other tested browsers: * MSIE 7 * Safari 2 * Konqueror 3.5 * iCab 3 But neither has it any ill effects, so... it's a start. There's probably some other way to force the layout algorithm to behave that I haven't quite stumbled on yet... Might have better luck with the fixed table layout option, though that seems less friendly to the little + and - columns. The C++ diff plugins will have to be updated to support this scheme, but no harm will be done if they're not (just they won't do anything new). --- diff --git a/RELEASE-NOTES b/RELEASE-NOTES index f7a391b766..310bd6e35b 100644 --- a/RELEASE-NOTES +++ b/RELEASE-NOTES @@ -58,6 +58,8 @@ it from source control: http://www.mediawiki.org/wiki/Download_from_SVN * (bug 9417) Uploading new versions of images when using Postgres no longer throws warnings. * (bug 9908) Using tsearch2 with Postgres 8.1 no longer gives an error. +* (bug 1438) Fix for diff table layout on very wide lines for Gecko and + Opera-based browsers (incomplete, does not fix KHTML or MSIE) == MediaWiki API changes since 1.10 == diff --git a/includes/DefaultSettings.php b/includes/DefaultSettings.php index 5f4bacf3d3..39fda53652 100644 --- a/includes/DefaultSettings.php +++ b/includes/DefaultSettings.php @@ -1125,7 +1125,7 @@ $wgCacheEpoch = '20030516000000'; * to ensure that client-side caches don't keep obsolete copies of global * styles. */ -$wgStyleVersion = '67'; +$wgStyleVersion = '68'; # Server-side caching: diff --git a/includes/DifferenceEngine.php b/includes/DifferenceEngine.php index af65ce3aaf..7c5518b204 100644 --- a/includes/DifferenceEngine.php +++ b/includes/DifferenceEngine.php @@ -488,10 +488,10 @@ CONTROL; $ntitle = ''.$ntitle.''; } $header = " - +
- - + + "; @@ -1738,17 +1738,17 @@ class TableDiffFormatter extends DiffFormatter # HTML-escape parameter before calling this function addedLine( $line ) { - return ""; + return ""; } # HTML-escape parameter before calling this function deletedLine( $line ) { - return ""; + return ""; } # HTML-escape parameter before calling this function contextLine( $line ) { - return ""; + return ""; } function emptyLine() { diff --git a/skins/monobook/main.css b/skins/monobook/main.css index f5ddfebdae..25a6f3438f 100644 --- a/skins/monobook/main.css +++ b/skins/monobook/main.css @@ -605,6 +605,10 @@ td.diff-context { text-decoration: none; } +table.diff td div { + overflow: auto; +} + /* ** keep the whitespace in front of the ^=, hides rule from konqueror ** this is css3, the validator doesn't like it when validating as css2
{$otitle}{$ntitle}{$otitle}{$ntitle}
+{$line}+
{$line}
-{$line}-
{$line}
{$line}
{$line}