Paragraph Style: Heading. Master Doc Inserting Unwanted Page Break Between Title on Two Lines

Hello (world - 1st post. Many more to come I feel:)

I'm formatting a master document.

My chapter headings are like this:
"CHAPTER 1
Blah Blah Blah

textbody_textbody_etc_etc"

When I update the master doc LO inserts a page break between the 2 headings
on separate lines, so:
"CHAPTER 1"
.....page break....
"Blah Blah Blah

textbody_textbody_etc_etc"

If I manually delete the page break, when I update the master doc it gets
re-inserted.

So, dear community - how do I fix this please?

Cheers,

Brooks

Definition of styles on the master have precedence over styles of the same name defined on sub-documents. Check the definition of your heading style on the master → Text flow tab to see if there is any automated page break set there. If that do not solve the problem, please try to create a minimum example (the master and one sub-document with just a bit of dummy text) and upload it anywhere so we can see what's going on.

Regards,
Ricardo

Hi Ricardo,

Many thanks for the prompt response...

I guess part of the problem is that I do want to have an automatic page
break before each chapter, so yes, page break is on in the text flow tab in
the master document.

As a quick workaround I can just insert whitespace, so the chapter title is
on one line but appears to be below it on the page - it looks wrong though
(like the hack it is:).

Hmm

Assuming you are working with styles and that you defined your heading as starting on a new page, you probably want the same style-sheet for the sub-documents and the master.

That is hard to achieve in LO out off the box. But you may want to use Template Changer for that, extension: http://bugs.documentfoundation.org/attachment.cgi?id=103039

Having exactly the same templates for the master and the sub-documents makes life much easier :wink:

Hi Ricardo,

Many thanks for the prompt response...

I guess part of the problem is that I do want to have an automatic page
break before each chapter, so yes, page break is on in the text flow tab in
the master document.

As a quick workaround I can just insert whitespace, so the chapter title is
on one line but appears to be below it on the page - it looks wrong though
(like the hack it is:).

Thus, I do not understand your problem :wink:

On your first message it seemed that you had an unwanted page break, but on the second you said that there must be a page break but somehow that page break is "wrong" on the master and that you are "fixing" it by inserting some space... on the subdocuments or in the master?

So, can you please provide a sample file that shows the problem? AFAIK, this list do not accept attachments so you need to upload it somewhere else.

Regards,
Ricardo

Just a short query, are you really sure you need the added complexity of
a master document plus chapter documents?

I started out on this basis for a book because it seemed a nice and
logical thing to do. But then found that it was not necessary.

LO Writer can handle easily a technical document with some 15 chapters,
70 diagrams, Table of Contents with 3 or 4 levels, alphabetical index
etc with no difficulty.

Of course your requirements may well be different.

Philip

Hi Wiebe,

Many thanks for Template Changer - I hadn't come across that before, will
investigate further.

Apologies to all that I am not clearly explaining myself.

This is not an issue with transferring from from sub-doc to master, it's
the same on both if I mirror the sub-doc settings to the master.

1. I do want to have an auto page break for each chapter.

The chapter headings are laid out so that there are two lines of heading:

CHAPTER N
This Is What Happens in Chapter N

textbodytextbodyetcetc

So somewhat logically LO inserts a page break thus:

"...pagebreak...
CHAPTER N
...pagebreak...
This Is What Happens in Chapter N

textbodytextbodyetcetc."

What I was looking for was a([n] easy) method to tell LO to not insert page
break between headings when they're next to each other.

Thinking aloud I guess the solution may be to setup another heading with
identical settings except page break off - presumably that'd do it right?

HI Philip,

I've been exploring using master-doc as my 200 page thesis was becoming
unmanageable as a single (writer) doc. I've found navigation across the doc
much easier since breaking it up into 60 or so separate docs, things like
the ToC is great, and it's nice to know the layout is consistent of the
whole doc, particularly as I've writing the bugger for about 6 years now!
Of course some of this may well be more growing familiarity with the
program. A big recent change has been in the update via the Debian repo's,
5.2.1.2 is much more stable. The devs seem to also have solved some of the
issues that were causing the gui to be painfully slow - particularly with
opening drop-down menus.

Ricardo,

Appreciate you weighing in again. Conceptually I think I've solved the
issue but if not I'll upload an example somewhere/somehow:)

Cheers guys, positive community experience so far,

Julian

Hi Wiebe,

Many thanks for Template Changer - I hadn't come across that before, will
investigate further.

Apologies to all that I am not clearly explaining myself.

This is not an issue with transferring from from sub-doc to master, it's
the same on both if I mirror the sub-doc settings to the master.

1. I do want to have an auto page break for each chapter.

The chapter headings are laid out so that there are two lines of heading:

CHAPTER N
This Is What Happens in Chapter N

textbodytextbodyetcetc

So somewhat logically LO inserts a page break thus:

"...pagebreak...
CHAPTER N
...pagebreak...
This Is What Happens in Chapter N

textbodytextbodyetcetc."

Ok, I think I understand now :wink:

Just don't use two paragraph for chapter number and chapter name: between the number and the name of the chapter insert a Shift-Enter to break the line. This way both lines will be considered by Writer as a single paragraph and you'll get only one page break. And don't worry: Writer's TOC will ignore the line break so everything will be OK. NOTE: I'm using this method on my own book in order to get a two line heading.

Regards,
Ricardo

Ricardo!

yes Yes YES

Perfect, thank you:)

But you may want to use

Template Changer for that, extension:
http://bugs.documentfoundation.org/attachment.cgi?id=103039

