FlowDocument.FontWeight Tulajdonság
Definíció
Fontos
Egyes információk olyan, kiadás előtti termékekre vonatkoznak, amelyek a kiadásig még jelentősen módosulhatnak. A Microsoft nem vállal kifejezett vagy törvényi garanciát az itt megjelenő információért.
Lekéri vagy beállítja a felső szintű betűtípus súlyát a FlowDocument.
public:
property System::Windows::FontWeight FontWeight { System::Windows::FontWeight get(); void set(System::Windows::FontWeight value); };
public System.Windows.FontWeight FontWeight { get; set; }
member this.FontWeight : System.Windows.FontWeight with get, set
Public Property FontWeight As FontWeight
Tulajdonság értéke
A kívánt betűvastagságot meghatározó osztály tagja FontWeights . Az alapértelmezett értéket az MessageFontWeight érték határozza meg.
Példák
Az alábbi példa bemutatja, hogyan állíthatja be egy FontWeightFlowDocument elem attribútumát.
<FlowDocumentReader>
<FlowDocument
FontFamily="Century Gothic"
FontSize="12"
FontStretch="UltraExpanded"
FontStyle="Italic"
FontWeight="UltraBold"
>
<Paragraph>
Any font settings on this paragraph would override the font settings
for the FlowDocument.
</Paragraph>
</FlowDocument>
</FlowDocumentReader>
Az alábbi példa bemutatja, hogyan állíthatja be a FontWeight tulajdonságot programozott módon.
FlowDocument flowDoc = new FlowDocument(new Paragraph(new Run("A bit of text content...")));
// Set the desired column gap to 10 device independend pixels.
flowDoc.FontFamily = new FontFamily("Century Gothic");
flowDoc.FontSize = 12.0;
flowDoc.FontStretch = FontStretches.UltraExpanded;
flowDoc.FontStyle = FontStyles.Italic;
flowDoc.FontWeight = FontWeights.UltraBold;
Dim flowDoc As New FlowDocument(New Paragraph(New Run("A bit of text content...")))
' Set the desired column gap to 10 device independend pixels.
flowDoc.FontFamily = New FontFamily("Century Gothic")
flowDoc.FontSize = 12.0
flowDoc.FontStretch = FontStretches.UltraExpanded
flowDoc.FontStyle = FontStyles.Italic
flowDoc.FontWeight = FontWeights.UltraBold
Megjegyzések
A gyermekelemek beállításai FontWeight felülbírálják ezt a legfelső szintű beállítást.
Függőségi tulajdonság adatai
| Termék | Érték |
|---|---|
| Azonosító mező | FontWeightProperty |
Metaadat-tulajdonságok beállítása: true |
\ |