r54806 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r54805‎ | r54806 | r54807 >
Date:19:22, 11 August 2009
Author:tparscal
Status:resolved (Comments)
Tags:
Comment:
When the text size is set in the body in EM, it affects all other em measurements, however if it's set in px it is both properly calculated on different screens (as oposed to pt in some cases) and does not distort the em calculations that follow. This is the best cross browser solution I have found so far, and fixes bug #20175.
Modified paths:
  • /trunk/phase3/skins/vector/main-ltr.css (modified) (history)
  • /trunk/phase3/skins/vector/main-rtl.css (modified) (history)

Diff [purge]

Index: trunk/phase3/skins/vector/main-ltr.css
@@ -21,7 +21,7 @@
2222 margin: 0;
2323 padding: 0;
2424 font-family: sans-serif;
25 - font-size: 0.9em;
 25+ font-size: 13px;
2626 }
2727 body {
2828 background-color: #f3f3f3;
@@ -652,8 +652,7 @@
653653 border: 1px dashed #2f6fab;
654654 color: black;
655655 background-color: #f9f9f9;
656 - line-height: 1.2em;
657 - font-size: 1.2em;
 656+ line-height: 1.1em;
658657 }
659658 ul {
660659 line-height: 1.5em;
Index: trunk/phase3/skins/vector/main-rtl.css
@@ -21,7 +21,7 @@
2222 margin: 0;
2323 padding: 0;
2424 font-family: sans-serif;
25 - font-size: 0.9em;
 25+ font-size: 13px;
2626 }
2727 body {
2828 background-color: #f3f3f3;
@@ -652,8 +652,7 @@
653653 border: 1px dashed #2f6fab;
654654 color: black;
655655 background-color: #f9f9f9;
656 - line-height: 1.2em;
657 - font-size: 1.2em;
 656+ line-height: 1.1em;
658657 }
659658 ul {
660659 line-height: 1.5em;

Follow-up revisions

RevisionCommit summaryAuthorDate
r54820Vector fixes from trunk:...brion22:40, 11 August 2009
r55333Bug #20175 identifies some rendering artifacts which started popping up when ...tparscal18:19, 19 August 2009

Comments

#Comment by Simetrical (talk | contribs)   17:00, 16 August 2009

px, pt, etc. are bad for accessibility in IE, at least before IE8 or so. IE doesn't allow the user's font size changes to affect px/pt/etc. sizes, only em sizes. Thus only em should ever be used for font size.

I don't understand what problem you were trying to fix here. The em value for descendants will be relative to the computed value that was inherited. Whether it was specified in em or px should be irrelevant.

#Comment by Brion VIBBER (talk | contribs)   01:11, 19 August 2009

This is a serious regression, breaking user customizability of font sizes.

#Comment by Werdna (talk | contribs)   16:55, 27 August 2009

Seems to be reverted on SVN HEAD.

Status & tagging log