diff options
author | Sean Whitton <spwhitton@spwhitton.name> | 2018-04-24 10:48:39 -0700 |
---|---|---|
committer | Sean Whitton <spwhitton@spwhitton.name> | 2018-04-24 10:48:39 -0700 |
commit | de5ee82ed0e287ada3a5b272d8365a04fe8e9f95 (patch) | |
tree | 126c941f08f4d1e2775a694d4fd7f7c859b4b81b /data/templates | |
parent | abcbe3005117f90babc225ce958766845cf59d2b (diff) | |
parent | 5e6879dbf98eb5528c7f417b349118aadca40d71 (diff) |
New upstream version 2.1.2~dfsg
Diffstat (limited to 'data/templates')
23 files changed, 817 insertions, 395 deletions
diff --git a/data/templates/default.beamer b/data/templates/default.beamer deleted file mode 100644 index 680a4121d..000000000 --- a/data/templates/default.beamer +++ /dev/null @@ -1,278 +0,0 @@ -\documentclass[$if(fontsize)$$fontsize$,$endif$$if(lang)$$babel-lang$,$endif$$if(handout)$handout,$endif$$if(beamer)$ignorenonframetext,$endif$$for(classoption)$$classoption$$sep$,$endfor$]{$documentclass$} -\setbeamertemplate{caption}[numbered] -\setbeamertemplate{caption label separator}{: } -\setbeamercolor{caption name}{fg=normal text.fg} -\beamertemplatenavigationsymbols$if(navigation)$$navigation$$else$empty$endif$ -$if(fontfamily)$ -\usepackage[$for(fontfamilyoptions)$$fontfamilyoptions$$sep$,$endfor$]{$fontfamily$} -$else$ -\usepackage{lmodern} -$endif$ -\usepackage{amssymb,amsmath} -\usepackage{ifxetex,ifluatex} -\usepackage{fixltx2e} % provides \textsubscript -\ifnum 0\ifxetex 1\fi\ifluatex 1\fi=0 % if pdftex - \usepackage[$if(fontenc)$$fontenc$$else$T1$endif$]{fontenc} - \usepackage[utf8]{inputenc} -$if(euro)$ - \usepackage{eurosym} -$endif$ -\else % if luatex or xelatex - \ifxetex - \usepackage{mathspec} - \else - \usepackage{fontspec} - \fi - \defaultfontfeatures{Ligatures=TeX,Scale=MatchLowercase} -$for(fontfamilies)$ - \newfontfamily{$fontfamilies.name$}[$fontfamilies.options$]{$fontfamilies.font$} -$endfor$ -$if(euro)$ - \newcommand{\euro}{€} -$endif$ -$if(mainfont)$ - \setmainfont[$for(mainfontoptions)$$mainfontoptions$$sep$,$endfor$]{$mainfont$} -$endif$ -$if(sansfont)$ - \setsansfont[$for(sansfontoptions)$$sansfontoptions$$sep$,$endfor$]{$sansfont$} -$endif$ -$if(monofont)$ - \setmonofont[Mapping=tex-ansi$if(monofontoptions)$,$for(monofontoptions)$$monofontoptions$$sep$,$endfor$$endif$]{$monofont$} -$endif$ -$if(mathfont)$ - \setmathfont(Digits,Latin,Greek)[$for(mathfontoptions)$$mathfontoptions$$sep$,$endfor$]{$mathfont$} -$endif$ -$if(CJKmainfont)$ - \usepackage{xeCJK} - \setCJKmainfont[$for(CJKoptions)$$CJKoptions$$sep$,$endfor$]{$CJKmainfont$} -$endif$ -\fi -$if(theme)$ -\usetheme[$for(themeoptions)$$themeoptions$$sep$,$endfor$]{$theme$} -$endif$ -$if(colortheme)$ -\usecolortheme{$colortheme$} -$endif$ -$if(fonttheme)$ -\usefonttheme{$fonttheme$} -$endif$ -$if(mainfont)$ -\usefonttheme{serif} % use mainfont rather than sansfont for slide text -$endif$ -$if(innertheme)$ -\useinnertheme{$innertheme$} -$endif$ -$if(outertheme)$ -\useoutertheme{$outertheme$} -$endif$ -% use upquote if available, for straight quotes in verbatim environments -\IfFileExists{upquote.sty}{\usepackage{upquote}}{} -% use microtype if available -\IfFileExists{microtype.sty}{% -\usepackage{microtype} -\UseMicrotypeSet[protrusion]{basicmath} % disable protrusion for tt fonts -}{} -$if(lang)$ -\ifnum 0\ifxetex 1\fi\ifluatex 1\fi=0 % if pdftex - \usepackage[shorthands=off,$for(babel-otherlangs)$$babel-otherlangs$,$endfor$main=$babel-lang$]{babel} -$if(babel-newcommands)$ - $babel-newcommands$ -$endif$ -\else - \usepackage{polyglossia} - \setmainlanguage[$polyglossia-lang.options$]{$polyglossia-lang.name$} -$for(polyglossia-otherlangs)$ - \setotherlanguage[$polyglossia-otherlangs.options$]{$polyglossia-otherlangs.name$} -$endfor$ -\fi -$endif$ -\newif\ifbibliography -$if(natbib)$ -\usepackage{natbib} -\bibliographystyle{$if(biblio-style)$$biblio-style$$else$plainnat$endif$} -$endif$ -$if(biblatex)$ -\usepackage[$if(biblio-style)$style=$biblio-style$,$endif$$for(biblatexoptions)$$biblatexoptions$$sep$,$endfor$]{biblatex} -$for(bibliography)$ -\addbibresource{$bibliography$} -$endfor$ -$endif$ -$if(verbatim-in-note)$ -\usepackage{fancyvrb} -$endif$ -\hypersetup{ -$if(title-meta)$ - pdftitle={$title-meta$}, -$endif$ -$if(author-meta)$ - pdfauthor={$author-meta$}, -$endif$ -$if(keywords)$ - pdfkeywords={$for(keywords)$$keywords$$sep$, $endfor$}, -$endif$ -$if(colorlinks)$ - colorlinks=true, - linkcolor=$if(linkcolor)$$linkcolor$$else$Maroon$endif$, - citecolor=$if(citecolor)$$citecolor$$else$Blue$endif$, - urlcolor=$if(urlcolor)$$urlcolor$$else$Blue$endif$, -$else$ - pdfborder={0 0 0}, -$endif$ - breaklinks=true} -\urlstyle{same} % don't use monospace font for urls -$if(verbatim-in-note)$ -\VerbatimFootnotes % allows verbatim text in footnotes -$endif$ -$if(listings)$ -\usepackage{listings} -$endif$ -$if(lhs)$ -\lstnewenvironment{code}{\lstset{language=Haskell,basicstyle=\small\ttfamily}}{} -$endif$ -$if(highlighting-macros)$ -$highlighting-macros$ -$endif$ -$if(tables)$ -\usepackage{longtable,booktabs} -\usepackage{caption} -% These lines are needed to make table captions work with longtable: -\makeatletter -\def\fnum@table{\tablename~\thetable} -\makeatother -$endif$ -$if(graphics)$ -\usepackage{graphicx,grffile} -\makeatletter -\def\maxwidth{\ifdim\Gin@nat@width>\linewidth\linewidth\else\Gin@nat@width\fi} -\def\maxheight{\ifdim\Gin@nat@height>\textheight0.8\textheight\else\Gin@nat@height\fi} -\makeatother -% Scale images if necessary, so that they will not overflow the page -% margins by default, and it is still possible to overwrite the defaults -% using explicit options in \includegraphics[width, height, ...]{} -\setkeys{Gin}{width=\maxwidth,height=\maxheight,keepaspectratio} -$endif$ - -% Prevent slide breaks in the middle of a paragraph: -\widowpenalties 1 10000 -\raggedbottom - -$if(section-titles)$ -\AtBeginPart{ - \let\insertpartnumber\relax - \let\partname\relax - \frame{\partpage} -} -\AtBeginSection{ - \ifbibliography - \else - \let\insertsectionnumber\relax - \let\sectionname\relax - \frame{\sectionpage} - \fi -} -\AtBeginSubsection{ - \let\insertsubsectionnumber\relax - \let\subsectionname\relax - \frame{\subsectionpage} -} -$endif$ - -$if(links-as-notes)$ -% Make links footnotes instead of hotlinks: -\renewcommand{\href}[2]{#2\footnote{\url{#1}}} -$endif$ -$if(strikeout)$ -\usepackage[normalem]{ulem} -% avoid problems with \sout in headers with hyperref: -\pdfstringdefDisableCommands{\renewcommand{\sout}{}} -$endif$ -\setlength{\parindent}{0pt} -\setlength{\parskip}{6pt plus 2pt minus 1pt} -\setlength{\emergencystretch}{3em} % prevent overfull lines -\providecommand{\tightlist}{% - \setlength{\itemsep}{0pt}\setlength{\parskip}{0pt}} -$if(numbersections)$ -\setcounter{secnumdepth}{$if(secnumdepth)$$secnumdepth$$else$5$endif$} -$else$ -\setcounter{secnumdepth}{0} -$endif$ -$if(dir)$ -\ifxetex - % load bidi as late as possible as it modifies e.g. graphicx - $if(latex-dir-rtl)$ - \usepackage[RTLdocument]{bidi} - $else$ - \usepackage{bidi} - $endif$ -\fi -\ifnum 0\ifxetex 1\fi\ifluatex 1\fi=0 % if pdftex - \TeXXeTstate=1 - \newcommand{\RL}[1]{\beginR #1\endR} - \newcommand{\LR}[1]{\beginL #1\endL} - \newenvironment{RTL}{\beginR}{\endR} - \newenvironment{LTR}{\beginL}{\endL} -\fi -$endif$ -$for(header-includes)$ -$header-includes$ -$endfor$ - -$if(title)$ -\title{$title$} -$endif$ -$if(subtitle)$ -\subtitle{$subtitle$} -$endif$ -$if(author)$ -\author{$for(author)$$author$$sep$ \and $endfor$} -$endif$ -$if(institute)$ -\institute{$for(institute)$$institute$$sep$ \and $endfor$} -$endif$ -\date{$date$} - -\begin{document} -$if(title)$ -\frame{\titlepage} -$endif$ - -$for(include-before)$ -$include-before$ - -$endfor$ -$if(toc)$ -\begin{frame} -\tableofcontents[hideallsubsections] -\end{frame} - -$endif$ -$body$ - -$if(natbib)$ -$if(bibliography)$ -$if(biblio-title)$ -$if(book-class)$ -\renewcommand\bibname{$biblio-title$} -$else$ -\renewcommand\refname{$biblio-title$} -$endif$ -$endif$ -\begin{frame}[allowframebreaks]{$biblio-title$} -\bibliographytrue -\bibliography{$for(bibliography)$$bibliography$$sep$,$endfor$} -\end{frame} - -$endif$ -$endif$ -$if(biblatex)$ -\begin{frame}[allowframebreaks]{$biblio-title$} -\bibliographytrue -\printbibliography[heading=none] -\end{frame} - -$endif$ -$for(include-after)$ -$include-after$ - -$endfor$ -\end{document} diff --git a/data/templates/default.commonmark b/data/templates/default.commonmark index 95d7e52cc..9f6ca96de 100644 --- a/data/templates/default.commonmark +++ b/data/templates/default.commonmark @@ -11,7 +11,7 @@ $include-before$ $endfor$ $if(toc)$ -$toc$ +$table-of-contents$ $endif$ $body$ diff --git a/data/templates/default.context b/data/templates/default.context index 4a3457934..56f4e9cf7 100644 --- a/data/templates/default.context +++ b/data/templates/default.context @@ -23,6 +23,7 @@ $endif$ style=$linkstyle$, color=$linkcolor$, contrastcolor=$linkcontrastcolor$] + % make chapter, section bookmarks visible when opening document \placebookmarks[chapter, section, subsection, subsubsection, subsubsubsection, subsubsubsubsection][chapter, section] \setupinteractionscreen[option=bookmark] @@ -37,26 +38,22 @@ $endif$ $if(pagenumbering)$ \setuppagenumbering[$for(pagenumbering)$$pagenumbering$$sep$,$endfor$] $endif$ + % use microtypography \definefontfeature[default][default][script=latn, protrusion=quality, expansion=quality, itlc=yes, textitalics=yes, onum=yes, pnum=yes] \definefontfeature[smallcaps][script=latn, protrusion=quality, expansion=quality, smcp=yes, onum=yes, pnum=yes] \setupalign[hz,hanging] \setupitaliccorrection[global, always] + \setupbodyfontenvironment[default][em=italic] % use italic as em, not slanted -\usemodule[simplefonts$if(fontsize)$,$fontsize$$endif$] -\setmainfontfallback[DejaVu Serif][range={greekandcoptic, greekextended}, force=yes, rscale=auto] -$if(mainfont)$ -\setmainfont[$mainfont$] -$endif$ -$if(sansfont)$ -\setsansfont[$sansfont$][rscale=auto] -$endif$ -$if(monofont)$ -\setmonofont[$monofont$][features=none, rscale=auto] -$endif$ -$if(mathfont)$ -\setmathfont[$mathfont$][rscale=auto] -$endif$ + +\definefallbackfamily[mainface][rm][DejaVu Serif][preset=range:greek, force=yes] +\definefontfamily[mainface][rm][$if(mainfont)$$mainfont$$else$Latin Modern Roman$endif$] +\definefontfamily[mainface][mm][$if(mathfont)$$mathfont$$else$Latin Modern Math$endif$] +\definefontfamily[mainface][ss][$if(sansfont)$$sansfont$$else$Latin Modern Sans$endif$] +\definefontfamily[mainface][tt][$if(monofont)$$monofont$$else$Latin Modern Typewriter$endif$][features=none] +\setupbodyfont[mainface$if(fontsize)$,$fontsize$$endif$] + \setupwhitespace[$if(whitespace)$$whitespace$$else$medium$endif$] $if(indenting)$ \setupindenting[$for(indenting)$$indenting$$sep$,$endfor$] @@ -95,6 +92,11 @@ $endif$ \setupthinrules[width=15em] % width of horizontal rules +\setupxtable[frame=off] +\setupxtable[head][topframe=on,bottomframe=on] +\setupxtable[body][] +\setupxtable[foot][bottomframe=on] + $for(header-includes)$ $header-includes$ $endfor$ diff --git a/data/templates/default.docbook b/data/templates/default.docbook4 index 5313c4083..5313c4083 100644 --- a/data/templates/default.docbook +++ b/data/templates/default.docbook4 diff --git a/data/templates/default.docbook5 b/data/templates/default.docbook5 index 415ccf9c3..b2c407903 100644 --- a/data/templates/default.docbook5 +++ b/data/templates/default.docbook5 @@ -1,6 +1,9 @@ <?xml version="1.0" encoding="utf-8" ?> <!DOCTYPE article> <article +$if(lang)$ + xml:lang="$lang$" +$endif$ xmlns="http://docbook.org/ns/docbook" version="5.0" $if(mathml)$ xmlns:mml="http://www.w3.org/1998/Math/MathML" @@ -8,6 +11,9 @@ $endif$ xmlns:xlink="http://www.w3.org/1999/xlink" > <info> <title>$title$</title> +$if(subtitle)$ + <subtitle>$subtitle$</subtitle> +$endif$ $if(author)$ <authorgroup> $for(author)$ diff --git a/data/templates/default.dzslides b/data/templates/default.dzslides index 97d518931..892a434cb 100644 --- a/data/templates/default.dzslides +++ b/data/templates/default.dzslides @@ -12,10 +12,15 @@ $if(keywords)$ <meta name="keywords" content="$for(keywords)$$keywords$$sep$, $endfor$"> $endif$ <title>$if(title-prefix)$$title-prefix$ – $endif$$pagetitle$</title> - <style type="text/css">code{white-space: pre-wrap;}</style> + <style type="text/css"> + code{white-space: pre-wrap;} + span.smallcaps{font-variant: small-caps;} + span.underline{text-decoration: underline;} + div.column{display: inline-block; vertical-align: top; width: 50%;} $if(quotes)$ - <style type="text/css">q { quotes: "“" "”" "‘" "’"; }</style> + q { quotes: "“" "”" "‘" "’"; } $endif$ + </style> $if(highlighting-css)$ <style type="text/css"> $highlighting-css$ @@ -26,7 +31,7 @@ $for(css)$ <link rel="stylesheet" href="$css$"> $endfor$ $else$ -<link href='http://fonts.googleapis.com/css?family=Oswald' rel='stylesheet'> +<link href='https://fonts.googleapis.com/css?family=Oswald' rel='stylesheet'> <style> html, .view body { background-color: black; counter-reset: slideidx; } @@ -183,7 +188,7 @@ $endif$ $endif$ $if(toc)$ <section id="$idprefix$TOC"> -$toc$ +$table-of-contents$ </section> $endif$ $for(include-before)$ diff --git a/data/templates/default.epub b/data/templates/default.epub2 index afcf96a3e..cca9fcf6f 100644 --- a/data/templates/default.epub +++ b/data/templates/default.epub2 @@ -6,6 +6,15 @@ <meta http-equiv="Content-Style-Type" content="text/css" /> <meta name="generator" content="pandoc" /> <title>$pagetitle$</title> + <style type="text/css"> + code{white-space: pre-wrap;} + span.smallcaps{font-variant: small-caps;} + span.underline{text-decoration: underline;} + div.column{display: inline-block; vertical-align: top; width: 50%;} +$if(quotes)$ + q { quotes: "“" "”" "‘" "’"; } +$endif$ + </style> $if(highlighting-css)$ <style type="text/css"> $highlighting-css$ diff --git a/data/templates/default.epub3 b/data/templates/default.epub3 index 8a12e0fb3..b22714963 100644 --- a/data/templates/default.epub3 +++ b/data/templates/default.epub3 @@ -5,11 +5,15 @@ <meta charset="utf-8" /> <meta name="generator" content="pandoc" /> <title>$pagetitle$</title> -$if(quotes)$ <style type="text/css"> - q { quotes: "“" "”" "‘" "’"; } - </style> + code{white-space: pre-wrap;} + span.smallcaps{font-variant: small-caps;} + span.underline{text-decoration: underline;} + div.column{display: inline-block; vertical-align: top; width: 50%;} +$if(quotes)$ + q { quotes: "“" "”" "‘" "’"; } $endif$ + </style> $if(highlighting-css)$ <style type="text/css"> $highlighting-css$ diff --git a/data/templates/default.html b/data/templates/default.html4 index 8caea26c8..714b3ff2e 100644 --- a/data/templates/default.html +++ b/data/templates/default.html4 @@ -14,10 +14,15 @@ $if(keywords)$ <meta name="keywords" content="$for(keywords)$$keywords$$sep$, $endfor$" /> $endif$ <title>$if(title-prefix)$$title-prefix$ – $endif$$pagetitle$</title> - <style type="text/css">code{white-space: pre;}</style> + <style type="text/css"> + code{white-space: pre-wrap;} + span.smallcaps{font-variant: small-caps;} + span.underline{text-decoration: underline;} + div.column{display: inline-block; vertical-align: top; width: 50%;} $if(quotes)$ - <style type="text/css">q { quotes: "“" "”" "‘" "’"; }</style> + q { quotes: "“" "”" "‘" "’"; } $endif$ + </style> $if(highlighting-css)$ <style type="text/css"> $highlighting-css$ @@ -53,7 +58,7 @@ $endif$ $endif$ $if(toc)$ <div id="$idprefix$TOC"> -$toc$ +$table-of-contents$ </div> $endif$ $body$ diff --git a/data/templates/default.html5 b/data/templates/default.html5 index 5641ecb80..5c484f376 100644 --- a/data/templates/default.html5 +++ b/data/templates/default.html5 @@ -1,23 +1,28 @@ <!DOCTYPE html> -<html$if(lang)$ lang="$lang$"$endif$$if(dir)$ dir="$dir$"$endif$> +<html xmlns="http://www.w3.org/1999/xhtml" lang="$lang$" xml:lang="$lang$"$if(dir)$ dir="$dir$"$endif$> <head> - <meta charset="utf-8"> - <meta name="generator" content="pandoc"> - <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes"> + <meta charset="utf-8" /> + <meta name="generator" content="pandoc" /> + <meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=yes" /> $for(author-meta)$ - <meta name="author" content="$author-meta$"> + <meta name="author" content="$author-meta$" /> $endfor$ $if(date-meta)$ - <meta name="dcterms.date" content="$date-meta$"> + <meta name="dcterms.date" content="$date-meta$" /> $endif$ $if(keywords)$ - <meta name="keywords" content="$for(keywords)$$keywords$$sep$, $endfor$"> + <meta name="keywords" content="$for(keywords)$$keywords$$sep$, $endfor$" /> $endif$ <title>$if(title-prefix)$$title-prefix$ – $endif$$pagetitle$</title> - <style type="text/css">code{white-space: pre;}</style> + <style type="text/css"> + code{white-space: pre-wrap;} + span.smallcaps{font-variant: small-caps;} + span.underline{text-decoration: underline;} + div.column{display: inline-block; vertical-align: top; width: 50%;} $if(quotes)$ - <style type="text/css">q { quotes: "“" "”" "‘" "’"; }</style> + q { quotes: "“" "”" "‘" "’"; } $endif$ + </style> $if(highlighting-css)$ <style type="text/css"> $highlighting-css$ @@ -56,7 +61,7 @@ $endif$ $endif$ $if(toc)$ <nav id="$idprefix$TOC"> -$toc$ +$table-of-contents$ </nav> $endif$ $body$ diff --git a/data/templates/default.jats b/data/templates/default.jats new file mode 100644 index 000000000..228a0636a --- /dev/null +++ b/data/templates/default.jats @@ -0,0 +1,203 @@ +<?xml version="1.0" encoding="utf-8" ?> +$if(xml-stylesheet)$ +<?xml-stylesheet type="text/xsl" href="$xml-stylesheet$"?> +$endif$ +<!DOCTYPE article PUBLIC "-//NLM//DTD JATS (Z39.96) Journal Publishing DTD v1.0 20120330//EN" + "JATS-journalpublishing1.dtd"> +$if(article.type)$ +<article xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink" dtd-version="1.0" article-type="$article.type$"> +$else$ +<article xmlns:mml="http://www.w3.org/1998/Math/MathML" xmlns:xlink="http://www.w3.org/1999/xlink" dtd-version="1.0" article-type="other"> +$endif$ +<front> +<journal-meta> +$if(journal.publisher-id)$ +<journal-id journal-id-type="publisher-id">$journal.publisher-id$</journal-id> +$endif$ +$if(journal.nlm-ta)$ +<journal-id journal-id-type="nlm-ta">$journal.nlm-ta$</journal-id> +$endif$ +$if(journal.pmc)$ +<journal-id journal-id-type="pmc">$journal.pmc$</journal-id> +$endif$ +<journal-title-group> +$if(journal.title)$ +<journal-title>$journal.title$</journal-title> +$endif$ +$if(journal.abbrev-title)$ +<abbrev-journal-title>$journal.abbrev-title$</abbrev-journal-title> +$endif$ +</journal-title-group> +$if(journal.pissn)$ +<issn pub-type="ppub">$journal.pissn$</issn> +$endif$ +$if(journal.eissn)$ +<issn pub-type="epub">$journal.eissn$</issn> +$endif$ +<publisher> +<publisher-name>$journal.publisher-name$</publisher-name> +$if(journal.publisher-loc)$ +<publisher-loc>$journal.publisher-loc$</publisher-loc> +$endif$ +</publisher> +</journal-meta> +<article-meta> +$if(article.publisher-id)$ +<article-id pub-id-type="publisher-id">$article.publisher-id$</article-id> +$endif$ +$if(article.doi)$ +<article-id pub-id-type="doi">$article.doi$</article-id> +$endif$ +$if(article.pmid)$ +<article-id pub-id-type="pmid">$article.pmid$</article-id> +$endif$ +$if(article.pmcid)$ +<article-id pub-id-type="pmcid">$article.pmcid$</article-id> +$endif$ +$if(article.art-access-id)$ +<article-id pub-id-type="art-access-id">$article.art-access-id$</article-id> +$endif$ +$if(article.heading)$ +<article-categories> +<subj-group subj-group-type="heading"> +<subject>$article.heading$</subject> +</subj-group> +$if(article.categories)$ +<subj-group subj-group-type="categories"> +$for(article.categories)$ +<subject>$article.categories$</subject> +$endfor$ +</subj-group> +$endif$ +</article-categories> +$endif$ +$if(title)$ +<title-group> +<article-title>$title$</article-title> +</title-group> +$endif$ +$if(author)$ +<contrib-group> +$for(author)$ +<contrib contrib-type="author"> +$if(author.orcid)$ +<contrib-id contrib-id-type="orcid">$author.orcid$</contrib-id> +$endif$ +<name> +$if(author.surname)$ +<surname>$author.surname$</surname> +<given-names>$author.given-names$</given-names> +$else$ +<string-name>$author$</string-name> +$endif$ +</name> +$if(author.email)$ +<email>$author.email$</email> +$endif$ +$if(author.aff-id)$ +<xref ref-type="aff" rid="aff-$contrib.aff-id$"/> +$endif$ +$if(author.cor-id)$ +<xref ref-type="corresp" rid="cor-$author.cor-id$"><sup>*</sup></xref> +$endif$ +</contrib> +$endfor$ +</contrib-group> +$endif$ +$if(article.author-notes)$ +<author-notes> +$if(article.author-notes.corresp)$ +$for(article.author-notes.corresp)$ +<corresp id="cor-$article.author-notes.corresp.id$">* E-mail: <email>$article.author-notes.corresp.email$</email></corresp> +$endfor$ +$endif$ +$if(article.author-notes.conflict)$ +<fn fn-type="conflict"><p>$article.author-notes.conflict$</p></fn> +$endif$ +$if(article.author-notes.con)$ +<fn fn-type="con"><p>$article.author-notes.con$</p></fn> +$endif$ +</author-notes> +$endif$ +$if(date)$ +$if(date.iso-8601)$ +<pub-date pub-type="epub" iso-8601-date="$date.iso-8601$"> +$else$ +<pub-date pub-type="epub"> +$endif$ +$if(date.day)$ +<day>$pub-date.day$</day> +$endif$ +$if(date.month)$ +<month>$pub-date.month$</month> +$endif$ +$if(date.year)$ +<year>$pub-date.year$</year> +$else$ +<string-date>$date$</string-date> +$endif$ +</pub-date> +$endif$ +$if(article.volume)$ +<volume>$article.volume$</volume> +$endif$ +$if(article.issue)$ +<issue>$article.issue$</issue> +$endif$ +$if(article.fpage)$ +<fpage>$article.fpage$</fpage> +$endif$ +$if(article.lpage)$ +<lpage>$article.lpage$</lpage> +$endif$ +$if(article.elocation-id)$ +<elocation-id>$article.elocation-id$</elocation-id> +$endif$ +$if(history)$ +<history> +</history> +$endif$ +$if(copyright)$ +<permissions> +$if(copyright.statement)$ +<copyright-statement>$copyright.statement$</copyright-statement> +$endif$ +$if(copyright.year)$ +<copyright-year>$copyright.year$</copyright-year> +$endif$ +$if(copyright.holder)$ +<copyright-holder>$copyright.holder$</copyright-holder> +$endif$ +$if(copyright.text)$ +<license license-type="$copyright.type$" xlink:href="$copyright.link$"> +<license-p>$copyright.text$</license-p> +</license> +</permissions> +$endif$ +$endif$ +$if(tags)$ +<kwd-group kwd-group-type="author"> +$for(tags)$ +<kwd>$tags$</kwd> +$endfor$ +</kwd-group> +$endif$ +$if(article.funding-statement)$ +<funding-group> +<funding-statement>$article.funding-statement$</funding-statement> +</funding-group> +$endif$ +</article-meta> +$if(notes)$ +<notes>$notes$</notes> +$endif$ +</front> +<body> +$body$ +</body> +<back> +$if(back)$ +$back$ +$endif$ +</back> +</article> diff --git a/data/templates/default.latex b/data/templates/default.latex index 128f79d8d..c36bf8576 100644 --- a/data/templates/default.latex +++ b/data/templates/default.latex @@ -1,4 +1,16 @@ -\documentclass[$if(fontsize)$$fontsize$,$endif$$if(lang)$$babel-lang$,$endif$$if(papersize)$$papersize$paper,$endif$$for(classoption)$$classoption$$sep$,$endfor$]{$documentclass$} +\PassOptionsToPackage{unicode=true}{hyperref} % options for packages loaded elsewhere +\PassOptionsToPackage{hyphens}{url} +$if(colorlinks)$ +\PassOptionsToPackage{dvipsnames,svgnames*,x11names*}{xcolor} +$endif$ +% +\documentclass[$if(fontsize)$$fontsize$,$endif$$if(lang)$$babel-lang$,$endif$$if(papersize)$$papersize$paper,$endif$$if(beamer)$ignorenonframetext,$if(handout)$handout,$endif$$if(aspectratio)$aspectratio=$aspectratio$,$endif$$endif$$for(classoption)$$classoption$$sep$,$endfor$]{$documentclass$} +$if(beamer)$ +\setbeamertemplate{caption}[numbered] +\setbeamertemplate{caption label separator}{: } +\setbeamercolor{caption name}{fg=normal text.fg} +\beamertemplatenavigationsymbols$if(navigation)$$navigation$$else$empty$endif$ +$endif$ $if(beamerarticle)$ \usepackage{beamerarticle} % needs to be loaded first $endif$ @@ -17,22 +29,21 @@ $endif$ \ifnum 0\ifxetex 1\fi\ifluatex 1\fi=0 % if pdftex \usepackage[$if(fontenc)$$fontenc$$else$T1$endif$]{fontenc} \usepackage[utf8]{inputenc} -$if(euro)$ - \usepackage{eurosym} -$endif$ + \usepackage{textcomp} % provides euro and other symbols \else % if luatex or xelatex +$if(mathspec)$ \ifxetex \usepackage{mathspec} \else - \usepackage{fontspec} + \usepackage{unicode-math} \fi +$else$ + \usepackage{unicode-math} +$endif$ \defaultfontfeatures{Ligatures=TeX,Scale=MatchLowercase} $for(fontfamilies)$ \newfontfamily{$fontfamilies.name$}[$fontfamilies.options$]{$fontfamilies.font$} $endfor$ -$if(euro)$ - \newcommand{\euro}{€} -$endif$ $if(mainfont)$ \setmainfont[$for(mainfontoptions)$$mainfontoptions$$sep$,$endfor$]{$mainfont$} $endif$ @@ -43,13 +54,54 @@ $if(monofont)$ \setmonofont[Mapping=tex-ansi$if(monofontoptions)$,$for(monofontoptions)$$monofontoptions$$sep$,$endfor$$endif$]{$monofont$} $endif$ $if(mathfont)$ +$if(mathspec)$ + \ifxetex \setmathfont(Digits,Latin,Greek)[$for(mathfontoptions)$$mathfontoptions$$sep$,$endfor$]{$mathfont$} + \else + \setmathfont[$for(mathfontoptions)$$mathfontoptions$$sep$,$endfor$]{$mathfont$} + \fi +$else$ + \setmathfont[$for(mathfontoptions)$$mathfontoptions$$sep$,$endfor$]{$mathfont$} +$endif$ $endif$ $if(CJKmainfont)$ + \ifxetex \usepackage{xeCJK} \setCJKmainfont[$for(CJKoptions)$$CJKoptions$$sep$,$endfor$]{$CJKmainfont$} + \fi +$endif$ +$if(luatexjapresetoptions)$ + \ifluatex + \usepackage[$for(luatexjapresetoptions)$$luatexjapresetoptions$$sep$,$endfor$]{luatexja-preset} + \fi +$endif$ +$if(CJKmainfont)$ + \ifluatex + \usepackage[$for(luatexjafontspecoptions)$$luatexjafontspecoptions$$sep$,$endfor$]{luatexja-fontspec} + \setmainjfont[$for(CJKoptions)$$CJKoptions$$sep$,$endfor$]{$CJKmainfont$} + \fi $endif$ \fi +$if(beamer)$ +$if(theme)$ +\usetheme[$for(themeoptions)$$themeoptions$$sep$,$endfor$]{$theme$} +$endif$ +$if(colortheme)$ +\usecolortheme{$colortheme$} +$endif$ +$if(fonttheme)$ +\usefonttheme{$fonttheme$} +$endif$ +$if(mainfont)$ +\usefonttheme{serif} % use mainfont rather than sansfont for slide text +$endif$ +$if(innertheme)$ +\useinnertheme{$innertheme$} +$endif$ +$if(outertheme)$ +\useoutertheme{$outertheme$} +$endif$ +$endif$ % use upquote if available, for straight quotes in verbatim environments \IfFileExists{upquote.sty}{\usepackage{upquote}}{} % use microtype if available @@ -57,14 +109,22 @@ $endif$ \usepackage[$for(microtypeoptions)$$microtypeoptions$$sep$,$endfor$]{microtype} \UseMicrotypeSet[protrusion]{basicmath} % disable protrusion for tt fonts }{} -\PassOptionsToPackage{hyphens}{url} % url is loaded by hyperref +$if(indent)$ +$else$ +\IfFileExists{parskip.sty}{% +\usepackage{parskip} +}{% else +\setlength{\parindent}{0pt} +\setlength{\parskip}{6pt plus 2pt minus 1pt} +} +$endif$ $if(verbatim-in-note)$ \usepackage{fancyvrb} $endif$ -\usepackage[unicode=true]{hyperref} $if(colorlinks)$ -\PassOptionsToPackage{usenames,dvipsnames}{color} % color is loaded by hyperref +\usepackage{xcolor} $endif$ +\usepackage{hyperref} \hypersetup{ $if(title-meta)$ pdftitle={$title-meta$}, @@ -91,32 +151,12 @@ $endif$ $if(geometry)$ \usepackage[$for(geometry)$$geometry$$sep$,$endfor$]{geometry} $endif$ -$if(lang)$ -\ifnum 0\ifxetex 1\fi\ifluatex 1\fi=0 % if pdftex - \usepackage[shorthands=off,$for(babel-otherlangs)$$babel-otherlangs$,$endfor$main=$babel-lang$]{babel} -$if(babel-newcommands)$ - $babel-newcommands$ -$endif$ -\else - \usepackage{polyglossia} - \setmainlanguage[$polyglossia-lang.options$]{$polyglossia-lang.name$} -$for(polyglossia-otherlangs)$ - \setotherlanguage[$polyglossia-otherlangs.options$]{$polyglossia-otherlangs.name$} -$endfor$ -\fi -$endif$ -$if(natbib)$ -\usepackage{natbib} -\bibliographystyle{$if(biblio-style)$$biblio-style$$else$plainnat$endif$} -$endif$ -$if(biblatex)$ -\usepackage[$if(biblio-style)$style=$biblio-style$,$endif$$for(biblatexoptions)$$biblatexoptions$$sep$,$endfor$]{biblatex} -$for(bibliography)$ -\addbibresource{$bibliography$} -$endfor$ +$if(beamer)$ +\newif\ifbibliography $endif$ $if(listings)$ \usepackage{listings} +\newcommand{\passthrough}[1]{#1} $endif$ $if(lhs)$ \lstnewenvironment{code}{\lstset{language=Haskell,basicstyle=\small\ttfamily}}{} @@ -126,8 +166,16 @@ $highlighting-macros$ $endif$ $if(tables)$ \usepackage{longtable,booktabs} +$if(beamer)$ +\usepackage{caption} +% These lines are needed to make table captions work with longtable: +\makeatletter +\def\fnum@table{\tablename~\thetable} +\makeatother +$else$ % Fix footnotes in tables (requires footnote package) -\IfFileExists{footnote.sty}{\usepackage{footnote}\makesavenoteenv{long table}}{} +\IfFileExists{footnote.sty}{\usepackage{footnote}\makesavenoteenv{longtable}}{} +$endif$ $endif$ $if(graphics)$ \usepackage{graphicx,grffile} @@ -140,24 +188,52 @@ $if(graphics)$ % using explicit options in \includegraphics[width, height, ...]{} \setkeys{Gin}{width=\maxwidth,height=\maxheight,keepaspectratio} $endif$ +$if(beamer)$ +% Prevent slide breaks in the middle of a paragraph: +\widowpenalties 1 10000 +\raggedbottom +$if(section-titles)$ +\setbeamertemplate{part page}{ +\centering +\begin{beamercolorbox}[sep=16pt,center]{part title} + \usebeamerfont{part title}\insertpart\par +\end{beamercolorbox} +} +\setbeamertemplate{section page}{ +\centering +\begin{beamercolorbox}[sep=12pt,center]{part title} + \usebeamerfont{section title}\insertsection\par +\end{beamercolorbox} +} +\setbeamertemplate{subsection page}{ +\centering +\begin{beamercolorbox}[sep=8pt,center]{part title} + \usebeamerfont{subsection title}\insertsubsection\par +\end{beamercolorbox} +} +\AtBeginPart{ + \frame{\partpage} +} +\AtBeginSection{ + \ifbibliography + \else + \frame{\sectionpage} + \fi +} +\AtBeginSubsection{ + \frame{\subsectionpage} +} +$endif$ +$endif$ $if(links-as-notes)$ % Make links footnotes instead of hotlinks: -\renewcommand{\href}[2]{#2\footnote{\url{#1}}} +\DeclareRobustCommand{\href}[2]{#2\footnote{\url{#1}}} $endif$ $if(strikeout)$ \usepackage[normalem]{ulem} % avoid problems with \sout in headers with hyperref: \pdfstringdefDisableCommands{\renewcommand{\sout}{}} $endif$ -$if(indent)$ -$else$ -\IfFileExists{parskip.sty}{% -\usepackage{parskip} -}{% else -\setlength{\parindent}{0pt} -\setlength{\parskip}{6pt plus 2pt minus 1pt} -} -$endif$ \setlength{\emergencystretch}{3em} % prevent overfull lines \providecommand{\tightlist}{% \setlength{\itemsep}{0pt}\setlength{\parskip}{0pt}} @@ -166,6 +242,8 @@ $if(numbersections)$ $else$ \setcounter{secnumdepth}{0} $endif$ +$if(beamer)$ +$else$ $if(subparagraph)$ $else$ % Redefines (sub)paragraphs to behave more like sections @@ -178,6 +256,34 @@ $else$ \renewcommand{\subparagraph}[1]{\oldsubparagraph{#1}\mbox{}} \fi $endif$ +$endif$ +$if(pagestyle)$ +\pagestyle{$pagestyle$} +$endif$ + +% set default figure placement to htbp +\makeatletter +\def\fps@figure{htbp} +\makeatother + +$for(header-includes)$ +$header-includes$ +$endfor$ +$if(lang)$ +\ifnum 0\ifxetex 1\fi\ifluatex 1\fi=0 % if pdftex + \usepackage[shorthands=off,$for(babel-otherlangs)$$babel-otherlangs$,$endfor$main=$babel-lang$]{babel} +$if(babel-newcommands)$ + $babel-newcommands$ +$endif$ +\else + % load polyglossia as late as possible as it *could* call bidi if RTL lang (e.g. Hebrew or Arabic) + \usepackage{polyglossia} + \setmainlanguage[$polyglossia-lang.options$]{$polyglossia-lang.name$} +$for(polyglossia-otherlangs)$ + \setotherlanguage[$polyglossia-otherlangs.options$]{$polyglossia-otherlangs.name$} +$endfor$ +\fi +$endif$ $if(dir)$ \ifxetex % load bidi as late as possible as it modifies e.g. graphicx @@ -195,15 +301,16 @@ $if(dir)$ \newenvironment{LTR}{\beginL}{\endL} \fi $endif$ - -% set default figure placement to htbp -\makeatletter -\def\fps@figure{htbp} -\makeatother - -$for(header-includes)$ -$header-includes$ +$if(natbib)$ +\usepackage[$natbiboptions$]{natbib} +\bibliographystyle{$if(biblio-style)$$biblio-style$$else$plainnat$endif$} +$endif$ +$if(biblatex)$ +\usepackage[$if(biblio-style)$style=$biblio-style$,$endif$$for(biblatexoptions)$$biblatexoptions$$sep$,$endfor$]{biblatex} +$for(bibliography)$ +\addbibresource{$bibliography$} $endfor$ +$endif$ $if(title)$ \title{$title$$if(thanks)$\thanks{$thanks$}$endif$} @@ -220,9 +327,20 @@ $if(institute)$ \institute{$for(institute)$$institute$$sep$ \and $endfor$} $endif$ \date{$date$} +$if(beamer)$ +$if(titlegraphic)$ +\titlegraphic{\includegraphics{$titlegraphic$}} +$endif$ +$if(logo)$ +\logo{\includegraphics{$logo$}} +$endif$ +$endif$ \begin{document} $if(title)$ +$if(beamer)$ +\frame{\titlepage} +$else$ \maketitle $endif$ $if(abstract)$ @@ -230,20 +348,27 @@ $if(abstract)$ $abstract$ \end{abstract} $endif$ +$endif$ $for(include-before)$ $include-before$ $endfor$ $if(toc)$ +$if(beamer)$ +\begin{frame} +\tableofcontents[hideallsubsections] +\end{frame} +$else$ { $if(colorlinks)$ -\hypersetup{linkcolor=$if(toccolor)$$toccolor$$else$black$endif$} +\hypersetup{linkcolor=$if(toccolor)$$toccolor$$else$$endif$} $endif$ \setcounter{tocdepth}{$toc-depth$} \tableofcontents } $endif$ +$endif$ $if(lot)$ \listoftables $endif$ @@ -261,12 +386,26 @@ $else$ \renewcommand\refname{$biblio-title$} $endif$ $endif$ +$if(beamer)$ +\begin{frame}[allowframebreaks]{$biblio-title$} +\bibliographytrue +$endif$ \bibliography{$for(bibliography)$$bibliography$$sep$,$endfor$} +$if(beamer)$ +\end{frame} +$endif$ $endif$ $endif$ $if(biblatex)$ +$if(beamer)$ +\begin{frame}[allowframebreaks]{$biblio-title$} +\bibliographytrue +\printbibliography[heading=none] +\end{frame} +$else$ \printbibliography$if(biblio-title)$[title=$biblio-title$]$endif$ +$endif$ $endif$ $for(include-after)$ diff --git a/data/templates/default.markdown b/data/templates/default.markdown index 95d7e52cc..9f6ca96de 100644 --- a/data/templates/default.markdown +++ b/data/templates/default.markdown @@ -11,7 +11,7 @@ $include-before$ $endfor$ $if(toc)$ -$toc$ +$table-of-contents$ $endif$ $body$ diff --git a/data/templates/default.ms b/data/templates/default.ms new file mode 100644 index 000000000..f4204338a --- /dev/null +++ b/data/templates/default.ms @@ -0,0 +1,112 @@ +.\" **** Custom macro definitions ********************************* +.\" * Super/subscript +.\" (https://lists.gnu.org/archive/html/groff/2012-07/msg00046.html) +.ds { \v'-0.3m'\\s[\\n[.s]*9u/12u] +.ds } \s0\v'0.3m' +.ds < \v'0.3m'\s[\\n[.s]*9u/12u] +.ds > \s0\v'-0.3m' +.\" * Horizontal line +.de HLINE +.LP +.ce +\l'20' +.. +$if(highlighting-macros)$ +.\" * Syntax highlighting macros +$highlighting-macros$ +$endif$ +.\" **** Settings ************************************************* +.\" text width +.nr LL 5.5i +.\" left margin +.nr PO 1.25i +.\" top margin +.nr HM 1.25i +.\" bottom margin +.nr FM 1.25i +.\" header/footer width +.nr LT \n[LL] +.\" point size +.nr PS $if(pointsize)$$pointsize$$else$10p$endif$ +.\" line height +.nr VS $if(lineheight)$$lineheight$$else$12p$endif$ +.\" font family: A, BM, H, HN, N, P, T, ZCM +.fam $if(fontfamily)$$fontfamily$$else$T$endif$ +.\" paragraph indent +.nr PI $if(indent)$$indent$$else$2m$endif$ +.\" interparagraph space +.nr PD 0.33v +.\" footnote width +.nr FL \n[LL] +.\" footnote point size +.nr FPS (\n[PS] - 2000) +$if(papersize)$ +.\" paper size +.ds paper $papersize$ +$endif$ +.\" color used for strikeout +.defcolor strikecolor rgb 0.7 0.7 0.7 +.\" color for links (rgb) +.ds PDFHREF.COLOUR 0.35 0.00 0.60 +.\" border for links (default none) +.ds PDFHREF.BORDER 0 0 0 +.\" point size difference between heading levels +.nr PSINCR 1p +.\" heading level above which point size no longer changes +.nr GROWPS 2 +.\" comment these out if you want a dot after section numbers: +.als SN SN-NO-DOT +.als SN-STYLE SN-NO-DOT +.\" pdf outline fold level +.nr PDFOUTLINE.FOLDLEVEL 3 +.\" start out in outline view +.pdfview /PageMode /UseOutlines +.\" *************************************************************** +.\" PDF metadata +.pdfinfo /Title "$title-meta$" +.pdfinfo /Author "$author-meta$" +$if(adjusting)$ +.ad $adjusting$ +$endif$ +$if(hyphenate)$ +.hy +$else$ +.nh \" Turn off hyphenation by default. +$endif$ +$if(has-inline-math)$ +.EQ +delim @@ +.EN +$endif$ +$for(header-includes)$ +$header-includes$ +$endfor$ +$if(title)$ +.TL +$title$ +$endif$ +$for(author)$ +.AU +$author$ +$endfor$ +$if(date)$ +.ND "$date$" +$endif$ +$if(abstract)$ +.AB +$abstract$ +.AE +$endif$ +.\" 1 column (use .2C for two column) +.1C +$for(include-before)$ +$include-before$ +$endfor$ +$body$ +$if(toc)$ +.TC +$endif$ +$for(include-after)$ +$include-after$ +$endfor$ +.pdfsync diff --git a/data/templates/default.muse b/data/templates/default.muse new file mode 100644 index 000000000..05534adef --- /dev/null +++ b/data/templates/default.muse @@ -0,0 +1,44 @@ +$if(author)$ +#author $author$ +$endif$ +$if(title)$ +#title $title$ +$endif$ +$if(lang)$ +#lang $lang$ +$endif$ +$if(LISTtitle)$ +#LISTtitle $LISTtitle$ +$endif$ +$if(subtitle)$ +#subtitle $subtitle$ +$endif$ +$if(SORTauthors)$ +#SORTauthors $SORTauthors$ +$endif$ +$if(SORTtopics)$ +#SORTtopics $SORTtopics$ +$endif$ +$if(date)$ +#date $date$ +$endif$ +$if(notes)$ +#notes $notes$ +$endif$ +$if(source)$ +#source $source$ +$endif$ + +$for(header-includes)$ +$header-includes$ + +$endfor$ +$for(include-before)$ +$include-before$ + +$endfor$ +$body$ +$for(include-after)$ + +$include-after$ +$endfor$ diff --git a/data/templates/default.opendocument b/data/templates/default.opendocument index bb01d4bbb..e0bc5c1d3 100644 --- a/data/templates/default.opendocument +++ b/data/templates/default.opendocument @@ -23,6 +23,135 @@ $endif$ $for(include-before)$ $include-before$ $endfor$ +$if(toc)$ +<text:table-of-content> + <text:table-of-content-source text:outline-level="10"> + <text:index-title-template text:style-name="Contents_20_Heading"> + $toc-title$ + </text:index-title-template> + <text:table-of-content-entry-template text:outline-level="1" + text:style-name="Contents_20_1"> + <text:index-entry-link-start text:style-name="Internet_20_link" /> + <text:index-entry-chapter /> + <text:index-entry-text /> + <text:index-entry-link-end /> + <text:index-entry-tab-stop style:type="right" + style:leader-char="." /> + <text:index-entry-link-start text:style-name="Internet_20_link" /> + <text:index-entry-page-number /> + <text:index-entry-link-end /> + </text:table-of-content-entry-template> + <text:table-of-content-entry-template text:outline-level="2" + text:style-name="Contents_20_2"> + <text:index-entry-link-start text:style-name="Internet_20_link" /> + <text:index-entry-chapter /> + <text:index-entry-text /> + <text:index-entry-link-end /> + <text:index-entry-tab-stop style:type="right" + style:leader-char="." /> + <text:index-entry-link-start text:style-name="Internet_20_link" /> + <text:index-entry-page-number /> + <text:index-entry-link-end /> + </text:table-of-content-entry-template> + <text:table-of-content-entry-template text:outline-level="3" + text:style-name="Contents_20_3"> + <text:index-entry-link-start text:style-name="Internet_20_link" /> + <text:index-entry-chapter /> + <text:index-entry-text /> + <text:index-entry-link-end /> + <text:index-entry-tab-stop style:type="right" + style:leader-char="." /> + <text:index-entry-link-start text:style-name="Internet_20_link" /> + <text:index-entry-page-number /> + <text:index-entry-link-end /> + </text:table-of-content-entry-template> + <text:table-of-content-entry-template text:outline-level="4" + text:style-name="Contents_20_4"> + <text:index-entry-link-start text:style-name="Internet_20_link" /> + <text:index-entry-chapter /> + <text:index-entry-text /> + <text:index-entry-link-end /> + <text:index-entry-tab-stop style:type="right" + style:leader-char="." /> + <text:index-entry-link-start text:style-name="Internet_20_link" /> + <text:index-entry-page-number /> + <text:index-entry-link-end /> + </text:table-of-content-entry-template> + <text:table-of-content-entry-template text:outline-level="5" + text:style-name="Contents_20_5"> + <text:index-entry-link-start text:style-name="Internet_20_link" /> + <text:index-entry-chapter /> + <text:index-entry-text /> + <text:index-entry-link-end /> + <text:index-entry-tab-stop style:type="right" + style:leader-char="." /> + <text:index-entry-link-start text:style-name="Internet_20_link" /> + <text:index-entry-page-number /> + <text:index-entry-link-end /> + </text:table-of-content-entry-template> + <text:table-of-content-entry-template text:outline-level="6" + text:style-name="Contents_20_6"> + <text:index-entry-link-start text:style-name="Internet_20_link" /> + <text:index-entry-chapter /> + <text:index-entry-text /> + <text:index-entry-link-end /> + <text:index-entry-tab-stop style:type="right" + style:leader-char="." /> + <text:index-entry-link-start text:style-name="Internet_20_link" /> + <text:index-entry-page-number /> + <text:index-entry-link-end /> + </text:table-of-content-entry-template> + <text:table-of-content-entry-template text:outline-level="7" + text:style-name="Contents_20_7"> + <text:index-entry-link-start text:style-name="Internet_20_link" /> + <text:index-entry-chapter /> + <text:index-entry-text /> + <text:index-entry-link-end /> + <text:index-entry-tab-stop style:type="right" + style:leader-char="." /> + <text:index-entry-link-start text:style-name="Internet_20_link" /> + <text:index-entry-page-number /> + <text:index-entry-link-end /> + </text:table-of-content-entry-template> + <text:table-of-content-entry-template text:outline-level="8" + text:style-name="Contents_20_8"> + <text:index-entry-link-start text:style-name="Internet_20_link" /> + <text:index-entry-chapter /> + <text:index-entry-text /> + <text:index-entry-link-end /> + <text:index-entry-tab-stop style:type="right" + style:leader-char="." /> + <text:index-entry-link-start text:style-name="Internet_20_link" /> + <text:index-entry-page-number /> + <text:index-entry-link-end /> + </text:table-of-content-entry-template> + <text:table-of-content-entry-template text:outline-level="9" + text:style-name="Contents_20_9"> + <text:index-entry-link-start text:style-name="Internet_20_link" /> + <text:index-entry-chapter /> + <text:index-entry-text /> + <text:index-entry-link-end /> + <text:index-entry-tab-stop style:type="right" + style:leader-char="." /> + <text:index-entry-link-start text:style-name="Internet_20_link" /> + <text:index-entry-page-number /> + <text:index-entry-link-end /> + </text:table-of-content-entry-template> + <text:table-of-content-entry-template text:outline-level="10" + text:style-name="Contents_20_10"> + <text:index-entry-link-start text:style-name="Internet_20_link" /> + <text:index-entry-chapter /> + <text:index-entry-text /> + <text:index-entry-link-end /> + <text:index-entry-tab-stop style:type="right" + style:leader-char="." /> + <text:index-entry-link-start text:style-name="Internet_20_link" /> + <text:index-entry-page-number /> + <text:index-entry-link-end /> + </text:table-of-content-entry-template> + </text:table-of-content-source> +</text:table-of-content> +$endif$ $body$ $for(include-after)$ $include-after$ diff --git a/data/templates/default.plain b/data/templates/default.plain index 95d7e52cc..9f6ca96de 100644 --- a/data/templates/default.plain +++ b/data/templates/default.plain @@ -11,7 +11,7 @@ $include-before$ $endfor$ $if(toc)$ -$toc$ +$table-of-contents$ $endif$ $body$ diff --git a/data/templates/default.revealjs b/data/templates/default.revealjs index 1d356ef8d..65ab09049 100644 --- a/data/templates/default.revealjs +++ b/data/templates/default.revealjs @@ -17,10 +17,15 @@ $endif$ <meta name="apple-mobile-web-app-status-bar-style" content="black-translucent"> <meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no, minimal-ui"> <link rel="stylesheet" href="$revealjs-url$/css/reveal.css"> - <style type="text/css">code{white-space: pre;}</style> + <style type="text/css"> + code{white-space: pre-wrap;} + span.smallcaps{font-variant: small-caps;} + span.underline{text-decoration: underline;} + div.column{display: inline-block; vertical-align: top; width: 50%;} $if(quotes)$ - <style type="text/css">q { quotes: "“" "”" "‘" "’"; }</style> + q { quotes: "“" "”" "‘" "’"; } $endif$ + </style> $if(highlighting-css)$ <style type="text/css"> $highlighting-css$ @@ -60,7 +65,7 @@ $endfor$ <div class="slides"> $if(title)$ -<section> +<section id="$idprefix$title-slide"> <h1 class="title">$title$</h1> $if(subtitle)$ <p class="subtitle">$subtitle$</p> @@ -75,7 +80,7 @@ $endif$ $endif$ $if(toc)$ <section id="$idprefix$TOC"> -$toc$ +$table-of-contents$ </section> $endif$ @@ -103,9 +108,11 @@ $if(slideNumber)$ // Display the page number of the current slide slideNumber: $slideNumber$, $endif$ -$if(history)$ // Push each slide change to the browser history +$if(history)$ history: $history$, +$else$ + history: true, $endif$ $if(keyboard)$ // Enable keyboard shortcuts for navigation @@ -223,15 +230,36 @@ $endif$ $if(maxScale)$ maxScale: $maxScale$, $endif$ +$if(mathjax)$ + math: { + mathjax: 'https://cdnjs.cloudflare.com/ajax/libs/mathjax/2.7.0/MathJax.js', + config: 'TeX-AMS_HTML-full', + tex2jax: { + inlineMath: [['\\(','\\)']], + displayMath: [['\\[','\\]']], + balanceBraces: true, + processEscapes: false, + processRefs: true, + processEnvironments: true, + preview: 'TeX', + skipTags: ['script','noscript','style','textarea','pre','code'], + ignoreClass: 'tex2jax_ignore', + processClass: 'tex2jax_process' + }, + }, +$endif$ // Optional reveal.js plugins dependencies: [ { src: '$revealjs-url$/lib/js/classList.js', condition: function() { return !document.body.classList; } }, { src: '$revealjs-url$/plugin/zoom-js/zoom.js', async: true }, - $if(notes-server)$ +$if(notes-server)$ { src: '$revealjs-url$/socket.io/socker.io.js', async: true }, { src: '$revealjs-url$/plugin/notes-server/client.js', async: true }, - $endif$ +$endif$ +$if(mathjax)$ + { src: '$revealjs-url$/plugin/math/math.js', async: true }, +$endif$ { src: '$revealjs-url$/plugin/notes/notes.js', async: true } ] }); diff --git a/data/templates/default.rst b/data/templates/default.rst index 30005d19b..e9c0dc203 100644 --- a/data/templates/default.rst +++ b/data/templates/default.rst @@ -15,12 +15,6 @@ $if(date)$ $endif$ $endif$ -$if(math)$ -.. role:: math(raw) - :format: html latex -.. - -$endif$ $if(rawtex)$ .. role:: raw-latex(raw) :format: latex diff --git a/data/templates/default.rtf b/data/templates/default.rtf index 59e132b3f..a7f79376d 100644 --- a/data/templates/default.rtf +++ b/data/templates/default.rtf @@ -18,7 +18,7 @@ $if(spacer)$ {\pard \ql \f0 \sa180 \li0 \fi0 \par} $endif$ $if(toc)$ -$toc$ +$table-of-contents$ $endif$ $for(include-before)$ $include-before$ diff --git a/data/templates/default.s5 b/data/templates/default.s5 index 6ab482864..e9c36b4d4 100644 --- a/data/templates/default.s5 +++ b/data/templates/default.s5 @@ -15,13 +15,18 @@ $if(keywords)$ <meta name="keywords" content="$for(keywords)$$keywords$$sep$, $endfor$" /> $endif$ <title>$if(title-prefix)$$title-prefix$ – $endif$$pagetitle$</title> - <style type="text/css">code{white-space: pre;}</style> + <style type="text/css"> + code{white-space: pre-wrap;} + span.smallcaps{font-variant: small-caps;} + span.underline{text-decoration: underline;} + div.column{display: inline-block; vertical-align: top; width: 50%;} +$if(quotes)$ + q { quotes: "“" "”" "‘" "’"; } +$endif$ + </style> <!-- configuration parameters --> <meta name="defaultView" content="slideshow" /> <meta name="controlVis" content="hidden" /> -$if(quotes)$ - <style type="text/css">q { quotes: "“" "”" "‘" "’"; }</style> -$endif$ $if(highlighting-css)$ <style type="text/css"> $highlighting-css$ @@ -59,7 +64,7 @@ $endfor$ </div> <div class="presentation"> $if(title)$ -<div class="titleslide slide"> +<div class="title-slide slide"> <h1 class="title">$title$</h1> $if(subtitle)$ <h2 class="subtitle">$subtitle$</h2> @@ -74,7 +79,7 @@ $endif$ $endif$ $if(toc)$ <div class="slide" id="$idprefix$TOC"> -$toc$ +$table-of-contents$ </div> $endif$ $body$ diff --git a/data/templates/default.slideous b/data/templates/default.slideous index 30c93567d..ad58272ae 100644 --- a/data/templates/default.slideous +++ b/data/templates/default.slideous @@ -16,10 +16,15 @@ $if(keywords)$ <meta name="keywords" content="$for(keywords)$$keywords$$sep$, $endfor$" /> $endif$ <title>$if(title-prefix)$$title-prefix$ – $endif$$pagetitle$</title> - <style type="text/css">code{white-space: pre;}</style> + <style type="text/css"> + code{white-space: pre-wrap;} + span.smallcaps{font-variant: small-caps;} + span.underline{text-decoration: underline;} + div.column{display: inline-block; vertical-align: top; width: 50%;} $if(quotes)$ - <style type="text/css">q { quotes: "“" "”" "‘" "’"; }</style> + q { quotes: "“" "”" "‘" "’"; } $endif$ + </style> $if(highlighting-css)$ <style type="text/css"> $highlighting-css$ @@ -79,7 +84,7 @@ $endif$ $endif$ $if(toc)$ <div class="slide" id="$idprefix$TOC"> -$toc$ +$table-of-contents$ </div> $endif$ $body$ diff --git a/data/templates/default.slidy b/data/templates/default.slidy index cccf3537d..98b8d669d 100644 --- a/data/templates/default.slidy +++ b/data/templates/default.slidy @@ -16,10 +16,15 @@ $if(keywords)$ <meta name="keywords" content="$for(keywords)$$keywords$$sep$, $endfor$" /> $endif$ <title>$if(title-prefix)$$title-prefix$ – $endif$$pagetitle$</title> - <style type="text/css">code{white-space: pre;}</style> + <style type="text/css"> + code{white-space: pre-wrap;} + span.smallcaps{font-variant: small-caps;} + span.underline{text-decoration: underline;} + div.column{display: inline-block; vertical-align: top; width: 50%;} $if(quotes)$ - <style type="text/css">q { quotes: "“" "”" "‘" "’"; }</style> + q { quotes: "“" "”" "‘" "’"; } $endif$ + </style> $if(highlighting-css)$ <style type="text/css"> $highlighting-css$ @@ -65,7 +70,7 @@ $endif$ $endif$ $if(toc)$ <div class="slide" id="$idprefix$TOC"> -$toc$ +$table-of-contents$ </div> $endif$ $body$ |