Javascript Reference
Categories: STYLE

javascript STYLE fontVariant

@March 15, 2008, 1:22 a.m.
fontVariantFirefox/Netscape/NN 6 IE 4 Chrome/Safari/DOM 2  

Read/Write  

Specifies whether the element should be rendered in all uppercase letters in such a way that lowercase letters of the source code are rendered in smaller uppercase letters. If a font family contains a small caps variant, the browser should use it automatically. More likely, however, the browser calculates a smaller size for the uppercase letters that take the place of source code lowercase letters. In practice, Internet Explorer 4 renders the entire source code content as uppercase letters of the same size as the parent element's font, regardless of the case of the source code. Later IE versions and Netscape 6 use two different uppercase sizes.

 
Example
 
document.getElementById("emphasis").style.fontVariant = "small-caps";
 
Value

Any of the following constant values as strings: normal | small-caps.

 
Default

normal


Powered by Linode.