javascript STYLE font
| font | NN 6 IE 4 DOM 2 |
| Read/Write | |
|
This is a shorthand property that lets you set one or more font-related propertiesfontFamily, fontSize, lineHeight (which must be preceded by a / symbol in this property), fontStyle, fontVariant, and fontWeightwith one assignment statement. A space-delimited list of values (in any sequence) is applied to the specific font properties for which the value is a valid type. Or, you can short-circuit these individual settings by choosing one of the default (operating-system-dependent) system fonts: caption | icon | menu | message-box | small-caption | status-bar. |
|
| Example | |
document.getElementById("subhead").style.font = "bolder small-caps 16pt";
|
|
| Value | |
For syntax and examples of value types for font-related properties, see the respective property listing. |
|
| Default | |
None. |
|
Previous: javascript STYLE fontFamily
Next: javascript STYLE filter
1844,Nickname,Homepage or email,Comments here,Add comment
