温馨提示×

温馨提示×

您好,登录后才能下订单哦!

密码登录×
登录注册×
其他方式登录
点击 登录注册 即表示同意《亿速云用户服务条款》

css 列表属性详细总结

发布时间:2020-08-05 23:47:57 来源:网络 阅读:372 作者:crazy_charles 栏目:开发技术


列表类型(list-style-type)

要影响列表的样式,最简单(同时支持最充分)的办法就是改变其标志类型。

在一个无序列表中,列表项的标志 (marker) 是出现在各列表项旁边的圆点。

在有序列表中,标志可能是字母、数字或另外某种计数体系中的一个符号。

属性值有以下:

list-style-type:none无标记

list-style-type:disc默认,标记是实心圆

list-style-type:circle 空心圆

list-style-type:square实心方块

list-style-type:decimal标记是数字

list-style-type:decimal-leading-zero 0开头的数字标记(01,02,03)等 

list-style-type:lower-roman 小写罗马数字(i,ii,iii,iv,v)

list-style-type:upper-roman 大写罗马数字(I,II,III,IV)

list-style-type:lower-alpha 小写英文字母(a,b,c,d)

list-style-type:upper-alpha 大写英文字字母(A,B,C,D)

list-style-type:lower-greek 小写希腊字母(alpha,beta,gamma)

list-style-type:lower-latin 小写拉丁字母(a,b,c,d)

list-style-type:upper-latin 大写拉丁字母(A,B,C,D)

 

标记位置(list-style-position)

inside 列表项目标记位置在文本以内,且环绕文本根据标记对齐

outside 默认值,保持标记位于文本的本侧,列表项目目标记防止在文本以外,且环绕文本不根据标记对齐

inherit 规定应该从父元素继承list-style-position属性的值


设置图像列表标记(list-style-p_w_picpath)

属性值有以下

URL 图像的路径

none 默认,无图形被显示

inher 规定从父元素继承list-style-p_w_picpath属性的值


ul li {

list-style-p_w_picpath : url(xxx.gif)

}

向AI问一下细节

免责声明:本站发布的内容(图片、视频和文字)以原创、转载和分享为主,文章观点不代表本网站立场,如果涉及侵权请联系站长邮箱:is@yisu.com进行举报,并提供相关证据,一经查实,将立刻删除涉嫌侵权内容。

AI