IFont::put_Weight

Sets the font's weight. This property may affect the bold property as well. Bold is set to TRUE if the weight is greater than the average of FW_NORMAL (400) and FW_BOLD (700), that is 550.

HRESULT put_Weight(
  short weight  //Weight for the font
);
 

Parameters

weight
[in] New weight for the font.

Return Values

S_OK
The weight was changed successfully.
S_FALSE
This font does not support different weights. This value is not an error condition.

QuickInfo

  Windows NT: Use version 4.0 or later.
  Windows: Use Windows 95 or later.
  Windows CE: Unsupported.
  Header: Declared in ocidl.h.

See Also

IFont::get_Weight