[This documentation is for preview only, and is subject to change in later releases. Blank topics are included as placeholders.]
Gets or sets the weight or thickness of the specified font.
Assembly: PresentationFramework (in PresentationFramework.dll)
XMLNS for XAML: http://schemas.microsoft.com/winfx/2006/xaml/presentation, http://schemas.microsoft.com/netfx/2007/xaml/presentation
The following example shows how to set the property of a control.
Private Sub ChangeFontWeight(ByVal Sender As Object, ByVal e As RoutedEventArgs) If (btn5.FontWeight = FontWeights.Bold) Then btn5.FontWeight = FontWeights.Normal btn5.Content = "FontWeight" Else btn5.FontWeight = FontWeights.Bold btn5.Content = "Control font weight changes from Normal to Bold." End If End Sub
Windows 8 Consumer Preview, Windows Server 8 Beta, Windows 7, Windows Server 2008 SP2, Windows Server 2008 R2 (Server Core Role supported with SP1 or later; Itanium not supported)