- Data Structure
- Networking
- RDBMS
- Operating System
- Java
- MS Excel
- iOS
- HTML
- CSS
- Android
- Python
- C Programming
- C++
- C#
- MongoDB
- MySQL
- Javascript
- PHP
- Physics
- Chemistry
- Biology
- Mathematics
- English
- Economics
- Psychology
- Social Studies
- Fashion Studies
- Legal Studies
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Convert the colors of the object to 256 shades of gray with CSS
Use the grayscale effect to convert the colors of the object to 256 shaded of gray. The following parameter is used in this filter:
Parameter | Description |
---|---|
Gray | Converts the colors of the object to 256 shades of gray. |
Example
You can try to run the following code to set grayscale effect:
<html> <head> </head> <body> <img src="/css/images/logo.png" alt="CSS Logo" style="Filter: Gray"> <p>Text Example:</p> <div style="width: 357; height: 50; font-size: 30pt; font-family: Arial Black; color: red; Filter: Gray">CSS Tutorials</div> </body> </html>
Advertisements