Commit a872a426 authored by Benoit Rat's avatar Benoit Rat

doc: fixing title/subtitle

We did try to use the YAML metadata block but for a strange reason it
does not work with starting-kit.md so we have decided to create a
specific Makefile rule for this purpose
parent 4364d91e
......@@ -23,8 +23,8 @@ PDF=$(addprefix pdf/, $(SRC:.md=.pdf))
TEX=$(SRC:.md=.tex)
## Pandoc arguments
OPTIONS=-f markdown --toc --number-sections --smart
TEMPLATE=pandoc.latex
OPTIONS=-s --from markdown+yaml_metadata_block --toc --number-sections --smart
TEMPLATE=pandoc.latex
ifneq "$(TEMPLATE)" ""
......@@ -47,6 +47,11 @@ pdf: $(PDF)
DIR_%:
mkdir -p $(subst DIR_,,$@)
pdf/wr-starting-kit.pdf: wr-starting-kit.md Makefile $(TEMPLATE) DIR_pdf
pandoc $(OPTIONS) --latex-engine=xelatex --listings --highlight-style=haddock $(TEMPLATEARG) \
-V title="WR Starting Kit" -V subtitle="User Guide" -V author="Seven Solutions" \
-V lang=english -V fontsize=11pt -V documentclass=article -V bg-color=238,245,240 -V date="$(DATE) - $(VERSION)" -o $@ $<
pdf/%.pdf: %.md Makefile $(TEMPLATE) DIR_pdf
pandoc $(OPTIONS) --latex-engine=xelatex --listings --highlight-style=haddock $(TEMPLATEARG) \
-V lang=english -V fontsize=11pt -V documentclass=article -V bg-color=238,245,240 -V date="$(DATE) - $(VERSION)" -o $@ $<
......
---
title: 'Generate WR Starting Kit Documentation'
subtitle: "How to generate starting kit pdf from markdown using pandoc"
author: Seven Solutions
...
Intro
==========
......
......@@ -351,7 +351,7 @@ $endif$
%% Footer
\renewcommand{\footrulewidth}{1pt}
\fancyfoot[L]{{\scriptsize \bfseries $title$ - $title-prefix$} \\ \raisebox{5pt}{\tiny $date$}}
\fancyfoot[L]{{\scriptsize \bfseries $title$ - $subtitle$} \\ \raisebox{5pt}{\tiny $date$}}
\fancyfoot[C]{\raisebox{0pt}{\small \weburl }}
\fancyfoot[R]{\raisebox{0pt}{\scriptsize \thepage}}
......@@ -405,31 +405,26 @@ $endif$
\makeatletter
\def\thickhrulefill{\leavevmode \leaders \hrule height 1pt\hfill \kern \z@}
\renewcommand{\maketitle}{\begin{titlepage}%
$if(imgcover)$
\ThisLRCornerWallPaper{1}{$imgcover$}
$endif$
\vspace{5mm}
\begin{minipage}{\textwidth}
\vspace{4.5cm}
\begin{flushright}
\fontsize{10pt}{8pt}\selectfont
{\@date}
\end{flushright}
\end{minipage}
\begin{minipage}{\textwidth}
\vspace{5.8cm}
\noindent
\begin{center}
\textsc{\textbf{\@title}}
\end{center}
\vspace{7cm}
\begin{flushleft}
{\Large \textbf{\@author}}\\
\vspace{2cm}
{\large \OldTexttt{Seven Solutions S.L}}\\
{\url{www.sevensols.com}}
\end{flushleft}
\end{minipage}
\let\footnotesize\small
\let\footnoterule\relax
\parindent \z@
\reset@font
\null\vfil
\begin{flushleft}
\Huge \textbf{\@title}
\end{flushleft}
\par
\hrule height 4pt
\par
\begin{flushright}
\large \@date \par
\end{flushright}
\vskip 500\p@
\vfil\null
\begin{flushleft}
\Large \textbf{\@author}
\end{flushleft}
\hrule height 2pt
\end{titlepage}%
\setcounter{footnote}{0}%
}
......
% WR SPEC Starting Kit
% Benoit RAT, Javier Diaz (Seven Solutions) & Miguel Jimenez (UGR)
### Copyright
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment