Proprietà orphans CSS
Definition and usage
orphans
The attribute is used to specify the minimum number of lines that must be retained at the bottom of the page or column.
Tip:See also widows
Attribute.
Example
When printing, at least 4 lines must be displayed at the bottom of each page, and at least 2 lines at the top:
@media print { orphans: 4; widows: 2; }
CSS syntax
orphans: integer|initial|inherit;
Attribute value
Value | Description |
---|---|
integer |
Specifies the minimum number of lines that must be retained at the bottom of the page or column. Negative values are not allowed. |
initial | Sets this property to its default value. See initial. |
inherit | Inherits this property from its parent element. See inherit. |
Technical details
Default value: | 2 |
---|---|
Inheritance: | Yes |
Animation creation: | Not supported. See:Animation-related properties. |
Version: | CSS3 |
JavaScript syntax: | object.style.orphans = "3" |
Browser support
The numbers in the table indicate the first browser version to fully support this property.
Chrome | Edge | Firefox | Safari | Opera |
---|---|---|---|---|
25.0 | 8.0 | Non supportato | 3.1 | 10.0 |