font-weightfont-weight*
*Contents  *Index  *Topic Contents
*Previous Topic: font-variant
*Next Topic: height

font-weight

Description

Sets the weight (boldness) of the text.

Syntax

{ font-weight: normal | bold | bolder | lighter | 100 | 200 | 300 | 400 | 500 | 600 | 700 | 800 | 900}

Remarks

The key words for font-weight values are mapped to specific font variations depending on the fonts that are installed on the user's computer. In many cases, the user will not see the difference between different font-weight settings because the system will choose the closest match, which may be the same as the next relative font-weight setting that was previously set on the page. In any case, Internet Explorer 4.0 will always render a bolder font at least the same if not darker than a lighter font.

Setting the font-weight to 400 is equivalent to normal. Setting the font-weight to 700 is the equivalent to bold.

A font-weight of bolder or lighter is interpreted relative to the parent element's weight. A value of bolder for text whose parent is normal would set the text to bold.

Internet Explorer currently supports only normal | bold.

This attribute is inherited.

Applies To

A, ADDRESS, APPLET, B, BIG, BLOCKQUOTE, BODY, CAPTION, CENTER, CITE, CODE, COL, COLGROUP, DD, DFN, DIR, DIV, DL, DT, EM, FIELDSET, FORM, H1, H2, H3, H4, H5, H6, HTML, I, INPUT, KBD, LABEL, LEGEND, LI, LISTING, MARQUEE, MENU, OL, P, PLAINTEXT, PRE, S, SAMP, SELECT, SMALL, SPAN, STRIKE, STRONG, SUB, SUP, TABLE, TBODY, TD, TEXTAREA, TFOOT, TH, THEAD, TR, TT, U, UL, VAR, XMP, INPUT type=button, INPUT type=file, INPUT type=reset, INPUT type=submit, INPUT type=text

Scripting Property

fontWeight


Up Top of Page
© 1997 Microsoft Corporation. All rights reserved. Terms of Use.