From: Aryeh Gregor Date: Thu, 9 Nov 2006 07:06:58 +0000 (+0000) Subject: Fix regression in usability per . Document structure tweaked so that tags once more contain only the header text and not the section edit links. --- diff --git a/includes/DefaultSettings.php b/includes/DefaultSettings.php index a78f6f959e..9e2ce25d38 100644 --- a/includes/DefaultSettings.php +++ b/includes/DefaultSettings.php @@ -1037,7 +1037,7 @@ $wgCacheEpoch = '20030516000000'; * to ensure that client-side caches don't keep obsolete copies of global * styles. */ -$wgStyleVersion = '24'; +$wgStyleVersion = '25'; # Server-side caching: diff --git a/includes/Parser.php b/includes/Parser.php index 336b6f8f32..36e112a2b1 100644 --- a/includes/Parser.php +++ b/includes/Parser.php @@ -3520,7 +3520,7 @@ class Parser $toc .= $sk->tocLine($anchor, $tocline, $numbering, $toclevel); } # give headline the correct tag - @$head[$headlineCount] .= "
"; if( $showEditLink && ( !$istemplate || $templatetitle !== "" ) ) { if ( empty( $head[$headlineCount] ) ) { @@ -3531,11 +3531,10 @@ class Parser else $head[$headlineCount] .= $sk->editSectionLink($this->mTitle, $sectionCount+1, $headline_hint); } - // Yes, the headline logically goes before the edit section. Why isn't it there - // in source? Ask the CSS people. The float gets screwed up if you do that. - // This might be moved to before the editsection at some point so that it will - // display a bit more prettily without CSS, so please don't rely on the order. - $head[$headlineCount] .= ' '.$headline.''; + // Yes, the headline logically goes before the edit section. It can't + // be put there, however, because of bugs in IE's and Firefox's float + // rendering. See . + $head[$headlineCount] .= "
"; $headlineCount++; if( !$istemplate ) diff --git a/includes/Skin.php b/includes/Skin.php index 0f9ca2ca67..94766455ee 100644 --- a/includes/Skin.php +++ b/includes/Skin.php @@ -763,7 +763,7 @@ END; function pageTitle() { global $wgOut; - $s = '

' . htmlspecialchars( $wgOut->getPageTitle() ) . '

'; + $s = '

' . htmlspecialchars( $wgOut->getPageTitle() ) . '

