forked from AisjaThijssen/uvt-quarto-letter
-
Notifications
You must be signed in to change notification settings - Fork 1
/
README.qmd
57 lines (41 loc) · 1.66 KB
/
README.qmd
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
---
format: gfm
---
<!-- README.md is generated from README.qmd. Please edit that file -->
```{r}
#| include: false
# Create pdf and png version of template
library(tidyverse)
library(quarto)
library(magick)
# Render template
fs::dir_copy("_extensions/letter", "_extensions/tilburgsciencehub/letter")
quarto_render(input = "template.qmd")
fs::dir_delete("_extensions/tilburgsciencehub")
# Convert rendered PDF to PNG
image_read_pdf("template.pdf", pages = 1) |>
image_montage(geometry = "x500+25+35", tile = 1, bg = "grey92", shadow = TRUE) |>
image_convert(format = "png") |>
image_write("examples/template.png")
# Move pdf to examples folder
fs::file_move("template.pdf", "examples/template.pdf")
```
# Tilburg University Letter Format Template
This is a Quarto template that assists you in creating a letter on Tilburg University letterhead
## Creating a new letter
You can use this as a template to create a letter.
To do this, use the following command:
```bash
quarto use template tilburgsciencehub/uvt-quarto-letter
```
This will install the extension and create an example qmd file that you can use as a starting place for your letter.
## Installation for existing document
You may also use this format with an existing Quarto project or document.
From the quarto project or document directory, run the following command to install this format:
```bash
quarto install extension tilburgsciencehub/uvt-quarto-letter
```
## Adding Lato font to your LateX distribution
Download the font from google https://fonts.google.com/specimen/Lato and add the folder to the fonts folder in your local latex distribution.
## Example
[![](examples/template.png)](examples/template.pdf)