使用 CSS 设置反转效果
cssweb developmentfront end technology更新于 2025/2/20 11:24:17
反转效果用于将对象的颜色映射到色谱中的相反值,即创建负片图像。
此滤镜使用以下参数:
| Sr.No | 参数 &描述 |
|---|---|
| 1 | Invert 将对象的颜色映射到色谱中的相反值。 |
示例
您可以尝试运行以下代码来实现反转效果:
<html> <head> </head> <body> <img src = "/images/css.gif" alt = "CSS Logo" style = "Filter: invert" /> <p>Text Example:</p> <div style = "width: 357; height: 50; font-size: 30pt; font-family: Arial Black; color: red; Filter: invert"> CSS Tutorials </div> </body> </html>
相关文章
有用资源
css 参考教程 - 该教程包含有关 css 的更多信息:https://www.cainiaomax.com/css/

