expression web 视频教程第十一节 格式菜单[5] 样式
11讲 这些Css样式都是网络找的资料,如果大家想深入给我留言。要不我就跳过这些东西。但是我会把相关的参考资料贴出来。谢谢大家关注
语法:
background-repeat : repeat | no-repeat | repeat-x | repeat-y 
取值:
| repeat | : | 默认值。背景图像在纵向和横向上平铺 | 
| no-repeat | : | 背景图像不平铺 | 
| repeat-x | : | 背景图像仅在横向上平铺 | 
| repeat-y | : | 背景图像仅在纵向上平铺 | 
说明:
设置或检索对象的背景图像是否及如何铺排。必须先指定对象的背景图像( background-image )。
此属性对于 currentStyle 对象而言是只读的。对于其他对象而言是可读写的。
对应的脚本特性为 backgroundRepeat 。
此属性对于 currentStyle 对象而言是只读的。对于其他对象而言是可读写的。
对应的脚本特性为 backgroundRepeat 。
示例:
menu { background: url("images/aardvark.gif"); background-repeat: repeat-y; } 
p { background: url("images/aardvark.gif"); background-repeat: no-repeat; }
p { background: url("images/aardvark.gif"); background-repeat: no-repeat; }
================================================
语法:
background-position-x : length | left | center | right 
取值:
| length | : | 百分数 | 由浮点数字和单位标识符组成的长度值。请参阅 长度单位 | 
| left | : | 居左 | 
| center | : | 居中 | 
| right | : | 居右 | 
说明:
设置或检索对象的背景图像横坐标位置。必须先指定 background-image 属性。
该属性定位不受对象的补丁属性( padding )设置影响。
默认值为: 0% 。
此属性对于 currentStyle 对象而言是只读的。对于其他对象而言是可读写的。
对应的脚本特性为 backgroundPositionX 。
该属性定位不受对象的补丁属性( padding )设置影响。
默认值为: 0% 。
此属性对于 currentStyle 对象而言是只读的。对于其他对象而言是可读写的。
对应的脚本特性为 backgroundPositionX 。
示例:
p { background-image: url("images/aardvark.gif"); background-position-x: 35%; background-repeat:no-repeat; } 
=============================================
语法:
background-position-y : length | top | center | bottom 
取值:
| length | : | 百分数 | 由浮点数字和单位标识符组成的长度值。请参阅 长度单位 | 
| top | : | 居顶 | 
| center | : | 居中 | 
| bottom | : | 居底 | 
说明:
设置或检索对象的背景图像纵坐标位置。必须先指定 background-image 属性。
该属性定位不受对象的补丁属性( padding )设置影响。
默认值为: 0% 。
此属性对于 currentStyle 对象而言是只读的。对于其他对象而言是可读写的。
对应的脚本特性为 backgroundPositionY 。
该属性定位不受对象的补丁属性( padding )设置影响。
默认值为: 0% 。
此属性对于 currentStyle 对象而言是只读的。对于其他对象而言是可读写的。
对应的脚本特性为 backgroundPositionY 。
示例:
div { background-image: url("images/aardvark.gif"); background-position-y: 35%; background-repeat:no-repeat; } 
===============================
background-attachment : scroll | fixed 
取值:
| scroll | : | 默认值。背景图像是随对象内容滚动 | 
| fixed | : | 背景图像固定 | 
说明:
设置或检索背景图像是随对象内容滚动还是固定的。
此属性对于 currentStyle 对象而言是只读的。对于其他对象而言是可读写的。
请参阅 bgProperties 属性(特性)。对应的脚本特性为 backgroundAttachment 。
此属性对于 currentStyle 对象而言是只读的。对于其他对象而言是可读写的。
请参阅 bgProperties 属性(特性)。对应的脚本特性为 backgroundAttachment 。
示例:
html { background-image: url("anasazi.tif"); background-attachment: fixed; } 
body { background-attachment: scroll; }
body { background-attachment: scroll; }
| dsfsdfsdfsdf | dsfdssdfsdds | 
| dsfdsds | dsfsddsds | 
 
                    
                     
                    
                 
                    
                 
                
            
         
 
         浙公网安备 33010602011771号
浙公网安备 33010602011771号