Get the App
SLTechnology News&Howtos  ›  Development  › 

What is the use of the text-emphasis attribute in css

Shulou Source: shulou.com Published: 2022-06-01 11:15:26 10月03日 Update

This article mainly shows you the "what is the use of text-emphasis attributes in css", the content is simple and clear, and I hope it can help you solve your doubts. Let me lead you to study and learn "what is the use of text-emphasis attributes in css" this article.

CSS3text-emphasis attribute

The text-emphasis property is an abbreviated property that sets text-emphasis-style and text-emphasis-color in a declaration.

Tip: Adobe's "KentenGenericOpenTypeFont" is a font suitable for emphasizing (emphasis) marks, and it is specially designed for emphasis marks.

Basic syntax:

Text-emphasis:text-emphasis-styletext-emphasis-color

Text-emphasis-style: applies an emphasis tag to the text of an element.

Text-emphasis-color: defines the foreground color of the emphasis tag.

Note: the text-emphasis attribute is not supported by mainstream browsers at present.

An example of using the CSS3text-emphasis attribute

/ * Initialvalue*/

Text-emphasis:none;/*Noemphasismarks*/

/ * value*/

Text-emphasis:'x'

Text-emphasis:' point'

Text-emphasis:'\ 25B2'

Text-emphasis:'*'#555

Text-emphasis:'foo';/*ShouldNOTuse.Itmaybecomputedtoorrenderedas'f'only*/

/ * Keywordsvalue*/

Text-emphasis:filled

Text-emphasis:open

Text-emphasis:filledsesame

Text-emphasis:opensesame

/ * Keywordsvaluecombinedwithacolor*/

Text-emphasis:filledsesame#555

/ * Globalvalues*/

Text-emphasis:inherit

Text-emphasis:initial

Text-emphasis:unset

Description:

None: there is no emphasis mark.

Filled: the shape is full of solid colors. If neither filled nor open exists, this is the default value.

Open: the shape is hollow.

Dot: the mark of the small circle will be displayed. The filling point is'(Utility 2022) and the hollow point is' ◦'(U+25E6).

Circle: the mark of the large circle will be displayed. The solid circle is' ●'(U+25CF) and the hollow circle is' ○'(U+25CB). This is the default shape in horizontal writing mode when no other shapes are given.

Double-circle: the mark of the double circle will be displayed. The filled double circle is' ◉'(U+25C9), and the open double circle is' ◎'(U+25CE).

Triangle: the marker of the triangle will be displayed. The solid triangle is' ▲'(U+25B2) and the hollow triangle is' △'(U+25B3).

Sesame: a tag in the shape of a sesame will be displayed. The filled sesame is U+FE45, and the open sesame is U+FE46. This is the default shape in vertical writing mode when no other shapes are given.

Displays the given string as a tag

Defines the color of the tag If there is no color, the default is currentColor.

The above is all the content of the article "what is the use of text-emphasis attributes in css?" Thank you for reading! I believe we all have a certain understanding, hope to share the content to help you, if you want to learn more knowledge, welcome to follow the industry information channel!

Tags: Tags attributes shapes triangles content circles articles sesame this is triangles patterns emphasis colors learning help open mainstream elements fonts characters Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno macOS NVidia Huawei Apple vpn