.docname {Primitive functions}
.include {docs}

Primitive functions return elements that back standard Markdown syntax. Each one accepts parameters that plain Markdown may not, and can be intercepted via [`.extend`](extending-functions.qd) to customize their behavior and appearance across the entire document, even if created via standard Markdown syntax.

For example, extending `.heading` affects every `#`, `##`, and so on. Extending `.math` affects every `$ ... $` and `$$$ ... $$$`. See [*Element styling*](element-styling.qd) for the full mechanism.

## Available primitives

- [**`.heading`**](headings.qd) .docslink {quarkdown-stdlib/com.quarkdown.stdlib.module.Primitives/heading.html} backs `#`, `##`, ... headings. Exposes explicit control over depth, numbering, page breaks, and cross-reference identifiers.

- **`.paragraph`** .docslink {quarkdown-stdlib/com.quarkdown.stdlib.module.Primitives/paragraph.html} backs regular paragraphs.

- **`.link`** .docslink {quarkdown-stdlib/com.quarkdown.stdlib.module.Primitives/link.html} backs `[label](url "title")`.

- **`.image`** .docslink {quarkdown-stdlib/com.quarkdown.stdlib.module.Primitives/image.html} backs `![alt](url "title")`, with additional control over figure wrapping and [media storage](media-storage.qd).

- [**`.figure`**](figure.qd) .docslink {quarkdown-stdlib/com.quarkdown.stdlib.module.Primitives/figure.html} backs the block that wraps an image or other content.

- [**`.math`**](tex-formulae.qd) .docslink {quarkdown-stdlib/com.quarkdown.stdlib.module.Primitives/math.html} backs `$ ... $` and `$$$ ... $$$` formulas.

- [**`.pagebreak`**](page-break.qd) .docslink {quarkdown-stdlib/com.quarkdown.stdlib.module.Primitives/pagebreak.html} backs `<<<`. Can be extended to decorate every forced page break in the document.
