Control font size code output #11469
Unanswered
JackCaster
asked this question in
Q&A
Replies: 1 comment 2 replies
-
You could leverage the ---
title: Monospace font size
format: pdf
monofont: 'Latin Modern Mono'
monofontoptions: 'Scale=0.2'
keep-tex: true
---
```r
1 + 1
```
This works because the template is using If you want more targeted, your solution seems ok to me. FWIW This is Pandoc behavior here: jgm/pandoc#5491 The pandoc issue refers to a Lua filter : https://github.com/chdemko/pandoc-latex-fontsize. It is a JSON filter, and could work with Quarto, though maybe a Lua filter port exists. Anyhow, hope this helps understand. |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Description
Is it possible to change the font size of the output for a code block? By default, it is too large. My workaround is, for a PDF/Latex output, is to redefine the Highlight Verbatim environment (as found in the generated latex file) with
but I find this solution a bit clunky. It would be nice to be able to redefine the font size with a YAML option, for example.
Beta Was this translation helpful? Give feedback.
All reactions