transfer from old repo

This commit is contained in:
Andreas Gammelgaard Damsbo 2026-08-19 09:27:27 +02:00
commit 277e2b8cf3
No known key found for this signature in database
1111 changed files with 83736 additions and 0 deletions

View file

@ -0,0 +1,53 @@
title: Tufte Quarto
author: Fred Guth
version: 1.1.0
quarto-version: ">=1.2.215"
contributes:
project:
project:
type: book
output-dir: docs
format:
html:
page-layout: full
reference-location: margin
citation-location: block
title-block-style: none
css: styles.css
number-sections: false
linkcolor: Maroon
backgroundcolor: FloralWhite
sidebarbackgroundcolor: FloralWhite
mainfont: "heuristica"
toc-location: left
toc-title: "Contents"
default-image-extension: svg
pdf:
reference-location: margin
citation-location: margin
fig-cap-location: bottom
documentclass: tufte-book
classoption: [sfsidenotes]
number-sections: false
format-resources:
- tufte-book.cls
- tufte-common.def
- tufte.bst
template-partials: # replaces
- "partials/title.tex"
- "partials/before-body.tex"
include-in-header: #adds
- "partials/in-header.tex"
- "partials/definitions.tex"
include-after-body: #adds
- "partials/after-body.tex"
toc-depth: 2
toc-title: "Contents"
indent: 0px
biblio-style: dinat
# mainfont: "Minion Pro"
mainfont: "ETbb"
sansfont: "TeX Gyre Heros"
sansfontoptions: "Scale=MatchUppercase"
default-image-extension: pdf

View file

@ -0,0 +1,22 @@
\IfFileExists{Images/bookcover.pdf}{\includepdf{Images/bookcover.pdf}\clearpage}{}
$if(has-frontmatter)$
\frontmatter
$endif$
$if(title)$
$if(beamer)$
\frame{\titlepage}
$else$
\maketitle
\pagenumbering{gobble}
\IfFileExists{01-Front/copyright.tex}{\input{01-Front/copyright.tex}\clearpage}{}
\IfFileExists{01-Front/dedication.tex}{\input{01-Front/dedication.tex}\clearpage}{}
\IfFileExists{01-Front/epigraph.tex}{\input{01-Front/epigraph.tex}\clearpage}{}
$endif$
$if(abstract)$
\begin{abstract}
$abstract$
\end{abstract}
$endif$
$endif$
\pagenumbering{arabic}

View file

