"Chapter Break" topics are always on a new page

This forum is for all Flare issues related to PDF, eBook, Microsoft Word, Adobe FrameMaker, XPS, and XHTML book targets.
Post Reply
Tony
Propeller Head
Posts: 26
Joined: Fri Mar 22, 2013 6:02 am
Location: Jerusalem

"Chapter Break" topics are always on a new page

Post by Tony »

Hi,

After successfully creating single sourced PDF and HTML5 projects using auto-numbers I have moved on to other projects that (currently) only require PDF output.
And now I have discovered that selecting the "Chapter Break" setting in the TOC for a topic (on the Printed Output tab) causes the topic to always start on a new page.
It does not matter what I define in the CSS, the topic is always staring on a new PDF page. This was OK in my other projects because I actually wanted this behaivor.
But now I have a project where the numbered topics should always continue on the same page, unless I specifically define that it should start on a new page (and then I will use the "Page Layout Break" option). Is there any way to override this? If not, how can you use Auto-numbering without using the Chapter Break setting? I agree that on most occassions you probably would want to start a new "chapter" on a new page - but not always, as you can see from my example below (created using FrameMaker). Apart from the topic stating on a new page, everything else is just how I want it to be.
More info: All my topics are defined as <H1> and I prefer not to change that.

Thanks,
Tony

For example, this is what I need, both topic 1 and topic 2 on the same page -pity to waste almost a whole page :-):
ChapterBreakExample.png
You do not have the required permissions to view the files attached to this post.
KCinColorado
Propeller Head
Posts: 40
Joined: Tue Mar 20, 2012 11:00 am

Re: "Chapter Break" topics are always on a new page

Post by KCinColorado »

Hi Tony,

Did you ever resolve this issue (of chapters starting a new page in PDF output)? I am running into the same issue and logged a support call this morning with MadCap. So far, they have no answer or workaround but the call is still open. I'm hopeful...

Thanks.
KC
Lydia
Sr. Propeller Head
Posts: 373
Joined: Tue Apr 23, 2013 3:19 am
Location: The Netherlands, Amsterdam Area

Re: "Chapter Break" topics are always on a new page

Post by Lydia »

Hello Tony,
do you use the {chapnum} command for the autonumbering? If so, would it be an option to use numbering by the {n} command? Then you won't need to rely on chapter breaks for incrementing the number.

regards, Lydia.
Using Flare 10.2 and Flare 11 on Win 7
KCinColorado
Propeller Head
Posts: 40
Joined: Tue Mar 20, 2012 11:00 am

Re: "Chapter Break" topics are always on a new page

Post by KCinColorado »

Hi Lydia,

