Last modified: 2010-09-16 19:13:56 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T2008, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 8 - Option: Change the background color (texvc)
Option: Change the background color (texvc)
Status: RESOLVED FIXED
Product: MediaWiki extensions
Classification: Unclassified
Math (Other open bugs)
unspecified
All All
: Normal enhancement with 4 votes (vote)
: ---
Assigned To: Nobody - You can work on this!
:
: 3160 6954 9341 15462 16382 19181 (view as bug list)
Depends on:
Blocks: 22112
  Show dependency treegraph
 
Reported: 2004-08-10 16:43 UTC by xmlizer
Modified: 2010-09-16 19:13 UTC (History)
13 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description xmlizer 2004-08-10 16:43:52 UTC
Now that the wiki try to colorize itself, it is the time for most of the
software to synchronize with this fact.
So it will be good to have an option (may be global) to set that the background
color is some special color and in particular "TRANSPARENT"
Comment 1 Brion Vibber 2004-08-20 00:55:35 UTC
This would be problematic for a number of reasons, chiefly that when the style sheet is overridden by the user, the 
text color in the images will not change. This can lead to black-on-black text for some users using high-contrast 
settings, which will not be very helpful.

Also some browsers print transparent images with black backgrounds. (IE on Macintosh is one, IIRC).
Comment 2 xmlizer 2004-08-20 07:36:53 UTC
I know...that's why it has been proposed as optional!
May be could we set by default in CSS something like
 
 img { background-color : white; }

which could easily be commented out !!!
Comment 3 Brion Vibber 2004-08-20 07:38:23 UTC
That would not solve the printing problem, nor browser settings that override all stylesheets.
Comment 4 Antoine "hashar" Musso (WMF) 2005-01-20 08:11:48 UTC
Will not implement it as per brion comment.

One can edit the persite stylesheet in Mediawiki:monobook.css
or its user stylesheet in User:Name/monobook.css
Comment 5 River Tarnell 2005-05-22 16:15:31 UTC
CLOSED 
Comment 6 Brion Vibber 2005-08-17 00:33:08 UTC
*** Bug 3160 has been marked as a duplicate of this bug. ***
Comment 7 Aryeh Gregor (not reading bugmail, please e-mail directly) 2007-03-20 22:33:00 UTC
*** Bug 9341 has been marked as a duplicate of this bug. ***
Comment 8 Aryeh Gregor (not reading bugmail, please e-mail directly) 2007-03-20 22:33:28 UTC
*** Bug 6954 has been marked as a duplicate of this bug. ***
Comment 9 Christian Mertes 2007-03-21 08:14:46 UTC
IE on Macintosh? That browser is dead, Microsoft quit its development since version 5! Probably printing math is 
the least of your problems when you're still using IE5 today ;) Wouldn't it be possible to disable the 
transparency feature optionally? Or better yet just render white text on transparent background so even visually 
impaired would have pretty TeX output :) I don't think "no" is a good final word on this issue as even the ugly 
white borders aren't consistent since simple formulae are rendered without using TeX and so are lacking the 
white background.

Additionally Jan-Åke Larsson already did all the transparency work for us (see Bug 9341 for story and patch) so 
an option to switch it off doesn't seem too much to me (but then I don't know the code and I probably won't be 
the one to do it so...).

Kind regards,

Christian
Comment 10 Aryeh Gregor (not reading bugmail, please e-mail directly) 2007-03-21 16:20:33 UTC
Coding it was never the problem.  It's a one-line change.
Comment 11 Christian Mertes 2007-03-21 17:06:05 UTC
Well, how many lines is making it optional then? :)
Comment 12 Raimond Spekking 2008-10-17 21:36:11 UTC
*** Bug 15462 has been marked as a duplicate of this bug. ***
Comment 13 Aryeh Gregor (not reading bugmail, please e-mail directly) 2008-10-17 21:43:52 UTC
Refiling as LATER.  This might happen at some distant point if we use MathML, SVG, or who knows what.
Comment 14 Aryeh Gregor (not reading bugmail, please e-mail directly) 2008-11-18 16:50:16 UTC
*** Bug 16382 has been marked as a duplicate of this bug. ***
Comment 15 Christian Mertes 2008-11-18 18:30:20 UTC
Another duplicate... I still think it would great to have an opt-in switch to enable this feature, especially if it'd be a matter of five lines of code or so.
Comment 16 Aryeh Gregor (not reading bugmail, please e-mail directly) 2008-11-19 00:20:09 UTC
Okay, reopening.  I think you can make a good case that administrators should be able to configure this.  At a minimum, if they have a non-white background, they may want to configure the background to some non-transparent color other than white.

