Template talk:Unicode
From Wikipedia, the free encyclopedia
Template:unicode (backlinks, edit) containing:
<span class="Unicode">{{{1}}}</span>.
class="Unicode" is defined in MediaWiki:Common.css.
[edit] Examples
- {{unicode|⋊}} and {{unicode|⋉}} give ⋊ and ⋉.
- {{Unicode |а́҆зъ}} gives wrong result а́҆зъ: Combining Greek acute accent is not present.
[edit] See also
- {{latinx}} — favours fonts supporting all the characters in the Latin Extended B range (includes Old/Middle English).
- {{IPA}} — International Phonetic Alphabet.
- {{polytonic}} — Polytonic Greek.
- {{CDM}} — Forces a non-buggy font when using Combining Diacritical Marks.
- {{mufi}} — Forces a font which supports the MUFI characters.
A separate template for a particular symbol is sometimes convenient. e.g.:
- Template:0/ (talk, backlinks, edit) containing:
{{unicode|∅}}<noinclude>[[Category:Multilingual support templates|0/]]</noinclude>
giving ∅ (the name is a representation of the symbol, with the slash after instead of through the circle).
[edit] Discussion
This template was created to allow easy switching to unicode fonts. This is useful for pages that require unicode to display correctly, such as those written in International Phonetic Alphabet. On some browsers, such as Microsoft Internet Explorer, unicode does not seem to be activated automatically, so this template lets you force it manually.
Until MediaWiki 1.4, we won't be able to use a single template more than 5 times in any one article, so this limits the use of this for the time being. MW1.4 should be up within a month (Nov. 2004). I'm pretty sure you can go hog wild with templates now.
One might ask why bother to use a template for this. Simply:
- The template code is easier to remember than the HTML font style specification, which must be entered fairly precisely for this to work.
- The template code, although not completely transparent, is more transparent than asking new editors to use inline HTML CSS style tags. At least for many editors.
- Using the template allows us to change unicode display properties for all articles that employ the template at once. This is useful as the prefered fonts for displaying unicode are somewhat disputable and will change as new, more complete unicode fonts continue to be developed. The way font specification works, we can provide a whole list of suggested fonts and the first one that is active on the user's machine will be selected.
- When the page says Unicode, Internet Explorer will activate Unicode.
- However, when the page says Arial, Internet Explorer will display Arial. While Arial does include e. g. basic Greek and Cyrillic, it does not include e. g. IPA extensions. These are displayed in Arial anyway when the page says so – that is, they are displayed as the famous rectangles.
- David Marjanović | david.marjanovic_at_gmx.at | 00:44 | 2006/5/16
[edit] Fonts
The fonts currently in use are, in order:
- TITUS Cyberbit Basic, Code2000, Doulos SIL, Chrysanthi Unicode, Bitstream Cyberbit, Bitstream CyberBase, Thryomanes, Gentium, GentiumAlt, Visual Geez Unicode, Lucida Grande, Arial Unicode MS, Microsoft Sans Serif, Lucida Sans Unicode
Controlled by Template:Unicode_fonts.
I realize this is not preferable for everyone (I prefer Gentium over Code2000, and Lucida Sans Unicode over Arial Unicode MS), but the reason is simply that the current order will result in the most characters being displayed, and thus is imnhso the best choice for the Wikipedia. I highly recommend using a personal stylesheet (/monobook.css &c, class .Unicode) to enforce a "prettier" display where preferred. Jordi·✆ 12:46, 16 Mar 2005 (UTC)
[edit] Plane One fonts
Code2001, a Plane One font based on Code2000 is not listed, nor should other Plane One fonts be listed. In order to get fonts from higher planes than the BMP to display at all in Windows a font substitute must be provided, for which we can assume the user will have chosen a proper font. MSIE will then only use that font anyway, so there's no need to list them here. Jordi·✆ 01:23, 28 Mar 2005 (UTC)
- Can you explain that in more detail, or provide a reference? I don't understand what you mean by font substitute. Thanks. (I'm a Mac user, but curious because I'm interested in how to make multilingual web pages work across platforms). —Michael Z. 2005-03-28 07:57 Z
-
- Out of the box, Uniscribe (the set of services which allow for Unicode text on NT4, 2000, XP, and 2003) only supports the Basic Multilingual Plane ("Plane Zero") of Unicode. In order to get Windows to work with the higher planes, the proper use of Surrogate Code Points (U+D800 through U+DFFF) must be enabled (all Plane 1–16 characters are part of a Surrogate Pair).
- The registry setting is HKLM\Microsoft\Windows NT\CurrentVersion\LanguagePack: a DWORD SURROGATE must be created with value 2.
- This will not fix MSIE, however. For that browser two more settings must be changed: at HKCU\Software\Microsoft\Internet Explorer\International\Scripts\42 the user must enter a font for IEPropFontName and IEFixedFontName, and since MSIE then still will fail in most cases a third entry is needed at HKLM\SOFTWARE\Microsoft\WindowsNT\CurrentVersion\LanguagePack\SurrogateFallback: for each Plane a fallback font can be set. Example Plane1=Code2001, Plane15=Code2001 etc.. I have heard that installing a Microsoft language pack for some languages will do these changes automatically, but have been unable to confirm. HTH, Jordi·✆ 10:45, 28 Mar 2005 (UTC)
-
-
-
- Yeah, you must use regedit (or import a registry file: here's mine, for Code2001). The first step is needed for all applications including browsers like Opera or Mozilla, the other steps are for MSIE only (and programs which use IE internally). Jordi·✆ 18:04, 28 Mar 2005 (UTC)
-
-
[edit] Template:IPA
I modified the template based on Template:IPA to look like:
- <span class="Unicode" style="font-family:{{IPA fonts}}">{{{1}}}</span>
The "class" bit allows a stylesheet to override the template, and the {{IPA fonts}} seems to apply here too. dbenbenn | talk 15:14, 20 Jan 2005 (UTC)
- Template:IPA fonts includes Gentium font, which doesn't have a very wide range of characters. For example, it has Cyrillic letters for only the Russian language (I think you can manage Bulgarian with it too). It's not suitable for the intended application of Template:Unicode. —Michael Z. 2005-02-8 15:54 Z
[edit] Deficiencies with the unicode template
The unicode template does not work with all characters. For instance there's character #7778 the Ṣ character (an upper-case S with a dot beneath it) used in the Tucson, Arizona article, and character #7791; the ṯ character (a t with a bar underneath) used in the Hebrew alphabet article. Quite by chance, I have discovered that the polytonic template, intended for use with Polytonic Greek, actually does the job with both of those, so I've used it for Tucson, and also (in one place only as yet - there's a lot more to do) for Hebrew alphabet. Should the unicode template be upgraded to cover these sorts of characters? rossb 14:51, 25 Feb 2005 (UTC)
- Yes, please. It would be confusing to keep using Template:Polytonic for non-polytonic characters. Template:Unicode should support as wide a range of characters as possible.
- The danger is promoting a font that has these characters, but is missing some others. Is there a resource with a detailed listing of which characters are supported by what fonts? Alan Wood lists Unicode ranges, but some fonts have only partial support for some ranges.
- The real solution is to promote upgrading from MSIE to a modern browser, like Firefox; then we won't have to waste time screwing around with these technical templates. —Michael Z. 2005-02-25 17:03 Z
-
- I suspect that there's extremely little future in trying to urge the use of an alternative browser on the vast majority of users who've had MSIE delivered as standard with their PCs, not to mention those who may be using a PC provided by their place of work, and have no ability or authority to install new software. I hear there's a new version of MSIE coming out this year - maybe it will support unicode better? By the way I wasn't volunteering to upgrade the template myself - I don't have that sort of expertise! rossb 17:16, 25 Feb 2005 (UTC)
-
-
- As users have become more Internet-savvy, more have started adopting Mozilla browsers. Slow but steady. As far as designing web sites goes, I would love for MSIE 7 to have better unicode and web standards support, but I'm not going to hold my breath.
-
I've also used the polytonic template in the article Sütterlin to display some ligatures that the unicode template couldn't cope with. rossb 13:26, 28 Feb 2005 (UTC)
See Template talk:polytonic for a list of articles where I've used the polytonic template in this way. rossb
- When I first made this template, there weren't any more specific things out there, for polytonic, IPA, etc. I think the best use for this template is as the home of the most standard, inclusive unicode fonts possible, for use in cases not by now covered by their own specific templates. If your case is small and isolated, and covered by this template, then by all means use it. If your case becomes larger, you might want to create a new template for whatever character set is critical for your documents. Use your judgement in terms of proliferating templates. I wouldn't suggest continuing to hijack polytonic for other cases if this is in danger of becoming widespread practice (i.e. more than a few cases).
- The principle I would follow in font selection is orderly degradation. The first font in the list for this template should be the most character-inclusive available. Each subsequent font should cover a subset of the characters in the previous font, not a partially overlapping different set of characters. This way the degradation is at least orderly and predictable, which to my mind is preferable.
- I'm confident the problem will be solved with IE7, but I don't know when that will come out or become standard among MS people. Mozilla and Firefox are not going to conquer IE anytime soon, particularly as the cracker/virus community now begins to take advantage of their growing prevalence, sometimes more vulnerable coding, and usually less frequently applied patches. That's all I'll say on that, so any further comment is free to take over as the last word. --Chinasaur 08:17, 22 Mar 2005 (UTC)
-
- So taking your approach (which seems very reasonable) that the first font in the list should be the most inclusive, I wonder who will be able to take on the task of specifying a more inclusive font for the Unicode template. On the basis of my limited information, the first font used in the Polytonic template would seem to be more inclusive, but maybe it leaves out some characters that the unicode template currently addresses. I wouldn't say that I have a small and isolated case - or at least not a very specific case such as those that the Unicode and IPA templates were aimed at - I've just fairly randomly come across a variety of extended Latin characters that were giving problems - so maybe the Unicode template ought to be addressing this. rossb 09:12, 22 Mar 2005 (UTC)
There will always be special cases, which may have to be handled with specific formatting, or even characters that don't occur in any default system font. Maybe it's best to keep creating more specific templates, so that all examples in different places can be managed centrally (template:sutterlin, or template:latin_ligatures?). Sometimes you will just have to use an image to illustrate an example (e.g. ligature, A iotified (a specific form), hryvnia (in future Unicode version)). —Michael Z. 2005-03-22 20:35 Z
- As a final suggestion, it is probably possible (though far from optimal) to use TeX for some of these cases if fonts just won't do it and you don't want to deal with images directly. I'm not sure what we allow inside the <math> brackets though. For even further TeX support look into WikiSophia. --Chinasaur 17:47, 27 Mar 2005 (UTC)
Now that the Unicode template has been updated, I've adopted it in various articles for which I'd previously used the Polytonic template as described above. rossb 08:53, 1 Apr 2005 (UTC)
[edit] Problems at yogh
Take a look—I'm not sure what's wrong, but the template isn't working there. IE doesn't show the character, and I know I have Arial Unicode MS. —Simetrical (talk) 23:24, 27 Mar 2005 (UTC)
Whoops, I found the problem. Arial Unicode MS doesn't have the character. So what now? We can't leave 90% of the Internet with boxes. —Simetrical (talk) 23:28, 27 Mar 2005 (UTC)
- Code2000 has them. Unfortunately bumping Arial Unicode MS down again may break more than it solves. I'll look into a solution for yogh. Jordi·✆ 01:00, 28 Mar 2005 (UTC)
[edit] More problems with unicode template
The unicode template is doing a good job of representing ḥ, as well as a number of other characters...but with one huge flaw: it is persistently setting these characters off by the insertion of a leading space: Tsemaḥ. Any ideas what's wrong here? What's even more annoying is that ḥ, while not being set off by a space, appears to be rendering as God-only-knows what, rather than as ḥ like it should be. This same polytonic is showing up here as a poorly drawn spiral, but on Mizrahi Jews, it shows up as a fleur-de-lis. WHAT IS GOING ON HERE??? :-p Tomer TALK 09:44, Apr 7, 2005 (UTC)
- You are describing a spacing bug in Arial Unicode MS, likely the first Unicode font from the list you have installed. The other Unicode fonts listed are not broken. Jordi·✆ 10:11, 7 Apr 2005 (UTC)
-
-
- Install another Unicode font: Code2000, TITUS Cyberbit Basic, Doulos SIL, Chrysanthi Unicode are all given higher preference than Arial Unicode MS, so they will be used instead once installed. Code2000 at least includes the character, I am not sure about the other fonts. Jordi·✆ 10:47, 7 Apr 2005 (UTC)
-
-
- Also, the spacing thing means a lot less to me than the fact that the characters seem, bizarrely enough, to be being represented differently, on various pages. What's really disturbing is that I changed the the unicode representation to polytonic specifically to get it to appear correctly on the page, which it did...but now today, it's no longer showing up correctly. what gives? Tomer TALK 10:41, Apr 7, 2005 (UTC)
The extra space is a "feature" someone added to Wikipedia's template code. It adds an extra line break character (not an HTML <br> tag) at the start of the HTML code in any template. This doesn't show up if there's already a space before the template, since HTML compresses white space, but it does show up when the template is in running text.
I've mentioned this at Wikipedia:Village pump (technical)#Leading white space in templates screws up rendering, and hopefully someone can fix it.
I haven't seen the problem with incorrect characters showing up. Have you noticed it on more than one computer? Sounds like a font-rendering bug on your system. —Michael Z. 2005-04-7 14:14 Z
- P.S. the spacing problem won't show up if you use the template on entire words, or any other span of text starting with white-space. How do these look: Mizraḥi and Mizrāḥî? —Michael Z. 2005-04-7 14:20 Z
I think the problem may arise because you're using Polytonic rather than Unicode. Both of these have been updated recently. In particular Polytonic now favours a serif font in both English and Greek (it was sans before), and this may be the cause of the fleur de lis, which I certainly see on my system here with MSIE. Note that the fleur de lis is the bold version, the spiral is tne normal version, and using italics gives other characters - see below. The effect of the recent change to the Unicode template by the way is that you should no longer need to user Polytonic other than for polytonic Greek. I myself started using Polytonic to overcome the problems with Unicode a while back but have now reverted all this.
- With Unicode: Mizraḥi and Mizrāḥî
- With Polytonic: Mizraḥi and Mizrāḥî
- Polytonic and bold Mizraḥi and Mizrāḥî
- Polytonic and italic Mizraḥi and Mizrāḥî
- Polytonic bold and italic Mizraḥi and Mizrāḥî
rossb 15:04, 7 Apr 2005 (UTC)
- Woah! Those all looked fine on my Mac, except the h-dot is not italicized (of course, my browser ignores the templates' font spec). I just looked at it in a vanilla Windows XP system, and each line is mucked up in a different way! At least there's no extra space. I think we have to face the fact that some systems just won't be able to read some text. —Michael Z. 2005-04-7 15:41 Z
-
-
- I've put some stuff in my Wikipedia user CSS to apply text colour to these templates. Helps troubleshoot some problems. Below is the code. These web-safe colours are just light enough to distinguish the colour (in my browser), but dark enough so that they don't jump off the page. —Michael Z. 2005-04-7 23:10 Z
-
/* show me the templates */ .IPA { color: #060; } .polytonic, span[lang|="grc"] { color: #006; } .Unicode { color: #600; }
[edit] Characters still not supported
As of today, the template still does not cater for:
rossb 06:29, 11 Apr 2005 (UTC)
Nope, it supports them, but you have to have the correct fonts installed. Nothing the template can do about that. —Simetrical (talk) 20:02, 18 Apr 2005 (UTC)
- FYI, on a stock WinXP system, Firefox shows the Romanian esses, but not the others.
- Each of the fonts probably supports a different range of characters. Only the intersection of the ranges will be displayed reliably on most Windows systems, but only one of the fonts will be used on a particular Windows system. If these three characters are all that breaks on your Windows installation, then you're probably doing very well. —Michael Z. 2005-04-18 20:27 Z
-
- Can someone who's sure they've got all the right fonts installed check to see whether or not this ☿ shows up as the little squiggly for Mercury (planet)? I added {{Unicode| }} to it, but it still doesn't show up on my sqween. In case you're uncertain, it should look like this: . Tomer TALK 01:26, Jun 6, 2005 (UTC)
-
-
-
- I've verified w/ a friend of mine that they work...so I apparently just need to update my fontset. -Tomer = 68.190.162.144 04:00, 6 Jun 2005 (UTC) (I can't log in for some reason)
- FWIW that's working fine in IE6 for me also, as are the three samples above. I'm assuming that's Code2000 doing the work since that's the first on the list which I have installed here. What we could do with is some way of knowing what sub-ranges various fonts support, then we could recommend the best for vanilla Unicode, IPA, and various languages. --Phil | Talk 14:06, Jun 6, 2005 (UTC)
-
-
Certain blackletter characters don't seem to work correctly, and I suspect this might somehow be the template's fault. Specifically, I know that I have characters like 픸 on my system, because they show up in Firefox, but the Unicode template doesn't make them visible in IE. Is there any way to check which of my fonts is providing me with the ability to see the extra blackletters? —Simetrical (talk) 06:14, 15 Jun 2005 (UTC)
- Blackletter is in Plane 1, which I don't think any of the fonts listed in the template support. Code2001 supports Plane 1, but only Plane 1, so it wouldn't be a suitable font choice for IE. Maybe we need another template for Plane 1 fonts? There are probably some MathML fonts that support it too. DopefishJustin (・∀・) June 28, 2005 23:38 (UTC)
-
- You can forget about Plane 1 and higher with Windows. The only way to get characters outside the BMP to work in Windows is by editing the registry, even if you do have the correct fonts. And then MSIE is limited to that one font for the entire plane: it simply won't change to a different font even if the declared font is empty.
- At least other browsers (Opera & Firething) can handle the higher planes normally, but still only if the registry hacks are in place. Jordi·✆ 18:42, 15 July 2005 (UTC)
-
-
- Nonsense, Plane 1 characters (for example in Darius I of Persia) work fine for me in Windows 2000 and Windows XP with Firefox, no registry changes necessary. Code2001 needs to be installed, of course. DopefishJustin (・∀・) 17:49, July 19, 2005 (UTC)
-
-
-
-
- On closer inspection, the SURROGATE registry entry is set. I always install all language packs so I suppose that could have set it. I don't think it's unreasonable to expect people who want to view exotic characters to have language packs installed, though. UTF-8 (which is what Wikipedia uses) doesn't make use of surrogates, though, so I'm not sure what relevance a setting for surrogate display would have. IE is still hopeless without additional changes, unfortunately. DopefishJustin (・∀・) 18:00, July 19, 2005 (UTC)
-
-
-
-
-
-
- You still need surrogates in UTF-8: if you don't, ̰ (Gothic A) displays as þ. There is then still an issue with UTF-8 encoding and higher planes in Internet Explorer, regardless of the surrogate setting. UTF-8 characters outside the BMP (chars U+10000 and up) encoded using NCRs will only work if the user sets the MSIE encoding to "User defined", or the server is broken to send "x-user-defined" (which breaks all other browsers). And even then you run into issues if the SURROGATE bit is not set.
- Since we CANNOT rely on Wikipedia visitors to have the surrogate flag set, nor can we rely on them having a font capable of displaying Plane One (I know of only three such fonts), I stand behind my words.
- FYI, the surrogate bit is not only for MSIE: it is for ALL Windows applications. Firething and Opera won't be able to display Plane One characters either if surrogate=0. Jordi·✆ 18:30, 19 July 2005 (UTC)
-
-
-
-
-
-
-
-
- "UTF-8 (which is what Wikipedia uses) doesn't make use of surrogates" indeed but the windows api isn't utf-8 based. So it has to be converted to UTF-16 for passing to the windows display routines. If surrogate support isn't enabled (i'm unclear why MS didn't enable it by default, possiblly some compatibility issue) then afaict you can't use non-bmb characters with the windows text system period. Plugwash 12:49, 12 March 2006 (UTC)
-
-
-
-
[edit] Built-in?
It seems to me that while this template is a good idea, it would be vastly more useful and convenient if it was handled at the level of the MediaWiki software; that is, make MediaWiki aware of the ranges of characters that can be displayed unassisted by IE, and have it put any others in <span>s with a CSS class of "unicode" when generating the HTML for the page, and then specify the Unicode font list in the stylesheet. This would have several advantages: editors could enter Unicode characters in an article and it would "just work" without having to do anything extra, all existing non-template-using articles would work with no conversion effort, the article markup would look much cleaner, the server hit of using nested templates everywhere would be eliminated, and the HTML generated would be more compact due to not duplicating the font list every time. The same IE problem affects any site using MediaWiki (including the other Wikimedia projects and Wikipedia languages) so it seems reasonable to centralize it; since the font list would be in the stylesheet it could of course be customized by individual MediaWiki users. DopefishJustin (・∀・) 18:17, July 15, 2005 (UTC)
- One major complication i see with this is that combining diacritics etc often won't work over such boundries. So doing this automatically would mean a much greater knowlage of unicode to know at which points its safe to insert a font switch. Plugwash 12:51, 12 March 2006 (UTC)
[edit] Code2000 occupying all fonts
Since installing the Code2000 font, all Unicode characters like IPA characters or numerical symbols are represented with that font. I must say Code2000 is far away from rendering good characters - how can I change my Firefox / Windows XP to regulary use Arial Unicode instead for all characters that are representable with Arial Unicode? --Abdull 22:01, 14 August 2005 (UTC)
- Change your Firething font settings: it should allow you to pick a font for each Unicode range (the Mozilla suite does, as does Opera). This template does not affect any browsers except for the broken MSIE. Jordi·✆ 03:50, 15 August 2005 (UTC)
[edit] Something broken in MediaWiki?
Howcome all the {{Unicode|foo}}
references are coming out as {{{1}}} (like so: foo )? Something appears to be rather broken! — OwenBlacker 15:07, August 20, 2005 (UTC)
[edit] the second font-family
Why, user:Naive cynic, did you say "rv - only Internet Explorer needs this"? (In reference to the reversion from what I changed on 8/20 or 8/21.)
- If Internet Explorer does need it, well--many people use Internet Explorer, and we shouldn't exclude them from enjoying Wikipedia. And what harm can come to others (non-IE users) by putting the
/*
and*/
around the whole of the secondfont-family:
segment? Which is better? "Why include the comment-out?/* font-family: inherit */
", or "font-family: /**/ inherit;
"? To me, as I read it, neither looks functional. And if the second one is functional neither way, it should just be deleted.- The "font-family" attribute, or whatever it's called, is already extant immediately preceding, so if we don't remark out the second one the only way that w3.org suggests, why even include it?
Therefore, I'm deleting the whole of that second part. There's no need to have it. I see why the font-family: inherit;
should be there, just in case there is no suitable font, and the default font will suffice. So why the comment-out? -- D. F. Schmidt (talk) 06:46, 22 August 2005 (UTC)
- This unusual comment uses another bug in Internet Explorer to hide the rest of the line from IE 6. See also Template talk:IPA#Technical details. -- Naive cynic 07:15, 22 August 2005 (UTC)
[edit] Usage of this template
It seems as this may be a reply to a couple of the discussions started on this page, but I've made a comment on the talk page of the font listing that would likely be of interest to maintainers of this template, as well: Template talk:Unicode fonts#Use of this template. —Gordon P. Hemsley→✉ 10:13, 25 September 2005 (UTC)
[edit] Font declaration has been moved to Common.css
The way Template:IPA, Template:Unicode, and Template:Polytonic do their job has been changed. They should continue to work as before. Sorry if this causes any inconvenience.
The font declarations for these three templates have been moved to the style sheet at MediaWiki:Common.css. This reduces the size of Wikipedia pages' code, by as much as 100kB in the case of IPA. The respective font declarations are applied to HTML entities with one of the following attributes (capitalization counts). The three templates in question have been updated, so they will continue working as before.
class="IPA"
class="Unicode"
class="polytonic"
The only disadvantage of the new scheme is that only admin users are able to edit the font declarations in Common.css (or is it an advantage?). But you can override the font declaration for yourself by editing your own Wikipedia user style sheet. See Template talk:IPA#Applying custom styles to IPA text. Alternatively, you can use a browser like Mozilla Firefox, Opera, or Safari, in which Unicode text just works.
The reason for this change is that the Mediawiki software no longer allows comments in inline style sheets, because Microsoft Internet Explorer's incorrect parsing is unsafe and can be used for cross-site scripting attacks. See Wikimedia bug no. 3588.
Similar font declarations applied to any tables or divs on Wikipedia should have one of the above-mentioned class attributes added instead.
The style sheet code in Common.css looks like this:
/* Support for Template:IPA, Template:Unicode and Template:Polytonic. The inherit declaration resets the font for all browsers except MSIE6. The empty comment must remain. */ .IPA { font-family: Chrysanthi Unicode, Doulos SIL, Gentium, GentiumAlt, Code2000, TITUS Cyberbit Basic, DejaVu Sans, Bitstream Vera Sans, Bitstream Cyberbit, Arial Unicode MS, Lucida Sans Unicode, Hiragino Kaku Gothic Pro, Matrix Unicode; font-family /**/:inherit; } .Unicode { font-family: TITUS Cyberbit Basic, Code2000, Doulos SIL, Chrysanthi Unicode, Bitstream Cyberbit, Bitstream CyberBase, Bitstream Vera, Thryomanes, Gentium, GentiumAlt, Visual Geez Unicode, Lucida Grande, Arial Unicode MS, Microsoft Sans Serif, Lucida Sans Unicode; font-family /**/:inherit; } .polytonic { font-family: Athena, Gentium, Palatino Linotype, Arial Unicode MS, Lucida Sans Unicode, Lucida Grande, Code2000; font-family /**/:inherit; }
Please discuss this at Template talk:IPA#Font declaration has been moved to Common.css. —Michael Z. 2005-10-4 15:40 Z
[edit] Font problem with y with macron
y with macron, ȳ, Unicode 233 hex, which is used in Old English morphology, appears as a box on my computer even though it is enclosed in Template Unicode. The same problem occurs with Template IPA: ȳ
I use MSIE 6.0, and my fonts include Arial Unicode MS, Microsoft Sans Serif.
The problem appears to be that Arial Unicode MS appears before Microsoft Sans Serif in MediaWiki:Common.css, but Arial Unicode MS doesn't support codes 218-24F. --teb728 19:26, 6 November 2005 (UTC)
- Sounds like you need to create a new template with a font list geared towards your type of text. Just copy this one and edit the copy appropriately after checking the fonts. Plugwash 23:41, 7 April 2006 (UTC)
- Actually you will wan't to work from an old (pre migration to main CSS) version of this template and then if its used a lot discuss putting the list in main CSS with the admins.
-
- I created {{unicode2}} which favours fonts that support all chracters in the Latin Extended B range. This should solve your problem. —Ruud 20:18, 2 May 2006 (UTC)
-
-
- {{unicode2}} is a bad name for a template. Why not something like {{unicodeLatinExtendedB}}? --cesarb 23:45, 2 May 2006 (UTC)
-
-
-
-
- We probably want to have templates for each language in the future, so the
<span lang="..">
is set correctly, as well as select better fonts for IE users, making {{unicode2}} obsole with {{oldenglish}} and {{middleneglish}}. But if the name really bothers you, you're free to rename it (although I suggest to keep it as short as possible). —Ruud 00:29, 3 May 2006 (UTC)
- We probably want to have templates for each language in the future, so the
-
-
- Test: ȳ —Ruud 03:45, 3 May 2006 (UTC)
Thanks for the new template. I note (for completion of this section) that {{unicode2}} has been renamed to {{latinx}}. --teb728 05:50, 20 May 2006 (UTC)
[edit] Adding a mk: language link
Can you please add the Macedonian language link (mk:Уникод), so Macedonian editors who come here would know that we already have such a templete. Thank you. --B. Jankuloski 23:25, 27 May 2006 (UTC)
- Done. —Ruud 02:04, 28 May 2006 (UTC)
[edit] Between this template and IAST template
...which one is more suited to render transliterated devanagiri script words on most computers? --Babub(Talk|Contribs) 14:48, 19 July 2006 (UTC)
The need for the Unicode template to display Devanagari is no longer as much of an issue as better support for Unicode is more widespread. The Unicode template is rarely used on the Hinduism pages that use Devanagari. The IAST transliteration method can be shown via the IAST template if IAST is used. The template I see most often on the Hinduism pages for Sanskrit is some variant of this: ([[Sanskrit]]:{{lang|sa|गणेश पुराणम्}}; {{IAST|gaṇeśa purāṇam}}) which displays:
(Sanskrit:गणेश पुराणम्; gaṇeśa purāṇam)
Notice that no explicit Unicode tage is used. The LANG tag argument is just the raw Unicode character value. The IAST template and the Unicode template do different things. IAST is one of several incompatible transliteration methods for Devanagari. So using the IAST tag specifies which of the alternative methods is being used. Also note that IAST is a transliteration method for a writing system (Devanagari) which is used for multiple languages such as Hindi, Sanskrit, etc. Sanskrit is a language that can be written using various writing systems, such as Bonji, IAST, Devanagari, etc. Buddhipriya 02:38, 24 February 2007 (UTC)
[edit] ‽
Maybe we should include the ‽ in this. Randfan
[edit] Need support from admin
{{editprotected}}
I need admin support in creating "Template:Unicode" at Marathi Language Wikipedia (wiki language code mr) as it is,from english wikipedia for following reason . Only the difference is we do not want you to protect immidiately, after neccessary translations if any admins at Marathi wiki can protect the same.
We at Marathi Language Wikipedia are translating articles related to Devanagari and portions of Sanskrit article of english wikipedia are also being translated.
So earliest help from admin is requested.
Mahitgar 07:37, 9 November 2006 (UTC)
- You don't need an en admin to do this (although you do need an mr admin). Add the following to mr:MediaWiki:Common.css:
.Unicode { font-family: Code2000, TITUS Cyberbit Basic, Doulos SIL, Chrysanthi Unicode, Bitstream Cyberbit, Bitstream CyberBase, Thryomanes, Gentium, GentiumAlt, Visual Geez Unicode, Lucida Grande, Arial Unicode MS, Microsoft Sans Serif, Lucida Sans Unicode; font-family /**/:inherit; }
- and create the mr template Unicode as
<span class="Unicode">{{{1}}}</span>
- Hope that helps. --ais523 08:38, 9 November 2006 (UTC)
- It seems that the relevant section was already in mr:MediaWiki:Common.css, so I've created mr:Template:Unicode for you. Hope it works... --ais523 08:44, 9 November 2006 (UTC)
[edit] DejaVu font
I would like to encourage to add the DejaVu Sans font to the Unicode template, like:
.Unicode { font-family: Code2000, Code2001, "Free Serif", "TITUS Cyberbit Basic", "Doulos SIL", "Chrysanthi Unicode", "Bitstream Cyberbit", "Bitstream CyberBase", "DejaVu Sans", Thryomanes, Gentium, GentiumAlt, "Lucida Grande", "Free Sans", "Arial Unicode MS", "Microsoft Sans Serif", "Lucida Sans Unicode"; font-family /**/:inherit;
Deriving from the free Bitstream Vera font the DejaVu project (see http://dejavu.sourceforge.net/) tries to fill all missing Unicode characters. It grows with each revision and therefor became the default font of the Fedora Linux distribution.
Greetings, Andreas 09:04, 15 July 2007 (UTC)
[edit] deprecate
This template should eventually be deprecated. There is no dichotomy "unicode vs. non-unicode". Out-of-the-box support of frequently used Unicode characters is quite good these days, and for obscure Unicode ranges, there is often no single font. You need to select different fonts for {{cuneiform}} and for {{coptic}}, yet both are Unicode fonts. I appreciate the historical necessity of this template, and we should certainly keep it around as a fallback option, but most cases should now be addressed by {{lang}} and friends. dab (𒁳) 10:18, 24 July 2007 (UTC)