outline-width プロパティ
outline-width プロパティは、アウトラインの線幅を指定するプロパティです。
アウトラインはborderの外側に描写され、borderのように行下左右の区別はありません。
outline-width プロパティは、outline-styleプロパティに線種が指定されていないと機能しません。
outline-style: dotted;
outline-color: red;
outline-width: 2px;
詳しくは Example を参照してください
ページ内 Index
構文(Syntax)
CSS
outline-width: medium | thin | thick | length | initial | inherit;
DOM ( JavaScript )
String = object.style.outlineWidth;
object.style.outlineWidth="medium | thin | thick | length | initial | inherit";
値(Values)
| Value | 摘要 |
|---|---|
| medium | 初期値(default値) |
| thin | 細め |
| thick | 太め |
| length | 数値で指定、CSS長さの単位 |
| initial | 初期値に戻す |
| inherit | 親エレメントのプロパティを継承 |
備考(Remarks)
| 初期値(Default value) | medium |
| 継承(Inherited) | No |
| CSS Animation | Yes |
Example
outline-widthの例です。 見やすいように、点線、赤色、幅を3pxの線に指定しています。 borderの直ぐ外側、marginよりも内側に表示されています。
関連するプロパティ
以下は関連するプロパティです。
| outline | アウトラインに関するプロパティの一括定義 |
| outline-width | 線の幅 |
| outline-style | 線種 |
| outline-color | 線の色 |
| outline-offset | borderからの余白 |
