Share via


RichTextBlock.FontStyle Properti

Definisi

Mendapatkan atau mengatur gaya font untuk konten dalam elemen ini.

public:
 property FontStyle FontStyle { FontStyle get(); void set(FontStyle value); };
FontStyle FontStyle();

void FontStyle(FontStyle value);
public FontStyle FontStyle { get; set; }
var fontStyle = richTextBlock.fontStyle;
richTextBlock.fontStyle = fontStyle;
Public Property FontStyle As FontStyle
<RichTextBlock FontStyle="fontStyleMemberName"/>

Nilai Properti

Gaya font yang diminta, yang merupakan enumerasi FontStyle bernama konstanta. Defaultnya adalah Normal.

Keterangan

Atur properti FontStyle untuk menentukan peregangan font default yang akan digunakan untuk semua teks di RichTextBlock. Anda dapat mengganti nilai ini untuk elemen teks tertentu di RichTextBlock dengan mengatur properti TextElement.FontStyle .

Berlaku untuk

Lihat juga