Comments (7)
Just a quick note for everyone having the same problem. You can insert two commands into the template with header-includes
to create a pagebreak for every top level heading (see also #81):
---
title: "Example PDF"
author: [Author]
date: "2017-02-20"
subject: "Markdown"
keywords: [Markdown, Example]
lang: "en"
header-includes: |
\usepackage{sectsty}
\sectionfont{\clearpage}
...
# Vinaque sanguine metuenti cuiquam Alcyone fixus
Lorem markdownum Letoia, et alios: figurae flectentem annis aliquid Peneosque ab
esse, obstat gravitate. Obscura atque coniuge, per de coniunx, sibi **medias
commentaque virgine** anima tamen comitemque petis, sed. In Amphion vestros
hamos ire arceor mandere spicula, in licet aliquando.
# Aesculeae domus vincemur et Veneris adsuetus lapsum
Lorem markdownum Letoia, et alios: figurae flectentem annis aliquid Peneosque ab
esse, obstat gravitate. Obscura atque coniuge, per de coniunx, sibi **medias
commentaque virgine** anima tamen comitemque petis, sed. In Amphion vestros
hamos ire arceor mandere spicula, in licet aliquando.
from pandoc-latex-template.
I'm glad you like it! This really means a lot to me.
First of all I used the KOMA-Script class scrartcl
as the document class because it has some advantages over the default article
class. For typesetting a book I recommend the corresponding KOMA-Script class scrbook
instead of the default book
. All the examples should work with the KOMA-Script class.
To get the correct chapter headings (and page breaks before them) you need to tell pandoc that it should convert first level headings #
to chapters with the command --top-level-division=chapter
(-> Manual).
There will be one blank page before each chapter because the template is two-sided per default (I think I should change that). So if you plan to publish your book as a PDF and don't need a blank page you should add the class option onesided
which can be done by supplying a template variable -V classoption=oneside
(-> Manual).
Unfortunately I never really tested chapters with my template so there are some strange chapter headings. I filed a new Issue (#16) and try to figure out what's wrong.
from pandoc-latex-template.
Yeah, I think that would do the trick. But \newpage
instead of \newline
:)
from pandoc-latex-template.
I too struggled with this a while back and couldnt get it to work. Ended up with entering \newpage
at the top of each markdown file (ie top level heading).
from pandoc-latex-template.
Thanks a stack for the feedback. I'll give it a go.
from pandoc-latex-template.
@martinlarsson: my brain only really registered your message now :)
My entire document is in one markdown file. Would one add that \newline
before each # Heading
then?
from pandoc-latex-template.
lol: goodness... thanks!
from pandoc-latex-template.
Related Issues (20)
- pandoc fails to use eisvogel template HOT 2
- disable headers and footers
- indent first line of footnotes HOT 1
- \usepackage{ragged2e} has no effect
- Changing Color and Size of text in YAML Metadata block
- Issue with pandoc/latex docker image and missing texlive packages HOT 2
- Is it possible to split markdown files into several files and then compile with pandoc? HOT 2
- Cannot use `code-block-font-size` from the command line HOT 1
- Undefined control sequence when used with citeproc HOT 5
- toc-own-page: true - not working HOT 2
- imgage resize HOT 3
- Fatal problem with citeproc in Pandoc 3.1.8. and Eisvogel 2.4.1: "... missing \item." HOT 7
- There is no line break between the H4-level heading and the body text HOT 3
- Captions not working in default configuration with Docker image ?
- JavaScript highlighting (fenced code blocks)
- Hyphens not appearing in generated PDF HOT 1
- Dynamic images in the table
- Chapter color
- Can I set paper size, borders individually, 1..2 pages, etc
- Syntax highlight
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from pandoc-latex-template.