Typography.DiscretionaryLigatures 屬性

定義

取得或設定值,該值會判斷是否啟用判別連字。

public:
 property bool DiscretionaryLigatures { bool get(); void set(bool value); };
public bool DiscretionaryLigatures { get; set; }
member this.DiscretionaryLigatures : bool with get, set
Public Property DiscretionaryLigatures As Boolean

屬性值

如果啟用判別連字則為 true,否則為 false。 預設值是 false

備註

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

任意連字是設計成裝飾,而不是專為可讀性而設計。 下列文字顯示 Pericles 字型 Discretionary 連音符號。

使用 OpenType 任意連字的文字
任意連字集的範例

下列程式碼範例示範如何使用 屬性,定義 Pericles 字 DiscretionaryLigatures 型的任意音符號字元。

<Paragraph FontFamily="Pericles" Typography.DiscretionaryLigatures="True">
  <Run Typography.StylisticAlternates="1">CO</Run>
  <Run Typography.StylisticAlternates="1">LA</Run>
  <Run Typography.StylisticAlternates="1">LE</Run>
  <Run Typography.StylisticAlternates="1">LI</Run>
  <Run Typography.StylisticAlternates="1">LL</Run>
  <Run Typography.StylisticAlternates="1">LO</Run>
  <Run Typography.StylisticAlternates="1">LU</Run>
</Paragraph>

XAML Attribute Usage

<objectTypography.DiscretionaryLigatures=「bool」/>

相依性屬性資訊

識別碼欄位 DiscretionaryLigaturesProperty
中繼資料屬性設定為 true AffectsMeasure, AffectsRender, Inherits

適用於

另請參閱