CSS样式表属性

本文深入探讨了CSS背景和文本属性的使用方法,包括背景色、背景图像、背景重复、定位、关联,以及文本的缩进、对齐、字间距、字母间距、字符转换、文本装饰和方向等。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

CSS背景

背景色: background-color

背景图像: background-image

background-image: url(...)

背景重复:  background-repeat

background-repeat: repeat-x / repeat-y / no-repeat

背景定位: background-position

center / top / bottom / right / left

百分制 长度值

背景关联:  background-attachment

scroll / fixed  

CSS文本

缩进文本: text-indent

水平对齐: text-align

left / right / center / justify

字间距: word-spacing

字母间距: letter-spacing

字符转换: text-transform

none / uppercase / lowercase / capitalize

文本装饰: text-decoration

none / underline / overline / line-through / blink

处理空白符: white-space

normal 忽略多余空白符

pre 保留原文格式

nowrap 防止元素中文本换行

pre-line / pre-wrap

文本方向:  direction

ltr / rtl / inherit

文本颜色: color

行高: line-height

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值