Get the App
SLTechnology News&Howtos  ›  Development  › 

What is the use of the punctuation-trim attribute in css

Shulou Source: shulou.com Published: 2022-06-01 12:14:35 10月02日 Update

This article will explain in detail what is the use of the punctuation-trim attribute in css. The editor thinks it is very practical, so I share it for you as a reference. I hope you can get something after reading this article.

CSS3punctuation-trim attribute

What it does: the punctuation-trim attribute specifies whether punctuation is trimmed if the punctuation is at the beginning or end of a line, or near another full-width punctuation mark.

Syntax:

Punctuation-trim:none | start | end | allow-end | adjacent

None: open or close punctuation marks without trimming.

Start: trims the open punctuation mark at the end of each line.

End: trims the closed punctuation mark at the end of each line.

Allow-end: trim the closing punctuation at the end of each line if there is another reason that does not fit the previous one.

Adjacent: if the previous adjacent character trim opening punctuation is a full-shaped opening, middle or ending punctuation, or ideographic space. Trim the end of punctuation if the next adjacent character is a fullform closed or intermediate punctuation, or ideographic space.

Note: the punctuation-trim attribute is not supported by mainstream browsers at present.

An example of using the CSS3punctuation-trim attribute

Trim the open punctuation at the beginning of each line in the p element:

P

{

Punctuation-trim:start

}

This is the end of this article on "what is the use of punctuation-trim attributes in css". I hope the above content can be of some help to you, so that you can learn more knowledge. if you think the article is good, please share it out for more people to see.

Tags: Punctuation punctuation symbols trimming attributes articles ideographic full shape character beginning text more space ideographic closure good practical mainstream function element Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno Apple vpn macOS NVidia Docker