css padding属性
翻译结果:
padding
英 [ˈpædɪŋ] 美 [ˈpædɪŋ]
n.衬垫;衬料;赘语;废话
v.给…装衬垫,加垫子( pad的现在分词 );步行,放轻脚步走
css padding属性 语法
作用:在一个声明中设置所有内边距属性。
说明:这个简写属性设置元素所有内边距的宽度,或者设置各边上内边距的宽度。行内非替换元素上设置的内边距不会影响行高计算;因此,如果一个元素既有内边距又有背景,从视觉上看可能会延伸到其他行,有可能还会与其他内容重叠。元素的背景会延伸穿过内边距。不允许指定负边距值。
注释:不允许使用负值。所有浏览器都支持 padding 属性。
css padding属性 示例
<html> <head> <style type="text/css"> td.test1 {padding: 15px} td.test2 {padding: 10px 25px} </style> </head> <body> <table border="1"> <tr> <td class="test1"> 这个表格单元的每个边拥有相等的内边距。 </td> </tr> </table> <br /> <table border="1"> <tr> <td class="test2"> 这个表格单元的上和下内边距是 10px,左和右内边距是 25px。 </td> </tr> </table> </body> </html>
运行实例 »
点击 "运行实例" 按钮查看在线实例
热门推荐
CSS 相关词典
- keyframes 翻译 示例 语法
- animation 翻译 示例 语法
- animation-name 翻译 示例 语法
- animation-duration 翻译 示例 语法
- animation-timing-function 翻译 示例 语法
- animation-delay 翻译 示例 语法
- animation-iteration-count 翻译 示例 语法
- animation-direction 翻译 示例 语法
- animation-play-state 翻译 示例 语法
- animation-fill-mode 翻译 示例 语法
- background 翻译 示例 语法
- background-attachment 翻译 示例 语法
- background-color 翻译 示例 语法
- background-image 翻译 示例 语法
- background-position 翻译 示例 语法
- resize 翻译 示例 语法
- background-repeat 翻译 示例 语法
- background-clip 翻译 示例 语法
- outline-offset 翻译 示例 语法
- background-origin 翻译 示例 语法
- background-size 翻译 示例 语法
- nav-up 翻译 示例 语法
- border 翻译 示例 语法
- nav-right 翻译 示例 语法
- nav-left 翻译 示例 语法
- nav-index 翻译 示例 语法
- border-bottom 翻译 示例 语法
- nav-down 翻译 示例 语法
- icon 翻译 示例 语法
- box-sizing 翻译 示例 语法
- appearance 翻译 示例 语法
- transition-delay 翻译 示例 语法
- transition-timing-function 翻译 示例 语法
- transition-duration 翻译 示例 语法
- transition-property 翻译 示例 语法
- transition 翻译 示例 语法
- backface-visibility 翻译 示例 语法
- border-bottom-color 翻译 示例 语法
- border-bottom-style 翻译 示例 语法
- perspective-origin 翻译 示例 语法
- border-bottom-width 翻译 示例 语法
- perspective 翻译 示例 语法
- border-color 翻译 示例 语法
- transform-style 翻译 示例 语法
- border-left 翻译 示例 语法
- border-left-color 翻译 示例 语法
- transform-origin 翻译 示例 语法
- border-left-style 翻译 示例 语法
- border-left-width 翻译 示例 语法
- transform 翻译 示例 语法
- border-right 翻译 示例 语法
- border-right-color 翻译 示例 语法
- word-wrap 翻译 示例 语法
- border-right-style 翻译 示例 语法
- word-break 翻译 示例 语法
- border-right-width 翻译 示例 语法
- text-wrap 翻译 示例 语法
- border-style 翻译 示例 语法
- text-shadow 翻译 示例 语法
- border-top 翻译 示例 语法
- border-top-color 翻译 示例 语法
- border-top-style 翻译 示例 语法
- text-overflow 翻译 示例 语法
- border-top-width 翻译 示例 语法
- text-outline 翻译 示例 语法
- border-width 翻译 示例 语法
- text-justify 翻译 示例 语法
- outline 翻译 示例 语法
- outline-color 翻译 示例 语法
- text-emphasis 翻译 示例 语法
- outline-style 翻译 示例 语法
- punctuation-trim 翻译 示例 语法
- outline-width 翻译 示例 语法
- hanging-punctuation 翻译 示例 语法
- border-bottom-left-radius 翻译 示例 语法
- word-spacing 翻译 示例 语法
- border-bottom-right-radius 翻译 示例 语法
- white-space 翻译 示例 语法
- border-image 翻译 示例 语法
- border-image-outset 翻译 示例 语法
- unicode-bidi 翻译 示例 语法
- border-image-repeat 翻译 示例 语法
- border-image-slice 翻译 示例 语法
- border-image-source 翻译 示例 语法
- text-transform 翻译 示例 语法
- border-image-width 翻译 示例 语法
- border-radius 翻译 示例 语法
- text-indent 翻译 示例 语法
- border-top-left-radius 翻译 示例 语法
- text-decoration 翻译 示例 语法
- border-top-right-radius 翻译 示例 语法
- box-shadow 翻译 示例 语法
- text-align 翻译 示例 语法
- line-height 翻译 示例 语法
- letter-spacing 翻译 示例 语法
- direction 翻译 示例 语法
- overflow-x 翻译 示例 语法
- overflow-y 翻译 示例 语法
- color 翻译 示例 语法
- overflow-style 翻译 示例 语法