スタイルborderImageSliceプロパティ
例
image-borderの内側のオフセットを指定します。
document.getElementById("myDIV").style.borderImageSlice = "50% 10%";
定義と使用法
borderImageSliceプロパティは、画像境界の内側のオフセットを指定します。
ブラウザのサポート
表の数字は、プロパティを完全にサポートする最初のブラウザバージョンを示しています。
Property | |||||
---|---|---|---|---|---|
borderImageSlice | Yes | 11.0 | Yes | 6.0 | 15.0 11.0 O |
代わりにborderImageプロパティを見てください!
構文
borderImageSliceプロパティを返します。
object.style.borderImageSlice
borderImageSliceプロパティを設定します。
object.style.borderImageSlice = "number|%|fill|initial|inherit"
プロパティ値
Value | Description |
---|---|
number | Numbers represent pixels in the image (if the image is a raster image) or vector coordinates (if the image is a vector image) |
% | Percentages are relative to the size of the image: the width of the image for the horizontal offsets, the height for vertical offsets. Default value is 100% |
fill | Causes the middle part of the border-image to be preserved |
initial | Sets this property to its default value. Read about initial |
inherit | Inherits this property from its parent element. Read about inherit |
技術的な詳細
デフォルト値: | 100% |
---|---|
戻り値: | 要素のborder-image-sliceプロパティを表す文字列 |
CSSバージョン | CSS3 |
関連ページ
CSSリファレンス:border-image-sliceプロパティ