Typography.StandardSwashes 屬性

定義

取得或設定值,該值會指定標準 Swash 形式的索引。

public:
 property int StandardSwashes { int get(); void set(int value); };
public int StandardSwashes { get; set; }
member this.StandardSwashes : int with get, set
Public Property StandardSwashes As Integer

屬性值

Int32

標準 Swash 形式的索引。 預設值是 0 (零)。

備註

這個屬性會取得或設定擁有 Typography 屬性的物件上的值,這是存取類別實例的唯一 Typography 方法。 此外,這個屬性支援附加屬性使用方式,以便在 XAML 中的文字包含物件上設定它。

花飾字是裝飾性字符,會使用精心設計且通常與書寫體相關聯的裝飾。 下列文字顯示 Pescadero 字型的標準和花飾字字符。

使用 OpenType 標準和花飾字字符的文字
標準字元和 swash 字元的範例

花飾字通常用為簡短片語中的裝飾項目,例如事件宣告。 下列文字使用花飾字強調大寫字母的事件名稱。

使用 OpenType 花飾字的文字
用於大寫字母的 Swash 範例

下列程式碼範例示範如何使用 屬性定義字 StandardSwashes 型的 Swash。

<Paragraph FontFamily="Pescadero" TextBlock.TextAlignment="Center">
  Wishing you a<LineBreak/>
  <Run Typography.StandardSwashes="1" FontSize="36">Happy New Year!</Run>
</Paragraph>

如果 的值 StandardSwashes 大於零,而且選取的字型不支援指定索引值的標準 Swashes 表單,則會顯示字母的預設格式。

XAML Attribute Usage

<object Typography.StandardSwashes="int"/>

相依性屬性資訊

識別碼欄位 StandardSwashesProperty
中繼資料屬性設定為 true AffectsMeasureAffectsRenderInherits

適用於

另請參閱