amitdivya / dompdf

Automatically exported from code.google.com/p/dompdf
0 stars 0 forks source link

page-break styling is not honored on on certain non-block elements (e.g. tbody) #398

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
Background:
We had a request to provide some kind of option to allow for row groups to 
avoid being split between pages (ref Grouping certain table rows on one page, 
https://groups.google.com/forum/#!topic/dompdf/HfWt70SB0OU). The most obvious 
solution is for the user to surround rows with a tbody element (multiple tbody 
elements would define multiple row groups). The tbody element would then be 
styled page-break-inside: avoid.

Defect:
page-break-inside: avoid is not honored for tbody elements. This might seem to 
be appropriate, tbody is a grouping element and a table layout element 
(http://www.w3.org/TR/html401/struct/tables.html#edef-TBODY). However, the 
CSS2.1 spec allows for page-break-inside to be applied to "to other elements, 
e.g., 'table-row' elements" 
(http://www.w3.org/TR/CSS2/page.html#page-break-props).

Resolution:
Honor page-break styling on elements that behave similar to block-level 
elements (e.g. tr, tbody, thead).

Original issue reported on code.google.com by eclecticgeek on 22 Dec 2011 at 7:37

GoogleCodeExporter commented 9 years ago

Original comment by eclecticgeek on 22 Dec 2011 at 7:38

Attachments:

GoogleCodeExporter commented 9 years ago

Original comment by eclecticgeek on 24 May 2013 at 3:00