当前位置: 首页 > 网络学院 > 网页制作基础教程 > CSS > CSS overflow属性
The overflow property sets what happens if the content of an element overflow its area.
当内容超出其所在元素的区域时overflow属性可以设置应该如何应对。
Inherited: No
继承性:无
p |
值 | 描述 |
---|---|
visible | The content is not clipped. It renders outside the element 内容不会被省掉。会显示在元素的外面 |
hidden | The content is clipped, but the browser does not display a scroll-bar to see the rest of the content 内容会被省掉,但浏览器不会显示滚动条以用来查看剩余的内容 |
scroll | The content is clipped, but the browser displays a scroll-bar to see the rest of the content 内容被省掉,但浏览器会显示滚动条以用来查看剩余的内容 |
auto | If the content is clipped, the browser should display a scroll-bar to see the rest of the content 如果内容被省掉了,浏览器才会显示出滚动条以用来查看剩余的内容 |