@ -0,0 +1,108 @@
% DEFINITIONS
% The fancyvrb package lets us customize the formatting of verbatim
% environments. We use a slightly smaller font.
\usepackage{fancyvrb}
\fvset{fontsize=\normalsize}
%%
% Prints argument within hanging parentheses (i.e., parentheses that take
% up no horizontal space). Useful in tabular environments.
\newcommand{\hangp}[1]{\makebox[0pt][r]{(}#1\makebox[0pt][l]{)}}
%%
% Prints an asterisk that takes up no horizontal space.
% Useful in tabular environments.
\newcommand{\hangstar}{\makebox[0pt][l]{*}}
%%
% Prints a trailing space in a smart way.
\usepackage{xspace}
% Prints the month name (e.g., January) and the year (e.g., 2008)
\newcommand{\monthyear}{%
\ifcase\month\or January\or February\or March\or April\or May\or June\or
July\or August\or September\or October\or November\or
December\fi\space\number\year
}
% Prints an epigraph and speaker in sans serif, all-caps type.
\newcommand{\epigraph}[2]{%
\begin{fullwidth}
\begin{flushright}
\sffamily\fontsize{8}{10}\selectfont
\sffamily\footnotesize
\begin{doublespace}
\vspace{-8cm}\noindent\allcaps{#1}\\% epigraph
\noindent\allcaps{#2}\\% author
\end{doublespace}
\vspace{5.1cm}
\end{flushright}
\end{fullwidth}
\normalfont
}
\newcommand{\blankpage}{\newpage\hbox{}\thispagestyle{empty}\newpage}
% insert 4cm before quote
\renewenvironment{quote}{
\list{}{\leftmargin=3.5cm\topsep=0pt}
\item\relax\small\itshape
}
{\endlist}
% change chapter formatting
\titlespacing*{\chapter}{0pt}{5cm}{1cm}
% \titlespacing*{\section}{0pt}{.6em}{.3em}
% \titlespacing*{\subsection}{0pt}{.4em}{.2em}
\titlespacing*{\section}{0pt}{0pt}{0pt}
\titlespacing*{\subsection}{0pt}{0pt}{0pt}
% Change Figure Caption in the Margin size
% \renewenvironment{@tufte@margin@float}[2][-1.2ex]%
% {\FloatBarrier% process all floats before this point so the figure/table numbers stay in order.
% \begin{lrbox}{\@tufte@margin@floatbox}%
% \begin{minipage}{\marginparwidth}%
% \@tufte@caption@font\footnotesize% <-- Add fontnotesize
% \def\@captype{#2}%
% \hbox{}\vspace*{#1}%
% \@tufte@caption@justification%
% \@tufte@margin@par%
% \noindent\normalsize%<-- restored size
% }
% {\end{minipage}%
% \end{lrbox}%
% \marginpar{\usebox{\@tufte@margin@floatbox}}%
% }
% \renewcommand\footnotesize{%
% \@setfontsize\footnotesize\@viiipt{9}%
% \abovedisplayskip 5\p@ \@plus2\p@ \@minus4\p@
% \abovedisplayshortskip \z@ \@plus\p@
% \belowdisplayshortskip 2.8\p@ \@plus\p@ \@minus2\p@
% \def\@listi{\leftmargin\leftmargini
% \topsep 2.5\p@ \@plus\p@ \@minus\p@
% \parsep 2\p@ \@plus\p@ \@minus\p@
% \itemsep \parsep}%
% \belowdisplayskip \abovedisplayskip
% }
% % Define Tuftian float styles (with the caption in the margin)
% \newcommand{\floatc@tufteplain}[2]{%
% \begin{lrbox}{\@tufte@caption@box}%
% \begin{minipage}[\floatalignment]{\marginparwidth}\hbox{}%
% \footnotesize\@tufte@caption@font{\@fs@cfont #1:} #2\par\normalsize%
% \end{minipage}%
% \end{lrbox}%
% \smash{\hspace{\@tufte@caption@fill}\usebox{\@tufte@caption@box}}%
% }

View file

@ -0,0 +1,77 @@
% FIX Marginnote duplication
\usepackage{savesym}
\savesymbol{marginfigure}
\savesymbol{marginnote}
\savesymbol{sidenote}
%%%%%%%
% FIX Makeuppercase error
% FIX Font clash Math error
% See https://tex.stackexchange.com/q/202142/157312
%
\renewcommand{\textls}[2][5]{%
\begingroup\addfontfeatures{LetterSpace=#1}#2\endgroup
}
\renewcommand{\allcapsspacing}[1]{\textls[15]{#1}}
\renewcommand{\smallcapsspacing}[1]{\textls[10]{#1}}
\renewcommand{\allcaps}[1]{\textls[15]{\MakeTextUppercase{#1}}}
\renewcommand{\smallcaps}[1]{\smallcapsspacing{\scshape\MakeTextLowercase{#1}}}
\renewcommand{\textsc}[1]{\smallcapsspacing{\textsmallcaps{#1}}}
\PassOptionsToPackage{no-math}{fontspec}
% \usepackage[mathlf, minionint,footnotefigures, frenchmath]{MinionPro}
% \setmainfont{$$}
% \setsansfont{TeX Gyre Heros}[Scale=MatchUppercase]
\ExplSyntaxOn
\int_new:N \l_mathcode_minus_int
\int_new:N \l_mathcode_equal_int
\exp_args:Nx \AtBeginDocument {
\exp_not:n {
\int_set:Nn \l_mathcode_minus_int { \XeTeXmathcodenum `\- }
\int_set:Nn \l_mathcode_equal_int { \XeTeXmathcodenum `\= }
}
\mathcode \int_eval:n { `\- } = \number \mathcode `\- \scan_stop:
\mathcode \int_eval:n { `\= } = \number \mathcode `\= \scan_stop:
}
\AtBeginDocument {
\XeTeXmathcodenum `\- = \l_mathcode_minus_int
\XeTeXmathcodenum `\= = \l_mathcode_equal_int
}
\ExplSyntaxOff
\usepackage[italic]{mathastext}
% \setromanfont{TeX Gyre Termes}
%%%%%%%
\usepackage{pdfpages} % for cover page
\graphicspath{{Images/}} % Make Images/ default figure path
\setlength{\parindent}{0pt}%
\setlength{\RaggedRightParindent}{0pt}
\setlength{\JustifyingParindent}{0pt}%
\setlength{\parskip}{\baselineskip}
%%
% Produces a full title page
\renewcommand{\maketitlepage}[0]{%
\cleardoublepage%
{%
\sffamily%
\begin{fullwidth}%
\fontsize{12}{14}\selectfont\par\noindent\textcolor{darkgray}{\allcaps{\thanklessauthor}}%
\vspace{12.5pc}%
\fontsize{20}{28}\selectfont\par\noindent\textcolor{darkgray}{\allcaps{\thanklesstitle}}%
\vfill%
\fontsize{10}{12}\selectfont\par\noindent\allcaps{\thanklesspublisher}%
\end{fullwidth}%
}
\thispagestyle{empty}%
\clearpage%
}

View file

@ -0,0 +1,17 @@
% TITLE PAGE
$if(book.title)$
\title[$book.title-short$]{$title$}
$endif$
$if(book.author)$
\author{$author$}
$endif$
$if(book.publisher)$
\publisher{$book.publisher$}
$endif$

View file

@ -0,0 +1,166 @@
.column-margin figcaption, .margin-caption, div.aside, aside, .column-margin {
color: #5a6570;
font-size: .625rem;
}
.sidebar-title {
margin-top: .25rem;
padding-bottom: .5rem;
font-size: .76rem;
line-height: 1rem;
visibility: visible;
}
.sidebar-item-container .chapter-number {
color: #212529;
font-size: .7rem;
}
.title .chapter-number {
color: #212529;
font-size: 1.5rem;
margin-right: 2rem;
}
.header-section-number {
color: #5a6570;
font-size: 1.3rem;
margin-right: 2rem;
}
body {
font-size: 16px;
line-height: 24px;
quotes: "‘" "’";
}
/* h1 {
font-family: 'Minion Pro', 'Crimson', serif;
font-style: italic;
padding-bottom: 1rem;
letter-spacing: 0rem;
} */
header .chapter-title {
font-family: 'Minion Pro', 'Crimson', serif;
font-style: italic;
text-transform: none;
font-size: 2.2rem;
letter-spacing: normal;
}
.sidebar {
font-family: sans-serif;
}
/* Hide scrollbar for Chrome, Safari and Opera */
.sidebar::-webkit-scrollbar {
display: none;
}
/* Hide scrollbar for IE, Edge and Firefox */
.sidebar {
-ms-overflow-style: none; /* IE and Edge */
scrollbar-width: none; /* Firefox */
}
.navbar-brand {
font-family: helvetica, monospace;
font-style: normal;
text-transform: uppercase;
letter-spacing: .11em;
line-height: 1.5rem;
font-size: 1em;
}
.sidebar-header > div > div > a > i {
display: none
}
.navbar-brand > a{
color: maroon;
}
.sidebar nav[role=doc-toc] ul {
font-size: 14px;
}
.sidebar nav[role=doc-toc] ul>li>a.active {
border-left: 1px solid maroon;
color: maroon !important;
}
.sidebar nav[role=doc-toc] ul>li>ul>li>a.active {
border-left: 1px solid maroon;
color: maroon !important;
}
.sidebar-title {
font-family: helvetica, monospace;
font-style: normal;
text-transform: uppercase;
letter-spacing: .11em;
line-height: 1.12rem;
font-size: .48rem;
}
.quarto-secondary-nav-title, .title {
/* font-family: 'Minion Pro', 'Crimson', serif; */
font-family: helvetica, monospace;
font-style: normal;
text-transform: uppercase;
letter-spacing: .125em;
line-height: 1.25em;
font-size: 1.5rem;
padding-top: .825rem
}
.quarto-secondary-nav-title {
font-size: 1.1rem;
}
.blockquote {
border-left: none;
}
.blockquote p {
font-size: smaller;
color: #5a6570;
font-style: italic;
}
@media (min-width:1280px) {
.blockquote p {
padding-left: 4cm;
}
}
.panel-caption, .figure-caption, figcaption {
color: #5a6570;
font-size: .825rem;
margin-bottom: .825rem;
}
.theorem-title {
margin-right: 1.5rem;
}
#fig-cover img {
background-color: white;
border: 1px solid #555;
}
.figure-img {
margin: auto;
}
#quarto-sidebar {
background: transparent;
}
div.sidebar-item-container .active, div.sidebar-item-container :hover, div.sidebar-item-container .show>.nav-link, div.sidebar-item-container .sidebar-link>code {
color: maroon;
}
nav[role=doc-toc] {
padding-bottom: 100px;
}
.sans-serif {
font-family: helvetica, monospace;
font-style: normal;
text-transform: uppercase;
}

View file

@ -0,0 +1,88 @@
\NeedsTeXFormat{LaTeX2e}[1994/06/01]
\ProvidesClass{tufte-book}[2015/06/30 v3.5.3 Tufte-book class]
%%
% Declare we're tufte-book
\newcommand{\@tufte@class}{book}% the base LaTeX class (defaults to the book style)
\newcommand{\@tufte@pkgname}{tufte-book}% the name of the package (defaults to tufte-handout)
%%
% Load the common style elements
\input{tufte-common.def}
%%
% Set up any book-specific stuff now
%%
% The front matter in Tufte's /Beautiful Evidence/ contains everything up
% to the opening page of Chapter 1. The running heads, when they appear,
% contain only the (arabic) page number in the outside corner.
%\newif\if@mainmatter \@mainmattertrue
\renewcommand\frontmatter{%
\if@openright%
\cleardoublepage%
\else%
\clearpage%
\fi%
\@mainmatterfalse%
\pagenumbering{arabic}%
%\pagestyle{plain}%
\fancyhf{}%
\ifthenelse{\boolean{@tufte@twoside}}%
{\fancyhead[LE,RO]{\thepage}}%
{\fancyhead[RE,RO]{\thepage}}%
}
%%
% The main matter in Tufte's /Beautiful Evidence/ doesn't restart the page
% numbering---it continues where it left off in the front matter.
\renewcommand\mainmatter{%
\if@openright%
\cleardoublepage%
\else%
\clearpage%
\fi%
\@mainmattertrue%
\fancyhf{}%
\ifthenelse{\boolean{@tufte@twoside}}%
{% two-side
\renewcommand{\chaptermark}[1]{\markboth{##1}{}}%
\fancyhead[LE]{\thepage\quad\smallcaps{\newlinetospace{\plaintitle}}}% book title
\fancyhead[RO]{\smallcaps{\newlinetospace{\leftmark}}\quad\thepage}% chapter title
}%
{% one-side
\fancyhead[RE,RO]{\smallcaps{\newlinetospace{\plaintitle}}\quad\thepage}% book title
}%
}
%%
% The back matter contains appendices, indices, glossaries, endnotes,
% bibliographies, list of contributors, illustration credits, etc.
\renewcommand\backmatter{%
\if@openright%
\cleardoublepage%
\else%
\clearpage%
\fi%
\@mainmatterfalse%
}
%%
% Only show the chapter titles in the table of contents
\setcounter{tocdepth}{0}
%%
% If there is a `tufte-book-local.sty' file, load it.
\IfFileExists{tufte-book-local.tex}{%
\@tufte@info@noline{Loading tufte-book-local.tex}%
\input{tufte-book-local}%
}{}
%%
% End of file
\endinput

File diff suppressed because it is too large Load diff

View file

@ -0,0 +1,39 @@
\NeedsTeXFormat{LaTeX2e}[1994/06/01]
\ProvidesClass{tufte-handout}[2015/06/21 v3.5.2 Tufte-handout class]
%%
% Declare we're tufte-handout
\newcommand{\@tufte@class}{article}% the base LaTeX class (defaults to the article/handout style)
\newcommand{\@tufte@pkgname}{tufte-handout}% the name of the package (defaults to tufte-handout)
%%
% Load the common style elements
\input{tufte-common.def}
%%
% Set up any handout-specific stuff now
%%
% Abstract
% TODO The abstract should be printed on its own page of the `titlepage'
% option was specified.
\renewenvironment{abstract}
{\begin{quotation}\if@tufte@sfsidenotes\begin{sffamily}\fi}
{\if@tufte@sfsidenotes\end{sffamily}\fi\end{quotation}}
%%
% If there is a `tufte-handout-local.tex' file, load it.
\IfFileExists{tufte-handout-local.tex}{%
\input{tufte-handout-local}%
\@tufte@info@noline{Loading tufte-handout-local.tex}%
}{}
%%
% End of file
\endinput

File diff suppressed because it is too large Load diff

File diff suppressed because it is too large Load diff