FontNumeralStyle 枚举

定义

描述 Typography 对象的数字样式。Describes the numeral style for a Typography object.

public enum class FontNumeralStyle
public enum FontNumeralStyle
type FontNumeralStyle = 
Public Enum FontNumeralStyle
继承
FontNumeralStyle

字段

Lining 1

使用内层数字样式。Lining numeral style is used. 将默认标志符号替换为高度相等的数字形式。Replaces default glyphs with numeric forms of even height.

Normal 0

使用默认数字样式。Default numeral style is used.

OldStyle 2

使用旧式数字样式。Old style numeral style is used. 将默认标志符号替换为高度和颜色与小写字母匹配的数字样式。Replaces default glyphs with a figure style that matches lowercase letters in height and color.

示例

下面的代码示例演示如何使用Typography对象的属性定义 Palatino Linotype 字体的旧样式数字。The following code example shows how to define old style numerals for the Palatino Linotype font, using properties of the Typography object.

<Paragraph FontFamily="Palatino Linotype">
  <Run Typography.NumeralStyle="Normal">1234567890</Run>
  <Run Typography.NumeralStyle="OldStyle">1234567890</Run>
</Paragraph>

注解

OpenType 字体支持旧样式数字格式。OpenType fonts support an old style numeral format. 此格式对于显示不再是标准样式的数字非常有用。This format is useful for displaying numerals in styles that are no longer standard. 以下文本以 Palatino Linotype 字体的标准和旧样式数字格式显示 18 世纪日期。The following text displays an 18th century date in standard and old style numeral formats for the Palatino Linotype font.

使用 OpenType 旧样式数字的文本Text using OpenType old style numerals
标准和旧样式数字的示例Example of standard and old style numerals

以下文本显示 Palatino Linotype 字体的标准数字,后跟旧样式数字。The following text displays standard numerals for the Palatino Linotype font, followed by old style numerals.

使用 OpenType 旧样式数字集的文本Text using OpenType old style numeral sets
标准和旧样式数字集的示例Example of standard and old style numeral sets

备注

大多数 OpenType 字体只公开了可用的全部 OpenType 功能的子集。Most OpenType fonts expose only a subset of the total OpenType features available. 如果指定的字体不支持特定功能, 则改用默认标志符号。If a specified font does not support a particular feature, the default glyphs are used instead.

适用于