Files
ClassContent/历届学生/逯帅帅/项目开发/上课项目/css练习/css属性笔记.txt
2024-09-27 02:06:13 +08:00

51 lines
1.4 KiB
Plaintext
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

1字体类
最常用
font-size 设置字体大小
font-weight 设置字体加粗
text-decoration 设置文字的线
line-height 设置行高 一般用于 div 内部的文字的垂直居中
偶尔使用
letter-spacing 设置字符的左右边距的
text-shadow颜色 x轴偏移距离 y轴偏移距离 阴影的模糊度 设置文字阴影
font-family: 设置字体风格的
自定义字体风格教程http://www.sharedblog.cn/post/126.html
不知道什么时候能使用
word-spacing 设置文字中空格大小的
2文本类
text-indent 设置段落的首行缩进
text-overflow 文字超过父元素的宽度的时候,显示 ...
white-space 设置文字超过父元素的时候,是否可以换行显示
overflow 设置文字超过父元素的时候,如何展示
text-align 设置文字在父元素中的水平对齐方式左left 中
center 右right
vertical-align 设置元素内部多个行内元素的Y对齐方式
outline: none 去除按钮和输入框激活时候的外边框
border-radius 设置元素的圆角属性
box-shadow 设置div的阴影
list-style 设置ul或者 ol 中li的样式风格 none
filter 设置滤镜 常用 blur模糊的
display: 设置元素如何显示
1可以让块标签和行标签相互转换
block 块标签
inline 行标签
inline-block 行内块标签
2none 把元素隐藏起来
其他方式
2.1 visibility: hidden
2.2 width 0 height 0
2.3 opacity 0 ~ 1
2.4 标签上加 hidden