RistmarkStart free

Guide

Sections

A section is a page-setup unit — its own size, margins, and header/footer. A document can be one section split across many physical pages, or several sections with completely different page setups.

What it is

The Section tab shows "Section N / M" at the top, with buttons to add a section, delete one, and move one earlier or later. Each section keeps its own size, margins, and header/footer — switching which section you're on is how later pages come out looking different from earlier ones.

Key options

  • Add a new section right after the one you're viewing
  • Delete a section, once more than one exists
  • Move a section earlier or later
  • Each section keeps its own size, margins, and header/footer

How editing works

Open the Section tab and look at the "Section N / M" row at the top. Click a thumbnail in the page rail — each is labelled with its physical page number and section. Or open the Outline tab in the left panel, which lists every section by name: clicking one scrolls to its first page (see The outline). Use the + to add a section, or the delete button to remove one again.

Showing or hiding a section

A section can be set to only appear when your data says so — useful for an optional page (a terms appendix, a second-language copy) most documents don't need. In the Section tab's Visibility area, turn on "Only show when…" and build the rule: pick a field, pick a comparison (is empty, is not empty, equals, does not equal, greater than, less than, at least, at most), and — for anything but the two "empty" checks — a value. The line under the controls always says one of five things against your current sample data: shown, hidden, the field wasn't found, the comparison doesn't fit that value's type, or the condition has a typo — never just "broken".

A condition written before this builder existed, or anything the builder can't express (a combined AND/OR, a function call), opens in an Advanced text box instead — switching to Advanced never changes what's saved, and switching back to the builder is refused, with the reason shown, for anything the builder can't represent exactly. One Undo change click restores the condition to what it was when you opened this section, however many builder edits you made in between.

A hidden section, or one whose condition is broken, doesn't print — a broken condition fails safe, the same as a legitimate "false".

A hidden section has no pages on the canvas and no thumbnail, so the Outline tab is where you find it again: it stays listed there, marked "Hidden: its condition is false" (or "condition error"), and everything inside it says it is hidden because of that section. Clicking it makes it the section the Section tab shows, where its condition is. With Show hidden content on the canvas on (at the top of the outline), the canvas also shows a band where its pages would be — "Section 'Terms' is hidden — its pages are not in the output" — and clicking the band does the same.

When to use more than one section

Use a new section whenever part of the document needs a different page setup or different header and footer:

  • a landscape page for a wide table inside a portrait document;
  • a cover page with no footer, followed by pages that have one;
  • a different letterhead for the second half (a Base-PDF letterhead belongs to a section);
  • an optional page, hidden by a rule (a terms appendix, a second-language copy).

If it only needs a new page, use a Page break instead; that does not need a section.

A worked example: a portrait letter with a landscape annex

  1. Build the letter in the first section.
  2. In the Section tab, press the + to add a section after it. The new section starts with the default A4 portrait page.
  3. In the new section, set Orientation to Landscape and put the wide table in its body.
  4. Give the annex its own header ("Annex — price list") by switching Header on in that section only. The first section is untouched.
  5. To number the annex separately, use {{ $page.sectionNumber }} and {{ $page.sectionCount }} in its page-number block (see Page number); {{ $page.number }} counts across the whole document.

What belongs to the section, and what does not

Size, orientation, margins, newspaper columns, Base-PDF letterhead, header, footer and visibility belong to the section. The blocks of the body belong to the section's body and flow from its first page to its last. The Grid and the sample data belong to the whole template.

If something looks wrong

  • The footer I set up is missing from the second half. Footers are per section; switch Footer on in that section as well.
  • A section's pages are missing from the output. Its visibility rule is false for the data you are generating with, or the rule is broken (a broken rule hides the section rather than printing something wrong). The Outline tab lists the section as hidden and why.
  • Page numbers restart or jump. They are counted across the whole document, not by section, unless you use the sectionNumber form in the page-number block.
  • My document has no pages. Every section is hidden by its rule. The API answers 422 in that case.