How to disable header on frontpage of rst2pdf document?

1.6k Views Asked by At

I am generating some PDF's and I would like to disable the header on the frontpage. I know there are built-in templates in rst2pdf and one template is called coverPage but I don't seem to be able to get it to work.

The manual is saying you should use a

..raw:: pdf  
  PageBreak coverPage

statement but that will insert a empty before the coverpage, so how can I have a coverpage without a header and without using the oddeven directive (I want to use the same header on all remaining pages).

Thanks for your suggestions!

2

There are 2 best solutions below

1
On BEST ANSWER

That's how you change the stylesheet after the cover page. You'll need to create a custom stylesheet that specifies what is the format of the first page and then change the style for the rest of document. Have a look at chapter 15 of the manual.

0
On

Note: current accepted answer contains broken link (linked website has gone).

The correct answer is simple:

1) In you style-file define:

pageSetup:
  firstTemplate: coverPage

2) Then in your template, when you want to start using header/footer add:

..raw:: pdf
  PageBreak cutePage

Make sure cutePage has set header/footer to true.