Template:Unicode/doc: Difference between revisions

From Official Kodi Wiki
Jump to navigation Jump to search
No edit summary
Line 10: Line 10:


==Purpose==
==Purpose==
This template is created to allow easy switching to [[unicode font]]s. It should ''only'' be used in cases where characters otherwise do not render correctly on some  browsers, such as [[Microsoft]] [[Internet Explorer]].  
This template is created to allow easy switching to [[w:unicode font|unicode font]]s. It should ''only'' be used in cases where characters otherwise do not render correctly on some  browsers, such as Internet Explorer.  


The fonts selected are designed to maximize the probability to render uncommon Unicode characters correctly. However, different fonts cover different [[Mapping of Unicode characters|Unicode ranges]]. It is probably mostly useful for various [[Unicode symbols]]. Do not use it for the following:
The fonts selected are designed to maximize the probability to render uncommon Unicode characters correctly. However, different fonts cover different [[w:Mapping of Unicode characters|Unicode ranges]]. It is probably mostly useful for various [[w:Unicode symbols|Unicode symbols]].
 
*For strings in the [[International Phonetic Alphabet]], use {{tl|IPA}}.
*For various non-Latin scripts, use {{tl|lang}} if possible, or {{tl|script}} otherwise.


==Guts of template==
==Guts of template==

Revision as of 16:04, 16 March 2012

Usage

The template looks for letter font families that are broadly supporting incurrent characters (symbols, characters). Input can be decimal like { or hexadecimal ©. E.g. (mind the 'x' for hex values):

  • ​{{unicode|⋊}}​
    -->
  • ​{{unicode|⋊}}​
    -->
  • ​{{unicode|⋊}}​
    --> (this may look trivial, but could be helpful in other browsers)

or

  • ​{{unicode|⋉}}​
    -->
  • ​{{unicode|⋉}}​
    -->
  • ​{{unicode|⋉}}​
    -->

Purpose

This template is created to allow easy switching to unicode fonts. It should only be used in cases where characters otherwise do not render correctly on some browsers, such as Internet Explorer.

The fonts selected are designed to maximize the probability to render uncommon Unicode characters correctly. However, different fonts cover different Unicode ranges. It is probably mostly useful for various Unicode symbols.

Guts of template

<span class="Unicode">{{{1}}}</span>

...wherein class="Unicode" is defined in MediaWiki:Common.js:

.Unicode {
    font-family: "Arial Unicode MS", "Lucida Sans Unicode"; 
}

A personal stylesheet (/monobook.css &c, class .Unicode) may be used to enforce a "prettier" display where preferred.