語言

TextBlock.GetFontWeight(DependencyObject) 方法

定義

回傳指定相依物件所附屬性的 FontWeight 值。

public:
 static System::Windows::FontWeight GetFontWeight(System::Windows::DependencyObject ^ element);
public static System.Windows.FontWeight GetFontWeight(System.Windows.DependencyObject element);
static member GetFontWeight : System.Windows.DependencyObject -> System.Windows.FontWeight
Public Shared Function GetFontWeight (element As DependencyObject) As FontWeight

參數

element
DependencyObject

用來取得附加屬性值 FontWeight 的相依物件。

傳回

附加屬性在指定相依物件上的 FontWeight 當前值。

例外狀況

element 是 null。

適用於

另請參閱