Quarto — Technical Publishing System

Published

November 3, 2023

Modified

April 23, 2025

Installation

Install Quarto 1:

# ...check for dependencies
quarto check

# ...create a project skeleton in the working directory
quarto create-project
quarto render
$BROWSER quarto.html

…refer to the Quarto Guide for documentation

Documents

Title Block

Title block2 with Front Matter3:

title: title
subtitle: sub-title
categories:
  - one
  - two
date: 2024/05/20
date-modified: 2024/06/05
title-block-banner: true
toc-depth: 4
toc-expand: 3
abstract: >
  some lone text...
  over multiple lines..

Text

Colorize & style text with:

Some [underlined]{.underline} text.

Some [less visible text]{.text-primary .text-opacity-25}
  • Styling
    • .markexample text
    • .smallcpasexample caps text
    • .underlineexample text
  • Text color…
    • .text-mutedexample text
    • .text-primaryexample text
    • .text-secondaryexample text
    • .text-successexample text
  • Opacity…
    • .text-opacity-75example text
    • .text-opacity-50example text
    • .text-opacity-25example text

Configure text style with SCSS:

$primary:       $blue !default;
$secondary:     $red-600 !default;
$mark-bg:       $yellow-100 !default;

Tables4

Simple table

See @tbl-label

a | b
--|--
1 | 2
3 | 4

: Caption {#tbl-label tbl-colwidths="[75,25]"}

Cross-reference labels must start with the tbl- prefix

Set column width for all tables:

---
title: "My Document"
format: html
tbl-colwidths: [25,75]
---

Figures5

![alternative text](path/to/image.png){#fig-name width=80% fig-align="left"} 

Attributes (separated by spaces)

  • #fig-name cross-reference figures by adding an ID
    • …with the fig- prefix …referencing the figure using the @ prefix
  • width and height
    • …default unit is pixel (alternative percent or millimeters)
    • …if only width is specified then height is calculated automatically.
  • fig-align …center by default
  • fig-alt …alternative text to a figure
  • .lightbox …add lightbox styling and behavior to images 6

Code Blocks

Pandox syntax high-lighting7 for code blocks8:

# list themes for syntax high-lighting code
quarto pandoc --list-highlight-languages

HTML Themes