FontFamily.GetTypefaces Method

Definition

Important

This API is not CLS-compliant.

Returns a collection of Typeface objects that represent the type faces in the default system font location.

C#
[System.CLSCompliant(false)]
public System.Collections.Generic.ICollection<System.Windows.Media.Typeface> GetTypefaces();

Returns

An ICollection<T> of Typeface objects.

Attributes

Examples

C#
// Return the font family for the selected font name.
FontFamily fontFamily = new FontFamily("Palatino Linotype");

// Return the collection of typefaces for the font family.
System.Collections.Generic.ICollection<Typeface> typefaces = fontFamily.GetTypefaces();

Applies to

Produkt Verzie
.NET Framework 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1
Windows Desktop 3.0, 3.1, 5, 6, 7, 8, 9, 10