Skip to content

Commit

Permalink
Fix compilation errors when using danish preamble
Browse files Browse the repository at this point in the history
Also fixes various warnings
  • Loading branch information
halvko authored and SSoelvsten committed Dec 22, 2021
1 parent 447754e commit 3aafccd
Show file tree
Hide file tree
Showing 12 changed files with 17 additions and 24 deletions.
8 changes: 4 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -125,28 +125,28 @@ depends on where you have the preamble files located compared to your document.

**Case: Same folder**
```tex
\documentclass[a4, english]{article}
\documentclass[english]{article}
\input{preamble_en.tex}
```

**Case: Relative path**
```tex
\documentclass[a4, english]{article}
\documentclass[english]{article}
\usepackage{import}
\subimport{../preamble/}{preamble_en.tex}
```

**Case: Absolute path**
> **On Windows**
```tex
\documentclass[a4, english]{article}
\documentclass[english]{article}
\usepackage{import}
\import{C:/GitHub/LaTeX-Preamble_and_Examples/preamble/}{preamble_en.tex}
```

> **On Unix**
```tex
\documentclass[a4, english]{article}
\documentclass[english]{article}
\usepackage{import}
\import{/home/username/Documents/LaTeX-Preamble_and_Examples/preamble/}{preamble_en.tex}
```
Expand Down
Binary file modified documents/examples_article.pdf
Binary file not shown.
2 changes: 1 addition & 1 deletion documents/examples_article.tex
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@

\author{Steffan Sølvsten\footnote{Together with numerous many other beautiful
people at Aarhus Univesity.}}
\affil{Aarhus University \\ \mailto{[email protected]}}
\date{Aarhus University \\ \mailto{[email protected]} \\[\baselineskip] \today}

\begin{document}

Expand Down
Binary file modified documents/template_blank.pdf
Binary file not shown.
2 changes: 1 addition & 1 deletion documents/template_blank.tex
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
% ---------------------------------------------------------------------------- %
% Load preamble
% ---------------------------------------------------------------------------- %
\documentclass[a4, english]{article}
\documentclass[english]{article}

% Import from absolute path:
%\usepackage{import}
Expand Down
Binary file modified documents/template_dissertation.pdf
Binary file not shown.
7 changes: 3 additions & 4 deletions documents/template_dissertation.tex
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
% ---------------------------------------------------------------------------- %
% Load base preamble
% ---------------------------------------------------------------------------- %
\documentclass[a4, english, twoside]{book}
\documentclass[english, twoside]{book}

% Import from the same folder
%\input{preamble_en.tex}
Expand Down Expand Up @@ -73,9 +73,8 @@
% ---------------------------------------------------------------------------- %
% Authors
% ---------------------------------------------------------------------------- %
\author{Steffan Sølvsten}
\author{Lorem Ipsum}
\affil{Aarhus University \\ \mailto{{soelvsten,ipsum}@cs.au.dk}}
\author{Steffan Sølvsten and Lorem Ipsum}
\date{Aarhus University \\ \mailto{{soelvsten,ipsum}@cs.au.dk} \\[2\baselineskip] \today}

% ---------------------------------------------------------------------------- %
% Main content
Expand Down
Binary file modified documents/template_report.pdf
Binary file not shown.
7 changes: 3 additions & 4 deletions documents/template_report.tex
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
% ---------------------------------------------------------------------------- %
% Load base preamble
% ---------------------------------------------------------------------------- %
\documentclass[a4, english, twoside]{article}
\documentclass[english, twoside]{article}

% Import from the same folder
%\input{preamble_en.tex}
Expand Down Expand Up @@ -72,9 +72,8 @@
% ---------------------------------------------------------------------------- %
% Authors
% ---------------------------------------------------------------------------- %
\author{Steffan Sølvsten}
\author{Lorem Ipsum}
\affil{Aarhus University \\ \mailto{{soelvsten,ipsum}@cs.au.dk}}
\author{Steffan Sølvsten and Lorem Ipsum}
\date{Aarhus University \\ \mailto{{soelvsten,ipsum}@cs.au.dk} \\[\baselineskip] \today}

% ---------------------------------------------------------------------------- %
% Main content
Expand Down
6 changes: 3 additions & 3 deletions preamble/lang_dk.tex
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
\usepackage[danish]{babel}
\renewcommand{\danishhyphenmins}{22}

\renewcommand\Authand{ og }
\renewcommand\Authands{, og }
\renewcommand\Affilfont{\small}
\newcommand\Authand{ og }
\newcommand\Authands{, og }
\newcommand\Affilfont{\small}

5 changes: 1 addition & 4 deletions preamble/preamble_base_p1.tex
Original file line number Diff line number Diff line change
Expand Up @@ -255,8 +255,5 @@

\declare{}

% import standard variables
\input{lang_en.tex}

% FROM HERE LOAD preamble_base_p2.tex with any custom settings in between!
% FROM HERE LOAD lang_en.tex/lang_dk.tex and then preamble_base_p2.tex.

4 changes: 1 addition & 3 deletions preamble/preamble_base_p2.tex
Original file line number Diff line number Diff line change
@@ -1,6 +1,4 @@
% LOAD THIS AFTER preamble_base_p1.tex !

\usepackage{authblk}
% LOAD THIS AFTER lang_{dk,en}.tex !

% ---------------------------------------------------------------------------- %
% lstlisting
Expand Down

0 comments on commit 3aafccd

Please sign in to comment.