fontWeightfontWeight*
*



Contents  *



Index  *Topic Contents
*Previous Topic: fontVariant
*Next Topic: form

fontWeight

Description

Sets or retrieves the weight (boldness) of the text.

Syntax

object.style.fontWeight[ = fontWeight]

Remarks

The key words for fontWeight 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 font-weight setting that was previously set on the element.

Setting the font-weight to 400 is equivalent to normal. Setting the font-weight to 700 is 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.

This property has read/write permission.

Applies To

HTML Tags 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, INPUT type=button, INPUT type=file, INPUT type=reset, INPUT type=submit, INPUT type=text, 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
Scripting style

CSS Attribute

font-weight


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