Home > Article > Web Front-end > Can css3 fonts be blurred?
css3 fonts can be blurred; developers can use the filter attribute in CSS3 to achieve the font blur effect. The filter syntax is "filter: blur(px);", and its filter attribute defines the visibility of the element. Effect.
The operating environment of this tutorial: Windows 7 system, CSS3 version, DELL G3 computer.
Recommended: css video tutorial
We can use the CSS3 filter attribute to achieve the font blur effect; syntax: filter: blur(px);
The filter attribute defines the visual effect (such as blur and saturation) of the element (usually ).
The attribute value blur(px) can set Gaussian blur to the image. The "radius" value sets the standard deviation of the Gaussian function, or how many pixels are blended together on the screen, so the larger the value, the blurr it is; if there is no set value, the default is 0; this parameter can set the css length value, but Percentage values are not accepted.
Example:
<!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <style> .blur { -webkit-filter: blur(1px); /* Chrome, Opera */ -moz-filter: blur(1px); -ms-filter: blur(1px); filter: blur(1px); } </style> </head> <body> <p>正常字体</p> <p class="blur">模糊的字体</p> </body> </html>
Rendering:
The above is the detailed content of Can css3 fonts be blurred?. For more information, please follow other related articles on the PHP Chinese website!