Home >Web Front-end >CSS Tutorial >How to use punctuation-trim attribute
The punctuation-trim attribute is used to specify whether the beginning or ending punctuation character should be trimmed when it appears on a line, or adjacent to another full-width punctuation character.
CSS3 punctuation-trim attribute
Function:punctuation-trim attribute Specifies whether punctuation is trimmed if it is at the beginning or end of a line, or adjacent to another full-width punctuation mark.
Syntax:
punctuation-trim: none|start|end|allow-end|adjacent;
none: Do not trim opening or closing punctuation.
start: Trim open punctuation at the end of each line.
end: Trim the closing 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 why it does not fit before.
adjacent: Trim opening punctuation if the previous adjacent character is a full-width opening, middle or end punctuation, or ideographic space. Trim ending punctuation if the next adjacent character is a full-width closing or intermediate punctuation, or ideographic space.
Note: Currently mainstream browsers do not support the punctuation-trim attribute.
CSS3 Example of using the punctuation-trim attribute
Trim the opening punctuation at the beginning of each line in the p element:
p { punctuation-trim:start; }
The above is the detailed content of How to use punctuation-trim attribute. For more information, please follow other related articles on the PHP Chinese website!