Although I have the TemplateChanger extension, it is worth noting that
in LibreOffice Writer 5.1.4.2 (as delivered and updated with
UbuntuStudio 16.04.1) the Help information is not presently correct.

F1 Help says that :

"TemplateChanger
You can assign a document template to one or more text documents by
using the TemplateChanger extension. All styles (paragraph, character,
frame, page, and list styles) will be loaded from the template,
replacing the current styles of the document.
The document will be linked to the template file. From now on the
document will behave as it was created using the template file.

To access this command...
Choose File - Send - Assing template (current document) (LibreOffice
Writer only)
Choose File - Send - Assing template (folder)"

In fact in LO 5.1.4.2, what I find is :

1. to access the functionality, it is under :

File > Templates > Assign template (current document)...
File > Templates > Assign template (folder)...

2. 'All styles ...' do NOT replace current styles of the current
document. It is true that additional styles in the new template which
were not in the original template are now listed in Styles and
Formatting > all styles but not shown under 'applied styles'.

How would Writer know which new style was equivalent to which old style?

3. the info under File > Properties continues to show the original
template name.

Philip

But you may want to use

Template Changer for that, extension:
http://bugs.documentfoundation.org/attachment.cgi?id=103039

Although I have the TemplateChanger extension, it is worth noting that
in LibreOffice Writer 5.1.4.2 (as delivered and updated with
UbuntuStudio 16.04.1) the Help information is not presently correct.

...

In fact in LO 5.1.4.2, what I find is :

...

2. 'All styles ...' do NOT replace current styles of the current
document. It is true that additional styles in the new template which
were not in the original template are now listed in Styles and
Formatting > all styles but not shown under 'applied styles'.

How would Writer know which new style was equivalent to which old style?

3. the info under File > Properties continues to show the original
template name.

Interesting, at my system:

2: All styles are replaced and

3: File > Properties shows the right template.

LO: Version: 5.2.1.2 Build ID: 1:5.2.1~rc2-0ubuntu1~xenial0, but as far as I know it worked fine too in LO 5.1.

Philip, are you using the TemplateChanger from the link mentioned at the top? The file is template-changer-1.2.7c.oxt, so version 1.2.7c.

Interesting, at my system:

2: All styles are replaced and

I should have been more precise. Styles are replaced where they have the
same name. New styles which did not exist before are included in 'all
styles' but not in 'applied styles'.

This does not surprise me because there is no way Writer could know how
or where they should be applied. That's my job.

3: File > Properties shows the right template.

Sometimes this happens, sometimes not. I've tried a few tests and can't
say what it depends on.

LO: Version: 5.2.1.2 Build ID: 1:5.2.1~rc2-0ubuntu1~xenial0, but as far
as I know it worked fine too in LO 5.1.

I think you must be using a later version from a ppa other than the main
Ubuntu repository - or else UbuntuStudio 16.04 differs from Ubuntu 16.04
in the LO selection.

Philip, are you using the TemplateChanger from the link mentioned at the
top? The file is template-changer-1.2.7c.oxt, so version 1.2.7c.

I just rechecked in Tools > extension manager and my template changer
says 1.2.7 although my download is 'template-changer-1.2.7c.oxt'
Just to be on the safe side, I removed and reinstalled the extension -
it still says 1.2.7 so I guess that's what 1.2.7c says.

My current concern is to pass a template I've developed to someone else.
I think the only safe way to do so, is to have place holder text (lorem
ipsum) in the template with an example of each style applied.

Philip

Greetings,

Where are you getting this Template Changer 1.2.7x?

When I go to the LO home page and then the extensions page, all I see is still the 1.2.6 version for LO 3.3 dated 2013 and a warning that it has not been updated for over a year! As far as I know, this 1.2.6 extension is not compatible with LO 4.x or 5.x.

Girvin Herr

I quote from an email by Wiebe van der Worp of 7 April 2016 :

"... you need to use this link for a working Template Changer:
http://bugs.documentfoundation.org/attachment.cgi?id=103039"

That is where I got my version 1.2.7 from

HTH
Philip

Wiebe & Philip,

Thanks for the response. I downloaded both the 1.2.7b and 1.2.7c versions. I will make a Slackware package of it to install on my system with LO 5.0.6.3 and try it out.

I normally use the load styles option, but now and then, when I open a document, I get a popup saying the template has changed and it allows me to cancel or update the document template. If I chose cancel, it sets a bit in the document to never allow this popup again for this document. The Template Changer was the only option to restore this popup option. I made the mistake years ago, thinking "Cancel" was the safe option and not knowing the consequences, to choose Cancel for some documents. I no longer know which ones, since I didn't keep records of what I had opted for each document. And so, I could still run into documents that have no way to restore this update feature or update the template without the Template Changer.

This is a strange and unintuitive place to find a working extension. Any plans to put it in the usual place for extensions under the LO home page to make it easier for users to find?

Thanks again.
Girvin Herr

I normally use the load styles option, but now and then, when I open a
document, I get a popup saying the template has changed and it allows me
to cancel or update the document template. If I chose cancel, it sets a
bit in the document to never allow this popup again for this document.
The Template Changer was the only option to restore this popup option.
I made the mistake years ago, thinking "Cancel" was the safe option and
not knowing the consequences, to choose Cancel for some documents. I no
longer know which ones, since I didn't keep records of what I had opted
for each document. And so, I could still run into documents that have
no way to restore this update feature or update the template without the
Template Changer.

Insightful! Learning every day.

This is a strange and unintuitive place to find a working extension.
Any plans to put it in the usual place for extensions under the LO home
page to make it easier for users to find?

You're right about this. Yesterday I added this here https://bugs.documentfoundation.org/show_bug.cgi?id=60592: