トップページ  > CSS  > text-emphasis-color

★CSSリファレンス

text-emphasis …… テキスト傍点のスタイル・色をまとめて指定する
Google Chrome(-webkit-) Safari(-webkit-) Firefox Opera(-webkit-)
広告

text-emphasisプロパティは、テキスト傍点のスタイル・色をまとめて指定する際に使用します。

指定できるのは、 text-emphasis-styletext-emphasis-colorプロパティの値です。 まとめて指定する場合には、半角スペース区切りで値を記述します。 省略された値は、初期値に設定されます。

尚、text-emphasisプロパティでは、 text-emphasis-positionプロパティの値は設定できないので注意してください。

■値

text-emphasis-styleプロパティの値
none filled open dot circle double-circle triangle sesame '文字列'
text-emphasis-styleのページを参照
text-emphasis-colorプロパティの値
16進法やカラーネームなどで色を指定
text-emphasis-colorのページを参照

■初期値・適用対象・値の継承

初期値
text-emphasis-styleは、none
text-emphasis-colorは、現在の色
適用対象
すべての要素
値の継承
しない

■使用例

スタイルシート部分は外部ファイル(sample.css)に記述。

p.sample {
	text-emphasis: triangle red;
}

HTMLソース

<p class="sample">
text-emphasis: triangle red;<br>
を指定。
</p>
↓↓↓

ブラウザ上の表示

text-emphasis: triangle red;
を指定。

■ベンダープレフィックスを付けた場合の使用例

スタイルシート部分は外部ファイル(sample.css)に記述。

p.prefix_sample {
	-webkit-text-emphasis: triangle red;
	-moz-text-emphasis: triangle red;
	-ms-text-emphasis: triangle red;
}

HTMLソース

<p class="prefix_sample">
-webkit-text-emphasis: triangle red;<br>
-moz-text-emphasis: triangle red;<br>
-ms-text-emphasis: triangle red;<br>
を指定。
</p>
↓↓↓

ブラウザ上の表示

-webkit-text-emphasis: triangle red;
-moz-text-emphasis: triangle red;
-ms-text-emphasis: triangle red;
を指定。

広告
Sponsors
広告
MuuMuu Domain!
ドメイン取るならお名前.com
現役エンジニアのオンライン家庭教師【CodeCamp】
サイトに広告を掲載してお小遣いが稼げる!【A8.net】
Node.jsコース
はじめてのプログラミングコース
▲ページ先頭へ
HTMLクイックリファレンスについて
© HTMQ