-webkit-text-stroke-color
Baseline Widely available
This feature is well established and works across many devices and browser versions. It’s been available across browsers since April 2017.
非標準: この機能は標準ではなく、標準化の予定もありません。公開されているウェブサイトには使用しないでください。ユーザーによっては使用できないことがあります。実装ごとに大きな差があることもあり、将来は振る舞いが変わるかもしれません。
-webkit-text-stroke-color
は CSS のプロパティで、テキストの文字の線の色を示します。このプロパティが設定されない場合、 color
プロパティの値が使用されます。
css
/* <color> 値 */
-webkit-text-stroke-color: red;
-webkit-text-stroke-color: #e08ab4;
-webkit-text-stroke-color: rgb(200, 100, 0);
/* グローバル値 */
-webkit-text-stroke-color: inherit;
-webkit-text-stroke-color: initial;
-webkit-text-stroke-color: unset;
構文
値
<color>
-
線の色。
公式定義
初期値 | currentcolor |
---|---|
適用対象 | すべての要素 |
継承 | あり |
計算値 | 色の計算値 |
アニメーションの種類 | 色 |
形式文法
-webkit-text-stroke-color =
<color>
例
角の色を変化させる
HTML
html
<p>Text with stroke</p>
<input type="color" value="#ff0000" />
CSS
css
p {
margin: 0;
font-size: 4em;
-webkit-text-stroke-width: 3px;
-webkit-text-stroke-color: #ff0000; /* ライブサンプルで変更可能 */
}
結果
仕様書
Specification |
---|
Compatibility # the-webkit-text-stroke-color |
ブラウザーの互換性
Report problems with this compatibility data on GitHubdesktop | mobile | |||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|
-webkit-text-stroke-color |
Legend
Tip: you can click/tap on a cell for more information.
- Full support
- Full support
The compatibility table on this page is generated from structured data. If you'd like to contribute to the data, please check out https://github.com/mdn/browser-compat-data and send us a pull request.