Gets or sets a FontCapitals enumerated value that indicates the capital form of the selected font.
Assembly: PresentationFramework (in PresentationFramework.dll)
XMLNS for XAML: http://schemas.microsoft.com/winfx/2006/xaml/presentation, http://schemas.microsoft.com/netfx/2007/xaml/presentation
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.
The following code example shows how to define capitals for the Pescadero font, using the 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.
MyParagraph.FontFamily = new FontFamily("Pescadero"); MyParagraph.FontSize = 48; Run run_1 = new Run("CAPITALS "); MyParagraph.Inlines.Add(run_1); Run run_2 = new Run("Capitals "); run_2.Typography.Capitals = FontCapitals.SmallCaps; MyParagraph.Inlines.Add(run_2); Run run_3 = new Run("Capitals"); run_3.Typography.Capitals = FontCapitals.AllSmallCaps; MyParagraph.Inlines.Add(run_3); MyParagraph.Inlines.Add(new LineBreak());