'; return $s; } diff --git a/skins/MonoBook.php b/skins/MonoBook.php index 4322e0dc74..9837fd21a8 100644 --- a/skins/MonoBook.php +++ b/skins/MonoBook.php @@ -95,7 +95,7 @@ class MonoBookTemplate extends QuickTemplate {
data['sitenotice']) { ?>
html('sitenotice') ?>
-

data['displaytitle']!=""?$this->html('title'):$this->text('title') ?>

+

data['displaytitle']!=""?$this->html('title'):$this->text('title') ?>

msg('tagline') ?>

html('subtitle') ?>
diff --git a/skins/common/cologneblue.css b/skins/common/cologneblue.css index 5b6e5bca1a..4b2e1ea709 100644 --- a/skins/common/cologneblue.css +++ b/skins/common/cologneblue.css @@ -78,8 +78,7 @@ h1 { font-family: Verdana, Arial, sans-serif; font-size: 180%; line-height: 21pt; } -h1 .editsection { font-size: 55.6%; } -h1.pagetitle { padding-bottom: 0; margin-bottom: 0; } +.mw-first-heading { padding-bottom: 0; margin-bottom: 0; } #article p.subtitle { color: #666666; font-size: 11pt; font-weight: bold; padding-top: 0; margin-top: 0; padding-bottom: 1ex; @@ -91,6 +90,6 @@ a:visited { color: #8D0749; } a.printable { text-decoration: underline; } a.stub, #quickbar a.stub { color:#772233; text-decoration:none; } a.new, #quickbar a.new { color: #CC2200; } -h2, h3, h4, h5, h6 { margin-bottom: 0; } +.mw-h1, .mw-h2, .mw-h3, .mw-h4, .mw-h5, .mw-h6 { margin-bottom: 0; } small { font-size: 75%; } input.mw-searchInput { width: 106px; } \ No newline at end of file diff --git a/skins/common/common.css b/skins/common/common.css index 3d4bc5edcc..fb722e7cd9 100644 --- a/skins/common/common.css +++ b/skins/common/common.css @@ -3,29 +3,21 @@ * This file contains CSS settings common to Wikistandard, Nostalgia and CologneBlue */ -/* For clarity, explicitly state some recommendations from to make sure the editsection links scale right */ +/* Header margin values from . + Frankly they're quite stupid and I have no idea if they're actually used, + but that's life. */ +.mw-h1 { margin: 1.33em 0 } +.mw-h2 { margin: 1.25em 0 } +.mw-h3 { margin: 0.97em 0 } +.mw-h4 { margin: 1.12em 0 } +.mw-h5 { margin: 1.25em 0 } +.mw-h6 { margin: 1.25em 0 } +h1, h2, h3, h4, h5, h6 { display: inline; padding: 0; margin: 0; } -h1 { font-size: 2em; } -h2 { font-size: 1.5em; } -h3 { font-size: 1.17em; } -h5 { font-size: .83em; } -h6 { font-size: .75em; } -h1, h2, h3, h4, h5, h6 { font-weight: bolder } - -/* Now the custom parts */ - -/* Make edit sections (which are inside h# tags) normal-sized */ .editsection { - font-weight: normal; float: right; margin-left: 5px; } -h1 .editsection { font-size: 50% } -h2 .editsection { font-size: 66.7% } -h3 .editsection { font-size: 85.5% } -h5 .editsection { font-size: 120% } -h6 .editsection { font-size: 133% } #footer { clear: both } /* images */ diff --git a/skins/common/commonPrint.css b/skins/common/commonPrint.css index 314ff5543e..4429e5de33 100644 --- a/skins/common/commonPrint.css +++ b/skins/common/commonPrint.css @@ -134,9 +134,6 @@ h1, h2, h3, h4, h5, h6 { font-weight: bold; } -.editsection { - font-weight: normal; -} p, .documentDescription { margin: 1em 0 ! important; diff --git a/skins/common/nostalgia.css b/skins/common/nostalgia.css index c9b36a70b0..4d5ec7e133 100644 --- a/skins/common/nostalgia.css +++ b/skins/common/nostalgia.css @@ -9,8 +9,8 @@ body { a.interwiki, a.external { color: #3366BB; } a.printable { text-decoration: underline; } a.stub { color:#772233; text-decoration:none; } -h1.pagetitle { padding-top: 0; margin-top: 0; padding-bottom: 0; margin-bottom: 0; } -h2, h3, h4, h5, h6 { margin-bottom: 0; } +.mw-first-heading { padding-top: 0; margin-top: 0; padding-bottom: 0; margin-bottom: 0; } +.mw-h1, .mw-h2, .mw-h3, .mw-h4, .mw-h5, .mw-h6 { margin-bottom: 0; } textarea { overflow: auto; } p.subtitle { padding-top: 0; margin-top: 0; } diff --git a/skins/common/wikistandard.css b/skins/common/wikistandard.css index 532e4fdca8..169fa30be6 100644 --- a/skins/common/wikistandard.css +++ b/skins/common/wikistandard.css @@ -25,20 +25,15 @@ form.inline { display: inline; } textarea { overflow: auto; } -h1.pagetitle { padding-top: 0; margin-top: 0; padding-bottom: 0; margin-bottom: 0; -font-size:150%; } -h1.pagetitle .editsection { font-size: 66.7%; } +.mw-first-heading { padding-top: 0; margin-top: 0; padding-bottom: 0; margin-bottom: 0; } +.mw-first-heading h1 { font-size: 1.5em; } +.mw-h1, .mw-h2, .mw-h3, .mw-h4, .mw-h5, .mw-h6 { margin-bottom: 0;} +h1, h2, h3, h4, h5, h6 { margin: 0; padding: 0; display: inline; } h2 { font-size: 120%; } -h2 .editsection { font-size: 83.3%; } -h2, h3, h4, h5, h6 { margin-bottom: 0;} h3 { font-size: 106.25%; } -h3 .editsection { font-size: 94.1%; } h4 { font-size: 103.125%; } -h4 .editsection { font-size: 97.0%; } h5 { font-size: 100%; } -h5 .editsection { font-size: 100%; } h6 { font-size: 95%; } -h6 .editsection { font-size: 105.3%; } hr.sep { color:gray;height:1px;background-color:gray;} p.subpages { font-size:small;} p.subtitle { padding-top: 0; margin-top: 0;} diff --git a/skins/monobook/main.css b/skins/monobook/main.css index 8c065b240c..9647826075 100644 --- a/skins/monobook/main.css +++ b/skins/monobook/main.css @@ -110,30 +110,29 @@ hr { } h1, h2, h3, h4, h5, h6 { + display: inline; color: black; background: none; - font-weight: normal; margin: 0; - padding-top: .5em; - padding-bottom: .17em; - border-bottom: 1px solid #aaa; + padding: 0; +} +h1, h2 { + font-weight: normal; } h1 { font-size: 188%; } -h1 .editsection { font-size: 53%; } h2 { font-size: 150%; } -h2 .editsection { font-size: 67%; } -h3, h4, h5, h6 { - border-bottom: none; - font-weight: bold; -} h3 { font-size: 132%; } -h3 .editsection { font-size: 76%; font-weight: normal; } h4 { font-size: 116%; } -h4 .editsection { font-size: 86%; font-weight: normal; } h5 { font-size: 100%; } -h5 .editsection { font-weight: normal; } h6 { font-size: 80%; } -h6 .editsection { font-size: 125%; font-weight: normal; } +.mw-h1 { padding-top: .94em; padding-bottom: .32em; } +.mw-h2 { padding-top: .75em; padding-bottom: .26em; } +.mw-h3 { padding-top: .66em; padding-bottom: .22em; } +.mw-h4 { padding-top: .58em; padding-bottom: .20em; } +.mw-h5 { padding-top: .50em; padding-bottom: .17em; } +.mw-h6 { padding-top: .40em; padding-bottom: .14em; } +.mw-h1, .mw-h2 { border-bottom: 1px solid #aaa; } +.mw-first-heading { margin-bottom: .1em; } .editsection { float: right; @@ -256,9 +255,6 @@ span.subpages { #bodyContent h3, #bodyContent h4, #bodyContent h5 { margin-bottom: .3em; } -.firstHeading { - margin-bottom: .1em; -} /* user notification thing */ .usermessage {