サイト内検索
...スタイルシート(css)...
スタイルシート・テキスト
単語の間隔
- 単語の間隔は、word-spacingプロパティを指定します。
- 間隔の指定は、数値+単位(px、em、他)を指定します。
- normal・・・(標準値・初期設定値)
- [使い方]
- .sample{word-spacing: 0.5em;}
- [メモ]
- IE8・operaでは、未対応です。
プロパティ名 | 値 | 説明 |
---|---|---|
word-spacing: | ; |
「数値+単位」(例・・2.5em)を指定します。
単位は、(px、em、他)を指定します。 |
normal; | 標準値・初期設定値 |
サンプル
[headの中]
<style type="text/css"><!--
.sample1{word-spacing: 0.5em;}
.sample2{word-spacing: 3.3em;}
.sample3{word-spacing: 15px;}
-->
</style>
[bodyの中]
<div class="sample1">abcdefghijkl</div><div class="sample2">abcdefghijkl</div>
<div class="sample3">abcdefghijkl</div>
[ブラウザ上]
abc def ghi jkl
abc def ghi jkl
abc def ghi jkl