Could you elaborate? MadCap support suggested removing the "GH:{chapnum}" that they told me to put in earlier (for H1's) with just " {n+}," and then using {n}.{n+} and {n}.{n}.{n+} for subheads. And removing the Chapter Breaks. I tried that and ended up with five chapter 1's. The H1's did not increment.

Thanks for any help. I have 5 "chapters" -- all very short. Would like Chap 1 to start o a new, right-hand page after the TOC and reset numbering from roman numerals to 1. But Chaps 2-5 should not start new pages.

kc
Lydia
Sr. Propeller Head
Posts: 373
Joined: Tue Apr 23, 2013 3:19 am
Location: The Netherlands, Amsterdam Area

Re: "Chapter Break" topics are always on a new page

Post by Lydia »

Hi kc,
you describe exactly what I had in mind (and what works for me).
Is the {n+} preceded by the GH: still? It needs to be a global (G) series counter.
At the moment I can't think of why this fails, else.

regards, Lydia.
Using Flare 10.2 and Flare 11 on Win 7
KCinColorado
Propeller Head
Posts: 40
Joined: Tue Mar 20, 2012 11:00 am

Re: "Chapter Break" topics are always on a new page

Post by KCinColorado »

THANK you so much, Lydia. I had removed the GH: from the H1. (Per MC support, I only had that in one place; all my other auto-numbering heads started with {chapnum}, which I removed while trying to get chapters to stop starting on new pages...).

So for future reference, to force new auto-numbered chapters to not start on a new page, define the autonumber head classes like this:

h1.chapterNoBreak
page-break-before: avoid
mc-auto-number-format: GH:{n}.{n}.{n+}

h2.sectionNumbered
mc-auto-number-format: GH:{n}.{n+}

h3.sectionNumbered
mc-auto-number-format: GH:{n}.{n}.{n+}

Then go into TOC, modify the properties of each chapter, and set Break Type to None. In my case, because I was using Roman Numerals for the TOC pages and wanted my Chapter 1 to start on a new, right page, and reset numbering to 1 (decimal), I left the Chapter Break selected for that chapter so Flare would honor the Page Number reset, which is otherwise dimmed when break type "None" is used.

Whew! Thanks for your help.

kc
Tony
Propeller Head
Posts: 26
Joined: Fri Mar 22, 2013 6:02 am
Location: Jerusalem

Re: "Chapter Break" topics are always on a new page

Post by Tony »

Thank You Lydia and KC,

I finally got it to work more or less how I want it to.
KC, you have a typo in your example
KCinColorado wrote:h1.chapterNoBreak
page-break-before: avoid
mc-auto-number-format: GH:{n}.{n}.{n+}
The mc-auto-number-format should be just {n+}.

Also, your example shows that you are using different Heading styles/levels in your topics.
For real single-sourcing power, I use only <H1> styles in my topics. This is what I do, using the CSS example below:
1. Use <H1> for all my topics.
2. In the TOC of each project, in the Advanced tab, set "Use TOC depth for heading levels".
3. Arrange the topics in my TOC exactly as I want them to appear in the PDF.
4. For any topics that I do want to appear on a new page, in the TOC I set the Break Type to "Page Layout Break" (in the Printed Output tab).

In this way I can re-use topics in multiple PDFs, and control the page breaks in each PDF target independently.

I have to say that the whole issue of auto-numbering and PDF output is very confusing and many settings seem to contradict or work against each other. It should not take days of investigation to do such a simple task.
As it is now, I will have to maintain 2 different sets of CSS files because in some outputs I need to use the "CH:{chapnum}" style, but in others I need the style described below. IMHO Madcap need to do a better job with this, and also improve the documentation with real-life examples.

Regards,

Tony

CSS Example:
h1,
h2,
h3
{
color: #0860A8;
font-family: "Trebuchet MS", Helvetica, sans-serif;
font-weight: bold;
margin-top: 20pt;
margin-bottom: 20pt;
margin-left: 0pt;
page-break-before: avoid;
mc-auto-number-offset: 0;
mc-auto-number-position: float-left;
}

h1
{
font-size: 20pt;
mc-heading-level: 1;
mc-auto-number-format: 'GH:{n+} ';
}

h2
{
font-size: 18pt;
mc-heading-level: 2;
mc-auto-number-format: 'GH:{n}.{n+} ';
}

h3
{
font-size: 16pt;
mc-heading-level: 3;
mc-auto-number-format: 'GH:{n}.{n}.{n+} ';
}
Lydia
Sr. Propeller Head
Posts: 373
Joined: Tue Apr 23, 2013 3:19 am
Location: The Netherlands, Amsterdam Area

Re: "Chapter Break" topics are always on a new page

Post by Lydia »

You're most welcome, glad to help out here.

@Tony - instead of using two CSS files - would it work to use one CSS with a different medium for the second set of definitions for autonumbers?

Kind Regards, Lydia.
Using Flare 10.2 and Flare 11 on Win 7
KCinColorado
Propeller Head
Posts: 40
Joined: Tue Mar 20, 2012 11:00 am

Re: "Chapter Break" topics are always on a new page

Post by KCinColorado »

Thanks so much for all the information, Tony -- and the typo alert. (I am using just {n+} as you stated; that was a cut/paste error on my part.)

Have to think about the approach you described. I have files in this particular project that include H1 - H3 headings within the same file. This is just a "book" that is generated in PDF output only, and was imported from Word. And the style sheet is used by two other projects that generate HTML5 Help and PDF (unnumbered).

You are so right about this whole auto-numbering thing being WAY too complex!

kc
edwardanthony777
Jr. Propeller Head
Posts: 3
Joined: Mon May 11, 2015 1:34 pm

Re: "Chapter Break" topics are always on a new page

Post by edwardanthony777 »

Is anyone aware of a simpler solution to this problem, particularly now that there are newer releases of Flare since these posts of 2012?

I'm finding this solution a bit awkward as our company is using an unconventional Chapter.Page numbering system and was hoping that I could suppress the page breaks on a new Chapter using the stylesheet (ie: page-break-before: avoid).

Any other options/solutions out there for this?
Lydia
Sr. Propeller Head
Posts: 373
Joined: Tue Apr 23, 2013 3:19 am
Location: The Netherlands, Amsterdam Area

Re: "Chapter Break" topics are always on a new page

Post by Lydia »

Hi, if you have a chapter.page numbering system, I'm not sure what you expect to happen.
When there are two chapter headings (say chapter 1 and chapter 2) on the same page,because you suppress the page break, what do you expect the page number to be? Should it be 1-pagenr or 2-pagenr?
I'm having difficulties understanding the numbering system and why the solution is hard to implement.
Can you tell a bit more?

Regards, Lydia.
Using Flare 10.2 and Flare 11 on Win 7
Post Reply