MediaWiki talk:Common.css/Archive 2
This is an archive of past discussions. Do not edit the contents of this page. If you wish to start a new discussion or revive an old one, please do so on the current talk page. |
Archive 1 | Archive 2 | Archive 3 | Archive 4 | Archive 5 |
CSS for metadata
Per my Village Pump proposal, I'm going to be adding a bit of CSS to enable the creation of metadata (ala Personendaten in the German Wikipedia). This will allow us to try out some metadata schemes and hopefully implement some in the future. See this article for more info. Kaldari 19:27, 22 December 2005 (UTC)
- BTW, if anyone's interested, I've set up the first metadata project at Wikipedia:Persondata. It's gotten a lot of positive feedback so far. Kaldari 19:56, 2 January 2006 (UTC)
CSS for navbars
See Template talk:Dynamic navigation box. Monobook contains the code missing in other CSS. -- User:Docu
- I disagree with this change completely. You're using a template to perform a function which really should be added as a software feature. Templates should be used to replicate text among article, not change the fundamental navigation structure outside of the article body. -- Netoholic @ 19:31, 2 January 2006 (UTC)
- That's nice. But a lot of templates are used as navigational aids (navboxes, etc). See for example, {{Street Fighter series}}. That the necessary code to make the show/hide buttons work isn't available in the other skins is something that should be rectified. —Locke Cole • t • c 19:42, 2 January 2006 (UTC)
Hiding and showing content is something that should be requested as a built-in to the software, where the Javascript code (currently in MediaWiki:monobook.js can be put through proper development practices, like CVS. -- Netoholic @ 20:01, 2 January 2006 (UTC)
Restoring missing stuff
I have restored the specifications for the date display templates which got removed for no reason explained in the Edit Summary. If this was a purposeful removal, then could whoever does it explain it here before doing it again, please? HTH HAND —Phil | Talk 08:16, 5 January 2006 (UTC)
Bug in Monobook.css?
As reported on Wikipedia:Village pump (technical)#Bug in Monobook.css there appear to be two errors in Common.css:
- Unknown property 'filter'.
- Error in parsing value for property 'line-height'.
Also, this may be completely unrelated, but my Firefox fails to display certain images while IE is able to display them (cache cleared, control-shift-R tricks all tried in vain):
- Image:Reflection_nebula_IC_349_near_Merope.jpg [1]
- Image:Reflection_nebula_IC_349_near_Merope_full.jpg [2]
Most other images are fine, and IE seems Ok with these. -Wikibob 03:54, 13 January 2006 (UTC)
- Both errors were from the experimental main page stuff. I went ahead and changed the line-height:auto since it wasn't valid CSS. The filter thing is an IE only special deal. Should we keep it or scrap it? Kaldari 04:19, 13 January 2006 (UTC)
- As for the images, check if you aren't using a misconfigured ad blocker. The first one has /ad/ on its URL, which is often indiscriminately blocked. --cesarb 04:51, 15 January 2006 (UTC)
- Yes, the IE filter thing keeps popping up in my js console. Can you hide it from non-IE browsers? Apparently this recalc thing does it? — Omegatron 01:48, 18 January 2006 (UTC)
CSS hack reduces accessibility
(conversation moved to Wikipedia talk:HiddenStructure#CSS hack reduces accessibility) -- Netoholic @ 15:28, 27 January 2006 (UTC)
Why Not Weeble?
(conversation moved to Wikipedia talk:HiddenStructure#Why Not Weeble?) -- Netoholic @ 15:29, 27 January 2006 (UTC)
Change request
(conversation moved/archived to Wikipedia talk:HiddenStructure#Change request) -- Netoholic @ 15:33, 27 January 2006 (UTC)
Tables inside frames
There are uses for tables of images inside frames, but the css doesn't work with them, since it puts a border around every image instead of around the table as a whole. {{Float begin}} handles this in a kludgy way, but better ones would be nice. One possible solution is to add:
div.thumb div table a img { border: 0; } div.thumb div table { border: 1px solid #ccc; }
Then I would modify float_begin to use the code in the above example. This will remove the border around images inside tables inside thumbnail frames and put the border around the table instead. There are other solutions, I'm sure, like using a div with a border so that you can put anything inside a frame, instead of just tables, but this would work for now. Can it be added? Are there any conflicts? — Omegatron 18:18, 20 January 2006 (UTC)
- I don't see where this is necessary enough to make a site-wide change to some pretty widely used CSS classes. It could cause conflicts later. You could either combine the smaller images into a larger one, or just kludge it for the few occassions it seems to be used. Take this example, where I put the information into a table using no templates and very little styling. -- Netoholic @ 21:28, 20 January 2006 (UTC)
- Your kludge is just as bad as the one currently in use. Adding to the css won't break anything and will provide a valid implementation.
- Another alternative is to create a new div.framed or div.framedtable class
instead of reusingin addition to the div.thumb class, if you're really worried about future css conflicts. — Omegatron 22:46, 20 January 2006 (UTC)- This is a big problem, and I support fixing it. Articles about chess usually construct chess boards out of individual chess tiles in a table. It's virtually impossible to put such a chess board in a frame, with a caption below, and have it look exactly the same as a wiki image in a frame. I have the sense that the "right" way to solve the problem is to have MediaWiki produce somewhat different code, something like
<div class="outer frame">
- This is a big problem, and I support fixing it. Articles about chess usually construct chess boards out of individual chess tiles in a table. It's virtually impossible to put such a chess board in a frame, with a caption below, and have it look exactly the same as a wiki image in a frame. I have the sense that the "right" way to solve the problem is to have MediaWiki produce somewhat different code, something like
<div class="inner frame">Image goes here</div> <div class="caption">Caption goes here</div>
</div>
- The problem is that MediaWiki currently produces
<div class="thumb">
- The problem is that MediaWiki currently produces
<div style="width:WIDTH SET HERE"> Image goes here <div class="thumbcaption">Caption here</div> </div>
</div>
- The problem with that code is that the image itself isn't inside its own DIV, so that "thumb" class has to put a frame around every image it contains. Omegatron's proposal looks like a good temporary workaround, but eventually we should get MediaWiki to just make good HTML code. dbenbenn | talk 22:05, 26 January 2006 (UTC)
- Yeah, it's only used "on a few occasions", like {{Chess diagram}} (36 instances), {{Chess position}} (17 instances), {{Football club infobox}} (454 instances), {{National football team}} (56 instances), {{Football kit box}}, ... Those are all tables of images that want to be inside a frame.
- Agreed that mediawiki should be fixed. bugzilla:1729 is close. — Omegatron 14:43, 28 January 2006 (UTC)
- Biology has another example. — Omegatron 15:37, 5 February 2006 (UTC)
Is anyone opposed to this code? — Omegatron 02:24, 1 March 2006 (UTC)
CSS hack reduces accessibility, confirmed
(conversation moved/archived to Wikipedia talk:HiddenStructure#CSS hack reduces accessibility, confirmed) -- Netoholic @ 15:34, 27 January 2006 (UTC)
From freedom scientific
Ok, this is what the Freedom Scientific site says about CSS with earlier versions of jaws. Feel free to refactor this if necessary. This applies to jaws 5.1 and earlier. For the whole web page, see [3]. Refreshing with insert+escape shortcut mentioned did not work on wikipedia. I have found out that diff links will also display better in later versions of jaws, so I, personally, will upgrade.
The text is as follows:
Q. Does JAWS support cascading style sheets (CSS)?
A. Yes, JAWS does support cascading style sheets (CSS). CSS is a way of marking up text using styles that are inherited by applying a set of style rules to a page without having to change the actual page content. For example, you can link an HTML document to a style sheet that displays all level one headings in red. There are some issues that authors of Web pages should be aware of when using CSS to ensure the page is accessible.
When a page loads and JAWS processes the HTML code, it also processes linked and inline style information to determine which elements should be rendered. Any elements that use a style with the attributes "visibility:hidden" or "display:none" are not included in the JAWS rendering of the page. However, if the page has elements shown when it first loads, but then dynamically hides these elements without user intervention after the page loads, JAWS does not detect that this has occurred and may still show the hidden content. Conversely, if a page hides content when it first loads but then dynamically shows this content after the page loads, JAWS does not announce the new content.
The safest course of action when developing Web pages is to hide anything in the HTML when the page first loads that should not be shown. Then, only hide or display content when the user interacts with the page (such as by clicking a link or item with the onClick attribute). When the user clicks text, links, images, and so on, JAWS asks Internet Explorer for the HTML again, and updates the page.
A JAWS user can press INSERT+ESC to refresh the page content in the virtual document. However, the source that is passed to JAWS by Internet Explorer should represent the current visible state of the page. This does not occur if the HTML source code does not reflect the true visibility status because of scripting. If that is the case, JAWS still does not have an accurate view of the document.
JAWS uses style information to try to determine the font name, font size, font attributes, colors, and text alignment. This information is provided to the user when he or she presses INSERT+F.
Other than visibility and text attributes, style information is not interpreted any further. JAWS does not indicate zIndex levels.
--—The preceding unsigned comment was added by Pianoman87 (talk • contribs) 10:03, 23 January 2006.
- Thank you for the information, and it's good to hear that the CSS hiddenStructure method does work with the most commonly-used screen reader. The method was originally used on Infobox templates only, where hiding a few rows which didn't have data was a convenience. For other uses of conditionally displaying information, as a group, we need to be smarter about developing good, simple solutions rather than "clever" ones. -- Netoholic @ 11:38, 23 January 2006 (UTC)
Please note that screen readers and other web browsers are not required to use CSS at all, and other ones may very well ignore it. Also note that main.css is loaded by a style element containing the attribute media="screen,projection"
, so it should be ignored by screen readers, and consequently the CSS cascade will be different for screen readers which respect the media attribute.
The gist of this is that we can't possibly know how every single browser, screen reader, and search engine will process pages. Therefore, we should follow HTML and CSS standards, accessibility guidelines, and good authoring practices, and not just ignore or pay lip service to them. —Michael Z. 2006-01-23 15:10 Z
- Quite interesting. Sounds like we need someone knowledgable on the subject to make a request to the developers to provide a way for editors to make changes to non-visual CSS. -- Netoholic @ 15:37, 23 January 2006 (UTC)
- For what purpose? If we follow basic good practice for accessibility in page content, that is, generate good HTML in the body, then we are probably 90 to 99 percent of the way there (of course, Graham's input would be helpful). Sounds like the HTML for diffs and perhaps red links needs to be tweaked (see below), but that's for the MediaWiki developers, not for Wikipedia editors to fix. The basic style sheets for other media are also a feature of MediaWiki, not part of the encyclopedic content. —Michael Z. 2006-01-23 15:51 Z
Ignoring css?
I can now confirm that both common.css and monobook.css are ignored in jaws versions below 6.0. This has other implications besides conditional statements. For example it makes interpreting diffs and distinguishing red links more difficult, because even the colour check commands do not work. The only thing the jaws 6.0 new features has to say relating to this is that "JAWS also features improved performance while you are reading complex Web sites." [4] The FAQ for jaws 5.0 did say that css was supported, though.
What could be causing this, and is there any way to fix it? Or maybe this is just another reason to upgrade, along with the fact that Firefox is supported. That's another 350 dollars or so out the window ... Graham/pianoman87 talk 15:28, 23 January 2006 (UTC)
- Thanks for the input, Graham. Your advice would probably be useful at Wikipedia:Accessibility and WikiProject Usability. The diffs and red link problems are probably in the realm of WikiMedia developers' work; I think meta:Usability and meta:Usability group may be where this is discussed. Template development falls somewhere between editors and developers, and is definitely a place where accessibility may be broken across many pages at once.
- Is there any way that editors could improve accessibility in general? —Michael Z. 2006-01-23 15:59 Z
The best thing that editors can do to improve accessibility is to follow the recommendations in the manual of style, like creating good link descriptions (especially for external links, and not "click here!"). Also, heading titles should be descriptive, and in a consistent order: the order for the last few headings should be see also, references and external links, for example. When editing, never break up a line unless absolutely necessary, as the easiest way to edit with a screen reader is to navigate line by line. Also, use as little code as possible, so the text in the edit window is easier to read. My pet peeve is code like [[clock|clocks]] instead of the perfectly correct code [[clock]]s, which takes up less space. Also, spelling and grammar errors can dramatically affect the sound of the text like "initative" instead of "initiative", which can make the text more difficult to read. The majority of my editing time is spent fixing spelling and grammar errors that affect the sound of the text in an article.
Images should contain a caption, and the caption should concisely describe any information contained in the image. Where possible, any charts or diagrams should have a text equivalent, or should be well-described so that users who can't see the image can gain some understanding of the concept.
The other things I can think of that should be avoided are very bad style, and I have not encountered them in any good articles. For example, having a heading title with the same name as one of the form names on the page, like "search" or "go". I've only seen two articles with this problem, and they both also required major cleanup.
Besides spelling and grammar errors, most well-developed wikipedia articles read well with jaws, at least for me. I think screen reader users need to be profficient in navigating the internet to get the most out of wikipedia, but that is true for every site. Graham/pianoman87 talk 03:55, 24 January 2006 (UTC)
- Thanks. Interesting that nearly all of this falls under simple good writing and tidy editing—helpful for a reader using any web browser. I think most "accessibility" practice just falls under simple usability.
- Should detailed descriptions of charts or diagrams go on their image page, or is it important to keep it all in the article? Regards. —Michael Z. 2006-01-25 05:35 Z
- Detailed image and chart descriptions should go on the image page, with text saying that activating the image link will lead to a more detailed description. I'll put a note on the main accessibility page saying that. Graham/pianoman87 talk 07:20, 25 January 2006 (UTC)
Edit request for fix of nested tables
Please change
table.wikitable th, table.wikitable td, table.prettytable th, table.prettytable td { border: 1px #aaaaaa solid; padding: 0.2em; } table.wikitable th, table.prettytable th { background: #f2f2f2; text-align: center; }
to
table.wikitable > tbody > tr > th, table.wikitable> tbody > tr > td, table.prettytable > tbody > tr > th, table.prettytable > tbody > tr > td { border: 1px #aaaaaa solid; padding: 0.2em; } table.wikitable > tbody > tr > th, table.prettytable > tbody > tr > th { background: #f2f2f2; text-align: center; }
So nested tables doesn't inherit the formating. →AzaToth 22:01, 27 January 2006 (UTC)
- Please try to rally some support, before requesting a change. If others agree your code is harmless and will help, this code should be added. But not before others have weighed in. Thank you. -- Ec5618 18:06, 30 January 2006 (UTC)
- It's rather simple, if you have the wiki-code:
- Please try to rally some support, before requesting a change. If others agree your code is harmless and will help, this code should be added. But not before others have weighed in. Thank you. -- Ec5618 18:06, 30 January 2006 (UTC)
{| |- | {| |- | |} |- | |}
- The DOM will be:
table | |--tbody | |--tr | | | |--td | | | |--table | | | |--tbody | | | |--tr | | | |--td |--tr | |--td
- Normally you don't have nested tables, and in the situations you have such, there is not always you want to inherit the formation from wikitable to the nested table, if you want you can always define the nested table as a wikitable, otherwise you have to manually reset all the formating on all td:s. The most logically solution is to limit the formation of wikitable to not transend deeper to nested tables by limit it to defined child (
table > tbody > tr > td
etc...) →AzaToth 19:20, 30 January 2006 (UTC)- My knowledge of CSS is limited I'm afraid. Can you please get someone to take a look at the code? I understand the problem, but not the cure you're proposing. I imagine this fix might break quite a few tables, as a lot of nested tables are currently defined only through inheritance. Is it not simpler to accept the inheritance and to redefine the variables for each sub-table? -- Ec5618 19:42, 30 January 2006 (UTC)
- No, that's impossible because you can't in the sub-table override class inheritance, you should be forced to do simlar to this:
- My knowledge of CSS is limited I'm afraid. Can you please get someone to take a look at the code? I understand the problem, but not the cure you're proposing. I imagine this fix might break quite a few tables, as a lot of nested tables are currently defined only through inheritance. Is it not simpler to accept the inheritance and to redefine the variables for each sub-table? -- Ec5618 19:42, 30 January 2006 (UTC)
- Normally you don't have nested tables, and in the situations you have such, there is not always you want to inherit the formation from wikitable to the nested table, if you want you can always define the nested table as a wikitable, otherwise you have to manually reset all the formating on all td:s. The most logically solution is to limit the formation of wikitable to not transend deeper to nested tables by limit it to defined child (
{| class="wikitable" |- | {| style="border: 0; background-color: white; border-collapse: separate;" |-style="border: 0; background-color: white; border-collapse: separate;" !style="border: 0; background-color: white; border-collapse: separate;"|Header |-style="border: 0; background-color: white; border-collapse: separate;" |style="border: 0; background-color: white; border-collapse: separate;"|data etc... |} |- | |}
- aslo you don't know what style a standard table looks like in all themes. →AzaToth 19:59, 30 January 2006 (UTC)
- I agree that this should be done, but I don't understand the > code to know whether it will break anything. — Omegatron 21:42, 30 January 2006 (UTC)
A B
means B descendant of A,A > B
means B child of A. →AzaToth 22:10, 30 January 2006 (UTC)- I know it refers to descendants; I'm just saying I'm not qualified enough on the site css or how descendants work to know whether it will break anything. Someone else needs to chime in. — Omegatron 19:06, 31 January 2006 (UTC)
- I ran into this problem of inheritance in editing the article Bobsleigh. I tried to nest invisible tables to align decimal points in a wikitable, but inheritance broke the formatting.
- I know it refers to descendants; I'm just saying I'm not qualified enough on the site css or how descendants work to know whether it will break anything. Someone else needs to chime in. — Omegatron 19:06, 31 January 2006 (UTC)
- The formatting Azatoth suggests appears to be correct. See the W3C standard for .css formatting of child selectors here. --Stormraven 14:29, 7 March 2006 (UTC)
- So, what would the effect be on nested tables, such as the ones on Help:Contents (the contents box consists of two nested tables), for example? And is the current code causing problems? -- Ec5618 09:25, 31 January 2006 (UTC)
- note. For clarification, on Help:Contents, the parent table sets the font-size to 160%. The child reduces it to 80% of that. Would your fix cause the child table to show the font at 80% of normal? -- Ec5618 09:29, 31 January 2006 (UTC)
- That's not class="wikitable", though.
- (And that visual formatting should be done with css, anyway; not a table.) — Omegatron 19:06, 31 January 2006 (UTC)
I'm can agree with a compromize, create a new rule .wikitable2 that are using my specification. →AzaToth 09:06, 15 February 2006 (UTC)
- I don't think that's a good idea. I also don't think anyone's disagreeing. :-) — Omegatron 02:23, 1 March 2006 (UTC)
- Please garner some support for the change first. Stifle (talk) 00:42, 11 May 2006 (UTC)
Class or id for removing underlines in a section of a table
Template:Arabic alphabet has a table with all the characters in the Arabic alphabet. The purpose of the table is to demonstrage what they look like, however since they are all wikilinks the added underlines obscures the letters themselves in some cases and just looks ugly in others. Is there some (hopefully already included) bit in any of the mediawiki css that coudl be used to remove the underlines from these links (but not from the rest of the template). Dalf | Talk 23:09, 28 January 2006 (UTC)
- As I have in my settis all removed underlines I don't see anyone, but if you want to manually force a template to not use underlines try:
<span style="text-decoration: none;">[[Article]]</span>
: Article. →AzaToth 23:31, 28 January 2006 (UTC)
- Tried that before (And again just now to be sure) but it does not work. From reading online I take it the span element can be sued to add decorations but not to remove them. Either that or the code that wikipedia adds to links ovrrides. Dalf | Talk 01:12, 29 January 2006 (UTC)
- Create a class (for instance nounderlines) and add a rule to Common.css:
- .nounderlines a { text-decoration: none }
- And then use <div class="nounderline">.
- Your text-decoration is being overriden by the one declared for the a element. --cesarb 01:32, 29 January 2006 (UTC)
- In fact, I've just gone ahead and done it; clear your cache and tell me if it works. --cesarb 01:39, 29 January 2006 (UTC)
- Now when you are here, what about my request one section above? :) →AzaToth 01:41, 29 January 2006 (UTC)
- Thanks! I moved the class to just the rows with the letters so the other links in the template will still have them. It looks a lot better! Thanks again. Dalf | Talk 02:25, 29 January 2006 (UTC)
- .nounderlines a { text-decoration: none } is overwritten by the preferences default. You need an !important in it to be totally effective (and anyone who really *really* wants underlines all the time can add a counter !important to their personal .css). --Splarka (rant) 07:31, 1 July 2006 (UTC)
invalid CSS
- #bodySearchMP .bodySearchIput { opacity: .85; filter: alpha(opacity=85); }
The declaration "filter: alpha(opacity=85);" doesn't seem to validate in any version of CSS. I assume this is something specific to MSIE. Unless I'm wrong, I will remove this line. —Michael Z. 2006-01-29 07:20 Z
- Thats correct, it a MSIE-specific declaration, should be removed. →AzaToth 07:24, 29 January 2006 (UTC)
- Thank you. — Omegatron 15:25, 29 January 2006 (UTC)
- You might use the following. It's not standard, but it works in the named browsers:
filter: alpha(opacity=85); /* for Internet Explorer */ -moz-opacity: 0.85; /* for Firefox etc. */ opacity: 0.85; /* CSS3: for Mozilla and Safari */
- I just thought you might want to know. --Fred Bradstadt 19:34, 31 January 2006 (UTC)
- There's another syntax error. Always check with the W3C CSS Validation Service after any changes. -- Schapel 01:18, 14 July 2006 (UTC)
Audio links
The problem: We want a way to briefly link to audio files, like so:
- Bordeaux (
pronunciation[?]) is a port city in...
But if you click on the loudspeaker icon, you go to the image page for the loudspeaker icon, which obviously confuses a lot of people. So, as of January 2006, it looks like this:
- Bordeaux (port city in... ) is a
(which shows up as an unknown character box in IE6, and isn't optimal anyway.)
Ideally, we would be able to use css or software changes to make a clickable icon for audio files.
A solution
Add this to your user css (User:YOURUSERNAME/monobook.css):
.audiolink a{ background: url("http://upload.wikimedia.org/wikipedia/commons/f/f7/Loudspeaker.png") center left no-repeat !important; padding-left: 16px !important; padding-right: 0 !important; }
and then reload this page:
- External audio link:
- External audio link with audiolink class:
- Internal audio link:
- Internal audio link with audiolink class:
This way people can click on the loudspeaker icon without going to the loudspeaker's image description page. If it works for everyone, can we add it to MediaWiki:Common.css and use the audiolink class where appropriate?
The icon should really be a system icon (in http://en.wikipedia.org/skins-1.5/monobook/), but we can use a (protected?) image from the Image: namespace for now. I made a copy here to be protected, but maybe that's not necessary.
Same discussion here. — Omegatron 18:56, 18 January 2006 (UTC)
Ok it doesn't work in common.css or monobook.css. Something to do with the !important not working? — Omegatron 03:29, 29 January 2006 (UTC)
- Did you try looking at it with Firefox's DOM Inspector? It's usually very enlightening. --cesarb 18:33, 30 January 2006 (UTC)
- I didn't try any troubleshooting. I didn't want to leave it in the sitewide css if it was breaking something. Maybe I'll try later. It works fine in my user css. — Omegatron 21:44, 30 January 2006 (UTC)
I did this succesfully with vi:MediaWiki:Common.css and vi:Tiêu bản:Âm thanh at the Vietnamese Wikipedia. – Minh Nguyễn (talk, contribs) 02:36, 30 January 2006 (UTC)
- It's not working correctly there, either. The speaker should be clickable and go to the same place as the link. A non-clickable speaker is better than one that goes to the image page, though. :-) — Omegatron 21:46, 30 January 2006 (UTC)
Oh yeah, I forgot to revisit that issue. Actually, I think it should be doable, using the same code that places little blue arrow icons after all the external links. – Minh Nguyễn (talk, contribs) 10:27, 31 January 2006 (UTC)
- It's basically the same code, and it works fine when I tried it in my user css. The speaker is clickable and goes to the sound file directly. I'll try to mess with the DOM inspector later. — Omegatron 18:57, 31 January 2006 (UTC)
- I had assumed that would be the logical solution. Links to irc channels, to secure external websites, and to external websites, all automatically display an icon. Adding another filetype to the list shouldn't be difficult. -- Ec5618 10:47, 31 January 2006 (UTC)
- That's what bugzilla:3726 is for. But do we really want it to display a speaker for all audio files? I wanted to add it just for a specific class, so we could pick and choose. I have code that will work for all audio files, too. — Omegatron 18:57, 31 January 2006 (UTC)
Ummm.... Nevermind. It works now. :-) — Omegatron 04:44, 1 February 2006 (UTC)
Similar for PDF files?
This is excellent? Is it possible to do something similar for PDF files? We mostly attempt to tag external links which will bring up PDF files, to warn users in advance: however this is not always easy in context. It would be nice if it were possible to arrange that all links to *.pdf had some sort of icon (like the little arrow for ordinary external links). FWIW bugzilla:1578 seems to be relevant. HTH HAND —Phil | Talk 14:06, 15 February 2006 (UTC)
- It certainly is.
#bodyContent a[href $="pdf"] { background: url(http://upload.wikimedia.org/wikipedia/en/thumb/7/79/Adobepdfreader7_icon.png/15px-Adobepdfreader7_icon.png) center right no-repeat; padding-right: 15px; }
- These icons should really be folded into Mediawiki once they have enough support, though. Currently they're from the image namespace.
- Oh, and if you use Firefox, you'll like the targetalert extension. — Omegatron 01:51, 1 March 2006 (UTC)
- Either put it in your user css or get the test styles bookmarklet from squarefree, copy and paste, and the following PDF files should have icons:
- http://www.example.org/notapdf.html
- http://www.example.org/pdffile.pdf
- not a PDF
- a PDF file — Omegatron 05:25, 2 March 2006 (UTC)
- Not bad, but I have a couple of issues with this:
- In Safari, the icon replaces the external link icon
- At that tiny size, the icon looks like a fuzzy blob
- It needs to be more iconic
- If it was just a couple of pixels bigger, it would align neatly with the text baseline, instead of floating above it
- Adding "(PDF)" still seems better to me. —Michael Z. 2006-03-02 06:05 Z
- Not working for me: I can see the icon fine by cutting/pasting the URL into IE, but I'm not getting anything other than the usual little arrow on those links. Is there some special incantation for IE, or am I simply SOL on this one? —Phil | Talk 08:11, 2 March 2006 (UTC)
- Not bad, but I have a couple of issues with this:
- But you see the regular external link icons? They're included in exactly the same way. Hmmm... Yes, it appears these selectors don't work in IE. I don't know how they add the external link icons, then... I'll have to dig through the site CSS some more...
In Safari, the icon replaces the external link icon
- Good. That's what it's supposed to do.
At that tiny size, the icon looks like a fuzzy blob
- Looks fine on my screen. I thought it was a little big, actually; it's 15×15 pixels wide, while the regular external link icon is only 10×10. It's just an example to show it can be done, anyway; it could easily be made bigger, if really necessary. Create a thumb of Image:Adobepdfreader7_icon.png at the size you want (anywhere), then copy the URL of that image and replace the one in the CSS statement.
It needs to be more iconic
- Which means... what, exactly?
If it was just a couple of pixels bigger, it would align neatly with the text baseline, instead of floating above it
- Depends on your font size, perhaps. How do the regular external link icons look? — Omegatron 15:13, 2 March 2006 (UTC)
"More iconic..." Sorry: I mean that it either needs to be redrawn at the small size so that it's sharper, and not so fuzzy, or maybe it should be replaced with something not antialiased at all and more stylized, perhaps a simple one-colour pixel-line drawing like the external link icon. —Michael Z. 2006-03-02 15:48 Z
- Ah. It looks good to me, though maybe it doesn't at lower screen resolutions? It's just a thumb of Image:Adobepdfreader7_icon.png. A dedicated icon would be better. (Also, the icon is apparently copyrighted. That would be another problem with sitewide use.) — Omegatron 16:02, 2 March 2006 (UTC)
Oh. Mediawiki uses a CSS class="external" to add the icons, so they work in IE. To get PDF icons in IE, you'd need to change Mediawiki or add a class manually:
<span class="PDFlink">[http://www.example.org/differentpdffile.pdf a PDF file]</span>
with CSS like:
#bodyContent a[href $="pdf"], #bodyContent span.PDFlink a { background: url(http://upload.wikimedia.org/wikipedia/en/thumb/7/79/Adobepdfreader7_icon.png/15px-Adobepdfreader7_icon.png) center right no-repeat; padding-right: 15px; }
But even that doesn't work. I give up.
I suggest not using IE. :-) — Omegatron 05:08, 3 March 2006 (UTC)
I'd suggest making the selector set more like this:
#bodyContent a[href$=".pdf"], #bodyContent a[href*=".pdf?"], #bodyContent span.PDFlink a
This would account for instances like these:
- http://www.example.org/2024/08/17/pdf (as in a blog or something)
- http://www.example.org/example.pdf?foo=bar (it could happen)
But we should also account for PDFs in the Image: namespace with a rule afterwards that negates this one.
– Minh Nguyễn (talk, contribs) 22:03, 4 March 2006 (UTC)
- Good ideas. The thing I've seen is something.pdf#page=14 , so this would be better:
#bodyContent a[href$=".pdf"], #bodyContent a[href*=".pdf?"], #bodyContent a[href*=".pdf#"], #bodyContent span.PDFlink a { background: url(http://upload.wikimedia.org/wikipedia/en/thumb/7/79/Adobepdfreader7_icon.png/15px-Adobepdfreader7_icon.png) center right no-repeat !important; padding-right: 15px; }
- Also, although the icon is copyrighted, Adobe allows it to be used for identifying PDF files, as I copied and pasted to Image:Adobepdfreader7_icon.png, so it is ok to use site-wide. Won't work in IE, but at least Firefoxers can use it. Then if Mediawiki is ever updated to tag PDF links, it will work for everyone. — Omegatron 00:27, 22 March 2006 (UTC)
Any opposition to me adding this for the benefit of those of us whose browsers support it? — Omegatron 14:50, 22 August 2006 (UTC)
- Sketchy in terms of freeness. For instance, they only permit its use if the PDF was created using Adobe Acrobat, not any third-party software, which we can't verify. I'd go with a little "PDF" marker somehow embedded in the external link icon, not the copyrighted and trademarked logo. Or you could ask a dev if they'd add it to the software itself, which would negate any worries on our level provided they agree. (Have you opened a bug?) —Simetrical (talk • contribs) 19:25, 22 August 2006 (UTC)
bugzilla:1578 has been unfixed for a year and a half. When it is fixed, the same icon can be used with the same CSS, but it will work in IE, too.
Other possibilities: {{PDFlink}} uses 15px. There's also 15px, 15px, Image:Icons-mini-file acrobat.gif, 15px, 15px, 15px, Image:Page white acrobat.png, 15px... An icon, presumably a copy of [5] or [6], was deleted based on the rationale here. Trademark vs copyright. The {{PDFlink}} icon, on the other hand, survived deletion here.
I don't really like the Noia icon, though; there are definitely better ones available. I like these pretty equally:
- PDF file15px
- PDF fileImage:Icons-mini-file acrobat.gif
- PDF fileImage:Page white acrobat.png
- PDF file15px
Also, as explained here, we can change the {{PDFlink}} template to apply the "PDFlink" style class, and this proposed change will work in IE for all such tagged links, as well. — Omegatron 19:09, 23 August 2006 (UTC)
My latest rendition:
#bodyContent a[href$=".pdf"].external, #bodyContent a[href*=".pdf?"].external, #bodyContent a[href*=".pdf#"].external, #bodyContent span.PDFlink a { background: url(http://upload.wikimedia.org/wikipedia/commons/thumb/2/23/Icons-mini-file_acrobat.gif/15px-Icons-mini-file_acrobat.gif) center right no-repeat; padding-right: 16px; }
Similar in width to the default external link icon, but still identifiable as a PDF icon. (Like this, but the icon is centered vertically:)
Doesn't show up on internal links (like Image: pages). Icon is license-free (and I tried all the other ones in many different size and configurations and this one looks best). Meshes well with my proposed {{PDFlink}} template (I tried it at User:Omegatron/PDFlink). I am going to go site-wide with this soon, if there are no objections, though I'm sure we'll see a handful of objections after it goes up. But we can tweak it then or remove it, depending on what people say. But I've been proposing this for months with no complaints about the concept, and {{PDFlink}}, which does effectively the same thing, passed a TfD, so it should go smoothly. — Omegatron 23:40, 26 August 2006 (UTC)
- Oh wait. It doesn't work in IE? Crap. — Omegatron 23:52, 26 August 2006 (UTC)
Ah. IE was crapping out on the advanced selectors. We could either do it this way or use some IE hack to hide them from it:
/* Change the external link icon to an Adobe icon for all PDF files */ /* (in browsers that support the selectors, like Mozilla and Opera) */ #bodyContent a[href$=".pdf"].external, #bodyContent a[href*=".pdf?"].external, #bodyContent a[href*=".pdf#"].external { background: url(http://upload.wikimedia.org/wikipedia/commons/thumb/2/23/Icons-mini-file_acrobat.gif/15px-Icons-mini-file_acrobat.gif) center right no-repeat; padding-right: 16px; } /* Change the external link icon to an Adobe icon anywhere the PDFlink class */ /* is used (notably Template:PDFlink). This works in IE, unlike the above. */ span.PDFlink a { background: url(http://upload.wikimedia.org/wikipedia/commons/thumb/2/23/Icons-mini-file_acrobat.gif/15px-Icons-mini-file_acrobat.gif) center right no-repeat !important; padding-right: 16px !important; }
This has all of the above features, works in Firefox and Opera for all PDF links, and in IE everywhere the PDFlink template or class is used. — Omegatron 00:45, 27 August 2006 (UTC)
I added it. Complaints go here: — Omegatron 00:18, 28 August 2006 (UTC)
CSS Opacity
JesseW removed the following:
#bodySearchMP .bodySearchIput { opacity: .85; }
Opacity is a CSS3 property, and it will validate if you tell the W3C's validator that the style sheet is CSS3. That said, I have no idea what it does or whether any browser supports it, so I don't mind that it was removed. —Michael Z. 2006-01-31 16:22 Z
- You might use the following. It's not standard, but it works in the named browsers:
filter: alpha(opacity=85); /* for Internet Explorer */ -moz-opacity: 0.85; /* for Firefox etc. */ opacity: 0.85; /* CSS3: for Mozilla and Safari */
- I just thought you might want to know. --Fred Bradstadt 19:34, 31 January 2006 (UTC)
- The only one of those that are legal CSS2 is
-moz-opacity: 0.85;
, offcourse it only works in mozilla-browsers, buts it's totally legal css2 (non-standard css must be defined with a leading dash). →AzaToth 19:41, 31 January 2006 (UTC)
- The only one of those that are legal CSS2 is
- Do you have a reference? The W3C's CSS FAQ specifically says that -moz-opacity does not validate. —Michael Z. 2006-02-1 01:07 Z
Consistent list alignment
I propose indenting bulleted lists so that they align consistently with numbered lists. Please see the proposal with examples at MediaWiki talk:Monobook.css#Consistent list alignment. —Michael Z. 2006-02-1 21:13 Z
- Please do it in MediaWiki:Monobook.css, where you proposed it, then. It works fine as-is in Classic-derived skins; your "fix" badly misaligns them. —Cryptic (talk) 23:29, 1 February 2006 (UTC)
Catalogue of CSS classes
I have created Wikipedia:Catalogue of CSS classes as a place to list and describe all the CSS classes (and IDs). The idea is to have a central place to put all the descriptions, instead of having them scattered all around the wiki. --cesarb 04:22, 3 February 2006 (UTC)
Adjustment to the cell padding
I am proposing that we adjust the cell padding for class 'wikitable'. It currently appears as "padding: 0.2em;" in the CSS. This produces vertical padding which is too large in proportion to the horizontal padding, and there is too much vertical space at smaller fonts. In the two tables below, I have created different cell spacings for comparison. I prefer a vertical spacing of 0 (especially with the small font) or 0.1em (since some might find 0 to be too tight with a normal font) and a horizontal spacing of 1ex or 0.5em. What do you think? —Mike 00:01, 11 February 2006 (UTC)
Size | as is | 0 | 0.1em | 0.2em | 0.3em | 0.4em | 0.5em | 1em | 1ex | ← horizontal padding |
---|---|---|---|---|---|---|---|---|---|---|
as is | 1,234,567 | |||||||||
0 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | ||
0.1em | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | ||
0.2em | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | ||
0.3em | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | ||
0.4em | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | ||
0.5em | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | ||
1em | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | ||
1ex | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | ||
↑ vertical padding |
Size | as is | 0 | 0.1em | 0.2em | 0.3em | 0.4em | 0.5em | 1em | 1ex |
---|---|---|---|---|---|---|---|---|---|
as is | 1,234,567 | ||||||||
0 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | |
0.1em | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | |
0.2em | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | |
0.3em | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | |
0.4em | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | |
0.5em | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | |
1em | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | |
1ex | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 | 1,234,567 |
- This a to a large extent a matter of taste. Looking at the examples above, I tend to agree that vertical padding could be decreased. To me vertical padding 0.1em and horizontal 0.2em (as is) looks best. Horizontal padding at 0.5em looks very wide to me and may waste critical space on the page. I have one technical question though. In your parameters you seem to use "padding: vert, hor", but the definition I know has "padding: top right bottom left". Are you sure it's well defined (and works in all browsers) the way you do it? −Woodstone 12:05, 11 February 2006 (UTC)
- Thanks for the confirmation (I knew it only for just one value). Since "em" derives from the font width and "ex" from the font hight, we might go for a horizontal padding of 0.2em and vertical padding of 0.2ex. −Woodstone 16:36, 11 February 2006 (UTC)
- Em is defined as em-height: the height of the font's character box, i.e. the font size. Most browsers treat ex as exactly 0.5 em (although reportedly MSIE/Mac tries to calculate true em-height by analyzing the rasterized font!). May as well use both measurements in em units, for consistency. —Michael Z. 2006-02-15 18:49 Z
- Em is defined as the width of a capital M (see for example the abdobe glossary, while ex is the height of a small x. Indeed, in most cases em is about 2 times ex.−Woodstone 20:08, 15 February 2006 (UTC)
PRE
Would it be possible to add the following? –
pre { overflow-x: auto; overflow-y: visible; }
This would keep long lines of code from adding horizontal scrollbars on large pages (for example WP:AN/I on occasion) and would instead add horizontal scrollbars directly to the PRE'd text.
To see this in action for yourself, simply add the line above to your userspace CSS override, then go to User:Locke Cole/Sandbox and scroll down to the "PRE test" section. —Locke Cole • t • c 02:06, 23 February 2006 (UTC)
- I'll second the suggestion. In my own CSS I have had "pre { overflow: auto; }" which has worked well. —Mike 03:19, 24 February 2006 (UTC)
- Not many people read these talk pages. Can I suggest that you bring it up first on the Technical section of the village pump? Ral315 (talk) 06:10, 28 February 2006 (UTC)
- Certainly, will post here when I've done it with a difflink. —Locke Cole • t • c 06:23, 28 February 2006 (UTC)
- Posted the request to village pump-proposals, here. —Locke Cole • t • c 06:27, 28 February 2006 (UTC)
- I support this idea. I've always wondered why pre'd text does this, and figured there must be a reason for it. Johnleemk | Talk 06:40, 28 February 2006 (UTC)
- ^ What he said. I support this too. Phoenix-forgotten 18:25, 28 February 2006 (UTC)
I use this, and suggested it a long time ago, but IE doesn't support it, in a bad way, and pages with lots of pres slow down browsers that do. It's not cut and dry. *Goes to look up the etymology of the term "cut and dry"* — Omegatron 01:40, 1 March 2006 (UTC)
- The phrase is "cut and dry", at least in common American usage. – Minh Nguyễn (talk, contribs) 22:09, 4 March 2006 (UTC)
- 'Many people mishear the standard expression meaning "set," "not open to change," as "cut and dry." Although this form is listed in the Oxford English Dictionary, it is definitely less common in sophisticated writing. The dominant modern usage is "cut and dried."' —Paul Brians (2003) Common Errors in English Usage, ISBN 1887902899.
- The Canadian Oxford Dictionary (2nd ed.) lists only "cut and dried", with the idioms and phrasal variations of the headword "cut". —Michael Z. 2006-03-05 18:33 Z
- Given how infrequently pre is used, and even more infrequently how often it's allowed to go on forever without wrapping, is this really a big issue? I mean, are you objecting to this change? =) And I wonder if IE7 improves the situation at all. —Locke Cole • t • c 01:53, 1 March 2006 (UTC)
- Re-reading your reply, it looks like I might have read it wrong. What exactly does it do in IE? —Locke Cole • t • c 02:21, 1 March 2006 (UTC)
- It adds unnecessary scroll bars to all the pres, if I remember correctly. :-)
- MediaWiki_talk:Monobook.css/archive1#pre_autoflow — Omegatron 02:27, 1 March 2006 (UTC)
- Weird. FWIW, in IE7 it doesn't work at all (no scrollbars at all except for the horizontal page scrollbar because of the width of the page). I wish I could get IE6 working again so I could try it out in that (for some reason, whenever I enter a URL in IE's address bar, it opens it in Firefox; no, the humor of this is not lost on me, heh). —Locke Cole • t • c 02:50, 1 March 2006 (UTC)
What are we doing with this? Is this a go or no go? howcheng {chat} 00:08, 8 March 2006 (UTC)
- What's the difference between having scroll bars on the page or scroll bars on the pre? Is this really a problem? Couldn't people just add that to their user CSS if they really prefer having their scrollbars on the pre (which seems a bit weird to me). Personally, I don't see a compelling need for this. Kaldari 00:13, 8 March 2006 (UTC)
- Lets see...
First it depends on how wide your screen is, perhaps you have a screen that is so large that it easly fit large pre-block inside. Seccond is that perhaps you doesn't care if a lot of information is beeing located outside your sceen, and you have to scroll horizontally to access that information (or it's might be that you never access pages that large block of text in pre-tags). And, yes, I know this edit violates WP:POINT, but I had to do that :)
→AzaToth 00:46, 8 March 2006 (UTC)
- Yes, it's much much nicer to have scroll bars on the pre itself. This is done in a lot of forums with stuff inside code tags, for intance. I've had it in my monobook.css for a while and I like it. — Omegatron 01:23, 8 March 2006 (UTC)
That's a nice demonstration, but I still don't get the point. Why would anyone prefer scrolling the pre over scrolling the window? For a lot of people, it's easier to scroll the window, for example if you use a scroll ball or one of those two finger trackpads. Why is scrolling the pre so much better? It seems like a matter of user preference to me rather than something that should be universally implemented. Kaldari 01:34, 8 March 2006 (UTC)
- Have you tried it? What skin do you use, by the way? Maybe it doesn't look as horrible in a non-monobook skin... — Omegatron 01:41, 8 March 2006 (UTC)
- Actually I haven't been able to get this particular hack to work at all. Kaldari 02:30, 8 March 2006 (UTC)
Why is scrolling the pre so much better?
- Because then you don't have to scroll back to continue reading.
- You can continue reading the article while referencing a specific point in the pre area (coding articles)
- It doesn't act like a page widening attack and ruin the entire page's layout. — Omegatron 00:25, 24 March 2006 (UTC)
Please don't use overflow-y. It's not supported in many browsers, including Internet Explorer 6.0 and Safari 2.0. Use overflow instead, which works almost just as well and is supported by all modern browsers. —Michiel Sikma, 13:05, 13 May 2006 (UTC)
- Doesn't work in Firefox 1.0 either (1.5 works fine). Won't
overflow
cause a vertical scrollbar to be added in certain situations (looks like it doesn't)? That would be bad, whileoverflow-y
wouldn;t cause any problems. —Ruud 14:42, 13 May 2006 (UTC)- This is a <div> with the overflow-y attribute:
- And here is one with just overflow, which is much more widely supported:
First it depends on how wide your screen is, perhaps you have a screen that is so large that it easly fit large pre-block inside. Seccond is that perhaps you doesn't care if a lot of information is beeing located outside your sceen, and you have to scroll horizontally to access that information (or it's might be that you never access pages that large block of text in pre-tags). And, yes, I know this edit violates WP:POINT, but I had to do that
- I don't have all browsers around to test this with, but I can assure you that these two look the exact same on Firefox 1.5. I don't think there's a reason to use overflow-y over overflow. PS: this does not seem to work with actual <pre> tag... looks like block quotes might have to be auto-converted to <div> tags if we want this to be possible at all. —Michiel Sikma, 21:27, 13 May 2006 (UTC) PPS: it seems that line breaks don't get automatically converted in that <div> tag. The white-space: pre; CSS attribute doesn't seem to emulate <pre> properly. Maybe we need to get a CSS expert in here?
New style for media templates
I have been working to update the media templates to a semantic HTML/CSS version, but I need some opinions from CSS gurus. The current templates use tables for visual layout and an inline image for decoration. I propose changing these templates to a simple unordered list and doing the styling with a CSS class. I've already added the (experimental) CSS to Common.css, and the list versions of the templates look like this:
- Accordion chords (file info)
- Chords being played on an accordion — 145 KB
- Problems listening to the file? See media help.
-
"Where Did You Sleep Last Night?" (file info)
- Performed by Leadbelly, a folk singer and guitarist; this Southern Appalachian song dates to the 1870s
-
[[Media:{{{filename}}}|"Cross Road Blues"]] ([[:Image:{{{filename}}}|file info]])
- Performed in 1937 by Robert Johnson, a Delta blues guitarist
-
"Po’ Gal" (file info)
- East Coast blues, performed by Zora Neale Hurston in 1939
- Problems playing the files? See media help.
- Buzz Aldrin steps onto the Moon (file info)
- Problems viewing the video? See media help.
- Rover training (file info)
- Launch of Apollo 15 (file info)
- Transposition, Docking and Extraction (file info)
- Problems viewing the files? See media help.
If you turn off CSS, they just look like lists:
- Accordion chords (file info)
- Chords being played on an accordion — 145 KB
- Problems listening to the file? See media help.
Questions:
- I have assumed that a list is better for accessibility, but I could be wrong about this. I'm sure it's better than the table currently in use, but is something else better?
- I've replaced an inline image with a decorative background image. Since it's just a decorative image, I figure this is good. This will prevent people from clicking on it and going to the image description page, for one thing. But maybe it's not?
Should we genericize the list formatting as class="medialist", and have the individual classes like class="videolist" do nothing besides specify the icon? That way if other templates are wanted it is less CSS to change:I've done this.
Feedback:
- I think they look awesome. Nice templates. I'll be sure to use them when the need arises. —Michiel Sikma, 09:53, 8 May 2006 (UTC)
See also Template_talk:Listen#CSS_version — Omegatron 02:58, 1 March 2006 (UTC)
Columns of content without ugly tables
I have been working to get rid of table-based visual layouts lately, and tried to tackle content in columns, like some people prefer with See also sections that have tons of links, etc. I don't really like putting stuff in columns at all, but whatever; I might as well make them work well. Besides, with the CSS-based layout, people who really don't like the columns can turn them off in their monobook.css. ;-) The original table-based templates are at {{col-begin}}, and my new div- and CSS-based ones are at Template talk:Columns. I need feedback and it needs tweaking. Bypass your cache if you don't see the example. — Omegatron 20:33, 19 March 2006 (UTC)
references-2column class breaks Firefox
This is completely unrelated to the section right above this one, which proposes an alternate solution for the same problem. — Omegatron 00:42, 28 August 2006 (UTC)
/* VALIDATOR NOTICE: the following is correct, but the W3C validator doesn't accept it */ /* -moz-* is a vendor-specific extension (CSS 2.1 4.1.2.1) */ /* column-count is from the CSS3 module "CSS Multi-column Layout" */ /* Please ignore any validator errors caused by these two lines */ .references-2column { font-size: 90%; -moz-column-count:2; column-count:2; }
- This code breaks shit. FF 1.5.0.4. Someone please remove the line " column-count:2;" ASAP, please. --Connel MacKenzie - wikt 03:35, 22 August 2006 (UTC)
- It's also terribly unuseful and unreadable if things are in multiple columns because of the great amount of wrapping that then occurs. I'm tired of this "some people think this is a change for the worse, but you can always turn it off in your own stylesheet!" mentality that a lot of these CSS additions seem to be presented with. —msikma <user_talk:msikma> 06:00, 22 August 2006 (UTC)
- Would a sysop here PLEASE remove the line " column-count:2;" ASAP. --Connel MacKenzie - wikt 03:56, 26 August 2006 (UTC)
- OK, it's gone. —Mets501 (talk) 04:09, 26 August 2006 (UTC)
- Thank you for trying. --Connel MacKenzie - wikt 00:16, 28 August 2006 (UTC)
- OK, it's gone. —Mets501 (talk) 04:09, 26 August 2006 (UTC)
- Would a sysop here PLEASE remove the line " column-count:2;" ASAP. --Connel MacKenzie - wikt 03:56, 26 August 2006 (UTC)
- Strange. It's exactly the same thing which was inline in several articles; why would it break when placed on Common.css but not when inlined? And BTW, I'm also on Firefox 1.5.0.6, and see no problems. If it's just the complaint on the JavaScript console, that's not actually breaking anything; it's, as it says, dropping the unknown declaration, and thus making no difference. I'm adding it back; please explain how is it breaking things before removing it again. --cesarb 03:19, 27 August 2006 (UTC)
- For an example of an article which currently uses it inline, see 2006 Israel-Lebanon conflict. My objective in creating the .references-2column class is to have it in a single place, instead of in several articles, so that if a change is decided (for instance, to reduce the font size to 85%), it can be made in a single place. --cesarb 04:09, 27 August 2006 (UTC)
- First you say it isn't causing errors, then you admit it is, and use that for justification for putting it back in? Pray tell, how can I visit Wikipedia, if everytime I do I'm punished by seconds of lockups from garbage CSS as it blitzes my JS console with each page load? AND NOW YOU ARE ADDING THE SAME BAD CSS DIRECTLY TO ENTRIES? (I see you've edited that entry, but don't feel like finding out if it was you personally, or a cohort that made the edit in question...considering the hundreds of edits recently.)
- Error-causing CSS does not belong anywhere. Isn't it obvious that great pains were taken to ensure JS/CSS errors don't occur anywhere in a default mediwiki installation? Fix it, or remove it. As someone else noted above, the functionality this (sometimes) provides is unwanted anyway. --Connel MacKenzie - wikt 00:16, 28 August 2006 (UTC)
- Don't Wikipedia formatting guidelines talk about experimenting in 800x600 sized browser windows? The two-column display is horrid on the "target" screen size (true for sister-projects, anyhow.) Yes, it is a pain for me to shrink my browser window down that small, but I do it when I'm testing Wiktionary pages. I only maximize the window temporarily, so I can see (when it is resized back down) what the page looks like to visitors. The example page given above looks pretty silly in that mode. Out of all those references, only five were less than two line; most were many lines of wrapped text, with lots of whitespace lost in the middle. The splits themselves, of course, are illogical. --Connel MacKenzie - wikt 00:26, 28 August 2006 (UTC)
- Thankfully, your "fix" doesn't break:
- Internet Explorer 7
- Netscape Navigator 7
- Konqueror 3.5
- Mozilla 1.7
- lynx 2.8
- Elinks 0.11
- w3m/0.5
- So, I suppose your recommendation will be that I should stick to one of them? --Connel MacKenzie - wikt 00:39, 28 August 2006 (UTC)
- Thankfully, your "fix" doesn't break:
Assume good faith. I'm not the one who introduced the 2-column layout to several articles (in fact, I introduced it to none). I just want to consolidate the CSS declarations to a single place, to make it easier to make enhancements and fixes; to do so, it first needs to be identical to what is currently being done. An example of a possible enhancement that could be done once all the articles are using the CSS class instead of an inline style would be to add column-width
(and -moz-column-width
), which specifies a minimum width to the columns (and thus directly addresses your complaint about it not working well on smaller windows); another one would be to add column-gap
(and -moz-column-gap
) to add a bit more spacing between the columns. And finally, I fail to see how a single message at the JavaScript console causes any slowdown; you are the first one to report it (remember that I also use Firefox 1.5, so I'd notice it quickly if there were any slowdown). Unfortunately, there's no way to hide the CSS3 version of the declaration (without the -moz-
prefix) from Gecko. Since no browser seems to understand the CSS3 version (I believe it's there for future-proofing; again, it wasn't my idea), it would be possible to remove column-count:2
(keeping only the -moz-column-count:2
understood by Gecko), after the references-2column
class is widely adopted (if it were to be removed right now, it's possible that the centralization would not be accepted). --cesarb 19:38, 28 August 2006 (UTC)
Fixing super/subscript leading
What does everyone think of this? I'm largely CSS-illiterate, so I can't venture an opinion (although I'll note that Firefox displays subscript and superscript without screwing up leading, yay!) —Simetrical (talk • contribs) 04:44, 20 March 2006 (UTC)
sup, sub {line-height: 0.1em; font-size: 1ex;}
- … has worked well so far for me. One should perhaps take some care about font sizes, too:
sup small, sub small {font-size: inherit;}
Coordinates in article heading
In concert with MediaWiki talk:Monobook.css#Coordinates in article heading, Wikipedia talk:WikiProject Geographical coordinates#Coordinates at the top of the article, and bug 4719, need something like:
/* Do not expand kvaleberg.com-URLs for printing */ #content span.coordinates a.external.text:after, #content span.coordinates a.external.autonumber:after { content: ""; }
plainlinks padding
Why do plainlinks have padding: 0 ! important;
? It's overriding my user CSS. I can't change the padding even with !important. — Omegatron 00:23, 24 March 2006 (UTC)
Update Common.css to reduce redundancy
Please see "Updates to CSS and JS pages to reduce redundancy". --Melancholie 00:45, 24 March 2006 (UTC)
Suppress underline of linked IPA
A problem has been signalled with linked IPA strings in the discussion at wikipedia talk:Manual of Style (pronunciation). Such strings often contain diacritics and slight modifications under the base line. If such a string is underlined, readability is damaged. Therefore it would be better to suppress any underlining of IPA links. The IPA strings are supported by the template:IPA and the class IPA defined in this style sheet. Adding specific style elements for IPA links would achieve this, approximately as follows:
.IPA a:link, .IPA a:visited {text-decoration: none}
Could someone check this out and add it? −Woodstone 16:46, 29 March 2006 (UTC)
- Strongly agree. The underlining is very hard to read for some characters, but it's very useful to link various IPA characters to their respective articles. Compare ѵ vs. ѵ̟. —Simetrical (talk • contribs) 19:16, 22 August 2006 (UTC)
- Done. —Mets501 (talk) 03:49, 26 August 2006 (UTC)
Highlight search box
- Please answer at VPT:Highlight search box
A proposal that came out the Main Page Redesign discussions was:
- Improve visibility of the left-navigation search box in the default MonoBook skin, with an orange-colored border (as used on the active tabs at the top).
This would be to aid new users in finding the search box.
- this is easily shown by adding this line to one's user/monobook.css. (and presummably common or monobook css for sitewide)
#searchBody {border-color: #FABD23;}
The only question remaining is can this highlight be easily coded to display on only select pages? (specifically the Main Page, and possibly any others we wanted to choose) (or only for non-signed-in users, or other useful permutations?) Or is it a choice of "site-wide or not at all"?
Once this is answered, I will copy the proposal to the proposal page. Thanks. --Quiddity 04:19, 6 April 2006 (UTC)
- You could probably do it by inserting a stylesheet altering #p-search directly onto the Main Page code. Unfortunately, I can't think of how to do this without having MediaWiki allow the <style> tag, which would be a major vulnerability. —BorgHunter
ubx(talk) 03:23, 5 May 2006 (UTC)- You could add it to the same Javascript file that hides the title header for the main page, maybe. But I recommend against it, since it's nothing but an inconsistent change in colors that only further confuses the user by the already abundant amount of colors on the main page. There's also zero feedback to let the user know exactly what this highlighted box means; sure, it's a search box, but why is it highlighted? Although the answer is obvious, it's not directly so. I think that perhaps the best way to make the search box more accessible to first-time users would be to move it to a different (yet logical) place (for example, right above the navigation box is not a logical place). I've got some ideas and will make mock-ups for them later. —Michiel Sikma, 12:23, 9 May 2006 (UTC)
- Also, please note that a lot of people come in via http://www.wikipedia.com/ and will use the search box on the front page of the portal rather than the one right here. People who specifically come to http://en.wikipedia.org/ are the ones who have been there before and thus know how to navigate. —Michiel Sikma, 12:24, 9 May 2006 (UTC)
- Here is what I'm talking about. —Michiel Sikma, 06:33, 11 May 2006 (UTC)
.messagebox.standard-talk
--James S. 22:57, 11 April 2006 (UTC)
- I disagree. I like the old colors. And besides, I don't think you should just make changes that easily to a CSS property that affects a whole lot of templates which weren't designed for that color anyway. —Michiel Sikma, 06:30, 4 May 2006 (UTC)
Please revert "resizing of footnotes by CSS"
...as explained here: wikipedia talk:footnotes#Resizing footnotes - what is going on?, there was no community consensus to do that.
Please also see and/or contribute to (ongoing) discussions at:
- wikipedia talk:footnotes#Resizing footnotes - what is going on?
- Wikipedia:Village pump (technical)#Change to MediaWiki:Common.css requested for references
AFAIK, (from what I read in these discussion places), the size of footnotes was reduced to 90% in a solo-action by R. Koot (diff), so please revert it until consensus shows this would be a good idea (not the case currently). --Francis Schonken 10:11, 4 May 2006 (UTC)
- See Wikipedia:Village_pump_(technical)#Change_to_MediaWiki:Common.css_requested_for_references. When I changed this, there was nobody opposing it and a smaller font size is already used in the featured articles, indicating a wider support. The best way to see wath the opinion of the community is would be to change it and see what the reactions are. —Ruud 14:14, 4 May 2006 (UTC)
- Cut the nonsense please, people had been opposing this, e.g. in Village Pump (proposals), at wikipedia talk:footnotes and also in the new (technical) Village Pump discussion linked above. You didn't even wait 5 days, or more than *three* people commenting in village pump (technical) before performing the change (which could be seen as WP:POINT while not even checking prior discussion on the talk page of the footnotes guideline).
- "smaller font size is already used in the featured articles"... most of these would be twice reduced by now, illegible on most screens. The community consensus was to NOT go by css, but instead keep the {{subst:FootnotesSmall}} template, voted upon in a TfD and kept, which by its standard "subst:" implementation has left a font-reducing "div" tag surrounding the css-reduced references on many pages by now. So double size-reducing on many pages...
- "The best way to see wath the opinion of the community is would be to change it and see what the reactions are." - Even if such questionable mode of conduct would be acceptable (I'm not going to go into that): the community has reacted: NO CONSENSUS to apply a standard font-size reduction for footnotes by css, so this css change should be reverted immediately. Please respect the consensus-seeking proceedings of the wikipedia community. --Francis Schonken 15:08, 4 May 2006 (UTC)
- Yes, I agree. Although I think it's fine that an admin chooses to be bold, I think that in this case it shouldn't have been done. It has affected a lot of (mostly good, well-citing) articles that now have a way too small font size for their references. Some people have started fixing their articles up, which means they're going to have to put the font downscaling back in when this change to the CSS is rolled back. I think that changes that break existing content or would otherwise affect a whole lot of articles should not be done unless there is strong consent to do so. —Michiel Sikma, 19:00, 4 May 2006 (UTC)
- Please keep this. CSS is the right way to do it. --Ligulem 19:51, 4 May 2006 (UTC)
- Agreed, CSS is the correct way to handle styling, and references should be consistant across articles (using a template means that some articles have references sized smaller, other articles have them sized at 100%). —Locke Cole • t • c 20:34, 4 May 2006 (UTC)
- Please Change this back. There is no good reason to have a global change to footnote font sizes. It is done in print to save space, but we don't have that problem on Wikipedia. If you want to change it, please do so in your personal stylesheet, but don't do it to everyone--Blainster 21:27, 4 May 2006 (UTC)
- The problem is the majority of featured articles do use 90%, because this is the local consensus on these articles. As they are featured, that does carry some wheight. And there is no consensus to change that on those articles to 100%. So I would propose to try to do it everywhere the same way. 90% isn't such a bad compromise, as there are a whole lot of editors that want 85 or 90% on their articles. Plus you can override it in your own User:Blainster/monobook.css (or whatever skin you use). Specifying <div style="font-size:85%"> in articles is bad (also via template inclusion). --Ligulem 21:51, 4 May 2006 (UTC)
- I agree. An emerging standard for presentation should be enacted in the stylesheet. Removing all the individual reference section text size reductions that currently exist and enacting this presentation change in the stylesheet will take many less edits than adding reference section text size templates to all 1,000,000 articles. Content and presentation should be seperated. Gentgeen 07:20, 5 May 2006 (UTC)
- Yeah hardcoding presentation in the articles is generally bad. The size change should be done in style sheets either by making all refernces small or by having a special class for small refernces. Jeltz talk 15:58, 6 May 2006 (UTC)
- I agree. An emerging standard for presentation should be enacted in the stylesheet. Removing all the individual reference section text size reductions that currently exist and enacting this presentation change in the stylesheet will take many less edits than adding reference section text size templates to all 1,000,000 articles. Content and presentation should be seperated. Gentgeen 07:20, 5 May 2006 (UTC)
- The problem is the majority of featured articles do use 90%, because this is the local consensus on these articles. As they are featured, that does carry some wheight. And there is no consensus to change that on those articles to 100%. So I would propose to try to do it everywhere the same way. 90% isn't such a bad compromise, as there are a whole lot of editors that want 85 or 90% on their articles. Plus you can override it in your own User:Blainster/monobook.css (or whatever skin you use). Specifying <div style="font-size:85%"> in articles is bad (also via template inclusion). --Ligulem 21:51, 4 May 2006 (UTC)
Copied from Village Pump
- I'm fully in favor of anything that avoids the daft (to my mind) tendency to crush footnotes to 85% or even less of the size of standard text. But I disagree with the need to bring it down even to 90%. Look at Hiroh Kikai, for example. The notes contain a lot of kanji, which (assuming your computer is set up to display them at all, of course) are likely to be harder to read at 90% than at 100%. So 100% is a good size (for media:screen, at least). I thought I'd change it back to 100%, via <references style="font-size:100%" /> but no, that throws up a syntax error ("Cite error 6; Invalid parameters; expecting none"). For media:screen, I see no need to make the font for footnotes any smaller than that for the main text. (It's not as if web pages were printed on paper.) And for WP, I think small print in footnotes could be a Bad Thing: it might suggest to editors and potential editors (as well of course as non-editing readers) that sources and "sourcing" really aren't important or are a tiresome chore normally deserving no more than token attention (cf boilerplate legalese). -- Hoary 08:34, 6 May 2006 (UTC)
I totally agree with Hoary. 90% on Hiroh Kikai is insane (I've corrected that temporarily to 100% in that article). Putting everything down to 90% doesn't work. Let's do the small-references class as I proposed below. --Ligulem 09:35, 6 May 2006 (UTC)
- Agree as well, that did look pretty bad. —Locke Cole • t • c 09:51, 6 May 2006 (UTC)
- Disagree with the above. In my view the 90% size looks much better and more professional. I have no trouble distinguishing the kanji characters. −Woodstone 10:14, 6 May 2006 (UTC)
- I've looked at it in IE 7 (beta 2) and in Firefox 1.5.x and in both, with the text size of the browser at default, some of the kanji characters become impossible to decipher (because they effectively turn into black squares or groups of black squares). Are you certain your browser isn't set to use a larger font by default, or perhaps you have something in your userspace CSS that's overriding it? I strongly sympathize with wanting a uniform appearance, but this corruption of certain character sets isn't acceptable. (Though perhaps we could try something larger like 95%?) —Locke Cole • t • c 10:38, 6 May 2006 (UTC)
- For Anyone's Interest, I'm using Konqueror with the text size at default. (And I'm delighted to say that, like its predecessors, IE 7 won't run on my computer.) -- Hoary 10:53, 6 May 2006 (UTC)
- I've looked at it in IE 7 (beta 2) and in Firefox 1.5.x and in both, with the text size of the browser at default, some of the kanji characters become impossible to decipher (because they effectively turn into black squares or groups of black squares). Are you certain your browser isn't set to use a larger font by default, or perhaps you have something in your userspace CSS that's overriding it? I strongly sympathize with wanting a uniform appearance, but this corruption of certain character sets isn't acceptable. (Though perhaps we could try something larger like 95%?) —Locke Cole • t • c 10:38, 6 May 2006 (UTC)
- I double checked, looking at the old version of Hiroh Kikai. My screen is a 17 inch at 1024x1280, medium text size in IE, 0 in firefox. To my surprise the kanji looked quite a bit worse using firefox (1.0.7) than with IE6.0. Actually the font turns out even a little smaller in IE, but is better readable. I tried resolution 768x1024 as well and there the difference remains but is less. Surprisingly in firefox the kanji is less cluttered on that resolution than in the higher one. All in all, I still favour a slightly reduced font for footnotes.
- As to the "professionalism" issue, that refers the "graphical" art as developed over many years for printed material. Certainly the web may have some different requirements, but that is by no means valid on all issues. The great majority of professional printed publications use smaller print for footnotes. So emulating that on the web evokes an image of professionalism to me. Feel free to disagree. −Woodstone 11:26, 6 May 2006 (UTC)
- Ligulem has indeed reverted the size reduction, but he's done so via precisely the kind of DIV kludge that I read (misread?) was about to be zapped by some bot. What he didn't do (because he couldn't) was adjust <references/> itself. At 90%, I too have little trouble distinguishing the kanji, but I have more than minimal trouble, and don't see what purpose is served by this small but additional trouble. Neither do I see how 90% looks better than 100%. As for the claim that it looks "more professional", I don't even know what this means, other perhaps than that small text is more reminiscent of professional websites. Well, professional (i.e. made-for-money) websites typically fall somewhere between mediocre and spectacularly bad, so to me "professionalism" in web design is no compliment. -- Hoary 10:53, 6 May 2006 (UTC)
- That (the bot run) was my suggested course of action if this was to be kept in MediaWiki:Common.css. The claims of professionalism stem from the idea that all references should be the same size in all articles (in other words, I shouldn't go from article A to article B and encounter varying sizes of text, one at 100%, the other at 92%, and still others at some other size as the authors saw fit). It looks bad. —Locke Cole • t • c 11:17, 6 May 2006 (UTC)
Please, please, please revert harmful change
Like in subject. This imposition is definitely not consensus, and causes problems for lots of people. Think disability community, for example; but also just pages that already use sizing of notes (which I don't think is a good idea either, but it's article-by-article). If users want custom CSS, that's fine, but don't impose disruptive CSS on all readers. LotLE×talk 19:08, 4 May 2006 (UTC)
- There was consensus on WP:VPT. —Locke Cole • t • c 20:34, 4 May 2006 (UTC)
- This change was not discussed on a sufficiently visible forum. The "consensus" consisted of exactly two (2) users. More than that have already objected. --Blainster 21:25, 4 May 2006 (UTC)
- Yeah, the only thing I can find on this alleged "consensus" is a discussion where maybe 3 people thought it was a good idea, and 4-5 thought it was a bad idea. And since then, numerous other editors have objected. At the very least, someone with the power to do so (I'm not an admin) should roll it back pending actual consensus being reached about the fairly dramatic and system-wide change. LotLE×talk 21:46, 4 May 2006 (UTC)
- Please also look at the older discussion [8]. There were more voices pro CSS. --Ligulem 21:49, 4 May 2006 (UTC)
- The dissenters showed up after the change was made. AFAIK there were no dissenters prior to the change. —Locke Cole • t • c 22:04, 4 May 2006 (UTC)
- I don't know how much more visible it could get than being discussed on the village pump twice. Maybe we should have asked for a notice to be placed in MediaWiki:Sitenotice too? *rolleyes* —Locke Cole • t • c 22:04, 4 May 2006 (UTC)
- Yeah, the only thing I can find on this alleged "consensus" is a discussion where maybe 3 people thought it was a good idea, and 4-5 thought it was a bad idea. And since then, numerous other editors have objected. At the very least, someone with the power to do so (I'm not an admin) should roll it back pending actual consensus being reached about the fairly dramatic and system-wide change. LotLE×talk 21:46, 4 May 2006 (UTC)
- There seem to be many more people arguing against this change than there are arguing in favour of it. Quite apart from the fact that it seems to have been changed without sufficient discussion beforehand, even retrospectively there is nothing approaching a consensus in favour of the change. It should be reverted for this reason alone. If references are now unreadable for many users, then this makes the need to revert still more urgent – Gurch 06:56, 5 May 2006 (UTC)
Compromise on references
If ol.references { font-size: 90%; }
is removed, could we then at least agree to add .references-small { font-size: 90%;}
and use that class on all those articles that want the smaller font? I think adding references-small doesn't hurt that much, right? This would at least eliminate the absolutely uneeded difference between 85% and 90%. Plus no need to hard code that into articles (or templates). --Ligulem 22:10, 4 May 2006 (UTC)
- Why don't we just make all of the text smaller while we're at it? — Omegatron 23:16, 4 May 2006 (UTC)
- Yes, this is what I would prefer. But apperently there is no consensus for this. As a compromise I would opt for adding
.references-small { font-size: 90%;}
. I'm trying to find a compromise that is acceptable for all. If everybody here insists on his position, then we just risk thatol.references { font-size: 90%; }
is removed and we are where we were before. Which is cleary not satisfactorily. But I must concede that I by myself was astonished thatol.references { font-size: 90%; }
was added to Common.css. Of course it was a surprise for me and I would be more than happy with that. But as you see, there are others here which are not happy with that at all. So I agree that this is no consensus for plainol.references { font-size: 90%; }
. So if there is an admin that removesol.references { font-size: 90%; }
I urge to add.references-small { font-size: 90%; }
as a replacement. Just for the records: I'm not an admin. --Ligulem 10:15, 5 May 2006 (UTC)
- Yes, this is what I would prefer. But apperently there is no consensus for this. As a compromise I would opt for adding
- Yes, this is what I would prefer.
- I was being sarcastic, actually. If you want all of the text on the page smaller, set it in your browser or your monobook.css. There's no reason for this arbitrary changing of font size for only certain parts of the article, and there's no reason to change the font size for everyone when only a few want it smaller. — Omegatron 17:03, 5 May 2006 (UTC)
- It was actually me who failed to convince people to refrain from using smaller fonts (as just one example: [9]). Ok chaps, do whatever you want. I've said what I had to say. --Ligulem 21:12, 5 May 2006 (UTC)
- :/
- The original issue stemmed from the fact that many people were wrapping
<references />
inside a DIV tag that modified the text size. This is non-uniform, and probably undesirable because some pages end up using 100%, some end up using 85%, and still others use values from 90-95% of the standard font size. By having this in a CSS class, we can affect all usage of references at once (or, as Ligulem suggests, at least provide a CSS class so pages will just use<div class="references-small"><references /></div>
). Of course it'll be more challenging to get people to use .references-small, and it still leads to some articles being 100% and others being whatever .references-small is set to.. but it's still better than using a template to do this (especially since the template is subst'd, making it impossible to update or change without going through and re-subst'ing them again). —Locke Cole • t • c 02:21, 5 May 2006 (UTC)
- The original issue stemmed from the fact that many people were wrapping
- I like the idea of defining a CSS class for small references. This allows consistent usage for those articles that want it, while not forcing it on all those articles where editors do not want it. And yes, I know individual logged in editors can disable it... but most readers of WP don't have the knowledge nor inclination to do this. LotLE×talk 03:21, 5 May 2006 (UTC)
- Maybe it's undesirable in YOUR opinion, Locke Cole, but not in everybody's. Again, I must point to the fact that not everybody feels that this is appropriate, and still the change was brought forth. Again, we should be pointing you towards your own monobook.css in which you should have made the changes for yourself; just because two people agree that a change should be made doesn't mean it's okay to make a site-wide change that breaks articles! And like I said, this is also about the editor's preference. It's obvious that some articles needs their references to be at 85% size and some do not. Again, disagree if you might, but this is what Wikipedia thinks, since some references are at 100% size and some are at a smaller size, and it depends on the amount of references entirely which one is used. You are avoiding consent by the community by this change because such a thing would never survive if it was actively sought. I think it's disgraceful that such changes can be made, and I find it even offensive that this is now actually being defended! Guys, wake up! No consent was sought for a site-wide change, which is against Wikipedia's nature!
- Having said that, I must agree that it's a great idea to unify the format of Wikipedia for consistency purposes. However, I firmly believe that some articles are better off without a smaller reference size (such as Re-recording, for example), while some are (such as Speedrun). Unifying the format is most likely best done by adding a CSS class for references-small which would have preferably a font size of 85% (as I find that 90% font size gives tiny problems with italic text in GNU/Linux with Bitstream Vera Sans as default font, which a lot of distros use). I would agree to such a change and help change articles to use this class rather than a percentage in font size. It's a whole lot better to simply do this rather than changing the references size for all articles, since, like I've pointed out, it's just harmful to articles. The references with double font downscaling are, at this moment, still not readable for some operating systems (such as Windows without font anti-aliasing) or people who can't read small text properly (I too have problems with my high resolution).
- I really hope that this is rolled back and changed into the references-small CSS. That would be okay, since it wouldn't break any existing articles. Please seek consent in the future, for the good of Wikipedia. —Michiel Sikma, 06:49, 5 May 2006 (UTC)
Proposing other solution (at least part of a solution for the future)
Part of this problem has been caused by me, but resulting from something completely different than the resizing issue: one of the complexities of this problem was caused by the fact that both the {{Footnotes}} and the {{FootnotesSmall}} templates were instructed to be used by a "subst:" (placing a lot of "div" tags in article namespace, that can't be undone by changing the template content). The reason for this has nothing to do with RESIZING but with the "help" comment included in these templates that doesn't become visible in edit mode unless with a "subst:" being applied to the template previously.
Here's a solution I'd like to elaborate (doesn't clean up the size-reducing div tags now in article namespace, but might be a better solution for the future).
PLEASE GIVE ME SOME TIME TO TRY THIS OUT
Here's a short description. Might seem complicated at first sight, but in fact it's quite simple, and adresses the issue, independent from the technique (css or "div") used for resizing:
- "Footnotes" template can be used either {{subst:Footnotes}} (resulting in 100% size) or {{subst:Footnotes|XX%}} This template - that contains the help comment - calls a non-subst application of {{footnotesSmall}}.
- "FootnotesSmall" is henceforth only to be used non-subst, and so does not need to contain the help comment. The technique for the resizing is contained/applied in that template (css, div tags...) but users not acquainted with these techniques are not bothered with that. The only thing they would see in "edit" mode is something that looks like this {{FootnotesSmall|resize=XX%}}. Understandable. Everyone can modify it without needing to be enlightened about css calls or whatever. The technical people can decide on how to implement the resizing in the "FootnotesSmall" template: all they need to know is that they're expected to receive a "resize" parameter, and if there is none, a standard resizing (e.g. 90%) is applied.
Also needs rewriting the instructions regarding the use of these templates on wikipedia:footnotes, but I'll try to make this work technically first. --Francis Schonken 14:54, 5 May 2006 (UTC)
- SEEMS TO WORK
- Will update footnotes guideline now.
- Things left to be done by an admin (at least the two first steps):
- remove the current overall css resize instruction from common.css
- replace it by a resize instruction by a call from common.css, e.g. .references-small { font-size: 90%;} OR .references-small { font-size: 92%;} (I prefer the second option).
- implement that .references-small call in {{FootnotesSmall}}, with a condition that if this template receives a resize=100% parameter, the resizing by css call to .references-small is not effectuated (& update user instructions on that page that only "100%" or alternatively "90%"/"92%" as standard resizing parameters are possible).
- tx! --Francis Schonken 16:02, 5 May 2006 (UTC)
- In fact, I've always copied the comment manually and used the template in non-subst mode. Sistematically, though, someone else has always removed the manual comment and used the subst, despite my further comments explaining why I didn't subst the template in the first place :) Now that everything is managed at the CSS level however (as it had to be from the start) we shouldn't have such issues again. What I would like to point out, though, is that the possibility to specify the
<resize=whatever_I_like>
is contrary to the spirit of both the template and of the css, i.e. having a *consistent* formatting in all articles. The class references-small just changes the font size: if I can specify a different size anyway, then what is its purpose? I would prefer sticking with something between 92% and 95% (or maybe simply<small> </small>
) and remove the resize parameter; one can always enlarge the whole page text with the scroll of a wheel, or a menu click, after all. --Gennaro Prota (talk) 23:34, 8 May 2006 (UTC)
- In fact, I've always copied the comment manually and used the template in non-subst mode. Sistematically, though, someone else has always removed the manual comment and used the subst, despite my further comments explaining why I didn't subst the template in the first place :) Now that everything is managed at the CSS level however (as it had to be from the start) we shouldn't have such issues again. What I would like to point out, though, is that the possibility to specify the
Reminder
To the admins or sysops: as you can read here and on the Village Pump technical page, there is no and never has been a consensus on changing the footnotes size. Please revert it for now until a consensus has been reached, as the change should not have been made in the first place. —Michiel Sikma, 10:58, 6 May 2006 (UTC)
- Except there was consensus, hence why the change was made to begin with. Please stop mis-stating the chronology of events; the ruckus was not raised until after the change was made. —Locke Cole • t • c 11:14, 6 May 2006 (UTC)
- Please stop lying. There was no consensus because you need more than just two people who have commented on an issue that has been around for only three days to reach a consensus. Now that the change has been made, everybody noticed it, and thus they have come here to give their opinion. It's only a good way of seeing that there are indeed people who explicitely disagree with this change, but didn't even know it was in the making.
- And as you can see in the old discussion, there never has been a consensus on this. Ever. And there isn't one now. Hence, whether this is a correct change or not doesn't matter because it should never have been made in the first place. —Michiel Sikma, 11:36, 6 May 2006 (UTC)
- Hi, please go read WP:CIV and WP:NPA. Calling people "liars" is incivil and a borderline personal attack. —Locke Cole • t • c 21:18, 6 May 2006 (UTC)
- You are not speaking the truth, Locke Cole, since, like I said, there was never consensus on this. You also never bothered to respond to the link I gave that leads to the old discussion in which there is no consensus.
- Now, this has gone on for long enough. Let's stop this. The change has been disputed endlessly by many different people, and the original reason the admin (Ruud) made the change early was to see if anybody would dispute it, as I cite: "The best way to see wath the opinion of the community is would be to change it and see what the reactions are." - the reactions were negative. As such, the change needs to be reverted. There is no reason not to do so. —Michiel Sikma, 22:41, 6 May 2006 (UTC)
- Hi, please go read WP:CIV and WP:NPA. Calling people "liars" is incivil and a borderline personal attack. —Locke Cole • t • c 21:18, 6 May 2006 (UTC)
Anyway, as a temporary solution, I made {{FootnotesSmall}} work according to the solution explained above. This solution currently uses div tags with style="font-size:...%", but adjusts correctly (with a workaround solution):
- {{subst:Footnotes}} or {{subst:Footnotes|100%}} or {{FootnotesSmall| resize = 100% }}, will always give the text of the references *in the same size* as the rest of the text on the page;
- {{subst:Footnotes|92%}} or {{FootnotesSmall}} or {{FootnotesSmall| resize = 92% }} (or any other % differing from 100%) will resize the text of the references to 92% of the size on text on the rest of the page.
Further, I note that some admins refuse to follow established consensus on wikipedia talk:footnotes, and the actual text of the Footnotes guideline that does not recognise that the <references/> tag should in any way resize the text of the references. These admins abuse their power, and that's as simple as that. I mean, I don't need admin powers to help guidelines and policies materialize (and I do quite some of that). Admins refusing to adjust the css according to these guidelines and policies is a completely different cup of tea. It won't make me pursue to become an admin (yet), for such one-off anomaly. I had some previous example of Ruud Koot's anti-wiki behaviour of trying to impose a solution by forced means against community consensus, and would still be able to document the strain he put on the wikipedia community then. With this new case, maybe time to ask Ruud's deposition as a sysop (whatever his other, more positive, contributions to wikipedia).
Please let me know when the css is updated. I'll not continue to follow this page, but might further promote the solution that resizes with div tags for having normal size of footnotes, although currently that is a deplorable workaround. So please let me know when the css is up-to-date, and I'll reverse these solutions, and assist to make a more elegant resizing template. --Francis Schonken 16:55, 7 May 2006 (UTC)
- I'd like to weigh in here... I strongly prefer reference font-sizes to be handled solely with .css and not with div tags. Exactly what this font size should be? I have personal preference for the smaller font-sizes (e.g. 90%), and can use my personal monobook.css to specify that (so as not to force my preference on everyone). But, when some articles use div tags then my personal preference becomes 81% font size. Please, we need to get away from using div tags and leave it to .css to deal with reference font sizes. --Aude (talk | contribs) 21:24, 7 May 2006 (UTC)
- If you solely want to browse references at 90% size only, then you could make the font-size of .references-small 111% in your custom CSS to null its effect. There is currently simply no good way of putting a smaller font size in the CSS for all references without breaking lots of things. And there's also the matter of opinion here, since there are editors who prefer using 100% size for articles with fewer references. —Michiel Sikma, 21:28, 8 May 2006 (UTC)
Size of traditional references
What should be done with History of entropy, which contains:
<div style="font-size:85%"> #{{note|Mendoza}} {{cite book|author=Mendoza, E. |title=Reflections on the Motive Power of Fire – and other Papers on the Second Law of Thermodynamics by E. Clapeyron and R. Clausius|publisher=New York: Dover Publications, Inc.|year=1988|id=ISBN 0486446417}} #{{note|tribus}} M. Tribus, E.C. McIrvine, “Energy and information”, Scientific American, 224 (September 1971). #{{note|avery}}{{cite book|author= Avery, John|title=Information Theory and Evolution|publisher=World Scientific|year=2003|id=ISBN 9812384006}} </div>
This is not affected by ol.references { font-size: 90%;}. --Ligulem 22:19, 7 May 2006 (UTC)
- Ok. Thanks for [10]! I applied the new references-small: [11]. --Ligulem 07:03, 8 May 2006 (UTC)
Is the intention in reducing the size simply to ape traditional print design, or specifically to visually indicate that the references are supplementary material? If references are smaller, then so should be other supplementary notes sections, including "See also", "External links", and "Further reading", as well as their headings, otherwise this is just inconsistent and certainly isn't an improvement. Let's not make major design changes to Wikipedia ad hoc and pell-mell.
By the way, why not just apply the keyword value "font-size: smaller;", which in modern browsers is the equivalent of 83.33% (=X/1.2). Since the default normal size in visual browsers is 16px, other useful values would be 93.75% (=15px) or 87.5% (=14px, which looks quite good in my browser). Relative sizes (relative keyword, em, or percentage) must be used, not absolute sizes (px, technically relative, but treated as absolute by most browsers).
If this format is to be applied reliably and flexibly throughout the Wikipedia, then someone should fix Bug 4741, so we can globally apply a style to all article sections called "References", and to their headings. —Michael Z. 2006-05-08 15:46 Z
- This last thing is exactly what was done a while back and has since been reverted due to discontent with the result. Reference sizes as well as the other sections that belong in the same category should be set to a new font size manually since there isn't really always a good systematic way of setting them. Usually, other reference types are also set to the same small size. Seems like this might be something for the manual of style to consider writing about.
- As for the font size, here are some comparison images: Windows and Linux. It seems that there's a gigantic gap between 87% and 86%. However, setting "font-size: smaller;" might be a good idea, since there seems to be consistency between the 83% size for Windows and Linux (I had a Mac OS 10.2 screenshot as well, but it's on a different computer so I can't show it at the moment; it was similar to Windows, though). It's something to consider. —Michiel Sikma, 21:23, 8 May 2006 (UTC)
- For comparison, here's a screen shot in Safari on Mac OS X 10.4.2 (I logged out to only use the default style sheet). The test page is at User:Mzajac/Font_size_test; feel free to edit it and use for more screen shots.
- From the screen shots, its looks like Firefox/Win and Safari both round percent-sized fonts to the nearest pixel. I don't know what Firefox/Linux is doing: perhaps rounding it to the nearest keyword size. A screen shot in MSIE/Win would be mandatory before making any decisions based on this. —Michael Z. 2006-05-09 04:30 Z
- Here's a full comparison: font hinting test results. I'd say that "smaller" is a nicely consistent font size between the different operating systems and browsers. —Michiel Sikma, 06:22, 9 May 2006 (UTC)
- Hi guys, I really don't understand all this bicycle shed discussion. What would be wrong with having one css class and let the user override its settings in his own monobook/whatever_else css? We do that for pretty much anything, why would footnotes be different? --Gennaro Prota (talk) 09:51, 11 May 2006 (UTC)
- Having all references at one smaller size is not a good idea because this breaks existing articles and is unwanted by a lot of editors, as it disables the ability to have references at 100% size. Having all references at one size is apparently against the style consensus of the editors. This CSS class allows us to fulfill the desires of the editors while retaining consistency in the articles that do have a smaller reference size. —Michiel Sikma, 06:32, 12 May 2006 (UTC)
- Very nice test sheet. To me "smaller" is really too small. That should not be the default for not-logged users. −Woodstone 09:53, 11 May 2006 (UTC)
- I think you might be right, actually. It's not a good idea to reduce usability for the reason of decreasing the size of articles. —Michiel Sikma, 06:32, 12 May 2006 (UTC)
- Hi guys, I really don't understand all this bicycle shed discussion. What would be wrong with having one css class and let the user override its settings in his own monobook/whatever_else css? We do that for pretty much anything, why would footnotes be different? --Gennaro Prota (talk) 09:51, 11 May 2006 (UTC)
Dark tables/infoboxes
The following CSS code should allow for dark/black wikitables and infoboxes. Significantly, this overrides the standard link colors so they'll work against a dark background.
This code should be placed below the existing wikitable CSS classes.
/* wikitable dark class for skinning tables/infoboxes */ table.wikitable.dark { background: #000000; color: #ffffff; } table.wikitable.dark th { background: #808080; } table.wikitable.dark a { color: #ffd447 !important; } table.wikitable.dark a:visited { color: #a5c969 !important; } table.wikitable.dark a:active { color: #0558ff !important; }
This code should be placed below the existing infobox CSS classes.
/* Infobox dark template style */ .infobox.dark { background-color: #000000; color: white; } .infobox.dark a { color: #ffd447 !important; } .infobox.dark a:visited { color: #a5c969 !important; } .infobox.dark a:active { color: #0558ff !important; }
If you'd like to see an example of this in use, please see User talk:Locke Cole/tvb. Please note that you'll need to copy the above CSS code into your userspace Monobook.css (or whichever skin you use). Note that the link colors are simply inversions of the existing link colors (hence why they're kind of ugly). If someone has a better idea for link colors, I'm all ears. =) But otherwise, I don't think there's anything else wrong with this (though I'd love some input from any CSS gurus out there). —Locke Cole • t • c 02:30, 5 May 2006 (UTC)
- Why? — Omegatron 17:53, 6 May 2006 (UTC)
- Someone wanted to do an infobox with a black/dark background, but with links it was hard to read. The only way to override the link color is to do something like..
[[WikiLink|<span style="color: <new color>">WikiLink</span>]]
. Obviously it'd be nicer if you could specify a different CSS class and have all the links changed automatically. —Locke Cole • t • c 21:11, 6 May 2006 (UTC)
- Someone wanted to do an infobox with a black/dark background, but with links it was hard to read. The only way to override the link color is to do something like..
One week later and with no objection I'm requesting this be added. Whoever adds this, pleas be sure to place them as noted above. —Locke Cole • t • c 13:53, 12 May 2006 (UTC)
Undiscussed changes
R. Koot, your change [12] specifically effected every browser except MSIE. Furthermore, the font you specified, Arial Unicode MS, has a serious bug affecting its display of some IPA. Please discuss changes to the style sheet before you make them. —Michael Z. 2006-05-06 18:27 Z
What are the style .LatinX and .MUFI? Where were these additions discussed? —Michael Z. 2006-05-06 18:31 Z
- Okay, I found {{Mufi}} and {{Latinx}}. Is it not possible to create a single font list to roll {{Latinx}} into {{Unicode}}? Shouldn't the class names and template names be capitalized the same way, to prevent confusion? —Michael Z. 2006-05-06 19:21 Z
- Replied at Michael's talk page. —Ruud 19:14, 7 May 2006 (UTC)
Proposal: class same-bg
It is sometimes useful to use borderless tables for lists. See here for an example. However, with the Monobook skin, http://en.wikipedia.org/skins-1.5/monobook/main.css sets the background of all tables to white:
/* general styles */ table { background: white; font-size: 100%; color: black; }
(None of the other styles currently do this.) As far as I can tell, the best way to get the same background is with the CSS setting background: none
. You can, of course, use the HTML style
attribute:
{| border="0" style="background:none" ...
but I much prefer using a CSS class in situations like this. See Village_pump_(technical)#CSS_setting_.22background:none.22 for some (ahem) background information (and note that background-color: inherit
does not work in Internet Explorer v6.x).
I therefore propose adding something like
.same-bg { background: none }
to MediaWiki:Common.css. (Or should it be added to MediaWiki:Monobook.css? Or even to /skins-1.5/monobook/main.css
?). This class name is just a suggestion.
Comments, questions, suggestions, improvements, etc all welcome. Cheers, CWC(talk) 09:17, 9 May 2006 (UTC)
- Wow, the silence is deafening. I hope that means that no-one objects to this change?
- If the change is made, we should explain the useage and usefulness of
class=same-bg
in m:Help:Table. We should probably also put a brief note about background colors in Wikipedia:How_to_use_tables#Possible_problems. - Hoping for at least one reply (pretty please?), CWC(talk) 12:41, 17 May 2006 (UTC)
- Looks good to me, and I'd put it in common.css rather than monobook.css in case some other skin similarly sets table colors. The usage note shouldn't be in m:Help:Table, since if the style is in MediaWiki:Common.css it would only be available in en.wikipedia (right?). Perhaps Template:Ph:Table or Wikipedia:How to use tables would be more appropriate. (ok, now you comment on mine, below) -- Rick Block (talk) 13:31, 17 May 2006 (UTC)
What is the advantage of removing this to the style sheet, rather than just using the inline style? I'm usually all for IDs and classes, but in this case it seems only to complicate the situation.
A suggestion: let's start naming table styles consistently (see also the stripes proposal below). How about prefixing all table styles with a "t-", and keeping them short and concise, as in class="t-nobg"
? —Michael Z. 2006-05-22 15:14 Z
- The major advantage of using a class rather than inline style is ease of future change — for example, if IE7 or a hypothetical iSafariPod needed something different.
- This class would be mostly used with tables, but could also be used in other elements, so the otherwise-reasonable "t-" convention is probably not wise in this case. I chose "same-bg" to be more meaningful to Wikipedians who don't understand the details of the CSS background properties, but I'm not firmly attached to the name.
- Cheers, CWC(talk) 04:52, 26 May 2006 (UTC)
- There's no reason to have different classes for tables versus other things. This style change is applicable to everything, in any case (anything could benefit from a transparent background), but if it weren't, you'd just use a selector like
table.same-bg
instead of simply.same-bg
. But regardless, I don't think we should go around creating single-attribute classes without having a reason beforehand; it's possible that a future browser will have trouble withstyle="background: transparent"
, sure, but it's also possible that a future browser will have trouble withstyle="color: red"
, or any other CSS attribute, or for that matter a problem with classes! We can't add all these things to the CSS, and every one we do add increases the size of a file that every viewer has to download by just that much.Please don't add this class to anything more until we've worked this out; classes can't be tracked down without great difficulty, and so if the class is removed from the stylesheet cleanup will be a bugger. —Simetrical (talk • contribs) 22:32, 9 July 2006 (UTC)
Request for Edit
Please add
.same-bg { background: none }
to MediaWiki:Common.css. Thanks, CWC(talk) 13:13, 3 June 2006 (UTC)
- Done. howcheng {chat} 17:27, 7 July 2006 (UTC)
This CSS code is incorrect.Sorry, my bad,background: none
sets the background image tonone
, not the background color, and so is superfluous (since background-images are generally impossible in MediaWiki). The correct CSS style isbackground: transparent
See the W3C specs. Both appear to work in Firefox, butnone
might not work as expected in all browsers, since it's not standards-compliant.background
is a sneaky attribute. It resets everything unspecified to its initial values, so what you have does work if you don't care about resetting all the image-related background stuff.In any case, the default for table background should be transparent. Look at Special:Movepage/Cat, for instance, for an example of the current Monobook's ugliness. But that's a Monobook question. —Simetrical (talk • contribs) 22:32, 9 July 2006 (UTC)
Font size wars
Can we please stop this silly conflict over the font size of references? All of the same arguments in favor of 'variable reference size' could be applied to the size of general text in each article as well... yet we don't have ridiculous edit wars over that. Logically, any instance of someone customizing the footnotes to look 'just right' on their browser to their personal preferences is going to make them look 'just a little off' on someone else's browser to their personal preferences. Which is why we'd smack someone upside the head if they tried to hard code in sizing of the general text. So... everyone trying to manually set the footnote sizes 'just right' for your screens? Consider yourselves smacked upside the head. Everyone is going to have a different take on whether 90% or 100% or 92.374% or whatever is the 'just right' footnote size. It is therefor ridiculous to code these separately for each instance of footnoting. All it accomplishes is silly edit wars and a chaotic mess where everyone sometimes gets footnotes that look too small, sometimes too big, et cetera. Pick a percentage which seems 'ok' (maybe not 'just right', but 'ok') to most and apply that globally. Then people who actually care about three pixels height more or less can make adjustments in their local CSS or browser to set things so they look right. There is no way to manually set the font-size so that it looks right to everyone... so the only logical approach is to set a consistent size which is at least reasonable and allow each user to fine tune if they wish. Kind of like we do with the size of text in general. --CBDunkerson 08:51, 11 May 2006 (UTC)
- I do not believe there is a font size war. There is some consensus on a lot of articles (a lot featured ones), where the editors prefer a smaller font for the references. Most common is 90%. So we managed now to have a CSS class references-small in this style sheet here. All I ask is to apply this class for the case where a smaller font for the references is wanted instead of hard-coding 90% into the articles. I also ask to use one common class for small references, and not to use 75%, 85%, 92% (common used sizes) for smaller references. I managed to exchange these hard-coded sizes with CSS class references-small on a lot of articles already and I encountered only opposition on Joel Brand as per today (possibly not based on technical/editorial grounds). --Ligulem 09:15, 11 May 2006 (UTC)
- Who can you deny that there is one? :) Admit it please, CBDunkerson's remarks are hardly questionable. In my humble opinion, the reason why we have all this noise here but not about other elements of the page is that no one asked about the latter (please, don't try to confirm or disprove this theory :)). And once you ask you get the classical Bicycle Shed Effect. —Gennaro Prota•Talk 14:26, 22 May 2006 (UTC)
- Font size war? What are you talking about? You're late; the discussion is over. We decided that a global CSS class for small references is what we need. We made it and are now applying it to the articles that have their references set to a smaller font size via style attributes. Also, I find is offensive that you think we're just idiots who are constantly changing the font size of the references around to suit our needs. I don't use a custom stylesheet because I want to make sure that what I see is what the guest reader will see, since that's mainly the group of people that I'm writing this encyclopedia for. I'd happily give up personal tastes if it helps me help the casual users retain a good usability when using this site. Reference sizes are part of that as well. Right now, the consensus is to use this, and the references are set to 90% font size. I personally prefer a smaller font size than that (I was using 85% in my articles before) but it seems that 90% might be more usable to most people. It doesn't matter. I don't see a reason for why you should complain at this time when we have a decent policy in effect. —Michiel Sikma, 06:39, 12 May 2006 (UTC)
- Oh, well as long as there isn't any hostility over the issue anymore. :]
- Sorry, but saying 'we are now applying the global CSS class' doesn't mean the argument is over when there are people deliberately removing that global CSS class.
- As to the rest of your diatribe... you are absolutely right. It makes no sense whatsoever to describe your actions in such a way. So... uh why do you assume I was doing something that makes absolutely no sense? Maybe I wasn't talking to you, but rather to those who are still switching notes to 85% or 95% or whatever else looks 'just right' to them? --CBDunkerson 11:40, 12 May 2006 (UTC)
- Well, it's true there was hostility over the issue. It was a pretty heated debate. It's cooled down now, but there's still disagreement over the issue. There are people who think that 90% is too small for their references, and I'm of the opinion that exceptions on a per-article basis should be possible, although not recommended. And yeah, you're right: me saying that "we're now applying the global CSS class" doesn't mean that anybody is besides me and some other people of which I know they're doing it, so it probably sounded a bit wrong of me to say that. It's true, however, that it's recommended by the style guide to not use style tags if it's possible to just use CSS, for consistency purposes.
- Having said that, I think we should still continue the debate on what actually does globally look best to most people (or the most important user group). 90% might not be the best size. —Michiel Sikma, 07:59, 13 May 2006 (UTC)
It still seems to be ill-thought through to me. A page with a smaller font for references, followed by see also and external links in the normal size looks bad. —Michael Z. 2006-05-22 15:20 Z
I agree. This arbitrary resizing or hiding of reference text in some articles but not others is irritating and counterproductive. We need to add something about this to the Manual of Style and start disciplining people who persist in edit warring over it. — Omegatron 13:54, 22 August 2006 (UTC)
Segmented infoboxes
I recently changed template:Infobox U.S. state so that a couple of the "rows" which were multiline elements (with labels and values effectively coincidentally appearing as "virtual rows") are actual rows in the table. Doing this requires making a couple of the rows neither bordered nor borderless, but "semi-bordered" with vertical cell separation but without row borders within a block of cells. Doing this within a single template is a little ugly, and the current version of template:Infobox U.S. state does not display as intended with IE (because IE does not support the border-top style in a TR). Looking at several of the templates in Category:Infobox templates I believe there are perhaps several dozen templates that could benefit from infobox styles for this purpose (perhaps called "toprow" and "mergedrow"), examples include:
- template:Infobox Alaska Communities
- template:Australia state or territory
- template:Infobox Australian City
- template:British Columbia municipality infobox
- template:Alberta municipality infobox
In general, I suspect any template that derives from template:Infobox Country could use such styles. I don't pretend to be a CSS expert, but I think the following would have the right effect:
.infobox.bordered .toprow td, .infobox.bordered .toprow th { border: 0; border-top: 1px solid #aaaaaa; border-right: 1px solid #aaaaaa; } .infobox.bordered .mergedrow td, .infobox.bordered .mergedrow th { border: 0; border-right: 1px solid #aaaaaa; }
Comments please. -- Rick Block (talk) 03:22, 16 May 2006 (UTC)
- Well, Rick's suggested CSS looks good to me. I'd expect it to be useful in lots of templates. Leaving out a few horizontal lines can make tables much more readable.
- (By the way, template:Infobox U.S. state is a very impressive piece of work. Even with IE6 leaving out too many horizontal lines, it is readable, concise and informative. Great work, folks! But I wouldn't be so complementary if Rick had not replaced the "parallel <br>s" trick with proper table structure. That sort of trick nearly always creates more problems than it solves in the long run.)
- Cheers, CWC(talk) 15:41, 17 May 2006 (UTC)
- The above idea would make editing multiline entries much easier, but needs some improvement. When suppressing the line, also the adjoining padding should be suppressed. And I wonder why it is only implemented sepcifically for "infobox.bordered" and not just for any "infobox" or even "wikitable".
.wikitable mergedrowtop td, .wikitable mergedrowtop th, .infobox .mergedrowtop td, .infobox .mergedrowtop th { border: 0; border-top: 1px solid #aaaaaa; border-right: 1px solid #aaaaaa; padding-bottom: 0; } .wikitable mergedrow td, .wikitable mergedrow th, .infobox .mergedrow td, .infobox .mergedrow th { border: 0; border-right: 1px solid #aaaaaa; padding-top: 0; padding-bottom: 0; } .wikitable mergedrowbottom td, .wikitable mergedrowbottom th, .infobox .mergedrowbottom td, .infobox .mergedrowbottom th { border: 0; border-right: 1px solid #aaaaaa; padding-top: 0; }
Comments? −Woodstone 10:30, 26 May 2006 (UTC)
- (still not pretending to be a CSS expert) It's currently infobox.bordered matching borderless, although I wouldn't object if it is made more general. I assume eliminating the padding would make it possible to use in (for example) Template:Infobox Australian City without having the separate cells with a background color visibly separated, which would be a good thing. One small change that's likely redundant, but I think I'd add a border-bottom to mergedrowbottom (it's redundant since the next row should be either a bordered row which will have a border-top or a mergedrowtop which will have a border-top - but who knows what weird thing somebody else might come up with in the future). -- Rick Block (talk) 14:37, 26 May 2006 (UTC)
- Looking into this a bit more, perhaps a better way to do this is with the border-style attribute for the appropriate border rather than by removing all borders and then readding the vertical ones. For example (similar changes would apply to all others):
.infobox .mergedrow th { border-top-style: none; border-bottom-style: none; padding-top: 0; padding-bottom: 0; }
- In addition, truly merged rows only seem to be possible if the border-collapse attribute is set to collapse which is only the case for bordered infoboxes (and wikitables). Any other comments on this? -- Rick Block (talk) 15:22, 3 June 2006 (UTC)
Excellent idea. This would even make it possible to slim down to:
.notop td, .notop th { border-top: 0; padding-top: 0; .nobottom td, .nobottom th{ border-bottom: 0; padding-bottom: 0; }
In a top row one would set class="nobottom", in a middle row class="notop nobottom", and in a bottom row class="notop". This could be applied for any kind of table. −Woodstone 16:08, 3 June 2006 (UTC)
Straw poll for footnote font sizes
There is a lot of heat/light on this topic which mixes several different issues: which font size is best for references, whether a certain change should have been made, whether it should be reverted, whether different articles should have different reference sizes. Perhaps a simple straw change on one question would help see where the community stands: which font size is preferable for reference/footnote sections of articles. Leave aside whether enforcing any change immediately would break FAs - let's just establish the desired end result: Stevage 13:07, 18 May 2006 (UTC)
- At the moment there is a fairly peaceful situation. I have converted a lot of articles that had hard coded sizes of 70%..92% to use CSS class references-small (so that we have that setting in one place here and being overrideable per logged-in user – for example me). I have applied that not only to sections with <references/> but generally to reference sections of varying kind (for example articles that do the referencing with the {{ref}} or other methods). I did not touch articles where there was no hard coded font size reduction and I did not replace hard coded fontsizes of 95% or larger (per request on article Joel Brand by SlimVirgin). I would keep it as it is for now. It was already hard enough to reach this compromise. And it is clearly a lot better that what we had before. All we could do is talk about the correct value for references-small. But I would recommend not to change that at the moment. If you lower that below 90% wikipedians will jump off the train and remove that CSS class from "their" articles and use again hard coded fontsizes. 90% was the most common used fontsize where small fonts are wanted. For example I can't remember having seen a featured article (FA) using a different reduced font-size (There are of course FA's that don't reduce the font size for the references). --Ligulem 15:14, 18 May 2006 (UTC)
- 100% - All reference sections in all articles should be the same size as their body text
- Comment (I don't vote for this): would be nice to have. Simply don't reduce the fontsizes for references. But we can't enforce that. There is no consenus to do this on all articles. But some articles already have it so. That's fine. Don't change that. --Ligulem 16:51, 18 May 2006 (UTC)
- Support — what is the purpose: to look like a book? To save paper? It looks poorly-designed when footnotes are small, followed by full-sized "see also" and "external links". —Michael Z. 2006-05-22 16:03 Z
- Support — I don't see any reason to reduce their size. If you must, use a site-wide CSS class and kill the size templates. — Omegatron 23:42, 24 May 2006 (UTC)
- Oppose — it is standard to have footnotes smaller than the body text to distinguish between the body text and footnotes. I see no reason to adopt an unprofessional and amateurish look and also looks hideous, particularly in articles with large numbers of footnotes. FearÉIREANN
\(caint) 22:12, 26 May 2006 (UTC)
- Support — This is the one I prefer, but size doesn't matter to me as much as how you use it. (Sorry, I just couldn't resist.) The automated reference notes (created by adding '<references/>') already has a references class assigned to it, and other references can also be wrapped in a div with the same class. If you want to modify the size of the font, please use that class.—Mike 05:23, 5 June 2006 (UTC)
- 90% - All reference sections in all articles should be 90% the size of their body text
Font sizes should never be other than 90% for footnotes.
- Sign here with comment
- Comment (I don't vote for this). 2nd best option for articles where the editors want a smaller font for the references. But please please do it with CSS, so that I can override it with my personal CSS file. --Ligulem 16:54, 18 May 2006 (UTC)
- Support. This is a well proven good looking form. It should be achieved by a template and CSS class. −Woodstone 09:03, 5 June 2006 (UTC)
- 100% by default, use a template for smaller fonts
- That is, reference sections 100% by default, but can add {{FootnotesSmall}} if small footnotes are desired
- Sign here with comment
- Comment (I don't vote for this): There is no need for a template. Do it with CSS. --Ligulem 16:56, 18 May 2006 (UTC)
- Comment (no vote): There's no need for any of this. It's fine the way it is. 100% size for most articles, 90% for some. —Michiel Sikma, 14:47, 20 May 2006 (UTC)
- 90%/85% by default, use a template for larger fonts
- That is, reference sections 85% or 90% (specify in your comment) by default, but can add {{FootnotesSmall}} if a larger footnote font is desired
- No one yet
- 100% by default, references should use DIV tags to specify font sizes as desired
- The ad hoc solution.
- No one yet
I don't care what the general style is, but don't change it on a per-article basis
No templates or <div>s, just a stylesheet specification (whether 100% or smaller). Or if it's done per-article, at the very least make sure it's a template so that it can be easily changed or removed if we change our minds later.
- Sign here with comment
- Consistency is more important than any one style with respect to the appearance of professionalism. —Simetrical (talk • contribs) 20:41, 18 May 2006 (UTC)
- (comment) Design the page. If footnotes are to be small, then they should all be, and so should other supplementary sections like notes, references, see also, external links, and the format of their headings should also reflect the reduced emphasis. —Michael Z. 2006-05-22 16:07 Z
- Sorry, for putting in a remark rather than voting, but I think it is very important to consider the following (slightly adapted from a discussion at Ligulem's talk page): "historically there have been all sorts of errors in this issue (wrapping
<references/>
in adiv
element, using a template in non-subst mode etc). Now we have a chance to remedy. What I question is the very same idea of choosing styles on a per article basis. If we agree that this should not be done then everything follows as a consequence: MediaWiki decides the class (the same for all articles) and logged-in users possibly override its attributes." --Gennaro Prota•Talk 15:06, 18 May 2006 (UTC)
- Trying to decide here something is one thing. Convincing wikipedians out in the big wilderness of articles is a completely different matter. You can vote here what you want. The key thing is, will it be accepted by wikipedians or not? If they disagree, they simply remove the CSS class again from their article and slap in their hardcoded beloved XX% again. --Ligulem 15:23, 18 May 2006 (UTC)
- So you are saying trying to establish a guideline is one thing, having people following it is another one? Then let's erase all the WP:MoS. As to the specific case, they can't in fact remove the class attribute, but they can enclose everything in a xx% div which, by an accident of HTML semantics, "applies" as a multiplier to what is contained within (e.g.: 90%×100% = 90%). OTOH this "customizations" may *always* happen, no matter how many choices you give in common.css: people could not like using italics for album titles, or God knows what. They could write:
<div style="font: italic small-caps 12px arial"><references/></div>
And what can we do? We don't have any control over this. I see it as a limitation of MediaWiki. Wikipedia definitely needs a sort of compilation phase, to parse articles before committing, so that errors are never inserted, rather than fixed manually by troops of people who sacrifice their mental and physic energies for (temporarily) correcting other people's negligence. --Gennaro Prota•Talk 16:37, 18 May 2006 (UTC)
- So you are saying trying to establish a guideline is one thing, having people following it is another one? Then let's erase all the WP:MoS. As to the specific case, they can't in fact remove the class attribute, but they can enclose everything in a xx% div which, by an accident of HTML semantics, "applies" as a multiplier to what is contained within (e.g.: 90%×100% = 90%). OTOH this "customizations" may *always* happen, no matter how many choices you give in common.css: people could not like using italics for album titles, or God knows what. They could write:
- So you are saying trying to establish a guideline is one thing, having people following it is another one? Yes. --Ligulem 16:42, 18 May 2006 (UTC)
- Then let's erase all the WP:MoS. I thought conforming to a project guideline was a prerequisite for joining it. In the programming world, you may be easily fired for intentionally violating coding guidelines. Apart from such considerations, what would you constructively suggest? --Gennaro Prota•Talk 16:49, 18 May 2006 (UTC)
- After having had a night of sleep and thought again about this: Why don't you propose a change to the MoS then? My recommendation would be to listen to and watch carefully article editors and trying to detect what they want. That's a key thing on wikipedia (consensus). If we find common use patterns of styles on a lot of articles, then we can try to move that into CSS. The other way is to propose a change to the MoS and try to gather consensus there. BTW I don't encourage to ignore guidelines. But there are a whole lot of wikipedians out there that even don't read them. And if enough wikipedians ignore a guideline, you can consider the guideline as being rejected. The only hard thing are policies. Today, we already have in the MoS (emphasis added):
--Ligulem 07:00, 19 May 2006 (UTC)"Formatting issues such as font size, blank space and color are issues for the Wikipedia site-wide style sheet and should not be dealt with in articles except in special cases. If you absolutely must specify a font size, use a relative size, that is, font-size: 80%; not an absolute size, for example, font-size: 4pt."
- I don't see why we're having this discussion right now. As it is, the solution that we have now is fine. We're not supposed to put unfair restrictions on editors, especially since editors are better judges of how an article should look rather than an algorithm. Font sizes must always be consistent, and consistency lies in the font size of 100%. However, some argue that a 90% font size makes references more readable: I agree with that, and that's why we made a CSS class with which people can override the default of 100%. Articles with references sometimes don't have more than ~15 references, which I recon could be seen as a limit at which to start using 90% font size. Articles with few references are much better off simply having the few that it does have at 100% size. As noted above, I don't see why there's a straw poll about this. The current situation is fine. —Michiel Sikma, 14:51, 20 May 2006 (UTC)
- After having had a night of sleep and thought again about this: Why don't you propose a change to the MoS then? My recommendation would be to listen to and watch carefully article editors and trying to detect what they want. That's a key thing on wikipedia (consensus). If we find common use patterns of styles on a lot of articles, then we can try to move that into CSS. The other way is to propose a change to the MoS and try to gather consensus there. BTW I don't encourage to ignore guidelines. But there are a whole lot of wikipedians out there that even don't read them. And if enough wikipedians ignore a guideline, you can consider the guideline as being rejected. The only hard thing are policies. Today, we already have in the MoS (emphasis added):
- Why should the number of references be relevant—are you trying to save paper? Making the text smaller indicates its supplementary nature. Making some reference sections with small font and others not is simply inconsistent, and contributes to an unprofessional feel of the web site.
- References sections are often dynamic. Now you are adding the editing burden of changing their format when they reach a certain size. This will contribute to inconsistency.
- Finally, as mentioned before, it is further inconsistent when the similar “See also”, “Notes”, and “External links” sections are contrastingly large.
- I appreciate your puristic stance. It's just not enforceable. If I understand you correctly, you are against that CSS class references-small. I just do not understand why. Did you actually take a look at what editors have done on articles? We had a gazillion applications of all sorts of "shrunken" font sizes for things that are reference-like (70%, 75%, 80%, 85%, whatever). Now we are trying to harmonize that shrink-zoo to 90% using a CSS class. Isn't that an improvement over the current situation? --Ligulem 13:31, 23 May 2006 (UTC)
- It's totally an improvement.
- But I still keep seeing people espousing smaller font for references, and very specific variations like smaller font when there are over 15 references, without articulating why they believe this is a good idea. I want to know what the design intent of this exercise is, so that I can offer advice help apply it consistently and in support of the design objective.
- Near as I can tell, different editors think this is a good idea for different reasons, most of them being something like "I like it". This is not a suitable basis for a major design change potentially affecting the appearance of thousands of Wikipedia articles. I fully support the use of the "references-small" template to help support the proposed changes, when we have made an informed decision regarding what they should actually be (or support undoing them). —Michael Z. 2006-05-23 14:25 Z
- To clarify, using a div with a class name is the best way how to apply small font to a section. But we still haven't clearly articulated why we should do this, and which articles and sections we should do it to. This is why there is conflict and chaos over the issue. It's a major issue affecting global article design issues, and we should seek wide opinion and get solid consensus. —Michael Z. 2006-05-23 15:03 Z
- There is no chaos. We actually have a consensus now. As you said yourself, it's an improvement we have now. --Ligulem 15:27, 23 May 2006 (UTC)
- I didn't realize that there was a consensus on where and how to use the smaller references style. Is this to be used where there are more than 15 references as stated above, or for all references sections. What about "Notes" or "Further reading" sections? "See also", "External links"? Can you point out where the consensus was determined, and add it to Wikipedia:Citing sources and Wikipedia:Citing sources/example style?
- Currently, all the documentation I can find is at WP:CLASS, which says "For small-font references in articles (in any format, not only Cite.php). To be used where the per article consensus demands smaller font for the references. (original discussion; see also {{FootnotesSmall}})". A guideline which says "use where desired" is not really a guideline. —Michael Z. 2006-05-23 17:26 Z
- Late, but I have to agree with Michael on this issue. — OwenBlacker 02:40, 28 May 2006 (UTC)
Table font sizes
Can someone add to table.wikitable font-size: 95% and change the padding to 0.4em? The table looks very "thin" and big right now and it is not aesthetically pleasing. Class="wikitable" looks so bad now that people are just not using it anymore and have gone back to using custom styled tables, which is exactly what we are trying to avoid in Wikipedia by using a Common style. For a comparison between the current style and what I'm proposing, see User:CieloEstrellado/tmp ☆ CieloEstrellado 03:14, 19 May 2006 (UTC)
- No one else wants that. Just add
table.wikitable {font-size: 95%;}
to User:CieloEstrellado/monobook.css — Omegatron 20:56, 20 May 2006 (UTC)
- Quite a while a discussion on this point (see above) has led to no change. Certainly no one agreed to more padding. Currently it is 0.2em. Making it 0.4em makes the table even thinner (your words). There was also no consensus for 95% font size, because many tables contain special characters that may become difficult to read. However, you can easily scale the font by setting class="wikitable" style="font-size: 95%" in a specific case. −Woodstone 12:07, 20 May 2006 (UTC)
- What good would that do? 95% font size is hardly even visibly smaller. It's imperative that we keep a consistent font size, anyway. I do think that it would be useful if the header of tables were in bold, though. —Michiel Sikma, 14:44, 20 May 2006 (UTC)
- The headers of tables are in bold. — Omegatron 20:56, 20 May 2006 (UTC)
- Oh, sorry, I didn't mean the header cells, I meant the captions. E.g.: —Michiel Sikma, 11:25, 21 May 2006 (UTC)
- The headers of tables are in bold. — Omegatron 20:56, 20 May 2006 (UTC)
- What good would that do? 95% font size is hardly even visibly smaller. It's imperative that we keep a consistent font size, anyway. I do think that it would be useful if the header of tables were in bold, though. —Michiel Sikma, 14:44, 20 May 2006 (UTC)
Header cell of a table |
---|
Content cell of a table |
- I agree. I proposed this a while ago, when the class was still a template, along with putting the caption beneath the table, but it never happened. — Omegatron 14:00, 22 August 2006 (UTC)
Proposal: striped table CSS class + JS
Hey all. I thought that people who watch this page may be interested in a proposal that I've posted on Wikipedia:Village pump (proposals) about striping wikitables. It involves changing CSS and JS. It's posted here: Village_pump_%28proposals%29#Proposal:_striped_table_CSS_class_.2B_JS. —Michiel Sikma, 05:21, 22 May 2006 (UTC)
- I looked into the same thing. — Omegatron 14:34, 22 August 2006 (UTC)
References class in references sections
I've read over the discussion here, but it's a bit unclear to me as to what exactly the references class was originally meant for. I thought it was just for footnotes (in long notes sections), and not reference sections, but that isn't clear. Could someone confirm that for me? --Spangineer[es] (háblame) 13:11, 22 May 2006 (UTC)
- It is meant to be used in both the references and footnote sections (if such a distinction exists in the articles), but I've also seen at least one article use it for the external link section. —Ruud 13:35, 22 May 2006 (UTC)
- This duality could even be one reason why we aren't able to reach a consensus. I, for one, could live with smaller footnotes, but I'd like references to be normally sized (especially because they usually have lot of italics, bold, etc., as estabilished by the Cite web, Cite news templates). In any case, that's just my taste and it means pretty much nothing. What matters is that we can't allow style choices on a per article basis. Accessibility and best practices considerations apart, I have never seen an encyclopedia where each article uses its own typographical style for footnotes or references. —Gennaro Prota•Talk 14:12, 22 May 2006 (UTC)
- I have replaced hard coded font size reductions with class references-small that I found in sections named like "Notes", "Footnotes", "References" and the like. Some example diffs might help (see my contribs for more): [13], [14], [15], [16], [17]. --Ligulem 16:47, 22 May 2006 (UTC)
- Initially I started with hardcoded font size and as I later discovered the class, I changed to references-small class --Oblivious 18:25, 22 May 2006 (UTC)
I bring it up because I hadn't seen this before (no FAs to my knowledge until just recently), and the reason for shrinking the text in the notes sections (having really long notes sections) doesn't often apply to references or further reading sections. I'd recommend leaving this to the individual authors of the articles to decide if it warrants shrinking or not, but in general I don't think they should be. --Spangineer[es] (háblame) 20:23, 22 May 2006 (UTC)
- Leaving this up to the individual authors of the articles to decide. Yes, that's what I'm doing. But I do replace hard coded size reductions on referencing stuff I find with the CSS class references-small. BTW a whole lot of FA had used hard coded 90%. I've replaced that on those articles with the CSS class references-small. What's the problem with that? This is clearly better than hard-coded 90%. --Ligulem 21:55, 22 May 2006 (UTC)
- We need a clear and stricter style guide for this. I've been working on a citation style guide in my user space which will also cover reference sizes in the future. Once it's finished, I'll link to it here; maybe we can use the ideas I'll outline for the official Wikipedia style guide if it is agreed with. It's at least a good idea to get some sort of policy going. —Michiel Sikma, 10:29, 23 May 2006 (UTC)
- Ligulem, you're doing exactly what I'd like; there's no problem. Others have been systematically shrinking references sections using this new class, and I don't think that's a good idea. --Spangineer[es] (háblame) 12:23, 23 May 2006 (UTC)
- Ah. Ok. I agree that applying references-small to cases where the references previously were non-shrunken, is bad. But if it's the per article consensus, then better doing it with CSS. We simply can't decree that references should be 100% everywhere. There are too many fans of the smaller fonts for the references. We should try to keep going forward with that CSS references-small and only apply it where wanted. This is better than a failed try to centralize on a singly style that half of the wikipedians deliberately ignore and then resort to hard coded font-size "corrections" again. --Ligulem 13:17, 23 May 2006 (UTC)
- Ligulem, you're doing exactly what I'd like; there's no problem. Others have been systematically shrinking references sections using this new class, and I don't think that's a good idea. --Spangineer[es] (háblame) 12:23, 23 May 2006 (UTC)
For what it's worth, I've created {{references-small}} which adds a references block in the small style. Stevage 10:32, 23 May 2006 (UTC)
Class name
The class "references-small" is named after its presumed presentation in a visual browser. This is contrary to good authoring practices for semantic/structural HTML. In text-only browsers and audible screen readers, this text will not be smaller, but it may be given a different colour, font weight, tone, pitch, etc. We may decide to use the same format for sections other than "References", including Notes, Further reading, See also, and External links, e.g. supplementary sections.
I propose renaming the class "s-supp", an abbreviation of "section, supplementary". Other future classes intended to apply to sections of an article could also be named with the s- prefix.
References:
—Michael Z. 2006-05-23 14:44 Z
- I disagree with the rename. --Ligulem 15:23, 23 May 2006 (UTC)
- Me too. --Siva1979Talk to me 03:23, 26 May 2006 (UTC)
- I disagree; the whole point of the class is to change the presentation of the section on a visual browser. --cesarb 22:00, 26 May 2006 (UTC)
Minor edit request: link to article about CSS in comment
Could some admin please put a link to CSS somewhere in the comment section on the top? This would help the newbies learning what CSS is. Thanks! --Ligulem 17:03, 25 May 2006 (UTC)
- Done. —Ruud 13:20, 27 May 2006 (UTC)
Syntax Highlighting Proposal
I created a syntax highlighting proposal a while ago, at WP:VPR#Syntax Coloring. It seemed to making some headway, but Rick Block suggested I move it here:
Proposal
Currently, source code in Wikipedia looks rather dull:
/* * This is fake Java code to demonstrate syntax coloring. * */ public static void main(String[] args) { String s = new String("This is a test"); char ch = 'c' + 123; }
Would it be better if syntax coloring could be applied to the code? Here is an example:
/* * This is fake Java code to demonstrate syntax coloring. * */ public static void main(String[] args) { String s = new String("This is a test"); char ch = 'c' + 123; }
To implement this, I had to use several <span>
tags to achieve this, which makes the code almost incomprehensible. What I am suggesting is a modification to MediaWiki:Common.css or MediaWiki:Monobook.css. We would define styles for various types of words in a syntax block:
/* CSS code */ syntax key { color:blue; font-weight:bold;} syntax string {color: maroon;} syntax char {color: orange;} syntax number {color: teal;} syntax comment {color: green;}
In the source code, we could simply write out:
<syntax> <comment>/** this is a comment</comment> <string>"Hey there!"</string> </syntax>
This makes future editing much simpler. If a certain user wished to customize the colors and styles, or turn them off, all he would need to do is modify his own CSS file. This would also pave the way for a possible syntax highlighting tool, much like the <math> tool. The parser would already have the styles in place.
Please, relay your thoughts to me. --Max Talk (add) 04:04, 23 May 2006 (UTC)
Comments
The earliest comments are still on the original page. Unsure of policy on this issue, I felt it was best not to copy their comments over.--Max Talk (add) 06:26, 26 May 2006 (UTC)
- I strongly oppose the use of colour in code samples. As most code samples in Wikipedia are very short, colour makes the code much harder to read (instead of easier, especially for people with vision problems). Any formatting of code can be done using bold and italic, which doesn't require any CSS classes. Also see Wikipedia:WikiProject Computer science/Manual of style (computer science). —Ruud 22:09, 26 May 2006 (UTC)
This is fake Java code to demonstrate syntax coloring.
public static void main(String[] args) { String s = new String("This is a test"); char ch = 'c' + 123; }
- I tend to agree with Ruud — syntax highlighting is more likely to be a hindrance than a help in the case of most code on Wikipedia. Wikipedia shouldn't contain large chunks of code (that kind of thing is more appropriate for Wikibooks, or sites like LiteratePrograms). --Allan McInnes (talk) 22:56, 26 May 2006 (UTC)
- Better not doing it in color. Syntax highlighting is ok for a programmer-editor, but not here. I agree with Ruud. --Ligulem 09:03, 27 May 2006 (UTC)
- I also oppose color syntax highlighting. It might look "neat", but I really do not think it has much actual value for this context (especially since pseudocode is supposed to be used whenever possible anyway). I think it would just get in the way. However, if we do end up having this go through, please make sure the standard colors are tolerable for those of us with various forms of color blindness. -- Zawersh 06:57, 28 May 2006 (UTC)
- Support. I think that Wikipedia should definitely do this. In fact, I can't see why this hasn't been done before. It's a great thing to be able to use the Web's capabilities to show color in code, something that books usually don't do simply for commercial reasons, as printing in color is expensive. This is a great thing and will help out the articles about code a lot. —Michiel Sikma, 19:09, 28 May 2006 (UTC)
- Support. Articles would benefit from it. --Siva1979Talk to me 04:09, 16 July 2006 (UTC)
I already have a syntax highlighter for CSS in my javascript. Look for /* Syntax highlighting on pre areas */
. — Omegatron 14:39, 22 August 2006 (UTC)
Force font to Arial Unicode MS, Lucida Sans Unicode on Microsoft Internet Explorer
Does anyone object to adding
* { font-family: "Arial Unicode MS", "Lucida Sans Unicode", sans-serif; font-family /**/:inherit; } textarea { font-family: "Arial Unicode MS", "Lucida Sans Unicode", monospace; font-family /**/:monospace; } pre { font-family: monospace; }
to Common.css? Disadvantage (Internet Explorer only): it overides the font selected by the user in their browser preferences, and can only be re-overridden by changing their own monobook.css. Advantage: it avoids situations such as this, this and probably many more. —Ruud 01:03, 27 May 2006 (UTC)
- P.S. I believe the default font in Internet Explorer is Arial, so for most users which have Microsoft Office installed (with which Arial Unicode MS ships) there should be no difference. —Ruud 01:05, 27 May 2006 (UTC)
- For the articles themselves we already have methods that should be used to mark unicode text so it displays correctly while not effecting the bulk of the body text (and your assertion that ariel and ariel unicode ms are identical for western text is not true). As for the edit boxes i'm not sure sacrificing a fixed width font is worth it. You could consider simsun for the edit box but i'm not sure how widely installed it is on western systems and it renders some ranges (such as greek) horriblly. Plugwash 01:09, 27 May 2006 (UTC)
- The problem is that {{unicode}} is not used consistently. Using Arial/Lucida Unicode for textarea is optional, however I see little advantage in using a monospaced font as (unlike source code or HTML) wiki markup doesn't use any "alignment". —Ruud 01:38, 27 May 2006 (UTC)
- I have added the proposed definitions to my monobook.css. I don't know if this produces the same as adding them to Common.css, but I noticed that the font of h1,h2,h3 as rendered on my Windows XP pro SP2 with IE 6.0 (patches all current) looks horribly bad. The fonts are rendered in a very poor resolution (I have 1280x1024 resolution on 19'' analog CRT monitor and I use standard type smoothing of fonts - not Cleartype, which is for LCD screens). This does not happen without these definitions. If requested, I can upload/email a screen shot. --Ligulem 09:28, 27 May 2006 (UTC)
- A screenshot would be helpful. —Ruud 13:13, 27 May 2006 (UTC)
- Without the proposed CSS modification: → Image:Fonts-WinXP-PRO-SP2-IE-6-Wikipedia-test-1.png. With your proposed modification made in my Monobook.CSS → Image:Fonts-WinXP-PRO-SP2-IE-6-Wikipedia-test-2.png. --Ligulem 14:25, 27 May 2006 (UTC)
- In the second screenshot, font smooting is disabled entirely. I have no idea why that happens? Do you have Arial/Lucida Unicode installed? What happens if you select Arial/Lucida Unicode in Internet Settings > Fonts > Latin? Can anyone else reproduce this? —Ruud 15:41, 27 May 2006 (UTC)
- Do you have Arial/Lucida Unicode installed? I do have "Arial (True Type)", "Arial Black (TrueType)", "Arial Black Italic (TrueType)", "Arial Bold (TrueType)", "Arial Bold Italic (TrueType)", "Arial Italic (TrueType)", and "Arial Unicode MS (TrueType)". When I double click on "Arial Unicode MS (TrueType)" in the Fonts system folder, it get a window with font examples and information about the font. The 18 size font looks bad, all other examples look good. BTW I do have font smoothing enabled (set to standard, as noted above). My Arial Unicode MS has the following additional info: Arial Unicode MS (OpenType), OpenTypeFont, Digitally Signed, TrueType Outlines, Version: 1.01, Digitized data copyright (c) 1993-2000 Agfa Monotype Corporation. --Ligulem 16:27, 27 May 2006 (UTC)
- I asked my brother. He has an LCD monitor with the same resolution as I have. He said it looks the same on his Windows XP pro as on my PC (he saw it on my PC), but only if he has set the font-smoothing to "Standard". If he has set it to "Cleartype", then it looks good (which is his ususal setting on his LCD monitor with digital interface). I conclude that this is a bug of the Arial Unicode MS font, that manifests if font-smoothing is set to standard. It looks good when font smoothing is set to "Cleartype", but that's not recommended for CRT type monitors. --Ligulem 16:35, 27 May 2006 (UTC)
- What happens if you select Arial/Lucida Unicode in Internet Settings > Fonts > Latin? If I open "Tools → Internet options → Fonts" and do set "Arial Unicode MS" for Latin based Language script in IE, the rendered page in IE looks equally bad as when I use your new CSS definitions in my Monobook.css, that means it looks exactly as this one → Image:Fonts-WinXP-PRO-SP2-IE-6-Wikipedia-test-2.png (which is lousy). Addendum: I forgot to remove your new CSS definitions from my monobook.css. Now, If I set "Tools → Internet options → Fonts" to "Arial Unicode MS" for Latin based Language script in IE, the rendered page looks good. --Ligulem 16:48, 27 May 2006 (UTC)
According to Arial Unicode MS, it does not support smoothing in the 14-18 pt range :/ (Strange, as Linux does smooth this font, how can smoothing be disabled for a certain range anyway? Why can't Microsoft just make something without bugs?) —Ruud 18:26, 27 May 2006 (UTC)
- Hoho, Arial Unicode MS is a decent article... Should have read that before. Yes, really strange that smoothing is not supported in that range. --Ligulem 18:55, 27 May 2006 (UTC)
- This is likely because it's supposed to be an add-on to the existing Arial font in case some glyphs can't be displayed with it. These are usually characters that aren't hinted (mostly because there are so many of them, like the Chinese alphabet, for example). Unhinted anti-aliasing would look awful on those fonts, so it simply isn't. It's still very stupid that it indiscriminately turns off anti-aliasing for all glyphs, though. —Michiel Sikma, 21:09, 27 May 2006 (UTC)
- They probably are hinted at 14-18pt but I think that hinting and smoothing are mutually incompatible. I can imagine that unhinted/smoothed CJK characters would look worse than hinted/unsmoothed ones. —Ruud 21:43, 27 May 2006 (UTC)
- Well, yeah, they're hinted to show up okay without anti-aliasing, which is why those fonts look legible, but if you try to anti-alias such a font when it isn't hinted, it'll end up as a big black unreadable blob. —Michiel Sikma, 19:11, 28 May 2006 (UTC)
- What's interesting though, is that they obviously did ClearType smoothing (which is for LCD monitors). I knew that my beloved electron canon in front of me is a doomed species... (I hate these lame duck LCD's). --Ligulem 21:39, 27 May 2006 (UTC)
- They probably are hinted at 14-18pt but I think that hinting and smoothing are mutually incompatible. I can imagine that unhinted/smoothed CJK characters would look worse than hinted/unsmoothed ones. —Ruud 21:43, 27 May 2006 (UTC)
- As above, except that ClearType always looks better than hinting, so it overrides some "hint/do not smooth" setting in the font. —Ruud 21:43, 27 May 2006 (UTC)
language-indication class
Hi guys,
after an enervating discussion at template talk:languageicon we couldn't find any consensus on the final appearance of link language indications. However there were many requests for a less flashy design; thus I ask to add the following class to common.css, so that anyone wanting a more sober design can obtain it via his personal style sheet:
.language-indication { cursor: default; font-family: sans-serif; font-size: 0.84em; font-weight: bold; color: navy; position: relative; bottom: 0.08em; }
This leaves the default aspect as it is now. Thanks —Gennaro Prota•Talk 18:30, 2 June 2006 (UTC)
- I personally think that this move (putting it in common.css) is premature as the template is not stable. Rather than a "no consensus", it's more a case of one user refusing to compromise and threatening an edit war if the template is changed, and a few other users opposing a more discreet design ignoring agreed-upon usability issues that would justify a simplification, and failing to provide any rationale for keeping it as it is. Please have a look at the discussion, your comments would be appreciated. PizzaMargherita 06:39, 3 June 2006 (UTC)
- I just filed a RfC about this discussion, so please don't do it just yet. Thanks. PizzaMargherita 07:05, 3 June 2006 (UTC)
hiddenStructure
I think it is time to remove the hiddenStructure class. This was originally incorporated here as an alternative to {{qif}} for hiding conditional text in templates. However, there are a number of accessibility problems with this method and it has been obsolete since m:ParserFunctions were introduced as a built-in way of performing the same tasks. Most of the existing uses of 'hiddenStructure' were converted to the '#if:' parser function weeks ago without incident. There are doubtless some pages still using hiddenStructure, but I think it would take minimal time to locate and convert them once the class is removed. Perhaps some sort of public notice could be given that some templates may stop hiding conditional text and info on where to go for help converting them. Thoughts? --CBDunkerson 10:44, 8 June 2006 (UTC)
- Wouldn't it be a better idea to remove it after all uses have been replaced (or make all hiddenStructures show up red and blinking :). Typing "hiddenStructure" into the searchbox reveals that it is still used on a few pages. —Ruud 01:24, 11 June 2006 (UTC)
- Yes. Remove it from the site and then remove it from the stylesheet. Or just remove it from the stylesheet and it will be removed from the site when it stops working... — Omegatron 14:41, 22 August 2006 (UTC)
Using Wikipedia Settings on Other Wikis
I want to use the prettytable settings on my wiki. My brute force approach was to copy http://en.wikipedia.org/wiki/Wikipedia:Common.css to my Common.css page, but this hasn't worked. Does anyone know how I can make something like this work? I am using MediaWiki 1.6.7. dryguy 19:24, 19 June 2006 (UTC)
- You could probably copy http://en.wikipedia.org/wiki/Wikipedia:Common.css to your common.css page and http://en.wikipedia.org/wiki/Wikipedia:Monobook.css to your Monobook.css page. —Mets501 (talk) 12:58, 20 June 2006 (UTC)
Thanks! Worked nicely. dryguy 02:21, 21 June 2006 (UTC)
Width setting for Talk page notices
Talk page notices are currently set at a standard width of 80%. Looking at the spectrum of talk page templates in use in en:Wikipedia, this is creating inconsistencies. It also, in my opinion, makes less than optimal use of the page. The border and colored background is sufficient to draw attention to these notices. Limiting the width to 80% is unnecessary. I would like to reset this default to 100%. Rossami (talk) 13:29, 24 June 2006 (UTC)
- Are there any objections or may I be bold? Rossami (talk) 01:57, 13 July 2006 (UTC)
- There's a rather old style guideline on this at Wikipedia:Template standardisation, which agreed upon 85% as the width. Personally, I find 100%-width boxes pretty ugly; I prefer 80 or 85%. —Simetrical (talk • contribs) 02:10, 10 August 2006 (UTC)
- Agreed. I feel that it would be appropriate to follow the style guidelines as much as possible. --Siva1979Talk to me 20:29, 10 August 2006 (UTC)
- So am I asking in the wrong place? Should I be asking somewhere else to change that particular style guideline? I ask because the vandalism warnings in particular are creating an unreadable hash of many anon talk pages. Templates that are typically at the top of the page (like {{sharedIP}}) are okay but some templates are intended for use in the body of the talk page (like {{test1}}, {{test5}} and all their variations). When you have to start reading down the page, there is a confusing mix of text, template and table showing the various warnings, all with varying widths, colors, images, etc. It's become quite difficult to sort through those pages when you need to investigate the history of a returning vandal. Rossami (talk) 20:39, 10 August 2006 (UTC)
- Point this discussion out on the village pump somewhere, that's all. I was just mentioning the guideline, not saying you had to change it first — agreement to change the 80% size here would be sufficient to deem the guideline changed. (It's already wrong, specifying 85% when the standard is 80%.) Personally, I'd be okay with expanding to 85%, but no further, for the various pastel boxes. On the other hand, messages directed at the one whose talk page it is shouldn't be in pastel boxes at all, they should read like ordinary messages; pastel boxes should be used only for general information of some kind. —Simetrical (talk • contribs) 01:19, 11 August 2006 (UTC)
- So am I asking in the wrong place? Should I be asking somewhere else to change that particular style guideline? I ask because the vandalism warnings in particular are creating an unreadable hash of many anon talk pages. Templates that are typically at the top of the page (like {{sharedIP}}) are okay but some templates are intended for use in the body of the talk page (like {{test1}}, {{test5}} and all their variations). When you have to start reading down the page, there is a confusing mix of text, template and table showing the various warnings, all with varying widths, colors, images, etc. It's become quite difficult to sort through those pages when you need to investigate the history of a returning vandal. Rossami (talk) 20:39, 10 August 2006 (UTC)
- Agreed. I feel that it would be appropriate to follow the style guidelines as much as possible. --Siva1979Talk to me 20:29, 10 August 2006 (UTC)
- There's a rather old style guideline on this at Wikipedia:Template standardisation, which agreed upon 85% as the width. Personally, I find 100%-width boxes pretty ugly; I prefer 80 or 85%. —Simetrical (talk • contribs) 02:10, 10 August 2006 (UTC)
- 80% seems obviously better. — Omegatron 20:48, 10 August 2006 (UTC)
- Was that a typo? —Simetrical (talk • contribs) 01:19, 11 August 2006 (UTC)
- I have no idea what that was. Lack of sleep? — Omegatron 14:42, 22 August 2006 (UTC)
- Was that a typo? —Simetrical (talk • contribs) 01:19, 11 August 2006 (UTC)
Comparison (100, 85, 80% respectively, from Template:Vblock; 80% is the current standard): —Simetrical (talk • contribs) 01:19, 11 August 2006 (UTC)
I motion to change the standard to 85%. This will bring us consistancy with the style guideline and slightly more efficient use of page space. Kaldari 01:28, 11 August 2006 (UTC)
New infobox styles
Anyone care if I add some infobox styles in support of the proposed Wikipedia:Geographical infoboxes guideline? I'd like to add an infobox style and some sub-styles (as in User:Rick Block/monobook.css) for use with infoboxes for geographical places. I have a modified version of Template:Infobox U.S. state in user:Rick Block/Infobox U.S. state if anyone would like to see what it might look like. Thanks. -- Rick Block (talk) 01:58, 2 July 2006 (UTC)
- This sounds like an excellent idea! --Siva1979Talk to me 21:01, 12 July 2006 (UTC
Standardization of image copyright tags
Please see Wikipedia talk:Image copyright tags#Template standardization for discussion on standardizing these templates. —Simetrical (talk • contribs) 02:08, 10 August 2006 (UTC)
Commons:MediaWiki:Common.css & interwiki problem
Can anyone tell me what efforts are being made to keep consistancy between these two (and other sister projects) with respect to this rather important central resource?
Why isn't there a master copy from Meta controlling?
Or at least the same master used on both the English language defaulted commons and this en.wikipedia (The hands down 800# gorrilla of wikipedia's by article count!)<g>
I'm curious, in that some text templates that were debugged and working fine are now evincing a variety of display issues including total disfunctionality.
One of these manifested two weeks back (square 'undef'd character', irrc, seen first on the commons) before my vacation trip. I've been tripping on others since last evening on both sister projects. The sqaure 'undef'd' char box seems to point logically directly to this (Commons:MediaWiki:Common.css) specific resource.
See: this if you care to help sort through this vexation and are a code guru.
While I didn't put that up for general consumption, in a nutshell, if it's not shown in bold (indicating a display 'nowiki' block, and hence the desired display effect) one should not be seeing any {s}, {space}, or {i} or {indent} manifestations in the captured HTML.
Something prior to reverts (about 18:00, 17 August 2006) was causing total dysfunction. (Note: This post is heavily indented using the now 2X reverted1 {{Indent}} [called via the {{I}} 'eye' template]). // FrankB 20:00, 17 August 2006 (UTC)