Now, who wants to write a patch?  I don't think I have math working on my machine . . .
Comment 17 Splarka 2009-06-13 22:25:12 UTC
*** Bug 19181 has been marked as a duplicate of this bug. ***
Comment 18 René Kijewski 2009-07-26 17:03:24 UTC
Could it not be possible to have per skin settings like [[MediaWiki:Math-foreground/Monobook]] and [[MediaWiki:Math-background/Monobook]]? That should solve the black-on-black problem stated in comment #1.
Comment 19 Helder 2009-08-30 14:10:59 UTC
Just for note: There is a related link/proposal at
http://meta.wikimedia.org/wiki/Help_talk:Displaying_a_formula/Archives/2005#Maynard_Handley.27s_suggestions

Helder
Comment 20 Aryeh Gregor (not reading bugmail, please e-mail directly) 2009-11-29 16:58:34 UTC
As of r59550, it's possible to change the background color on a per-<math> basis using \pagecolor and \definecolor.

(In reply to comment #18)
> Could it not be possible to have per skin settings like
> [[MediaWiki:Math-foreground/Monobook]] and
> [[MediaWiki:Math-background/Monobook]]? That should solve the black-on-black
> problem stated in comment #1.

The problem with transparent math backgrounds is IE6 at this point.  Black-on-black styles isn't a problem, since the style can just do .tex { background: white } to get the same display as now (in non-IE6 browsers).  But alpha transparency doesn't work on IE6, and it's not acceptable to degrade display of all math articles for 15% of our users, for the sake of a tiny number of users viewing equations outside of mainspace, or otherwise on non-white backgrounds.

If someone can come up with a PNG transparency fix for IE6 that doesn't degrade performance or otherwise cause problems, even on pages with hundreds of equations, then we can use that.  Otherwise, we won't (IMO) output transparent backgrounds by default until IE6 falls to, say, <1% market share.

But if someone wants to submit a patch that allows configuration of default math background color in LocalSettings.php, possibly including an off-by-default option to make it transparent, that would be fine, which is why this bug is still open.  I'm willing to review it if it's reasonably short (I shouldn't think it would be more than 20 lines).
Comment 21 Aryeh Gregor (not reading bugmail, please e-mail directly) 2009-11-30 18:57:16 UTC
Fixed in r59593 by freakolowsky -- this is now an admin-configurable option, $wgTexvcBackgroundColor, defaulting to white.  As far as I can determine, neither the software defaults nor the Wikimedia configuration will be changed to a transparent value in the foreseeable future, as long as IE6 is an issue.  Although of course, ultimately that's not my decision alone.

It would be worth considering a further change that would use binary transparency by default on the parts that are completely transparent.  This would reduce the solid white background to a white halo, which would probably look better, and it would work in all browsers.  I don't know how to do that, but I'm sure it's possible.
Comment 22 Jure Kajzer 2009-11-30 19:11:34 UTC
if you set the value to 'Transparent' it uses aplha transparency with antialiasing, but if you set it to 'transparent' it uses binary transparency as used in GIFs ... so that's solved IMO.

http://www.nongnu.org/dvipng/dvipng_4.html#IDX6
Comment 23 Aryeh Gregor (not reading bugmail, please e-mail directly) 2009-11-30 19:18:29 UTC
Hmm, so should we make that the default?
Comment 24 Bergi 2010-09-16 19:13:56 UTC
As there are already settings in [[Special:Preferences]] for TeX, it should be easy to add an option for white background. The default has to be transparent! As referring to comment 9, when IE5 was dead in 2007, what is it today?

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links