font-kerning プロパティ

プロパティ font-kerning は、 単語内の文字間のカーニングまたは間隔を設定します。 プロパティは次の値を取ることができます: auto(デフォルトはブラウザが決定)、 normal(カーニングを適用)および none (カーニングを適用しない)。

構文

cssセレクタ {
  font-kerning: auto または normal または none
}

例

テキストのデフォルトカーニングを設定してみましょう:

html<h1>見出し</h1>
<div>テキスト テキスト テキスト</div>
cssh1 {
  font-size: 40px;
  font-kerning: auto;
}
div {
  font-size: 18px;
}

Результат:

例

では、カーニングを設定してみましょう:

html<h1>見出し</h1>
<div>テキスト テキスト テキスト</div>
cssh1 {
  font-size: 40px;
  font-kerning: normal;
}
div {
  font-size: 18px;
}

Результат:

例

テキストからカーニングを削除してみましょう:

html<h1>見出し</h1>
<div>テキスト テキスト テキスト</div>
cssh1 {
  font-size: 40px;
  font-kerning: none;
}
div {
  font-size: 18px;
}

Результат:

関連項目

  • 垂直テキストにおける文字の向きを設定するプロパティ text-orientation
  • テキストの方向を設定するプロパティ writing-mode