Typography.Capitals Property


Gets or sets a FontCapitals enumerated value that indicates the capital form of the selected font.

Namespace:   System.Windows.Documents
Assembly:  PresentationFramework (in PresentationFramework.dll)

member Capitals : FontCapitals with get, set

Property Value

Type: System.Windows.FontCapitals

A FontCapitals enumerated value. The default value is Normal.

This property gets or sets a value on the object that owns a Typography property, which is the only way to access a Typography class instance. In addition, this property supports an attached property usage so that it can be set on text-containing objects in XAML.

Capitals are a set of typographical forms that render text in capital-styled glyphs. Typically, when text is rendered as all capitals, the spacing between letters can appear too tight, and the weight and proportion of the letters too heavy. OpenType supports a number of styling formats for capitals, including small capitals, petite capitals, titling, and capital spacing. These styling formats allow you to control the appearance of capitals.

The following text displays standard capital letters for the Pescadero font, followed by the letters styled as "SmallCaps" and "AllSmallCaps". In this case, the same font size is used for all three words.

Text using OpenType capitals

Example of capitals

The following code example shows how to define capitals for the Pescadero font, using the Capitals property. When the "SmallCaps" format is used, any leading capital letter is ignored.

The following code example accomplishes the same task as the previous markup example.

No code example is currently available or this language may not be supported.

<object Typography.Capitals="FontCapitals"/>

.NET Framework
Available since 3.0
Return to top