The cover of The Complete Idiot's Guide to Create a Web Page The Complete Idiot's Style Sheets Reference

| Index | Current Category: Printing |
| Previous Style: white-space | Next Style: width |


widows

Sets the minimum number of lines between a potential page break and the end of a block element for the break to occur within that element.

Support:

W3C StandardInternet ExplorerNetscape Navigator
CSS2 and later Not supported Not supported
Notes:
  • Widows are lines from the end of a block element (such as a paragraph) that appear by themselves at the top of a page.
  • For example, suppose this property is set to 3. If a potential page break occurs within an element, the browser uses the following to determine whether the page break is okay within the element:
    • If there are fewer than 3 lines left to go in the element, the page break occurs after the element.
    • If there are 3 or more lines left to go in the element, the page break is inserted within the element.

See Also:

orphans, page-break-after, page-break-before, page-break-inside

Possible Values:

[integer]
The minimum number of lines.

Support:

W3C StandardInternet ExplorerNetscape Navigator
CSS2 and later Not supported Not supported

Example:
<P STYLE="widows: 1">
Here's to the maiden of bashful fifteen;
Here's to the widow of fifty;
Here's to the flaunting extravagant queen;
And here's to the housewife that's thrifty.
Let the toast pass,- 
Drink to the lass,
I'll warrant she'll prove an excuse for the glass.
Richard Brinsley Sheridan
</P>

| Index | Current Category: Printing |
| Previous Style: white-space | Next Style: width |