Bug 130287 - Editing: Disable widow and orphan control for Table Contents style
Summary: Editing: Disable widow and orphan control for Table Contents style
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
7.0.0.0.alpha0+
Hardware: All All
: medium normal
Assignee: László Németh
URL:
Whiteboard: target:6.5.0
Keywords:
Depends on:
Blocks: DOCX-Tables
  Show dependency treegraph
 
Reported: 2020-01-30 12:09 UTC by NISZ LibreOffice Team
Modified: 2021-11-11 20:20 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:
Regression By:


Attachments
Example file from Writer (17.47 KB, application/vnd.oasis.opendocument.text)
2020-01-30 12:10 UTC, NISZ LibreOffice Team
Details
Screenshot of the problem in Writer (84.26 KB, image/png)
2020-01-30 12:11 UTC, NISZ LibreOffice Team
Details
The example document after turning off the widow control/orphan control (87.80 KB, image/png)
2020-01-30 12:11 UTC, NISZ LibreOffice Team
Details

Note You need to log in before you can comment on or make changes to this bug.
Description NISZ LibreOffice Team 2020-01-30 12:09:47 UTC
Description:
Since bug #89714 the default style has Widow and Orphan control on by default.
This can cause in Writer tables content being hidden, see attached file.
It would be a better default if these were disabled only for the Table Contents default style, since manually turning them off fixes the problem of the attachment.

Steps to Reproduce:
1.Open attached file.

Actual Results:
The text in the first cell of the second page is not entirely readable.

Expected Results:
All text in the table should be readable. This can be achieved by turning the Widow control and Orphan control off in the Table Contents styles Text Flow tab.


Reproducible: Always


User Profile Reset: No



Additional Info:
Comment 1 NISZ LibreOffice Team 2020-01-30 12:10:55 UTC
Created attachment 157524 [details]
Example file from Writer
Comment 2 NISZ LibreOffice Team 2020-01-30 12:11:17 UTC
Created attachment 157525 [details]
Screenshot of the problem in Writer
Comment 3 NISZ LibreOffice Team 2020-01-30 12:11:56 UTC
Created attachment 157526 [details]
The example document after turning off the widow control/orphan control
Comment 4 László Németh 2020-01-30 13:07:25 UTC
Note: Writer, like MSO ignores orphan/widow settings, but in the case of Writer, is not perfectly, for example, using vertically merged cells can cause a problem reported in Bug 128959.
Comment 5 Commit Notification 2020-01-31 06:47:29 UTC
László Németh committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/c81d766dd4ff7d8b580b7fdc79db6e68c5f14204

tdf#130287 disable orphan/widow control in Table Contents

It will be available in 6.5.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 6 László Németh 2020-02-11 13:57:48 UTC
Testing:

1. File->New
2. Insert a new table
3. Check "Text flow" paragraph settings of one of the table cells

Orphan/Widow settings are disabled (zeroes).
Comment 7 Nikolaj 2021-09-24 07:31:03 UTC
Version 7.1.6.2

Hi, made some research. Orphan and widow control should be definitly respected according to ODF specification.

But here there is no problem at all.

Libre office implements widow/orpahn/"keep together" control by secretly inserting soft page break before paragraphs in due places. Looks like algorythm is generally incorrect for tables (https://bugs.documentfoundation.org/show_bug.cgi?id=53088). But here LibreOffice works correctly. Don't know why. The soft break is inserted before the paragraph that doesn't fit page and this is correct.

Now let's go to the row span issue. Libre Office spans in this case three rows. Each of three rows have a height of 7mm. Generally in spanned rows LibreOffice ignores row height setting. And it is correct. As row height of spanned rows shuld be the sum or rows it spans. 

If the text could fit three rows (21 mm), than it wouldn't be cut. But in this case it shoud fit one left rows and it is correctly cutted.

Add tow more spanned row or just make row size for this third row "Fit to size" and text won't be cutted.

Don't see any error here. 

Looks like the solution by nemeth@numbertext.org didn't influence the problem and the bug should have been closed as INVALID.
Comment 8 Nikolaj 2021-11-11 20:20:07 UTC
Sorry, was too fast in conclusions, but can't delete previous comment. The bug is about default behavior. Orphans and widows control is still rather buggy in paragraphs inside table cells (7.1.6.2), it is quite reasonable to turn it off by default. Awaiting https://bugs.documentfoundation.org/show_bug.cgi?id=53088