How do I get and keep a text body style paragraphs and heading immediately following a table?

When I insert a table into a document the text following the table shifts to the next page and I am unable to click on the page below the table. In one tip, I found that if I put my cursor at the end of text in the last cell of table and then hit Alt-Enter, I can then type text below the table.

The problem is that the text following the table uses the Default Style and I want to use Text Body style. I can change it to Text Body, but as soon as I hit enter to start a new paragraph all of the text following the table jumps to the next page and I can no longer click on the page below the table. I can still Alt-Enter and reenter text, but as soon as I hit enter the problem repeats.

Is this a known bug? Is there any kind of a work around?

A similar issue occurs when editing a document without a table on the page. Occasionally, text (starting from a new paragraph) from the middle of the page jumps to the next page, leaving the bottom half of the previous page empty. If I try to place my cursor at the first character of the new page and hit backspace, nothing happens. I need to highlight the text from the paragraph before and after the faulty page break and make sure they are the same style (text body). While this work around works in the case of no table, it does not work in the case of a table. I suspect the two problems are related.

I am using LibreOffice 4.2.1.1 on Debian Wheezy.

Please edit your question to indicate the file format of the template / document and whether it has only been created / edited in LO or with a mixture of different applications (e.g., LO + MSO). Thanks.

This is not an answer, but additional information. The problem that I describe does not occur with the standard template, but does occur with my organization’s template.

It took dozens of hours to create the template with the style to get the look for my organization’s reports.

Does anyone know if there is a tool or method to debug template styles in writer?

I have temporarily solved the problem by copying the whole document into a blank document and doing some minor formatting. So, this is solved for now, but time will tell as to whether the problem will reemerge.

I had this issue too, and solved it by editing the style for the heading that was jumping to the next page. Specifically, inside the edit style dialog, under the Text Flow tab, I unchecked the “Keep with next paragraph” box.

Gentle hacker, if this helped you, remember that next time you solve a problem, and help somebody else with a post here, on stack exchange, etc.!

As LO / ODF does not yet support table styles the Text Flow options of both the table and the Table Contents / Table Heading paragraph styles are generally used to control breaking. There is also a Spacing / Below value property for a table (Table tab) that can cause what you describe. All I can suggest is that you examine the settings in these locations to determine if the table definition is the cause.