References : Style sheets
Embedded content and automatic numbering properties
CSS2 proposes properties and values through which authors can automatically format contents (numbered lists, for instance, can be generated automatically). To do this, the designer of a Web page sets the style and location of the content to be generated by means of the :
before and :
after pseudo-elements which indicate the page's elements before or after which the content will automatically be generated.
content |
counter-increment |
counter-reset
|
marker-offset |
quotes
| content |
|
|
| Used with the :before and :after pseudo-elements to generate a content in the document. |
| |
| CSS2 value | <string> | <uri> | <counter> | attr(X) | open-quote | close-quote | no-open-quote | no-close-quote | inherit |
| |
| Initial value | Empty string |
| |
| Applied to | Pseudo-elements :before and :after. |
| |
| Inherited | No. |
| |
Top |
|
| counter-increment |
|
|
| Accepts one or several counter names (identifiers), each one of which can optionally be followed by an integer. The integer is the value by which the counter will be incremented for every occurrence of the element. |
| |
| CSS2 value | <identifier> | <integer> | none | inherit |
| |
| Initial value | none |
| |
| Applied to | All elements. |
| |
| Inherited | No. |
| |
Top |
|
| counter-reset |
|
|
| Contains a list of one or more counter names, each one followed by an optional integer. The latter gives the value that the counter will be set to on each occurrence of the element. |
| |
| CSS2 value | <identifier> | <integer> | none | inherit |
| |
| Initial value | none |
| |
| Applied to | All elements. |
| |
| Inherited | No. |
| |
Top |
|
| marker-offset |
|
|
| Specifies the distance between the nearest border edges of a marker box and its associated principal box. |
| |
| CSS2 value | <length> | auto | inherit |
| |
| Initial value | auto |
| |
| Applied to | Elements display that have been assigned the value property marker. |
| |
| Inherited | No. |
| |
Top |
|
| quotes |
|
|
| Defines quotation marks for embedded quotations. |
| |
| CSS2 value | <string> | <string>+ | none | inherit |
| |
| Initial value | Depends on the browser. |
| |
| Applied to | All elements. |
| |
| Inherited | Yes. |
| |
Top |
|