FontFamily.FamilyTypefaces Propriété
Définition
Important
Certaines informations portent sur la préversion du produit qui est susceptible d’être en grande partie modifiée avant sa publication. Microsoft exclut toute garantie, expresse ou implicite, concernant les informations fournies ici.
Obtient une collection de types de caractères pour l'objet FontFamily.
public:
property System::Windows::Media::FamilyTypefaceCollection ^ FamilyTypefaces { System::Windows::Media::FamilyTypefaceCollection ^ get(); };
public System.Windows.Media.FamilyTypefaceCollection FamilyTypefaces { get; }
member this.FamilyTypefaces : System.Windows.Media.FamilyTypefaceCollection
Public ReadOnly Property FamilyTypefaces As FamilyTypefaceCollection
Valeur de propriété
Un FamilyTypefaceCollection qui représente une collection de types de caractères pour l'objet FontFamily.
Exemples
// Return the font family for the selected font name.
FontFamily fontFamily = new FontFamily("Arial Narrow");
// Return the family typeface collection for the font family.
FamilyTypefaceCollection familyTypefaceCollection = fontFamily.FamilyTypefaces;
// Enumerate the family typefaces in the collection.
foreach (FamilyTypeface typeface in familyTypefaceCollection)
{
// Add the typeface style values to the styles combo box.
comboBoxStyles.Items.Add(typeface.Style);
}
comboBoxStyles.SelectedIndex = 0;
' Return the font family for the selected font name.
Dim fontFamily As New FontFamily("Arial Narrow")
' Return the family typeface collection for the font family.
Dim familyTypefaceCollection As FamilyTypefaceCollection = fontFamily.FamilyTypefaces
' Enumerate the family typefaces in the collection.
For Each typeface As FamilyTypeface In familyTypefaceCollection
' Add the typeface style values to the styles combo box.
comboBoxStyles.Items.Add(typeface.Style)
Next typeface
comboBoxStyles.SelectedIndex = 0
Remarques
Utilisation des éléments de propriété XAML
<object>
<object.FamilyTypefaces>
<OneOrMoreFontFamilyTypefaces/>
</object.FamilyTypefaces>
</object>
Valeurs XAML
OneOrMoreFontFamilyTypefaces
Une ou plusieurs polices pour l’objet FontFamily .