語法:
border-radius : none | <length>{1,4} [ / <length>{1,4} ]?
相關(guān)屬性: border-top-right-radius , border-bottom-right-radius , border-bottom-left-radius , border-top-left-radius
取值:
- <length>:
- 由浮點數(shù)字和單位標(biāo)識符組成的長度值。不可為負(fù)值。
- border-top-left-radius:
- 由浮點數(shù)字和單位標(biāo)識符組成的長度值。不可為負(fù)值。
說明:
- 第一個值是水平半徑。
- 如果第二個值省略,則它等于第一個值,這時這個角就是一個四分之一圓角。
- 如果任意一個值為0,則這個角是矩形,不會是圓的。
- 值不允許是負(fù)值。
引擎類型 | Gecko | Webkit | Presto |
---|---|---|---|
Border-radius | -moz-border-radius | -webkit-border-radius | ? |
border-bottom-left-radius | -moz-border-radius-bottomleft | -webkit-border-bottom-left-radius | |
border-bottom-right-radius | -moz-border-radius-bottomright | -webkit-border-bottom-right-radius | |
border-top-left-radius | -moz-border-radius-topleft | -webkit-border-top-left-radius | |
border-top-right-radius | -moz-border-radius-topright | -webkit-border-top-right-radius |
兼容性:
類型 |
![]() |
![]() |
![]() |
![]() |
![]() |
---|---|---|---|---|---|
版本 | (×)IE6 | (×)Firefox 2.0 | (√)Chrome 1.0.x | (×)Opera 9.64 | (√)Safari 3.1 |
(×)IE7 | (√)Firefox 3.0 | (√)Chrome 2.0.x | ? | ||
(×)IE8 | (√)Firefox 3.5 | ||||
示例:
